89 uint64_t messageData = 0u;
94 const uint8_t stringNumber = *pMuxId;
98 uint64_t data = (uint64_t)stringNumber;
103 float_t offset = 0.0f;
104 float_t factor = 4.0f;
105 signalData = (signalData + offset) * factor;
106 data = (int64_t)signalData;
114 signalData = (signalData + offset) * factor;
115 data = (int64_t)signalData;
123 signalData = (signalData + offset) * factor;
124 data = (int64_t)signalData;
136 signalData = (signalData + offset) * factor;
137 data = (int64_t)signalData;
145 signalData = (signalData + offset) * factor;
146 data = (int64_t)signalData;
154 signalData = (signalData + offset) * factor;
155 data = (int64_t)signalData;
175 #ifdef UNITY_UNIT_TEST
#define BS_NR_OF_STRINGS
Number of parallel strings in the battery pack.
BMS_CURRENT_FLOW_STATE_e BMS_GetCurrentFlowDirection(int32_t current_mA)
Get current flow direction, current value as function parameter.
uint32_t CANTX_StringStateEstimation(CAN_MESSAGE_PROPERTIES_s message, uint8_t *pCanData, uint8_t *pMuxId, const CAN_SHIM_s *const kpkCanShim)
can tx callback function for string state estimation
#define CAN_FOXBMS_MESSAGES_DEFAULT_DLC
Header for the driver for the CAN module.
#define CANTX_STRING_STATE_ESTIMATION_ID
#define CANTX_STRING_STATE_ESTIMATION_ID_TYPE
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...
Headers for the helper functions for the CAN module.
#define FAS_ASSERT(x)
Assertion macro that asserts that x is true.
math library for often used math functions
#define NULL_PTR
Null pointer.
CAN_IDENTIFIER_TYPE_e idType
CAN_ENDIANNESS_e endianness
DATA_BLOCK_PACK_VALUES_s * pTablePackValues
DATA_BLOCK_SOE_s * pTableSoe
DATA_BLOCK_SOC_s * pTableSoc
int32_t stringCurrent_mA[BS_NR_OF_STRINGS]
float_t averageSoc_perc[BS_NR_OF_STRINGS]
float_t minimumSoc_perc[BS_NR_OF_STRINGS]
float_t maximumSoc_perc[BS_NR_OF_STRINGS]
uint32_t minimumSoe_Wh[BS_NR_OF_STRINGS]
float_t maximumSoe_perc[BS_NR_OF_STRINGS]
float_t minimumSoe_perc[BS_NR_OF_STRINGS]