![]() |
GaIA BIOS Library
|
GWA Core IO Functions. More...
#include <stdint.h>Data Structures | |
| struct | block_t |
| struct | block_set_t |
| struct | spi_module_t |
| struct | spi_chain_t |
Macros | |
| #define | MAX_SPI_MODULES (32) |
| #define | MAX_BLOCKS (12) |
| #define | GWA_IO_ERR_MODULE_IDENTIFY (-1) |
| Error during modules identification. | |
| #define | GWA_IO_ERR_MEM_ALLOC (-2) |
| Error allocating memory. | |
Enumerations | |
| enum | module_type_t { GWA_BASE_NONE = 0x80 , GWA_BASE_IO = 0x81 , GWA_BASE_DISP = 0x82 , GWA_BASE_IO_201 = 0x83 , GWA_X84_BOARD = 0x84 , AMATH7_BASE_IO = 0x85 , GWA_BASE_IO_203 = 0x86 , GWA_GXIO00_BOARD = 0xA1 , GWA_GXST10_BOARD = 0xA2 , GWA_RGRID00_BOARD = 0xA6 } |
| The board types. More... | |
| enum | iobus_speed_t { iobus_default_speed = 0 , iobus_full_speed , iobus_high_speed , iobus_warp_speed } |
| IOBUS SPI speed settings. More... | |
| enum | block_type_t { BLK_DIP_SWITCH = 0x01 , BLK_INPUT = 0x02 , BLK_OUT_DIAG = 0x03 , BLK_OUTPUT = 0x04 , BLK_DISP_SEG = 0x05 , BLK_DISP_COL = 0x06 } |
| Device types on the SPI chain. More... | |
Functions | |
| void | gwa_core_io_lib_speed (iobus_speed_t speed) |
| IOBUS SPI speed setup. | |
| int | gwa_core_io_lib_init (void) |
| Identifies hardware and initializes the core library. | |
| const spi_module_t ** | gwa_core_get_modules (void) |
| Gets the list of installed modules. | |
| void | gwa_core_io_scan (void) |
| Scans the io spi daisy chain. | |
| void | gwa_core_io_out_copy (void) |
| Copies output values to SPI buffers. | |
| void | gwa_core_io_in_copy (void) |
| Copies input values from SPI buffers. | |
| uint16_t | gwa_dip_read (void) |
| Gets the DIP switch value. | |
Variables | |
| spi_chain_t | spi_chain |
| volatile uint8_t | gwa_dip_switch |
| volatile uint8_t | in_data [MAX_SPI_MODULES *MAX_BLOCKS] |
| Input data. | |
| uint16_t | in_data_len |
| Length of in_data array. | |
| volatile uint8_t | out_data [MAX_SPI_MODULES *MAX_BLOCKS] |
| Output data. | |
| uint16_t | out_data_len |
| Length of out_data array. | |
| volatile uint8_t | oldoutw_data [MAX_SPI_MODULES *MAX_BLOCKS] |
| Previously written output data. | |
| volatile uint8_t | oldoutr_data [MAX_SPI_MODULES *MAX_BLOCKS] |
| Read back output data. | |
| volatile uint8_t | diag_data [MAX_SPI_MODULES *MAX_BLOCKS] |
| Diagnostics data. | |
| uint16_t | diag_data_len |
| Length of diag_data array. | |
GWA Core IO Functions.