1
0
forked from fsfw/fsfw

introduced command message base and

command message IF
This commit is contained in:
2020-06-12 20:23:39 +02:00
parent f578c3ea29
commit 7b538e9750
10 changed files with 232 additions and 169 deletions

25
ipc/CommandMessageIF.h Normal file
View File

@ -0,0 +1,25 @@
#ifndef FRAMEWORK_IPC_COMMANDMESSAGEIF_H_
#define FRAMEWORK_IPC_COMMANDMESSAGEIF_H_
#include <framework/ipc/MessageQueueMessageIF.h>
#define MAKE_COMMAND_ID( number ) ((MESSAGE_ID << 8) + (number))
typedef uint16_t Command_t;
class CommandMessageIF: public MessageQueueMessageIF {
public:
virtual ~CommandMessageIF() {};
/**
* A command message shall have a uint16_t command ID field.
* @return
*/
virtual Command_t getCommand() const = 0;
/**
* A command message shall have a uint8_t message type ID field.
* @return
*/
virtual uint8_t getMessageType() const = 0;
};
#endif /* FRAMEWORK_IPC_COMMANDMESSAGEIF_H_ */