foxBMS - Unit Tests
1.2.1
The foxBMS Unit Tests API Documentation
|
Headers for the configuration for the SPI module. More...
Go to the source code of this file.
Data Structures | |
struct | SPI_INTERFACE_CONFIG |
Macros | |
#define | SPI_CSHOLD_BIT (0x10000000U) |
#define | SPI_WDEL_BIT (0x04000000U) |
#define | SPI_HARDWARE_CHIP_SELECT_FIELD_POSITION (16U) |
#define | SPI_DATA_FORMAT_FIELD_POSITION (24U) |
#define | SPI_TX_BUFFER_EMPTY_FLAG_POSITION (9u) |
#define | SPI_PC0_CLEAR_HW_CS_MASK (0xFFFFFF00u) |
#define | SPI_TX_EMPTY_TIMEOUT_ITERATIONS (6000u) |
#define | SPI_MAX_NUMBER_HW_CS (6u) |
#define | LTC_SPI_NODE (spiREG1) |
#define | SPI_SPI1_INDEX (0u) |
#define | SPI_SPI2_INDEX (1u) |
#define | SPI_SPI3_INDEX (2u) |
#define | SPI_SPI4_INDEX (3u) |
#define | SPI_SPI5_INDEX (4u) |
#define | SPS_SPI_CS_GIOPORT (hetREG2->DOUT) |
#define | SPS_SPI_CS_GIOPORT_DIR (hetREG2->DIR) |
#define | SPS_SPI_CS_PIN (1u) |
#define | N775_SPI_TX_NODE (spiREG1) |
#define | N775_SPI_TX_GIOPORT (N775_SPI_TX_NODE->PC3) |
#define | N775_SPI_TX_CS_PIN (2U) |
#define | N775_SPI_RX_NODE (spiREG5) |
#define | N775_SPI_RX_GIOPORT (N775_SPI_TX_NODE->PC3) |
#define | N775_SPI_RX_CS_PIN (2U) |
Typedefs | |
typedef enum SPI_BUSY_STATE | SPI_BUSY_STATE_e |
typedef enum SPI_CHIP_SELECT_TYPE | SPI_CHIP_SELECT_TYPE_e |
typedef struct SPI_INTERFACE_CONFIG | SPI_INTERFACE_CONFIG_s |
Enumerations | |
enum | SPI_BUSY_STATE { SPI_IDLE , SPI_BUSY } |
enum | SPI_CHIP_SELECT_TYPE { SPI_CHIP_SELECT_HARDWARE , SPI_CHIP_SELECT_SOFTWARE } |
Functions | |
void | SPI_SpsInterfaceSwitchToHighSpeed (SPI_INTERFACE_CONFIG_s *pSpiSpsInterface) |
Switch the SPS spi handle to high speed. More... | |
void | SPI_SpsInterfaceSwitchToLowSpeed (SPI_INTERFACE_CONFIG_s *pSpiSpsInterface) |
Switch the SPS spi handle to low speed. More... | |
Headers for the configuration for the SPI 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:
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:
Definition in file spi_cfg.h.
#define N775_SPI_RX_CS_PIN (2U) |
#define N775_SPI_RX_GIOPORT (N775_SPI_TX_NODE->PC3) |
#define N775_SPI_RX_NODE (spiREG5) |
#define N775_SPI_TX_CS_PIN (2U) |
#define N775_SPI_TX_GIOPORT (N775_SPI_TX_NODE->PC3) |
#define N775_SPI_TX_NODE (spiREG1) |
#define SPI_CSHOLD_BIT (0x10000000U) |
#define SPI_DATA_FORMAT_FIELD_POSITION (24U) |
#define SPI_HARDWARE_CHIP_SELECT_FIELD_POSITION (16U) |
#define SPI_MAX_NUMBER_HW_CS (6u) |
#define SPI_PC0_CLEAR_HW_CS_MASK (0xFFFFFF00u) |
#define SPI_TX_BUFFER_EMPTY_FLAG_POSITION (9u) |
#define SPI_TX_EMPTY_TIMEOUT_ITERATIONS (6000u) |
#define SPI_WDEL_BIT (0x04000000U) |
#define SPS_SPI_CS_GIOPORT (hetREG2->DOUT) |
#define SPS_SPI_CS_GIOPORT_DIR (hetREG2->DIR) |
#define SPS_SPI_CS_PIN (1u) |
typedef enum SPI_BUSY_STATE SPI_BUSY_STATE_e |
enum for spi interface state
typedef enum SPI_CHIP_SELECT_TYPE SPI_CHIP_SELECT_TYPE_e |
type of chip select for spi
typedef struct SPI_INTERFACE_CONFIG SPI_INTERFACE_CONFIG_s |
configuration of the SPI interface
enum SPI_BUSY_STATE |
enum SPI_CHIP_SELECT_TYPE |
void SPI_SpsInterfaceSwitchToHighSpeed | ( | SPI_INTERFACE_CONFIG_s * | pSpiSpsInterface | ) |
void SPI_SpsInterfaceSwitchToLowSpeed | ( | SPI_INTERFACE_CONFIG_s * | pSpiSpsInterface | ) |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
|
extern |
size of spi_busyFlags
|
extern |
|
extern |
|
extern |