|
Core
|
Core GPIO library. More...
Functions | |
| void | core_GPIO_init (GPIO_TypeDef *port, uint16_t pin, uint16_t dir, uint32_t pull) |
| Initialize a GPIO pin. | |
| void | core_GPIO_digital_write (GPIO_TypeDef *port, uint16_t pin, bool state) |
| Set a digital output. | |
| bool | core_GPIO_digital_read (GPIO_TypeDef *port, uint16_t pin) |
| Read a digital input. | |
| void | core_heartbeat_init (GPIO_TypeDef *port, uint16_t pin) |
| Set a particular pin as the heartbeat LED output. | |
| void | core_GPIO_toggle_heartbeat () |
| Toggle the heartbeat LED output. | |
| void | core_GPIO_set_heartbeat (bool state) |
| Set the state of the heartbeat LED. | |
Core GPIO library.
This core library component is used to initialize and control GPIO pins.
| bool core_GPIO_digital_read | ( | GPIO_TypeDef * | port, |
| uint16_t | pin ) |
Read a digital input.
| port | GPIO port (GPIOx) |
| pin | GPIO pin (GPIO_PIN_x) |
| void core_GPIO_digital_write | ( | GPIO_TypeDef * | port, |
| uint16_t | pin, | ||
| bool | state ) |
Set a digital output.
| port | GPIO port (GPIOx) |
| pin | GPIO pin (GPIO_PIN_x) |
| state | The desired setting of the output |
| void core_GPIO_init | ( | GPIO_TypeDef * | port, |
| uint16_t | pin, | ||
| uint16_t | dir, | ||
| uint32_t | pull ) |
Initialize a GPIO pin.
| port | Port on which the pin is located (GPIOx) |
| pin | Pin number (GPIO_PIN_x) |
| dir | Direction or pin mode (GPIO_MODE_INPUT, GPIO_MODE_OUTPUT_PP, GPIO_MODE_OUTPUT_OD, GPIO_MODE_AF_PP, GPIO_MODE_AF_OD, or GPIO_MODE_ANALOG) |
| pull | Pullup/pulldown resistor configuration (GPIO_NOPULL, GPIO_PULLUP, GPIO_PULLDOWN) |
| void core_GPIO_set_heartbeat | ( | bool | state | ) |
Set the state of the heartbeat LED.
| state | The desired setting of the output |
| void core_heartbeat_init | ( | GPIO_TypeDef * | port, |
| uint16_t | pin ) |
Set a particular pin as the heartbeat LED output.
| port | GPIO port (GPIOx) |
| pin | GPIO pin (GPIO_PIN_x) |