libpynq
(release 5EID0-2023 version 0.3.0 of 2024-04-25 09:42 )
|
Functions | |
int | gpio_interrupt_init (void) |
void | gpio_ack_interrupt (void) |
void | verify_interrupt_request (const io_t pin) |
void | gpio_print_interrupt (void) |
void | gpio_enable_interrupt (const io_t pin) |
void | gpio_disable_interrupt (const io_t pin) |
void | gpio_disable_all_interrupts (void) |
uint64_t | gpio_get_interrupt (void) |
uint8_t * | gpio_get_interrupt_pins (uint8_t *positions) |
void | gpio_wait_for_interrupt (const io_t pin) |
Functions for interrupt handling.
An example of using this library
void gpio_ack_interrupt | ( | void | ) |
acknowledges the raised interrupts and resets the interrupt word. Allows new interrupts to occur on the previously triggered pins.
Definition at line 3 of file interrupt.c.
void gpio_disable_all_interrupts | ( | void | ) |
Disables all interrupts from being raised.
Definition at line 8 of file interrupt.c.
void gpio_disable_interrupt | ( | const io_t | pin | ) |
Disables interrupts from occuring on the specific pin. Hereafter, the pin will not trigger an interrupt.
pin | to be disabled from obtianing interrupts |
Definition at line 7 of file interrupt.c.
void gpio_enable_interrupt | ( | const io_t | pin | ) |
enables a specific pin to raise interrupts.
pin | to raise interrupts |
Definition at line 6 of file interrupt.c.
uint64_t gpio_get_interrupt | ( | void | ) |
Definition at line 9 of file interrupt.c.
uint8_t* gpio_get_interrupt_pins | ( | uint8_t * | positions | ) |
Gets all pins on which an interrupt occurred.
Definition at line 10 of file interrupt.c.
int gpio_interrupt_init | ( | void | ) |
Enables interrupts to be set and read.
Definition at line 2 of file interrupt.c.
void gpio_print_interrupt | ( | void | ) |
prints the current interrupt word
Definition at line 5 of file interrupt.c.
void gpio_wait_for_interrupt | ( | const io_t | pin | ) |
Waits untill an interrupt occurs on the specified pin or if the value of pin is larger than 63, if any interrupt has occurred.
pin | The pin on which an interrupt should occur |
Definition at line 11 of file interrupt.c.
void verify_interrupt_request | ( | const io_t | pin | ) |
Checks for error in enabled pin. Terminates the process if the pin is not enabled.
pin | indicates a specific pin or if larger than 63, if any interrupt pin is enabled |
Definition at line 4 of file interrupt.c.