diff --git a/Sts1CobcSw/EduCommunicationErrorThread.cpp b/Sts1CobcSw/EduCommunicationErrorThread.cpp index 27fa39f9..6ea869ba 100644 --- a/Sts1CobcSw/EduCommunicationErrorThread.cpp +++ b/Sts1CobcSw/EduCommunicationErrorThread.cpp @@ -58,21 +58,9 @@ class EduCommunicationErrorThread : public RODOS::StaticThread } } eduCommunicationErrorThread; - -// TODO: Think about whether this is the right way to declare, design, use, etc. this -class ResumeEduErrorCommunicationThread : public RODOS::TimeEvent -{ -public: - auto handle() -> void override - { - eduCommunicationErrorThread.resume(); - RODOS::PRINTF("[EduCommunicationErrorThread] EduCommunicationThread resumed\n"); - } -} resumeEduErrorCommunicationThread; - - -auto ResumeEduErrorCommunicationThread() -> void +auto ResumeEduCommunicationErrorThread() -> void { - resumeEduErrorCommunicationThread.handle(); + eduCommunicationErrorThread.resume(); + RODOS::PRINTF("[EduCommunicationErrorThread] EduCommunicationErrorThread resumed\n"); } } diff --git a/Sts1CobcSw/EduCommunicationErrorThread.hpp b/Sts1CobcSw/EduCommunicationErrorThread.hpp index 091d4b57..aa20d3cc 100644 --- a/Sts1CobcSw/EduCommunicationErrorThread.hpp +++ b/Sts1CobcSw/EduCommunicationErrorThread.hpp @@ -11,5 +11,5 @@ namespace sts1cobcsw extern std::int32_t eduCommunicationErrorCounter; -auto ResumeEduErrorCommunicationThread() -> void; +auto ResumeEduCommunicationErrorThread() -> void; } diff --git a/Sts1CobcSw/EduListenerThread.cpp b/Sts1CobcSw/EduListenerThread.cpp index 4bb05a6e..1f3b7f41 100644 --- a/Sts1CobcSw/EduListenerThread.cpp +++ b/Sts1CobcSw/EduListenerThread.cpp @@ -69,7 +69,7 @@ class EduListenerThread : public StaticThread<> // RODOS::PRINTF( // "[EduListenerThread] Edu communication error after call to // GetStatus().\n"); - ResumeEduErrorCommunicationThread(); + ResumeEduCommunicationErrorThread(); } else { @@ -117,7 +117,7 @@ class EduListenerThread : public StaticThread<> "[EduListenerThread] Communication error after call to " "ReturnResult().\n"); */ - ResumeEduErrorCommunicationThread(); + ResumeEduCommunicationErrorThread(); } else { diff --git a/Sts1CobcSw/EduProgramQueueThread.cpp b/Sts1CobcSw/EduProgramQueueThread.cpp index 48c56fef..5b29676b 100644 --- a/Sts1CobcSw/EduProgramQueueThread.cpp +++ b/Sts1CobcSw/EduProgramQueueThread.cpp @@ -109,7 +109,7 @@ class EduProgramQueueThread : public RODOS::StaticThread RODOS::PRINTF("UpdateTime error code : %d\n", errorCode); RODOS::PRINTF( "[EduProgramQueueThread] Communication error after call to UpdateTime().\n"); - ResumeEduErrorCommunicationThread(); + ResumeEduCommunicationErrorThread(); } auto startDelay2 = ComputeStartDelay(); @@ -143,7 +143,7 @@ class EduProgramQueueThread : public RODOS::StaticThread RODOS::PRINTF( "[EduProgramQueueThread] Communication error after call to " "ExecuteProgram().\n"); - ResumeEduErrorCommunicationThread(); + ResumeEduCommunicationErrorThread(); } else { @@ -179,21 +179,9 @@ auto ComputeStartDelay() -> std::int64_t return startDelay; } - -// TODO: Think about whether this is the right way to declare, design, use, etc. this -class ResumeEduProgramQueueThreadEvent : public RODOS::TimeEvent -{ -public: - auto handle() -> void override - { - eduProgramQueueThread.resume(); - RODOS::PRINTF("EduProgramQueueThread resumed from me\n"); - } -} resumeEduProgramQueueThreadEvent; - - auto ResumeEduProgramQueueThread() -> void { - resumeEduProgramQueueThreadEvent.handle(); + eduProgramQueueThread.resume(); + RODOS::PRINTF("[EduProgramQueueThread] EduProgramQueueThread resumed\n"); } }