Skip to content

Commit

Permalink
Increase command timeouts for commissioning. (#14433)
Browse files Browse the repository at this point in the history
  • Loading branch information
cecille authored and pull[bot] committed Jan 30, 2024
1 parent 0338623 commit 1540311
Showing 1 changed file with 4 additions and 9 deletions.
13 changes: 4 additions & 9 deletions src/controller/AutoCommissioner.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -241,15 +241,10 @@ void AutoCommissioner::StartCommissioning(CommissioneeDeviceProxy * proxy)

Optional<System::Clock::Timeout> AutoCommissioner::GetCommandTimeout(CommissioningStage stage)
{
switch (stage)
{
case CommissioningStage::kWiFiNetworkEnable:
case CommissioningStage::kThreadNetworkEnable:
return MakeOptional(System::Clock::Timeout(System::Clock::Seconds16(30)));
default:
// Use default timeout specified in the IM.
return NullOptional;
}
// Per spec, all commands that are sent with the arm failsafe held need at least a 30s timeout. Using 30s everywhere for
// simplicity. 30s appears to be sufficient for long-running network commands (enable wifi and enable thread), but we may wish
// to increase the timeout for those commissioning stages at a later time.
return MakeOptional(System::Clock::Timeout(System::Clock::Seconds16(30)));
}

CHIP_ERROR AutoCommissioner::NOCChainGenerated(ByteSpan noc, ByteSpan icac, ByteSpan rcac, AesCcm128KeySpan ipk,
Expand Down

0 comments on commit 1540311

Please sign in to comment.