Paparazzi UAS  v5.15_devel-230-gc96ce27
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
led_hw.h File Reference
#include <stdio.h>
#include <caml/mlvalues.h>
#include <caml/memory.h>
#include <caml/callback.h>
+ Include dependency graph for led_hw.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.


#define LED_INIT(i)   { led_disable = false; }
#define LED_ON(i)   { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(1)); }
#define LED_OFF(i)   { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(0)); }
#define LED_TOGGLE(i)   { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(2)); }
#define LED_DISABLE(i)   { LED_OFF(i); led_disable = true; }
#define LED_PERIODIC()   {}


value * leds_closure
bool led_disable

Macro Definition Documentation

#define LED_DISABLE (   i)    { LED_OFF(i); led_disable = true; }

Definition at line 16 of file led_hw.h.

#define LED_INIT (   i)    { led_disable = false; }

Definition at line 12 of file led_hw.h.

#define LED_OFF (   i)    { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(0)); }

Definition at line 14 of file led_hw.h.

#define LED_ON (   i)    { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(1)); }

Definition at line 13 of file led_hw.h.

#define LED_PERIODIC ( )    {}

Definition at line 18 of file led_hw.h.

#define LED_TOGGLE (   i)    { if (leds_closure && !led_disable) callback2(*leds_closure, Val_int(i), Val_int(2)); }

Definition at line 15 of file led_hw.h.

Variable Documentation

bool led_disable

Definition at line 4 of file led_hw.c.

value* leds_closure

Definition at line 3 of file led_hw.c.

Referenced by register_leds_cb().