![]() |
LPCOpen Platform for LPC112X microcontrollers
112X
LPCOpen Platform for the NXP LPC112X family of Microcontrollers
|
For device familes identified with CHIP definitions CHIP_LPC11CXX, CHIP_LPC110X, and CHIP_LPC11XXLV only.
Data Structures | |
struct | LPC_GPIO_T |
GPIO port register block structure. More... | |
Enumerations | |
enum | GPIO_INT_MODE_T { GPIO_INT_ACTIVE_LOW_LEVEL = 0x0, GPIO_INT_ACTIVE_HIGH_LEVEL = 0x1, GPIO_INT_FALLING_EDGE = 0x2, GPIO_INT_RISING_EDGE = 0x3, GPIO_INT_BOTH_EDGES = 0x6 } |
GPIO interrupt mode definitions. More... | |
Functions | |
void | Chip_GPIO_Init (LPC_GPIO_T *pGPIO) |
Initialize GPIO block. More... | |
void | Chip_GPIO_DeInit (LPC_GPIO_T *pGPIO) |
De-Initialize GPIO block. More... | |
STATIC INLINE void | Chip_GPIO_WritePortBit (LPC_GPIO_T *pGPIO, uint32_t port, uint8_t bit, bool setting) |
Set a GPIO port/bit state. More... | |
STATIC INLINE void | Chip_GPIO_SetPinState (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin, bool setting) |
Set a GPIO pin state via the GPIO byte register. More... | |
STATIC INLINE bool | Chip_GPIO_ReadPortBit (LPC_GPIO_T *pGPIO, uint32_t port, uint8_t bit) |
Read a GPIO state. More... | |
STATIC INLINE bool | Chip_GPIO_GetPinState (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Get a GPIO pin state via the GPIO byte register. More... | |
void | Chip_GPIO_WriteDirBit (LPC_GPIO_T *pGPIO, uint32_t port, uint8_t bit, bool setting) |
Seta GPIO direction. More... | |
STATIC INLINE void | Chip_GPIO_SetPinDIROutput (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Set GPIO direction for a single GPIO pin to an output. More... | |
STATIC INLINE void | Chip_GPIO_SetPinDIRInput (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Set GPIO direction for a single GPIO pin to an input. More... | |
void | Chip_GPIO_SetPinDIR (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin, bool output) |
Set GPIO direction for a single GPIO pin. More... | |
STATIC INLINE bool | Chip_GPIO_ReadDirBit (LPC_GPIO_T *pGPIO, uint32_t port, uint8_t bit) |
Read a GPIO direction (out or in) More... | |
STATIC INLINE bool | Chip_GPIO_GetPinDIR (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Get GPIO direction for a single GPIO pin. More... | |
void | Chip_GPIO_SetDir (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t bit, uint8_t out) |
Set Direction for a GPIO port. More... | |
STATIC INLINE void | Chip_GPIO_SetPortDIROutput (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinMask) |
Set GPIO direction for a all selected GPIO pins to an output. More... | |
STATIC INLINE void | Chip_GPIO_SetPortDIRInput (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinMask) |
Set GPIO direction for a all selected GPIO pins to an input. More... | |
void | Chip_GPIO_SetPortDIR (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinMask, bool outSet) |
Set GPIO direction for a all selected GPIO pins to an input or output. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetPortDIR (LPC_GPIO_T *pGPIO, uint8_t port) |
Get GPIO direction for a all GPIO pins. More... | |
STATIC INLINE void | Chip_GPIO_SetPortValue (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t value) |
Set all GPIO raw pin states (regardless of masking) More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetPortValue (LPC_GPIO_T *pGPIO, uint8_t port) |
Get all GPIO raw pin states (regardless of masking) More... | |
STATIC INLINE void | Chip_GPIO_SetValue (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t bit) |
Set a GPIO port/bit to the high state. More... | |
STATIC INLINE void | Chip_GPIO_SetPortOutHigh (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pins) |
Set selected GPIO output pins to the high state. More... | |
STATIC INLINE void | Chip_GPIO_SetPinOutHigh (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Set an individual GPIO output pin to the high state. More... | |
STATIC INLINE void | Chip_GPIO_ClearValue (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t bit) |
Set a GPIO port/bit to the low state. More... | |
STATIC INLINE void | Chip_GPIO_SetPortOutLow (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pins) |
Set selected GPIO output pins to the low state. More... | |
STATIC INLINE void | Chip_GPIO_SetPinOutLow (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Set an individual GPIO output pin to the low state. More... | |
STATIC INLINE void | Chip_GPIO_SetPortToggle (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pins) |
Toggle selected GPIO output pins to the opposite state. More... | |
STATIC INLINE void | Chip_GPIO_SetPinToggle (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin) |
Toggle an individual GPIO output pin to the opposite state. More... | |
STATIC INLINE uint32_t | Chip_GPIO_ReadValue (LPC_GPIO_T *pGPIO, uint8_t port) |
Read current bit states for the selected port. More... | |
STATIC INLINE void | Chip_GPIO_SetPinModeEdge (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Configure the pins as edge sensitive for interrupts. More... | |
STATIC INLINE void | Chip_GPIO_SetPinModeLevel (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Configure the pins as level sensitive for interrupts. More... | |
STATIC INLINE uint32_t | Chip_GPIO_IsLevelEnabled (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns current GPIO edge or high level interrupt configuration for all pins for a port. More... | |
STATIC INLINE void | Chip_GPIO_SetEdgeModeBoth (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Sets GPIO interrupt configuration for both edges for selected pins. More... | |
STATIC INLINE void | Chip_GPIO_SetEdgeModeSingle (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Sets GPIO interrupt configuration for a single edge for selected pins. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetEdgeModeDir (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns current GPIO interrupt dual or single edge configuration for all pins for a port. More... | |
STATIC INLINE void | Chip_GPIO_SetModeHigh (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Sets GPIO interrupt configuration when in single edge or level mode to high edge trigger or high level. More... | |
STATIC INLINE void | Chip_GPIO_SetModeLow (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Sets GPIO interrupt configuration when in single edge or level mode to low edge trigger or low level. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetModeHighLow (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns current GPIO interrupt edge direction or level mode. More... | |
STATIC INLINE void | Chip_GPIO_EnableInt (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Enables interrupts for selected pins on a port. More... | |
STATIC INLINE void | Chip_GPIO_DisableInt (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Disables interrupts for selected pins on a port. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetEnabledInts (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns current enable pin interrupts for a port. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetRawInts (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns raw interrupt pending status for pin interrupts for a port. More... | |
STATIC INLINE uint32_t | Chip_GPIO_GetMaskedInts (LPC_GPIO_T *pGPIO, uint8_t port) |
Returns masked interrupt pending status for pin interrupts for a port. More... | |
STATIC INLINE void | Chip_GPIO_ClearInts (LPC_GPIO_T *pGPIO, uint8_t port, uint32_t pinmask) |
Clears pending interrupts for selected pins for a port. More... | |
void | Chip_GPIO_SetupPinInt (LPC_GPIO_T *pGPIO, uint8_t port, uint8_t pin, GPIO_INT_MODE_T mode) |
Composite function for setting up a full interrupt configuration for a single pin. More... | |
enum GPIO_INT_MODE_T |
GPIO interrupt mode definitions.
Definition at line 612 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_ClearInts | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Clears pending interrupts for selected pins for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to clear interrupts for (ORed value of bits 0..11) |
Definition at line 604 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_ClearValue | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | bit | ||
) |
Set a GPIO port/bit to the low state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
bit | : Bit(s) in the port to set low |
Definition at line 343 of file gpio_112x.h.
void Chip_GPIO_DeInit | ( | LPC_GPIO_T * | pGPIO | ) |
De-Initialize GPIO block.
pGPIO | : The base of GPIO peripheral on the chip |
Definition at line 58 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_DisableInt | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Disables interrupts for selected pins on a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to disable interrupts for (ORed value of bits 0..11) |
Definition at line 559 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_EnableInt | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Enables interrupts for selected pins on a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to enable interrupts for (ORed value of bits 0..11) |
Definition at line 547 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetEdgeModeDir | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns current GPIO interrupt dual or single edge configuration for all pins for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 492 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetEnabledInts | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns current enable pin interrupts for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 570 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetMaskedInts | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns masked interrupt pending status for pin interrupts for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 592 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetModeHighLow | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns current GPIO interrupt edge direction or level mode.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 535 of file gpio_112x.h.
STATIC INLINE bool Chip_GPIO_GetPinDIR | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Get GPIO direction for a single GPIO pin.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to get direction for |
Definition at line 198 of file gpio_112x.h.
STATIC INLINE bool Chip_GPIO_GetPinState | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Get a GPIO pin state via the GPIO byte register.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to get state for |
Definition at line 126 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetPortDIR | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Get GPIO direction for a all GPIO pins.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 263 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetPortValue | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Get all GPIO raw pin states (regardless of masking)
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 286 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_GetRawInts | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns raw interrupt pending status for pin interrupts for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 581 of file gpio_112x.h.
void Chip_GPIO_Init | ( | LPC_GPIO_T * | pGPIO | ) |
Initialize GPIO block.
pGPIO | : The base of GPIO peripheral on the chip |
Definition at line 52 of file gpio_112x.c.
STATIC INLINE uint32_t Chip_GPIO_IsLevelEnabled | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Returns current GPIO edge or high level interrupt configuration for all pins for a port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
Definition at line 451 of file gpio_112x.h.
STATIC INLINE bool Chip_GPIO_ReadDirBit | ( | LPC_GPIO_T * | pGPIO, |
uint32_t | port, | ||
uint8_t | bit | ||
) |
Read a GPIO direction (out or in)
pGPIO | : The base of GPIO peripheral on the chip |
port | : GPIO port to read |
bit | : GPIO bit to read |
Definition at line 186 of file gpio_112x.h.
STATIC INLINE bool Chip_GPIO_ReadPortBit | ( | LPC_GPIO_T * | pGPIO, |
uint32_t | port, | ||
uint8_t | bit | ||
) |
Read a GPIO state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : GPIO port to read |
bit | : GPIO bit to read |
Definition at line 113 of file gpio_112x.h.
STATIC INLINE uint32_t Chip_GPIO_ReadValue | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port | ||
) |
Read current bit states for the selected port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number to read |
Definition at line 412 of file gpio_112x.h.
void Chip_GPIO_SetDir | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | bit, | ||
uint8_t | out | ||
) |
Set Direction for a GPIO port.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port Number |
bit | : GPIO bit to set |
out | : Direction value, 0 = input, !0 = output |
Definition at line 75 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_SetEdgeModeBoth | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Sets GPIO interrupt configuration for both edges for selected pins.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to dual edge mode (ORed value of bits 0..11) |
Definition at line 463 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetEdgeModeSingle | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Sets GPIO interrupt configuration for a single edge for selected pins.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to single edge mode (ORed value of bits 0..11) |
Definition at line 475 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetModeHigh | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Sets GPIO interrupt configuration when in single edge or level mode to high edge trigger or high level.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to high mode (ORed value of bits 0..11) |
Definition at line 506 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetModeLow | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Sets GPIO interrupt configuration when in single edge or level mode to low edge trigger or low level.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to low mode (ORed value of bits 0..11) |
Definition at line 520 of file gpio_112x.h.
void Chip_GPIO_SetPinDIR | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin, | ||
bool | output | ||
) |
Set GPIO direction for a single GPIO pin.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to set direction for |
output | : true for output, false for input |
Definition at line 86 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_SetPinDIRInput | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Set GPIO direction for a single GPIO pin to an input.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to set direction on as input |
Definition at line 163 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinDIROutput | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Set GPIO direction for a single GPIO pin to an output.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to set direction on as output |
Definition at line 151 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinModeEdge | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Configure the pins as edge sensitive for interrupts.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to edge mode (ORed value of bits 0..11) |
Definition at line 424 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinModeLevel | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinmask | ||
) |
Configure the pins as level sensitive for interrupts.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinmask | : Pins to set to level mode (ORed value of bits 0..11) |
Definition at line 436 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinOutHigh | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Set an individual GPIO output pin to the high state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : pin number (0..n) to set high |
Definition at line 329 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinOutLow | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Set an individual GPIO output pin to the low state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : pin number (0..n) to set low |
Definition at line 371 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinState | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin, | ||
bool | setting | ||
) |
Set a GPIO pin state via the GPIO byte register.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : GPIO pin to set |
setting | : true for high, false for low |
Definition at line 100 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPinToggle | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin | ||
) |
Toggle an individual GPIO output pin to the opposite state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : pin number (0..n) to toggle |
Definition at line 399 of file gpio_112x.h.
void Chip_GPIO_SetPortDIR | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinMask, | ||
bool | outSet | ||
) |
Set GPIO direction for a all selected GPIO pins to an input or output.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinMask | : GPIO pin mask to set direction on (bits 0..b for pins 0..n) |
outSet | : Direction value, false = set as inputs, true = set as outputs |
Definition at line 97 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_SetPortDIRInput | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinMask | ||
) |
Set GPIO direction for a all selected GPIO pins to an input.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinMask | : GPIO pin mask to set direction on as input (bits 0..b for pins 0..n) |
Definition at line 238 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPortDIROutput | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pinMask | ||
) |
Set GPIO direction for a all selected GPIO pins to an output.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pinMask | : GPIO pin mask to set direction on as output (bits 0..n for pins 0..n) |
Definition at line 224 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPortOutHigh | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pins | ||
) |
Set selected GPIO output pins to the high state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pins | : pins (0..n) to set high |
Definition at line 315 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPortOutLow | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pins | ||
) |
Set selected GPIO output pins to the low state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pins | : pins (0..n) to set low |
Definition at line 357 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPortToggle | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | pins | ||
) |
Toggle selected GPIO output pins to the opposite state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pins | : pins (0..n) to toggle |
Definition at line 385 of file gpio_112x.h.
STATIC INLINE void Chip_GPIO_SetPortValue | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | value | ||
) |
Set all GPIO raw pin states (regardless of masking)
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
value | : Value to set all GPIO pin states (0..n) to |
Definition at line 275 of file gpio_112x.h.
void Chip_GPIO_SetupPinInt | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint8_t | pin, | ||
GPIO_INT_MODE_T | mode | ||
) |
Composite function for setting up a full interrupt configuration for a single pin.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
pin | : Pin number (0..11) |
mode | : GPIO interrupt mode selection |
Definition at line 108 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_SetValue | ( | LPC_GPIO_T * | pGPIO, |
uint8_t | port, | ||
uint32_t | bit | ||
) |
Set a GPIO port/bit to the high state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : Port number |
bit | : Bit(s) in the port to set high |
Definition at line 301 of file gpio_112x.h.
void Chip_GPIO_WriteDirBit | ( | LPC_GPIO_T * | pGPIO, |
uint32_t | port, | ||
uint8_t | bit, | ||
bool | setting | ||
) |
Seta GPIO direction.
pGPIO | : The base of GPIO peripheral on the chip |
port | : GPIO port to set |
bit | : GPIO bit to set |
setting | : true for output, false for input |
Definition at line 64 of file gpio_112x.c.
STATIC INLINE void Chip_GPIO_WritePortBit | ( | LPC_GPIO_T * | pGPIO, |
uint32_t | port, | ||
uint8_t | bit, | ||
bool | setting | ||
) |
Set a GPIO port/bit state.
pGPIO | : The base of GPIO peripheral on the chip |
port | : GPIO port to set |
bit | : GPIO bit to set |
setting | : true for high, false for low |
Definition at line 86 of file gpio_112x.h.