Paparazzi UAS  v5.2.2_stable-0-gd6b9f29
Paparazzi is a free software Unmanned Aircraft System.
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
telemetry.h File Reference

Periodic telemetry system header (includes downlink utility and generated code). More...

#include "std.h"
#include "messages.h"
#include "mcu_periph/uart.h"
#include "subsystems/datalink/downlink.h"
#include "generated/periodic_telemetry.h"
+ Include dependency graph for telemetry.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Detailed Description

Periodic telemetry system header (includes downlink utility and generated code).

In order to use it a subsystem/module:

  • include this header:
    #include "susystems/datalink/telemetry.h"
  • write a callback function:
    void your_callback(void) {
    // your code to send a telemetry message goes here
    }
  • register your callback function (if the message name doesn't match one of the names in your telemetry xml file or is already registered, the function return FALSE)
    register_periodic_telemetry(&your_telemetry_struct, "YOUR_MESSAGE_NAME", your_callback);
    In most cases, the default telemetry structure should be used (replace &your_telemetry_struct by DefaultPeriodic in the register function).

Definition in file telemetry.h.