58 #include "Mockdatabase.h"
60 #include "Mockfoxmath.h"
62 #include "Mockmpu_prototypes.h"
70 TEST_FILE(
"can_cbs_tx_minmax.c")
121 uint8_t data[8] = {0};
123 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
130 DATA_Read_1_DataBlock_IgnoreAndReturn(0u);
131 BMS_GetNumberOfConnectedStrings_IgnoreAndReturn(0u);
140 TEST_ASSERT_EQUAL(0x5D, data[0]);
141 TEST_ASSERT_EQUAL(0xC1, data[1]);
142 TEST_ASSERT_EQUAL(0xF4, data[2]);
143 TEST_ASSERT_EQUAL(0x00, data[3]);
144 TEST_ASSERT_EQUAL(0x00, data[4]);
145 TEST_ASSERT_EQUAL(0x00, data[5]);
146 TEST_ASSERT_EQUAL(0x23, data[6]);
147 TEST_ASSERT_EQUAL(0xF1, data[7]);
151 uint8_t data[8] = {0};
153 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
160 DATA_Read_1_DataBlock_IgnoreAndReturn(0u);
162 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
163 BMS_IsStringClosed_IgnoreAndReturn(
true);
173 TEST_ASSERT_EQUAL(0x5D, data[0]);
174 TEST_ASSERT_EQUAL(0xC1, data[1]);
175 TEST_ASSERT_EQUAL(0xF4, data[2]);
176 TEST_ASSERT_EQUAL(0x00, data[3]);
177 TEST_ASSERT_EQUAL(0x00, data[4]);
178 TEST_ASSERT_EQUAL(0x00, data[5]);
179 TEST_ASSERT_EQUAL(0x23, data[6]);
180 TEST_ASSERT_EQUAL(0xF1, data[7]);
uint32_t CAN_TxMinimumMaximumValues(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 min/max values
#define CAN_ID_TX_MINIMUM_MAXIMUM_VALUES
Headers for the helper functions for the CAN module.
Database configuration header.
@ DATA_BLOCK_ID_INSULATION_MONITORING
@ DATA_BLOCK_ID_CELL_VOLTAGE
@ DATA_BLOCK_ID_CURRENT_SENSOR
@ DATA_BLOCK_ID_OPEN_WIRE_BASE
@ DATA_BLOCK_ID_ERRORSTATE
@ DATA_BLOCK_ID_PACK_VALUES
@ DATA_BLOCK_ID_CELL_TEMPERATURE
@ DATA_BLOCK_ID_STATEREQUEST
#define NULL_PTR
Null pointer.
DATA_BLOCK_MIN_MAX_s * pTableMinMax
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
int16_t maximumTemperature_ddegC[BS_NR_OF_STRINGS]
int16_t minimumTemperature_ddegC[BS_NR_OF_STRINGS]
int16_t maximumCellVoltage_mV[BS_NR_OF_STRINGS]
DATA_BLOCK_HEADER_s header
int16_t minimumCellVoltage_mV[BS_NR_OF_STRINGS]
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
DATA_BLOCK_HEADER_s header
static DATA_BLOCK_CELL_VOLTAGE_s can_tableCellVoltages
static DATA_BLOCK_ERRORSTATE_s can_tableErrorState
static DATA_BLOCK_MSL_FLAG_s can_tableMslFlags
static DATA_BLOCK_MIN_MAX_s can_tableMinimumMaximumValues
static DATA_BLOCK_OPEN_WIRE_s can_tableOpenWire
static DATA_BLOCK_PACK_VALUES_s can_tablePackValues
static DATA_BLOCK_MOL_FLAG_s can_tableMolFlags
void testCAN_TxMinimumMaximumValuesAllStringsOpen(void)
const CAN_SHIM_s can_kShim
static DATA_BLOCK_CELL_TEMPERATURE_s can_tableTemperatures
static DATA_BLOCK_SOX_s can_tableSox
static DATA_BLOCK_RSL_FLAG_s can_tableRslFlags
static DATA_BLOCK_INSULATION_MONITORING_s can_tableInsulation
static DATA_BLOCK_SOF_s can_tableSof
QueueHandle_t imd_canDataQueue
static DATA_BLOCK_STATEREQUEST_s can_tableStateRequest
void testCAN_TxMinimumMaximumValuesAllStringsClosed(void)
static DATA_BLOCK_CURRENT_SENSOR_s can_tableCurrentSensor