added additional explicit returnvalues

This commit is contained in:
Robin Müller 2022-05-12 17:05:58 +02:00
parent c4c340fde1
commit b8cfb36426
No known key found for this signature in database
GPG Key ID: 11D4952C8CCEF814
2 changed files with 7 additions and 2 deletions

View File

@ -39,6 +39,11 @@ class Service11TelecommandScheduling final : public PusServiceBase {
static constexpr ReturnValue_t INVALID_TYPE_TIME_WINDOW =
HasReturnvaluesIF::makeReturnCode(CLASS_ID, 1);
static constexpr ReturnValue_t TIMESHIFTING_NOT_POSSIBLE =
HasReturnvaluesIF::makeReturnCode(CLASS_ID, 2);
static constexpr ReturnValue_t INVALID_RELATIVE_TIME =
HasReturnvaluesIF::makeReturnCode(CLASS_ID, 3);
// The types of PUS-11 subservices
enum Subservice : uint8_t {
ENABLE_SCHEDULING = 1,

View File

@ -345,7 +345,7 @@ inline ReturnValue_t Service11TelecommandScheduling<MAX_NUM_TCS>::doTimeshiftAct
"Service11TelecommandScheduling::doTimeshiftActivity: Either 0 or more than 1 TCs found. "
"No explicit timeshifting possible\n");
#endif
return RETURN_FAILED;
return TIMESHIFTING_NOT_POSSIBLE;
}
// temporarily hold the item
@ -380,7 +380,7 @@ inline ReturnValue_t Service11TelecommandScheduling<MAX_NUM_TCS>::doFilterTimesh
return result;
}
if (relativeTime == 0) {
return RETURN_FAILED;
return INVALID_RELATIVE_TIME;
}
// Do time window