Go to the documentation of this file.
39 #ifndef ALTERA_GPIO_H_
40 #define ALTERA_GPIO_H_
uint32_t base_address
Definition: altera_gpio.h:73
void * extra
Definition: no_os_gpio.h:112
Structure holding the parameters for GPIO initialization.
Definition: no_os_gpio.h:85
int32_t altera_gpio_get_direction(struct no_os_gpio_desc *desc, uint8_t *direction)
Get the direction of the specified GPIO.
Definition: altera_gpio.c:163
Altera platform specific GPIO descriptor.
Definition: altera_gpio.h:80
Header file of Delay functions.
int32_t no_os_axi_io_read(uint32_t base, uint32_t offset, uint32_t *data)
AXI IO Altera specific read function.
Definition: altera_axi_io.c:59
int32_t number
Definition: no_os_gpio.h:89
void * no_os_calloc(size_t nitems, size_t size)
Allocate memory and return a pointer to it, set memory to 0.
Definition: chibios_alloc.c:60
@ NIOS_II_GPIO
Definition: altera_gpio.h:59
uint32_t device_id
Definition: altera_gpio.h:71
const struct no_os_gpio_platform_ops altera_gpio_ops
Altera platform specific GPIO platform ops structure.
Definition: altera_gpio.c:259
void no_os_mdelay(uint32_t msecs)
Generate miliseconds delay.
Definition: altera_delay.c:65
int32_t altera_gpio_get(struct no_os_gpio_desc **desc, const struct no_os_gpio_init_param *param)
Obtain the GPIO decriptor.
Definition: altera_gpio.c:62
enum gpio_type type
Definition: altera_gpio.h:69
void no_os_udelay(uint32_t usecs)
Generate microseconds delay.
Definition: altera_delay.c:55
int32_t altera_gpio_direction_input(struct no_os_gpio_desc *desc)
Enable the input direction of the specified GPIO.
Definition: altera_gpio.c:132
Structure holding the GPIO descriptor.
Definition: no_os_gpio.h:102
gpio_type
Altera platform architecture types.
Definition: altera_gpio.h:57
int32_t no_os_gpio_get(struct no_os_gpio_desc **desc, const struct no_os_gpio_init_param *param)
Obtain the GPIO decriptor.
Definition: no_os_gpio.c:55
Structure holding the initialization parameters for Altera platform specific GPIO parameters.
Definition: altera_gpio.h:67
void no_os_free(void *ptr)
Deallocate memory previously allocated by a call to no_os_calloc or no_os_malloc.
Definition: chibios_alloc.c:75
int32_t altera_gpio_remove(struct no_os_gpio_desc *desc)
Free the resources allocated by no_os_gpio_get().
Definition: altera_gpio.c:117
#define NULL
Definition: wrapper.h:64
uint32_t device_id
Definition: altera_gpio.h:84
int32_t altera_gpio_get_value(struct no_os_gpio_desc *desc, uint8_t *value)
Get the value of the specified GPIO.
Definition: altera_gpio.c:226
int32_t no_os_gpio_set_value(struct no_os_gpio_desc *desc, uint8_t value)
Set the value of the specified GPIO.
Definition: no_os_gpio.c:203
int32_t altera_gpio_set_value(struct no_os_gpio_desc *desc, uint8_t value)
Set the value of the specified GPIO.
Definition: altera_gpio.c:185
const struct no_os_gpio_platform_ops altera_gpio_ops
Altera platform specific gpio platform ops structure.
Definition: altera_gpio.c:259
void * extra
Definition: no_os_gpio.h:95
int32_t altera_gpio_direction_output(struct no_os_gpio_desc *desc, uint8_t value)
Enable the output direction of the specified GPIO.
Definition: altera_gpio.c:149
Header file of GPIO Interface.
int32_t no_os_axi_io_write(uint32_t base, uint32_t offset, uint32_t data)
AXI IO Altera specific write function.
Definition: altera_axi_io.c:73
enum gpio_type type
Definition: altera_gpio.h:82
uint32_t base_address
Definition: altera_gpio.h:86
int32_t number
Definition: no_os_gpio.h:106
int32_t altera_gpio_get_optional(struct no_os_gpio_desc **desc, const struct no_os_gpio_init_param *param)
Get the value of an optional GPIO.
Definition: altera_gpio.c:101