55 #ifndef FOXBMS__CAN_HELPER_H_
56 #define FOXBMS__CAN_HELPER_H_
68 #define CAN_BYTE_0_POSITION (0u)
69 #define CAN_BYTE_1_POSITION (1u)
70 #define CAN_BYTE_2_POSITION (2u)
71 #define CAN_BYTE_3_POSITION (3u)
72 #define CAN_BYTE_4_POSITION (4u)
73 #define CAN_BYTE_5_POSITION (5u)
74 #define CAN_BYTE_6_POSITION (6u)
75 #define CAN_BYTE_7_POSITION (7u)
156 uint64_t *pCanSignal,
169 const uint8_t *
const kpkCanData,
Headers for the configuration for the CAN module.
enum CAN_ENDIANNESS CAN_ENDIANNESS_e
struct CAN_SIGNAL_TYPE CAN_SIGNAL_TYPE_s
void CAN_TxSetMessageDataWithSignalData(uint64_t *pMessage, uint64_t bitStart, uint8_t bitLength, uint64_t canSignal, CAN_ENDIANNESS_e endianness)
Puts CAN signal data in a 64-bit variable. This function is used to compose a 64-bit CAN message....
void CAN_TxSetCanDataWithMessageData(uint64_t message, uint8_t *pCanData, CAN_ENDIANNESS_e endianness)
Copy CAN data from a 64-bit variable to 8 bytes. This function is used to copy a 64-bit CAN message t...
void CAN_RxGetMessageDataFromCanData(uint64_t *pMessage, const uint8_t *const kpkCanData, CAN_ENDIANNESS_e endianness)
Copy CAN data from 8 bytes to a 64-bit variable.
void CAN_TxPrepareSignalData(float *pSignal, CAN_SIGNAL_TYPE_s signalProperties)
Prepare signal data. This function takes the signal data and applies factor, applies offset and compa...
void CAN_RxConvertRawSignalData(float *pSignalConverted, float signalRaw, CAN_SIGNAL_TYPE_s signalProperties)
Convert raw signal data. This function takes the raw signal data and applies offset and factor to con...
void CAN_RxGetSignalDataFromMessageData(uint64_t message, uint64_t bitStart, uint8_t bitLength, uint64_t *pCanSignal, CAN_ENDIANNESS_e endianness)
Gets CAN signal data from a 64-bit variable. This function is used to get signal data from a 64-bit C...
General macros and definitions for the whole platform.