63 #define NUMBER_OF_MUX_VOLTAGES_PER_MESSAGE (4u)
121 uint32_t signalData_valid = 0u;
125 signalData_valid = 0u;
127 signalData_valid = 1u;
132 cellVoltageInvalidFlagSignal.
bitStart,
138 float signalData_mV =
145 pMessage, cellVoltageSignal.
bitStart, cellVoltageSignal.
bitLength, (uint32_t)signalData_mV, endianness);
162 uint64_t message = 0;
199 #ifdef UNITY_UNIT_TEST
#define BS_NR_OF_CELL_BLOCKS_PER_MODULE
number of cells per module
#define BS_NR_OF_STRINGS
Number of parallel strings in the battery pack.
#define BS_NR_OF_CELL_BLOCKS_PER_STRING
static const CAN_SIGNAL_TYPE_s cellVoltage1_mV
static const CAN_SIGNAL_TYPE_s cellVoltage3_mV
static void CAN_TxVoltageSetData(uint8_t muxId, uint64_t *pMessage, CAN_SIGNAL_TYPE_s cellVoltageSignal, CAN_SIGNAL_TYPE_s cellVoltageInvalidFlagSignal, CAN_ENDIANNESS_e endianness, const CAN_SHIM_s *const kpkCanShim)
Helper function for CAN_TxVoltage()
static const CAN_SIGNAL_TYPE_s cellVoltage3InvalidFlag
static const CAN_SIGNAL_TYPE_s cellVoltage0_mV
uint32_t CAN_TxVoltage(uint32_t id, uint8_t dlc, CAN_ENDIANNESS_e endianness, uint8_t *pCanData, uint8_t *pMuxId, const CAN_SHIM_s *const kpkCanShim)
can tx callback function for cell voltages
static const CAN_SIGNAL_TYPE_s cellVoltage2InvalidFlag
#define NUMBER_OF_MUX_VOLTAGES_PER_MESSAGE
static const CAN_SIGNAL_TYPE_s cellVoltage2_mV
static const CAN_SIGNAL_TYPE_s cellVoltage1InvalidFlag
static const CAN_SIGNAL_TYPE_s cellVoltageMultiplexer
static const CAN_SIGNAL_TYPE_s cellVoltage0InvalidFlag
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_TxPrepareSignalData(float *pSignal, CAN_SIGNAL_TYPE_s signalProperties)
Prepare signal data. This function takes the signal data and applies factor, applies offset and compa...
Headers for the helper functions for the CAN module.
#define DATA_READ_DATA(...)
uint8_t DATA_GetModuleNumberFromVoltageIndex(uint16_t cellIndex)
Returns module number of passed cell index.
uint8_t DATA_GetStringNumberFromVoltageIndex(uint16_t cellIndex)
Returns string number of passed cell index.
uint8_t DATA_GetCellNumberFromVoltageIndex(uint16_t cellIndex)
Returns cell number of passed cell index.
#define FAS_ASSERT(x)
Assertion macro that asserts that x is true.
#define NULL_PTR
Null pointer.
DATA_BLOCK_CELL_VOLTAGE_s * pTableCellVoltage
uint64_t invalidCellVoltage[BS_NR_OF_STRINGS][BS_NR_OF_MODULES_PER_STRING]
int16_t cellVoltage_mV[BS_NR_OF_STRINGS][BS_NR_OF_CELL_BLOCKS_PER_STRING]