[telemetry] protect telemetry code with #if DOWNLINK

- also get rid of AP_DOWNLINK and FBW_DOWNLINK
- still needs to make it work again (for the only remaining classix in
  the world...)
This commit is contained in:
Gautier Hattenberger
2013-06-17 01:06:45 +02:00
parent 6ec20fd834
commit 116faaeda6
38 changed files with 203 additions and 125 deletions
+7 -3
View File
@@ -36,11 +36,11 @@
#include <math.h>
#include "navdata.h"
#include "subsystems/datalink/downlink.h"
#include "generated/periodic_telemetry.h"
int nav_fd;
#if DOWNLINK
#include "subsystems/datalink/telemetry.h"
static void send_navdata(void) {
DOWNLINK_SEND_ARDRONE_NAVDATA(DefaultChannel, DefaultDevice,
&navdata->taille,
@@ -72,6 +72,7 @@ static void send_navdata(void) {
&navdata->mz,
&navdata->chksum);
}
#endif
int navdata_init()
{
@@ -122,7 +123,10 @@ int navdata_init()
previousUltrasoundHeight = 0;
#if DOWNLINK
register_periodic_telemetry(DefaultPeriodic, "ARDRONE_NAVDATA", send_navdata);
#endif
return 0;
}