Add moved CAN bus sys task

This commit is contained in:
Henrik Stickann
2022-12-02 16:38:56 +01:00
parent b1539aab39
commit 15f79b0446
3 changed files with 641 additions and 0 deletions

View File

@@ -0,0 +1,49 @@
/**
* @file
* @brief CAN driver message request types for use in C code.
*/
#ifndef STA_RTOS_SYSTEM_CAN_MSG_H
#define STA_RTOS_SYSTEM_CAN_MSG_H
#include <stdint.h>
/**
* @brief CAN message header.
*
* @ingroup STA_RTOS_CanBus
*/
struct CanMsgHeader
{
uint32_t sid; /**< Message SID */
uint32_t eid; /**< Message EID */
uint8_t format; /**< Message ID format */
uint8_t payloadLength; /**< Payload length */
};
/**
* @brief Element type for CAN data message queue.
*
* @ingroup STA_RTOS_CanBus
*/
struct CanDataMsg
{
struct CanMsgHeader header; /**< Message header data */
uint8_t payload[64]; /**< Message payload */
};
/**
* @brief Element type for CAN system message queue.
*
* @ingroup STA_RTOS_CanBus
*/
struct CanSysMsg
{
struct CanMsgHeader header; /**< Message header data */
uint8_t payload[8]; /**< Message payload */
};
#endif // STA_RTOS_SYSTEM_CAN_MSG_H