File tree 2 files changed +7
-7
lines changed
clusters/icd-management-server
2 files changed +7
-7
lines changed Original file line number Diff line number Diff line change @@ -425,14 +425,13 @@ bool emberAfIcdManagementClusterUnregisterClientCallback(CommandHandler * comman
425
425
bool emberAfIcdManagementClusterStayActiveRequestCallback (CommandHandler * commandObj, const ConcreteCommandPath & commandPath,
426
426
const Commands::StayActiveRequest::DecodableType & commandData)
427
427
{
428
+ // Note: We only need this #if statement for platform examples that enable the ICD management server without building the sample
429
+ // as an ICD. Since this is not spec compliant, we should remove this #if statement once we stop compiling the ICD management
430
+ // server in those examples.
428
431
#if CHIP_CONFIG_ENABLE_ICD_SERVER
429
432
IcdManagement::Commands::StayActiveResponse::Type response;
430
433
response.promisedActiveDuration = Server::GetInstance ().GetICDManager ().StayActiveRequest (commandData.stayActiveDuration );
431
434
commandObj->AddResponse (commandPath, response);
432
- #else
433
- // Note: We only keep this line around for platform examples that enable the ICD management server without building the sample
434
- // as an ICD.
435
- commandObj->AddStatus (commandPath, InteractionModel::Status::UnsupportedCommand);
436
435
#endif // CHIP_CONFIG_ENABLE_ICD_SERVER
437
436
return true ;
438
437
}
Original file line number Diff line number Diff line change @@ -61,7 +61,7 @@ class ICDConfigurationData
61
61
62
62
System::Clock::Milliseconds16 GetActiveModeThreshold () { return mActiveThreshold ; }
63
63
64
- System::Clock::Milliseconds32 GetMaxStayActiveDuration () { return kMaxStayActiveDuration ; }
64
+ System::Clock::Milliseconds32 GetMaxStayActiveDuration () { return kMaxGuaranteedStayActiveDuration ; }
65
65
66
66
Protocols::SecureChannel::CheckInCounter & GetICDCounter () { return mICDCounter ; }
67
67
@@ -125,8 +125,9 @@ class ICDConfigurationData
125
125
126
126
static constexpr System::Clock::Seconds32 kMaxIdleModeDuration = System::Clock::Seconds32(18 * kSecondsPerHour );
127
127
static constexpr System::Clock::Seconds32 kMinIdleModeDuration = System::Clock::Seconds32(1 );
128
- // As defined in the spec, the maximum duration for the StayActiveDuration is 30s (spec 7.5.1)
129
- static constexpr System::Clock::Milliseconds32 kMaxStayActiveDuration = System::Clock::Milliseconds32(30000 );
128
+ // As defined in the spec, the maximum guaranteed duration for the StayActiveDuration is 30s "Matter Application
129
+ // Clusters: 9.17.7.5.1. PromisedActiveDuration Field"
130
+ static constexpr System::Clock::Milliseconds32 kMaxGuaranteedStayActiveDuration = System::Clock::Milliseconds32(30000 );
130
131
131
132
static_assert ((CHIP_CONFIG_ICD_IDLE_MODE_DURATION_SEC) <= kMaxIdleModeDuration.count(),
132
133
"Spec requires the IdleModeDuration to be equal or inferior to 64800s.");
You can’t perform that action at this time.
0 commit comments