- Main Page
- Modules
- Data Structures
- Files

- File List
- Globals

Data Structures | Defines | Typedefs | Enumerations | Functions
csl_gpio.h File Reference

GPIO functional layer API header file. More...

`#include <cslr.h>`
`#include <soc.h>`
`#include <cslr_gpio.h>`
`#include <csl_error.h>`
`#include <csl_types.h>`
`#include <csl_general.h>`

Go to the source code of this file.

## Data Structures
struct | CSL_GpioConfig
| Config structure of GPIO. This is used to setup and get values of GPIO Registers using GPIO_config and GPIO_getConfig function. More...
struct | CSL_GpioPinConfig
| Input parameters for configuring a GPIO pin This is used to configure the direction and edge detection. More...
struct | CSL_GpioObj
| structure parameters for GPIO Handle More...
## Defines
#define | CSL_GPIO_NUM_PIN 32
#define | CSL_GPIO_BIT_SET 1
#define | CSL_GPIO_BIT_RESET 0
#define | GPIO_DRIVE_HIGH 1
#define | GPIO_DRIVE_LOW 0
## Typedefs
typedef CSL_GpioObj * | GPIO_Handle
| this is a pointer to CSL_GpioObj and is passed as the first parameter to all GPIO CSL APIs
## Enumerations
enum | CSL_GpioPinNum { CSL_GPIO_PIN0 = 0, CSL_GPIO_PIN1 = 1, CSL_GPIO_PIN2 = 2, CSL_GPIO_PIN3 = 3, CSL_GPIO_PIN4 = 4, CSL_GPIO_PIN5 = 5, CSL_GPIO_PIN6 = 6, CSL_GPIO_PIN7 = 7, CSL_GPIO_PIN8 = 8, CSL_GPIO_PIN9 = 9, CSL_GPIO_PIN10 = 10, CSL_GPIO_PIN11 = 11, CSL_GPIO_PIN12 = 12, CSL_GPIO_PIN13 = 13, CSL_GPIO_PIN14 = 14, CSL_GPIO_PIN15 = 15, CSL_GPIO_PIN16 = 16, CSL_GPIO_PIN17 = 17, CSL_GPIO_PIN18 = 18, CSL_GPIO_PIN19 = 19, CSL_GPIO_PIN20 = 20, CSL_GPIO_PIN21 = 21, CSL_GPIO_PIN22 = 22, CSL_GPIO_PIN23 = 23, CSL_GPIO_PIN24 = 24, CSL_GPIO_PIN25 = 25, CSL_GPIO_PIN26 = 26, CSL_GPIO_PIN27 = 27, CSL_GPIO_PIN28 = 28, CSL_GPIO_PIN29 = 29, CSL_GPIO_PIN30 = 30, CSL_GPIO_PIN31 = 31 }
enum | CSL_GpioTriggerType { CSL_GPIO_TRIG_RISING_EDGE = 0, CSL_GPIO_TRIG_FALLING_EDGE = 1, CSL_GPIO_TRIG_CLEAR_EDGE = 2 }
| Enums for configuring GPIO pin edge detection. More...
enum | CSL_GpioDirection { CSL_GPIO_DIR_INPUT = 0, CSL_GPIO_DIR_OUTPUT = 1 }
| Enumeration for GPIO General Purpose Output Data. More...
enum | CSL_GpioConfigCmd { CSL_GPIO_CMD_CONFIG_BIT = 0, CSL_GPIO_CMD_INT_DISABLE = 1, CSL_GPIO_CMD_INT_ENABLE = 2, CSL_GPIO_CMD_CLEAR_INT_FLAG = 3 }
| Enumeration for GPIO Control. More...
## Functions
GPIO_Handle | GPIO_open (CSL_GpioObj *GPIOobj, CSL_Status *status)
CSL_Status | GPIO_close (GPIO_Handle hGPIO)
CSL_Status | GPIO_config (GPIO_Handle GPIOHandle, CSL_GpioConfig *config)
CSL_Status | GPIO_getConfig (GPIO_Handle hGpio, CSL_GpioConfig *config)
CSL_Status | GPIO_read (GPIO_Handle hGPIO, CSL_GpioPinNum pinNum, Uint16 *buffer)
CSL_Status | GPIO_write (GPIO_Handle hGPIO, CSL_GpioPinNum pinNum, Uint16 buffer)
CSL_Status | GPIO_reset (GPIO_Handle hGPIO)
CSL_Status | GPIO_configBit (GPIO_Handle hGpio, CSL_GpioPinConfig *config)
CSL_Status | GPIO_disableInt (GPIO_Handle hGpio, CSL_GpioPinNum pin)
CSL_Status | GPIO_enableInt (GPIO_Handle hGpio, CSL_GpioPinNum pin)
CSL_Status | GPIO_clearInt (GPIO_Handle hGpio, CSL_GpioPinNum pin)
int | GPIO_statusBit (GPIO_Handle hGpio, CSL_GpioPinNum pin, CSL_Status *status)

## Detailed Description

GPIO functional layer API header file.

Path: \(CSLPATH)\inc