|
Paparazzi UAS
v5.18.0_stable
Paparazzi is a free software Unmanned Aircraft System.
|
Go to the documentation of this file.
31 #include "generated/airframe.h"
32 #include "generated/modules.h"
37 #if (!defined BAT_CHECKER_GPIO && !defined BAT_CHECKER_LED)
38 #error You must define BAT_CHECKER_GPIO or BAT_CHECKER_LED in your airframe file.
42 #ifndef BAT_CHECKER_GPIO_ON
43 #define BAT_CHECKER_GPIO_ON gpio_set
45 #ifndef BAT_CHECKER_GPIO_OFF
46 #define BAT_CHECKER_GPIO_OFF gpio_clear
51 #ifdef BAT_CHECKER_LED
55 #ifdef BAT_CHECKER_GPIO
64 #ifdef BAT_CHECKER_LED
67 #ifdef BAT_CHECKER_GPIO
71 #ifdef BAT_CHECKER_LED
74 #ifdef BAT_CHECKER_GPIO
78 #ifdef BAT_CHECKER_LED
81 #ifdef BAT_CHECKER_GPIO
void gpio_setup_output(ioportid_t port, uint16_t gpios)
Setup one or more pins of the given GPIO port as outputs.
#define BAT_CHECKER_GPIO_ON
bool bat_low
battery low status
void bat_checker_periodic(void)
arch independent LED (Light Emitting Diodes) API
static void gpio_toggle(ioportid_t port, uint16_t pin)
Toggle a gpio output to low level.
bool bat_critical
battery critical status
void init_bat_checker(void)
struct Electrical electrical
#define BAT_CHECKER_GPIO_OFF