In the SU-2.5 step 3 we need to verify that OTA Requestor sends ApplyUpdateRequest again after 120 seconds of delay.
Implement a named pipe on the OTA Provider side that registers the ApplyUpdateRequest cmd retrieval.
Example :
void OTAProviderExample::HandleApplyUpdateRequest(app::CommandHandler * commandObj,
const app::ConcreteCommandPath & commandPath,
const ApplyUpdateRequest::DecodableType & commandData)
{
// ... existing code ...
ChipLogDetail(SoftwareUpdate, "%s: token: %s, version: %" PRIu32, __FUNCTION__, tokenBuf, commandData.newVersion);
// NEW: Send notification through named pipe if available
if (mPipeDelegate && mPipeDelegate->GetPipes())
{
Json::Value notification;
notification["Event"] = "ApplyUpdateRequest";
notification["Version"] = commandData.newVersion;
notification["Token"] = tokenBuf;
mPipeDelegate->GetPipes()->WriteToOutPipe(Json::writeString(notification));
}
// ... rest of existing code ...
}
In the SU-2.5 step 3 we need to verify that OTA Requestor sends
ApplyUpdateRequestagain after 120 seconds of delay.Implement a named pipe on the OTA Provider side that registers the
ApplyUpdateRequestcmd retrieval.Example :