Contiki-NG
|
Files | |
file | ioc.c |
Implementation of IOC functions. | |
file | ioc.h |
Header file with declarations for the I/O Control module. | |
IOC Functions | |
void | ioc_init () |
Initialise the IOC driver. | |
void | ioc_set_over (uint8_t port, uint8_t pin, uint8_t over) |
Set Port:Pin override function. | |
uint32_t | ioc_get_over (uint8_t port, uint8_t pin) |
Get Port:Pin override function. | |
void | ioc_set_sel (uint8_t port, uint8_t pin, uint8_t sel) |
Function select for Port:Pin. | |
#define | ioc_input_sel(port, pin) ((port << 3) | pin) |
Generates an IOC_INPUT_SEL_PXn value from a port/pin number. | |
Driver for the cc2538 I/O Control Module
#define ioc_input_sel | ( | port, | |
pin ) ((port << 3) | pin) |
Generates an IOC_INPUT_SEL_PXn value from a port/pin number.
port | The port as a number (PA: 0, PB: 1 etc) |
pin | The pin as a number |
Definition at line 286 of file ioc.h.
Referenced by i2c_init(), and uart_init().
uint32_t ioc_get_over | ( | uint8_t | port, |
uint8_t | pin ) |
Get Port:Pin override function.
port | The port as a number (PA: 0, PB: 1 etc) |
pin | The pin as a number |
The return value can be one of
Definition at line 60 of file ioc.c.
Referenced by gpio_hal_arch_no_port_pin_cfg_get().
void ioc_set_over | ( | uint8_t | port, |
uint8_t | pin, | ||
uint8_t | over ) |
Set Port:Pin override function.
port | The port as a number (PA: 0, PB: 1 etc) |
pin | The pin as a number |
over | The desired override configuration |
over can take the following values:
Definition at line 54 of file ioc.c.
Referenced by configure(), gpio_hal_arch_no_port_pin_cfg_set(), i2c_init(), pwm_disable(), pwm_start(), pwm_stop(), rtcc_set_alarm_time_date(), spi_arch_lock_and_open(), spix_cs_init(), spix_init(), sys_ctrl_init(), and uart_init().
void ioc_set_sel | ( | uint8_t | port, |
uint8_t | pin, | ||
uint8_t | sel ) |
Function select for Port:Pin.
port | The port as a number (PA: 0, PB: 1 etc) |
pin | The pin as a number |
sel | The desired function |
The value of sel can be any of the IOC_PXX_SEL_xyz defines. For example IOC_PXX_SEL_UART0_TXD will set the port to act as UART0 TX
Definition at line 66 of file ioc.c.
Referenced by i2c_init(), pwm_start(), spi_arch_lock_and_open(), spix_init(), and uart_init().