BUGSMINI sub protocol BUGS3H

This commit is contained in:
Pascal Langer committed 2019-04-18 10:44:42 +02:00
1 parent 6bc22c8ac4
commit 21790a9725
4 files changed
+27 -10

No files matched your search

+17 -5
View File
@@ -237,12 +237,24 @@ static void __attribute__((unused)) BUGSMINI_update_telemetry()
if(packet[0] == checksum)
{
RX_RSSI = packet[3];
if(packet[11] & 0x80)
v_lipo1 = 0xff; // Ok
else if(packet[11] & 0x40)
v_lipo1 = 0x80; // Warning
if(sub_protocol==BUGS3H)
{
if(packet[11] & 0x40)
v_lipo1 = 0x40; // Warning
else if(packet[11] & 0x80)
v_lipo1 = 0x20; // Critical
else
v_lipo1 = 0x80; // Ok
}
else
v_lipo1 = 0x00; // Critical
{
if(packet[11] & 0x80)
v_lipo1 = 0x80; // Ok
else if(packet[11] & 0x40)
v_lipo1 = 0x40; // Warning
else
v_lipo1 = 0x20; // Critical
}
telemetry_link=1;
}
#endif