56 #include "MockHL_can.h"
57 #include "Mockcan_cfg.h"
58 #include "Mockdatabase.h"
60 #include "Mockfoxmath.h"
61 #include "Mockftask.h"
67 #include "Mockqueue.h"
68 #include "Mocktest_can_mpu_prototype_queue_create_stub.h"
83 .distanceFromLastRelease = 42,
84 .commitHash =
"deadbeef",
85 .gitRemote =
"onTheDarkSideOfTheMoon.git",
141 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
153 canIsTxMessagePending_IgnoreAndReturn(0u);
154 canUpdateID_Ignore();
155 canTransmit_IgnoreAndReturn(0u);
160 canBASE_t node = {0};
161 canIsTxMessagePending_IgnoreAndReturn(0u);
162 canUpdateID_Ignore();
163 canTransmit_IgnoreAndReturn(0u);
171 canIsTxMessagePending_IgnoreAndReturn(1u);
173 for (uint8_t i = 0u; i < 32; i++) {
183 canIsTxMessagePending_ExpectAndReturn(pNode, 1, 0u);
184 canUpdateID_Expect(pNode, 1, 0x20040000u);
185 canTransmit_ExpectAndReturn(pNode, 1, &data, 0u);
190 canIsTxMessagePending_ExpectAndReturn(pNode, messageBox, 1u);
211 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
226 for (uint8_t stringNumber = 0u; stringNumber <
BS_NR_OF_STRINGS; stringNumber++) {
bool CAN_IsCurrentSensorCcPresent(uint8_t stringNumber)
get flag if CC message from current sensor is received.
CAN_STATE_s * TEST_CAN_GetCANState(void)
STD_RETURN_TYPE_e CAN_DataSend(canBASE_t *pNode, uint32_t id, uint8 *pData)
Sends over CAN the data passed in parameters. This function goes over the messageboxes and marks the ...
bool CAN_IsCurrentSensorPresent(uint8_t stringNumber)
set flag for presence of current sensor.
void CAN_EnablePeriodic(bool command)
enable/disable the periodic transmit/receive.
Header for the driver for the CAN module.
#define CAN_NR_OF_TX_MESSAGE_BOX
enum CAN_ENDIANNESS CAN_ENDIANNESS_e
@ DATA_BLOCK_ID_CELL_VOLTAGE
@ DATA_BLOCK_ID_CURRENT_SENSOR
@ DATA_BLOCK_ID_OPEN_WIRE_BASE
@ DATA_BLOCK_ID_CELL_TEMPERATURE
@ DATA_BLOCK_ID_STATEREQUEST
#define NULL_PTR
Null pointer.
bool currentSensorCCPresent[BS_NR_OF_STRINGS]
bool currentSensorPresent[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
const bool underVersionControl
#define TEST_ASSERT_FAIL_ASSERT(_code_under_test)
assert whether assert macro has failed
static DATA_BLOCK_CELL_VOLTAGE_s can_tableCellVoltages
void testDataSendNoMessagePending(void)
const CAN_MSG_RX_TYPE_s can_rxMessages[]
const VERSION_s foxbmsVersionInfo
static DATA_BLOCK_MIN_MAX_s can_tableMinimumMaximumValues
static DATA_BLOCK_OPEN_WIRE_s can_tableOpenWire
CAN_STATE_s * canTestState
static uint32_t can_dummy(uint32_t id, uint8_t dlc, CAN_ENDIANNESS_e endianness, uint8_t *pCanData, uint8_t *pMuxId, const CAN_SHIM_s const *kpkCanShim)
volatile bool ftsk_allQueuesCreated
const uint8_t can_txLength
void testDataSendMessagePending(void)
const CAN_MSG_TX_TYPE_s can_txMessages[]
void testIsCurrentSensorCcPresent(void)
const CAN_SHIM_s can_kShim
static DATA_BLOCK_CELL_TEMPERATURE_s can_tableTemperatures
QueueHandle_t ftsk_dataQueue
void testEnablePeriodic(void)
const uint8_t can_rxLength
void testDataSendNullPointerAsData(void)
void testIsCurrentSensorPresent(void)
QueueHandle_t imd_canDataQueue
void testDataSendNullPointerAsNode(void)
static DATA_BLOCK_STATEREQUEST_s can_tableStateRequest
void testCAN_TransmitBootMessage(void)
QueueHandle_t ftsk_canRxQueue
QueueHandle_t ftsk_imdCanDataQueue
static DATA_BLOCK_CURRENT_SENSOR_s can_tableCurrentSensor
Header file for the version information that is generated by the toolchain.