58 gpio_callbacks[(port << 3) + pin] = f;
72 for(i = 0; i < 8; i++) {
88 ENERGEST_ON(ENERGEST_TYPE_IRQ);
95 ENERGEST_OFF(ENERGEST_TYPE_IRQ);
104 ENERGEST_ON(ENERGEST_TYPE_IRQ);
111 ENERGEST_OFF(ENERGEST_TYPE_IRQ);
120 ENERGEST_ON(ENERGEST_TYPE_IRQ);
127 ENERGEST_OFF(ENERGEST_TYPE_IRQ);
136 ENERGEST_ON(ENERGEST_TYPE_IRQ);
143 ENERGEST_OFF(ENERGEST_TYPE_IRQ);
149 memset(gpio_callbacks, 0,
sizeof(gpio_callbacks));
#define GPIO_A_NUM
GPIO_A: 0.
void notify(uint8_t mask, uint8_t port)
Run through all registered GPIO callbacks and invoke those associated with the port and the pins spec...
#define GPIO_C_BASE
GPIO_C.
void gpio_port_d_isr()
Interrupt service routine for Port D.
#define GPIO_B_NUM
GPIO_B: 1.
Header file for the ARM Nested Vectored Interrupt Controller.
#define GPIO_A_BASE
GPIO_A.
#define GPIO_D_NUM
GPIO_D: 3.
Header file with register and macro declarations for the cc2538 GPIO module.
#define NULL
The null pointer.
void gpio_init()
Initialise the GPIO module.
#define lpm_exit()
Perform an 'Exit Deep Sleep' sequence.
void gpio_port_b_isr()
Interrupt service routine for Port B.
Header file with register manipulation macro definitions.
Header file for the energy estimation mechanism
#define GPIO_MIS
Interrupt status - masked.
#define GPIO_CLEAR_POWER_UP_INTERRUPT(PORT, PIN_MASK)
Clear power-up interrupt triggering for pins with PIN_MASK of port PORT.
void gpio_register_callback(gpio_callback_t f, uint8_t port, uint8_t pin)
Register GPIO callback.
void gpio_port_c_isr()
Interrupt service routine for Port C.
#define GPIO_B_BASE
GPIO_B.
#define GPIO_C_NUM
GPIO_C: 2.
void(* gpio_callback_t)(uint8_t port, uint8_t pin)
Type definition for callbacks invoked by the GPIO ISRs.
#define GPIO_CLEAR_INTERRUPT(PORT_BASE, PIN_MASK)
Clear interrupt triggering for pins with PIN_MASK of port with PORT_BASE.
void gpio_port_a_isr()
Interrupt service routine for Port A.
#define GPIO_D_BASE
GPIO_D.