Wirepas SDK
io.h File Reference

Go to the source code of this file.

Typedefs

typedef void(* wakeup_cb_f) (void)
 Mandatory callback for EXTI events. More...
 

Functions

void Io_init (void)
 Initialize IO's to a known state. More...
 
void Io_enableUartIrq (void)
 Enables UART IRQ pin. More...
 
void Io_setUartIrq (void)
 Sets (asserts) UART IRQ pin. More...
 
void Io_clearUartIrq (void)
 Clears (de-asserts) UART IRQ pin. More...
 
void Wakeup_pinInit (wakeup_cb_f cb)
 Setup wake-up pin. More...
 
void Wakeup_off (void)
 Disable wake-up functionality. More...
 
void Wakeup_clearIrq (void)
 Clear interrupt source flag. More...
 
void Wakeup_setEdgeIRQ (exti_irq_config_e edge, bool enable)
 Change edge for wake-up pin. More...
 

Enumerations

enum  exti_irq_config_e { EXTI_IRQ_RISING_EDGE = 0x01, EXTI_IRQ_FALLING_EDGE = 0x10, EXTI_IRQ_STATE_CHANGE = EXTI_IRQ_RISING_EDGE | EXTI_IRQ_FALLING_EDGE }
 

Typedef Documentation

◆ wakeup_cb_f

typedef void(* wakeup_cb_f) (void)

Mandatory callback for EXTI events.

Definition at line 43 of file io.h.

Function Documentation

◆ Io_clearUartIrq()

void Io_clearUartIrq ( void  )

Clears (de-asserts) UART IRQ pin.

◆ Io_enableUartIrq()

void Io_enableUartIrq ( void  )

Enables UART IRQ pin.

◆ Io_init()

void Io_init ( void  )

Initialize IO's to a known state.

◆ Io_setUartIrq()

void Io_setUartIrq ( void  )

Sets (asserts) UART IRQ pin.

◆ Wakeup_clearIrq()

void Wakeup_clearIrq ( void  )

Clear interrupt source flag.

◆ Wakeup_off()

void Wakeup_off ( void  )

Disable wake-up functionality.

◆ Wakeup_pinInit()

void Wakeup_pinInit ( wakeup_cb_f  cb)

Setup wake-up pin.

Parameters
cbMandatory callback that is invoked on event
Postcondition
Pin (EXTI channel) is fired and waiting for a falling edge trigger

◆ Wakeup_setEdgeIRQ()

void Wakeup_setEdgeIRQ ( exti_irq_config_e  edge,
bool  enable 
)

Change edge for wake-up pin.

Parameters
edgeEdge type to configure
enableEnable pin interrrupt

Enumeration Type Documentation

◆ exti_irq_config_e

Enumerator
EXTI_IRQ_RISING_EDGE 
EXTI_IRQ_FALLING_EDGE 
EXTI_IRQ_STATE_CHANGE 

Definition at line 33 of file io.h.

EXTI_IRQ_STATE_CHANGE
@ EXTI_IRQ_STATE_CHANGE
Definition: io.h:37
exti_irq_config_e
exti_irq_config_e
Definition: io.h:33
EXTI_IRQ_FALLING_EDGE
@ EXTI_IRQ_FALLING_EDGE
Definition: io.h:36
EXTI_IRQ_RISING_EDGE
@ EXTI_IRQ_RISING_EDGE
Definition: io.h:35