This is the chip specific include file for T32CZ20 SPI Driver note that there is a common include file for this HAL module that contains the APIs (such as the init function) that should be used by the application. More...
#include "tr_hal_platform.h"
Go to the source code of this file.
Data Structures | |
struct | SPI_REGISTERS_T |
the struct we use so we can address registers using field names More... | |
struct | tr_hal_spi_settings_t |
Typedefs | |
typedef void(* | tr_hal_spi_receive_callback_t) (uint8_t num_received_bytes, uint8_t *byte_buffer) |
typedef void(* | tr_hal_spi_event_callback_t) (tr_hal_spi_id_t spi_id, uint32_t event_bitmask) |
Enumerations | |
enum | tr_hal_spi_id_t { SPI_0_ID = 0 , SPI_1_ID = 1 } |
enum | tr_hal_spi_mode_t { TR_HAL_SPI_MODE_NORMAL = 0 , TR_HAL_SPI_MODE_DUAL = 2 , TR_HAL_SPI_MODE_QUAD = 3 } |
Normal SPI vs Dual SPI vs Quad SPI modes. More... | |
enum | tr_hal_spi_bit_size_t { TR_HAL_SPI_BIT_SIZE_8 = 0x10 , TR_HAL_SPI_BIT_SIZE_32 = 0x70 } |
enum | tr_hal_spi_clock_rate_t { SPI_CTRL_CLOCK_32_MHZ = 0x000 , SPI_CTRL_CLOCK_16_MHZ = 0x100 , SPI_CTRL_CLOCK_8_MHZ = 0x101 , SPI_CTRL_CLOCK_4_MHZ = 0x103 , SPI_CTRL_CLOCK_2_MHZ = 0x107 , SPI_CTRL_CLOCK_1_MHZ = 0x10F , SPI_CTRL_CLOCK_500_KHZ = 0x11F , SPI_CTRL_CLOCK_250_KHZ = 0x13F , SPI_CTRL_CLOCK_125_KHZ = 0x17F } |
Functions | |
SPI_REGISTERS_T * | tr_hal_spi_get_register_address (tr_hal_spi_id_t spi_id) |
tr_hal_status_t | tr_hal_spi_power_off (tr_hal_spi_id_t spi_id) |
tr_hal_status_t | tr_hal_spi_power_on (tr_hal_spi_id_t spi_id) |
tr_hal_status_t | tr_hal_spi_set_standard_pins (tr_hal_spi_id_t spi_id, tr_hal_gpio_pin_t clk_pin, tr_hal_gpio_pin_t chip_select_0_pin, tr_hal_gpio_pin_t sdo_pin, tr_hal_gpio_pin_t sdi_pin) |
tr_hal_status_t | tr_hal_spi_set_addl_cs_pins (tr_hal_spi_id_t spi_id, uint8_t num_chip_select, tr_hal_gpio_pin_t chip_select_1_pin, tr_hal_gpio_pin_t chip_select_2_pin, tr_hal_gpio_pin_t chip_select_3_pin) |
tr_hal_status_t | tr_hal_spi_read_stats (tr_hal_spi_id_t spi_id, uint32_t *transmit_started, uint32_t *transmit_completed, uint32_t *bytes_received) |
tr_hal_status_t | tr_hal_spi_clear_tx_busy (tr_hal_spi_id_t spi_id) |
This is the chip specific include file for T32CZ20 SPI Driver note that there is a common include file for this HAL module that contains the APIs (such as the init function) that should be used by the application.
this chip supports 2 SPIs. It supports standard SPI, and Dual and Quad SPI. see below for more information on standard SPI vs Dual SPI vs Quad SPI
SPDX-License-Identifier: LicenseRef-TridentMSLA SPDX-FileCopyrightText: 2025 Trident IoT, LLC https://www.tridentiot.com