new generic freertos task interface

This commit is contained in:
2020-07-12 18:01:09 +02:00
parent 99aef0cf28
commit b4f292f3d7
6 changed files with 31 additions and 7 deletions

View File

@ -15,7 +15,15 @@ public:
static const ReturnValue_t RETURN_FAILED = 1;
virtual ~HasReturnvaluesIF() {}
static ReturnValue_t makeReturnCode(uint8_t interfaceId, uint8_t number) {
/**
* It is discouraged to use the input parameters 0,0 and 0,1 as this
* will generate the RETURN_OK and RETURN_FAILED returnvalues.
* @param interfaceId
* @param number
* @return
*/
static constexpr ReturnValue_t makeReturnCode(uint8_t interfaceId,
uint8_t number) {
return (interfaceId << 8) + number;
}
};