RZA Flexible Software Package Documentation  Release v1.1.0

 
BSP I/O access

Functions

__STATIC_INLINE uint32_t R_BSP_PinRead (bsp_io_port_pin_t pin)
 
__STATIC_INLINE void R_BSP_PinWrite (bsp_io_port_pin_t pin, bsp_io_level_t level)
 
__STATIC_INLINE void R_BSP_PinAccessEnable (void)
 
__STATIC_INLINE void R_BSP_PinAccessDisable (void)
 

Detailed Description

This module provides basic read/write access to port pins.

Enumerations

enum  bsp_io_level_t
 
enum  bsp_io_direction_t
 
enum  bsp_io_port_t
 
enum  bsp_io_port_pin_t
 

Enumeration Type Documentation

◆ bsp_io_level_t

Levels that can be set and read for individual pins

Enumerator
BSP_IO_LEVEL_LOW 

Low.

BSP_IO_LEVEL_HIGH 

High.

◆ bsp_io_direction_t

Direction of individual pins

Enumerator
BSP_IO_DIRECTION_HIZ 

Hi-Z.

BSP_IO_DIRECTION_INPUT 

Input.

BSP_IO_DIRECTION_OUTPUT 

Output (Input disable)

BSP_IO_DIRECTION_OUTPUT_WITH_INPUT_ENABLE 

Output (Input enable)

◆ bsp_io_port_t

Superset list of all possible IO ports.

Enumerator
BSP_IO_PORT_00 

IO port 0.

BSP_IO_PORT_01 

IO port 1.

BSP_IO_PORT_02 

IO port 2.

BSP_IO_PORT_03 

IO port 3.

BSP_IO_PORT_04 

IO port 4.

BSP_IO_PORT_05 

IO port 5.

BSP_IO_PORT_06 

IO port 6.

BSP_IO_PORT_07 

IO port 7.

BSP_IO_PORT_08 

IO port 8.

BSP_IO_PORT_09 

IO port 9.

BSP_IO_PORT_10 

IO port 10.

BSP_IO_PORT_11 

IO port 11.

BSP_IO_PORT_12 

IO port 12.

BSP_IO_PORT_13 

IO port 13.

BSP_IO_PORT_14 

IO port 14.

BSP_IO_PORT_15 

IO port 15.

BSP_IO_PORT_16 

IO port 16.

BSP_IO_PORT_17 

IO port 17.

BSP_IO_PORT_18 

IO port 18.

◆ bsp_io_port_pin_t

Superset list of all possible IO port pins.

Enumerator
BSP_IO_PORT_00_PIN_00 

IO port 0 pin 0.

BSP_IO_PORT_00_PIN_01 

IO port 0 pin 1.

BSP_IO_PORT_00_PIN_02 

IO port 0 pin 2.

BSP_IO_PORT_00_PIN_03 

IO port 0 pin 3.

BSP_IO_PORT_01_PIN_00 

IO port 1 pin 0.

BSP_IO_PORT_01_PIN_01 

IO port 1 pin 1.

BSP_IO_PORT_01_PIN_02 

IO port 1 pin 2.

BSP_IO_PORT_01_PIN_03 

IO port 1 pin 3.

BSP_IO_PORT_01_PIN_04 

IO port 1 pin 4.

BSP_IO_PORT_02_PIN_00 

IO port 2 pin 0.

BSP_IO_PORT_02_PIN_01 

IO port 2 pin 1.

BSP_IO_PORT_02_PIN_02 

IO port 2 pin 2.

BSP_IO_PORT_02_PIN_03 

IO port 2 pin 3.

BSP_IO_PORT_03_PIN_00 

IO port 3 pin 0.

BSP_IO_PORT_03_PIN_01 

IO port 3 pin 1.

BSP_IO_PORT_03_PIN_02 

IO port 3 pin 2.

BSP_IO_PORT_03_PIN_03 

IO port 3 pin 3.

BSP_IO_PORT_04_PIN_00 

IO port 4 pin 0.

BSP_IO_PORT_04_PIN_01 

IO port 4 pin 1.

BSP_IO_PORT_04_PIN_02 

IO port 4 pin 2.

BSP_IO_PORT_04_PIN_03 

IO port 4 pin 3.

BSP_IO_PORT_04_PIN_04 

IO port 4 pin 4.

BSP_IO_PORT_04_PIN_05 

IO port 4 pin 5.

BSP_IO_PORT_05_PIN_00 

IO port 5 pin 0.

BSP_IO_PORT_05_PIN_01 

IO port 5 pin 1.

BSP_IO_PORT_05_PIN_02 

IO port 5 pin 2.

BSP_IO_PORT_05_PIN_03 

IO port 5 pin 3.

BSP_IO_PORT_05_PIN_04 

IO port 5 pin 4.

BSP_IO_PORT_06_PIN_00 

IO port 6 pin 0.

BSP_IO_PORT_06_PIN_01 

IO port 6 pin 1.

BSP_IO_PORT_06_PIN_02 

IO port 6 pin 2.

BSP_IO_PORT_06_PIN_03 

IO port 6 pin 3.

BSP_IO_PORT_06_PIN_04 

IO port 6 pin 4.

BSP_IO_PORT_07_PIN_00 

IO port 7 pin 0.

BSP_IO_PORT_07_PIN_01 

IO port 7 pin 1.

BSP_IO_PORT_07_PIN_02 

IO port 7 pin 2.

BSP_IO_PORT_07_PIN_03 

IO port 7 pin 3.

BSP_IO_PORT_07_PIN_04 

IO port 7 pin 4.

BSP_IO_PORT_08_PIN_00 

IO port 8 pin 0.

BSP_IO_PORT_08_PIN_01 

IO port 8 pin 1.

BSP_IO_PORT_08_PIN_02 

IO port 8 pin 2.

BSP_IO_PORT_08_PIN_03 

IO port 8 pin 3.

BSP_IO_PORT_08_PIN_04 

IO port 8 pin 4.

BSP_IO_PORT_09_PIN_00 

IO port 9 pin 0.

BSP_IO_PORT_09_PIN_01 

IO port 9 pin 1.

BSP_IO_PORT_09_PIN_02 

IO port 9 pin 2.

BSP_IO_PORT_09_PIN_03 

IO port 9 pin 3.

BSP_IO_PORT_10_PIN_00 

IO port 10 pin 0.

BSP_IO_PORT_10_PIN_01 

IO port 10 pin 1.

BSP_IO_PORT_10_PIN_02 

IO port 10 pin 2.

BSP_IO_PORT_10_PIN_03 

IO port 10 pin 3.

BSP_IO_PORT_10_PIN_04 

IO port 10 pin 4.

BSP_IO_PORT_11_PIN_00 

IO port 11 pin 0.

BSP_IO_PORT_11_PIN_01 

IO port 11 pin 1.

BSP_IO_PORT_11_PIN_02 

IO port 11 pin 2.

BSP_IO_PORT_11_PIN_03 

IO port 11 pin 3.

BSP_IO_PORT_12_PIN_00 

IO port 12 pin 0.

BSP_IO_PORT_12_PIN_01 

IO port 12 pin 1.

BSP_IO_PORT_13_PIN_00 

IO port 13 pin 0.

BSP_IO_PORT_13_PIN_01 

IO port 13 pin 1.

BSP_IO_PORT_13_PIN_02 

IO port 13 pin 2.

BSP_IO_PORT_13_PIN_03 

IO port 13 pin 3.

BSP_IO_PORT_13_PIN_04 

IO port 13 pin 4.

BSP_IO_PORT_14_PIN_00 

IO port 14 pin 0.

BSP_IO_PORT_14_PIN_01 

IO port 14 pin 1.

BSP_IO_PORT_14_PIN_02 

IO port 14 pin 2.

BSP_IO_PORT_15_PIN_00 

IO port 15 pin 0.

BSP_IO_PORT_15_PIN_01 

IO port 15 pin 1.

BSP_IO_PORT_15_PIN_02 

IO port 15 pin 2.

BSP_IO_PORT_15_PIN_03 

IO port 15 pin 3.

BSP_IO_PORT_16_PIN_00 

IO port 16 pin 0.

BSP_IO_PORT_16_PIN_01 

IO port 16 pin 1.

BSP_IO_PORT_17_PIN_00 

IO port 17 pin 0.

BSP_IO_PORT_17_PIN_01 

IO port 17 pin 1.

BSP_IO_PORT_17_PIN_02 

IO port 17 pin 2.

BSP_IO_PORT_17_PIN_03 

IO port 17 pin 3.

BSP_IO_PORT_18_PIN_00 

IO port 18 pin 0.

BSP_IO_PORT_18_PIN_01 

IO port 18 pin 1.

BSP_IO_PORT_18_PIN_02 

IO port 18 pin 2.

BSP_IO_PORT_18_PIN_03 

IO port 18 pin 3.

BSP_IO_PORT_18_PIN_04 

IO port 18 pin 4.

BSP_IO_PORT_18_PIN_05 

IO port 18 pin 5.

BSP_IO_NMI 

NMI.

BSP_IO_TMS_SWDIO 

TMS_SWDIO.

BSP_IO_TDO 

TDO.

BSP_IO_AUDIO_CLK1 

AUDIO_CLK1.

BSP_IO_AUDIO_CLK2 

AUDIO_CLK2.

BSP_IO_SD0_CLK 

CD0_CLK.

BSP_IO_SD0_CMD 

CD0_CMD.

BSP_IO_SD0_RST_N 

CD0_RST_N.

BSP_IO_SD0_DATA0 

SD0_DATA0.

BSP_IO_SD0_DATA1 

SD0_DATA1.

BSP_IO_SD0_DATA2 

SD0_DATA2.

BSP_IO_SD0_DATA3 

SD0_DATA3.

BSP_IO_SD0_DATA4 

SD0_DATA4.

BSP_IO_SD0_DATA5 

SD0_DATA5.

BSP_IO_SD0_DATA6 

SD0_DATA6.

BSP_IO_SD0_DATA7 

SD0_DATA7.

BSP_IO_SD1_CLK 

SD1_CLK.

BSP_IO_SD1_CMD 

SD1_CMD.

BSP_IO_SD1_DATA0 

SD1_DATA0.

BSP_IO_SD1_DATA1 

SD1_DATA1.

BSP_IO_SD1_DATA2 

SD1_DATA2.

BSP_IO_SD1_DATA3 

SD1_DATA3.

BSP_IO_QSPI0_SPCLK 

QSPI0_SPCLK.

BSP_IO_QSPI0_IO0 

QSPI0_IO0.

BSP_IO_QSPI0_IO1 

QSPI0_IO1.

BSP_IO_QSPI0_IO2 

QSPI0_IO2.

BSP_IO_QSPI0_IO3 

QSPI0_IO3.

BSP_IO_QSPI0_SSL 

QSPI0_SSL.

BSP_IO_OM_CS1_N 

OM_CS1_N.

BSP_IO_OM_DQS 

OM_DQS.

BSP_IO_OM_SIO4 

OM_SIO4.

BSP_IO_OM_SIO5 

OM_SIO5.

BSP_IO_OM_SIO6 

OM_SIO6.

BSP_IO_OM_SIO7 

OM_SIO7.

BSP_IO_QSPI_RESET_N 

QSPI_RESET_N.

BSP_IO_QSPI_WP_N 

QSPI_WP_N.

BSP_IO_WDTOVF_PERROUT_N 

WDTOVF_PERROUT_N.

BSP_IO_RIIC0_SDA 

RIIC0_SDA.

BSP_IO_RIIC0_SCL 

RIIC0_SCL.

BSP_IO_RIIC1_SDA 

RIIC1_SDA.

BSP_IO_RIIC1_SCL 

RIIC1_SCL.

Function Documentation

◆ R_BSP_PinRead()

__STATIC_INLINE uint32_t R_BSP_PinRead ( bsp_io_port_pin_t  pin)

Read the current input level of the pin.

Parameters
[in]pinThe pin
Return values
Currentinput level

◆ R_BSP_PinWrite()

__STATIC_INLINE void R_BSP_PinWrite ( bsp_io_port_pin_t  pin,
bsp_io_level_t  level 
)

Set a pin to output and set the output level to the level provided

Parameters
[in]pinThe pin
[in]levelThe level

◆ R_BSP_PinAccessEnable()

__STATIC_INLINE void R_BSP_PinAccessEnable ( void  )

Enable access to the PFS registers. Uses a reference counter to protect against interrupts that could occur via multiple threads or an ISR re-entering this code.

◆ R_BSP_PinAccessDisable()

__STATIC_INLINE void R_BSP_PinAccessDisable ( void  )

Disable access to the PFS registers. Uses a reference counter to protect against interrupts that could occur via multiple threads or an ISR re-entering this code.