From 7d9be35cb4d988b473d82a80a168076e4132ad24 Mon Sep 17 00:00:00 2001 From: meggert Date: Wed, 15 Mar 2023 10:36:25 +0100 Subject: [PATCH 1/2] reset relevant datasets on shutdown --- mission/devices/RwHandler.cpp | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/mission/devices/RwHandler.cpp b/mission/devices/RwHandler.cpp index 7f82b202..e70152dd 100644 --- a/mission/devices/RwHandler.cpp +++ b/mission/devices/RwHandler.cpp @@ -24,7 +24,6 @@ RwHandler::RwHandler(object_id_t objectId, object_id_t comIF, CookieIF* comCooki sif::error << "RwHandler: Invalid gpio communication interface" << std::endl; } } - RwHandler::~RwHandler() {} void RwHandler::doStartUp() { @@ -43,6 +42,17 @@ void RwHandler::doShutDown() { } internalState = InternalState::DEFAULT; updatePeriodicReply(false, rws::REPLY_ID); + { + PoolReadGuard pg(&statusSet); + statusSet.currSpeed = 0.0; + statusSet.referenceSpeed = 0.0; + statusSet.state = 0; + statusSet.setValidity(false, true); + } + { + PoolReadGuard pg(&tmDataset); + tmDataset.setValidity(false, true); + } // The power switch is handled by the assembly, so we can go off here directly. setMode(MODE_OFF); } -- 2.43.0 From bab0bbf82d9f175123a6c41b98d4295a4e5d2431 Mon Sep 17 00:00:00 2001 From: meggert Date: Wed, 15 Mar 2023 10:38:00 +0100 Subject: [PATCH 2/2] changelog --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 3c1891d6..8bc96840 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,10 @@ will consitute of a breaking change warranting a new major release: # [unreleased] +## Changed + +- Telemetry relevant datasets for the RWs are now set invalid and partially reset on shotdown. + # [v1.37.2] 2023-03-14 - Changed `PoolManager` bugfix implementation in the FSFW. -- 2.43.0