foxBMS - Unit Tests  1.6.0
The foxBMS Unit Tests API Documentation
test_nxp_mc33775a_afe.c File Reference

Test of some module. More...

#include "unity.h"
#include "Mockafe_dma.h"
#include "Mockdma.h"
#include "Mocknxp_mc33775a.h"
#include "Mockos.h"
#include "Mockpex.h"
#include <stdbool.h>
#include <stdint.h>
Include dependency graph for test_nxp_mc33775a_afe.c:

Go to the source code of this file.

Functions

void setUp (void)
 
void tearDown (void)
 

Variables

static DATA_BLOCK_CELL_VOLTAGE_s n775_cellVoltage = {.header.uniqueId = DATA_BLOCK_ID_CELL_VOLTAGE_BASE}
 
static DATA_BLOCK_CELL_TEMPERATURE_s n775_cellTemperature = {.header.uniqueId = DATA_BLOCK_ID_CELL_TEMPERATURE_BASE}
 
static DATA_BLOCK_MIN_MAX_s n775_minMax = {.header.uniqueId = DATA_BLOCK_ID_MIN_MAX}
 
static DATA_BLOCK_BALANCING_CONTROL_s n775_balancingControl = {.header.uniqueId = DATA_BLOCK_ID_BALANCING_CONTROL}
 
static DATA_BLOCK_ALL_GPIO_VOLTAGES_s n775_allGpioVoltage = {.header.uniqueId = DATA_BLOCK_ID_ALL_GPIO_VOLTAGES_BASE}
 
static DATA_BLOCK_BALANCING_FEEDBACK_s n775_balancingFeedback
 
static DATA_BLOCK_SLAVE_CONTROL_s n775_slaveControl = {.header.uniqueId = DATA_BLOCK_ID_SLAVE_CONTROL}
 
static DATA_BLOCK_OPEN_WIRE_s n775_openWire = {.header.uniqueId = DATA_BLOCK_ID_OPEN_WIRE_BASE}
 
static N775_SUPPLY_CURRENT_s n775_supplyCurrent = {0}
 
static N775_ERROR_TABLE_s n775_errorTable = {0}
 
N775_STATE_s n775_stateBase
 

Detailed Description

Test of some module.

SPDX-License-Identifier: BSD-3-Clause

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

  1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.
  2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.
  3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.

THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

We kindly request you to use one or more of the following phrases to refer to foxBMS in your hardware, software, documentation or advertising materials:

  • ″This product uses parts of foxBMS®″
  • ″This product includes parts of foxBMS®″
  • ″This product is derived from foxBMS®″
Author
foxBMS Team
Date
2020-06-10 (date of creation)
Updated
2023-10-12 (date of last update)
Version
v1.6.0
Prefix
TEST

Definition in file test_nxp_mc33775a_afe.c.

Function Documentation

◆ setUp()

void setUp ( void  )

Definition at line 117 of file test_nxp_mc33775a_afe.c.

◆ tearDown()

void tearDown ( void  )

Definition at line 120 of file test_nxp_mc33775a_afe.c.

Variable Documentation

◆ n775_allGpioVoltage

DATA_BLOCK_ALL_GPIO_VOLTAGES_s n775_allGpioVoltage = {.header.uniqueId = DATA_BLOCK_ID_ALL_GPIO_VOLTAGES_BASE}
static

Definition at line 86 of file test_nxp_mc33775a_afe.c.

◆ n775_balancingControl

DATA_BLOCK_BALANCING_CONTROL_s n775_balancingControl = {.header.uniqueId = DATA_BLOCK_ID_BALANCING_CONTROL}
static

Definition at line 85 of file test_nxp_mc33775a_afe.c.

◆ n775_balancingFeedback

DATA_BLOCK_BALANCING_FEEDBACK_s n775_balancingFeedback
static
Initial value:
= {
@ DATA_BLOCK_ID_BALANCING_FEEDBACK_BASE
Definition: database_cfg.h:84

Definition at line 87 of file test_nxp_mc33775a_afe.c.

◆ n775_cellTemperature

DATA_BLOCK_CELL_TEMPERATURE_s n775_cellTemperature = {.header.uniqueId = DATA_BLOCK_ID_CELL_TEMPERATURE_BASE}
static

Definition at line 83 of file test_nxp_mc33775a_afe.c.

◆ n775_cellVoltage

DATA_BLOCK_CELL_VOLTAGE_s n775_cellVoltage = {.header.uniqueId = DATA_BLOCK_ID_CELL_VOLTAGE_BASE}
static

Definition at line 82 of file test_nxp_mc33775a_afe.c.

◆ n775_errorTable

N775_ERROR_TABLE_s n775_errorTable = {0}
static

Definition at line 92 of file test_nxp_mc33775a_afe.c.

◆ n775_minMax

DATA_BLOCK_MIN_MAX_s n775_minMax = {.header.uniqueId = DATA_BLOCK_ID_MIN_MAX}
static

Definition at line 84 of file test_nxp_mc33775a_afe.c.

◆ n775_openWire

DATA_BLOCK_OPEN_WIRE_s n775_openWire = {.header.uniqueId = DATA_BLOCK_ID_OPEN_WIRE_BASE}
static

Definition at line 90 of file test_nxp_mc33775a_afe.c.

◆ n775_slaveControl

DATA_BLOCK_SLAVE_CONTROL_s n775_slaveControl = {.header.uniqueId = DATA_BLOCK_ID_SLAVE_CONTROL}
static

Definition at line 89 of file test_nxp_mc33775a_afe.c.

◆ n775_stateBase

N775_STATE_s n775_stateBase
Initial value:
= {
.firstMeasurementMade = false,
.currentString = 0u,
.pSpiTxSequenceStart = NULL_PTR,
.pSpiTxSequence = NULL_PTR,
.pSpiRxSequenceStart = NULL_PTR,
.pSpiRxSequence = NULL_PTR,
.currentMux = {0u},
.pMuxSequenceStart = NULL_PTR,
.pMuxSequence = NULL_PTR,
.n775Data.cellVoltage = &n775_cellVoltage,
.n775Data.cellTemperature = &n775_cellTemperature,
.n775Data.allGpioVoltage = &n775_allGpioVoltage,
.n775Data.minMax = &n775_minMax,
.n775Data.balancingFeedback = &n775_balancingFeedback,
.n775Data.balancingControl = &n775_balancingControl,
.n775Data.slaveControl = &n775_slaveControl,
.n775Data.openWire = &n775_openWire,
.n775Data.supplyCurrent = &n775_supplyCurrent,
.n775Data.errorTable = &n775_errorTable,
}
#define NULL_PTR
Null pointer.
Definition: fstd_types.h:77
static DATA_BLOCK_SLAVE_CONTROL_s n775_slaveControl
static N775_ERROR_TABLE_s n775_errorTable
static DATA_BLOCK_ALL_GPIO_VOLTAGES_s n775_allGpioVoltage
static DATA_BLOCK_MIN_MAX_s n775_minMax
static DATA_BLOCK_CELL_TEMPERATURE_s n775_cellTemperature
static DATA_BLOCK_CELL_VOLTAGE_s n775_cellVoltage
static DATA_BLOCK_BALANCING_CONTROL_s n775_balancingControl
static DATA_BLOCK_OPEN_WIRE_s n775_openWire
static N775_SUPPLY_CURRENT_s n775_supplyCurrent
static DATA_BLOCK_BALANCING_FEEDBACK_s n775_balancingFeedback

state of the state machine for the MC33775A driver

Definition at line 94 of file test_nxp_mc33775a_afe.c.

◆ n775_supplyCurrent

N775_SUPPLY_CURRENT_s n775_supplyCurrent = {0}
static

Definition at line 91 of file test_nxp_mc33775a_afe.c.