Fix compiler errors when telemetry is disabled (#474)

This commit is contained in:
Ben Lye authored and GitHub committed 2020-11-30 08:38:21 +01:00
1 parent e53f723fdb
commit b4421306c0
2 files changed
+13 -10

No files matched your search

+12 -10
View File
@@ -142,18 +142,20 @@ static void __attribute__((unused)) OMP_initialize_txid()
#endif
}
static void __attribute__((unused)) OMP_Send_Telemetry(uint8_t v)
{
v_lipo1=v;
telemetry_counter++; //LQI
telemetry_link=1;
if(telemetry_lost)
#ifdef OMP_HUB_TELEMETRY
static void __attribute__((unused)) OMP_Send_Telemetry(uint8_t v)
{
telemetry_lost = 0;
packet_count = 100;
telemetry_counter = 100;
v_lipo1=v;
telemetry_counter++; //LQI
telemetry_link=1;
if(telemetry_lost)
{
telemetry_lost = 0;
packet_count = 100;
telemetry_counter = 100;
}
}
}
#endif
enum {
OMP_BIND = 0x00,
+1
View File
@@ -344,6 +344,7 @@
#undef OMP_HUB_TELEMETRY
#undef RLINK_HUB_TELEMETRY
#undef DSM_RX_CYRF6936_INO
#undef DSM_FWD_PGM
#else
#if defined(MULTI_TELEMETRY) && defined(MULTI_STATUS)
#error You should choose either MULTI_TELEMETRY or MULTI_STATUS but not both.