BUGSMINI sub protocol BUGS3H

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

View File

@ -237,12 +237,24 @@ static void __attribute__((unused)) BUGSMINI_update_telemetry()
if(packet[0] == checksum) if(packet[0] == checksum)
{ {
RX_RSSI = packet[3]; RX_RSSI = packet[3];
if(packet[11] & 0x80) if(sub_protocol==BUGS3H)
v_lipo1 = 0xff; // Ok {
else if(packet[11] & 0x40) if(packet[11] & 0x40)
v_lipo1 = 0x80; // Warning v_lipo1 = 0x40; // Warning
else if(packet[11] & 0x80)
v_lipo1 = 0x20; // Critical
else
v_lipo1 = 0x80; // Ok
}
else 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; telemetry_link=1;
} }
#endif #endif

View File

@ -39,7 +39,7 @@
39,Hitec,OPT_FW,OPT_HUB,MINIMA 39,Hitec,OPT_FW,OPT_HUB,MINIMA
40,WFLY 40,WFLY
41,BUGS 41,BUGS
42,BUGSMINI 42,BUGSMINI,BUGSMINI,BUGS3H
43,Traxxas 43,Traxxas
44,NCC1701 44,NCC1701
45,E01X,E012,E015,E016H 45,E01X,E012,E015,E016H

View File

@ -19,7 +19,7 @@
#define VERSION_MAJOR 1 #define VERSION_MAJOR 1
#define VERSION_MINOR 2 #define VERSION_MINOR 2
#define VERSION_REVISION 1 #define VERSION_REVISION 1
#define VERSION_PATCH_LEVEL 36 #define VERSION_PATCH_LEVEL 37
//****************** //******************
// Protocols // Protocols
@ -257,12 +257,16 @@ enum E01X
E015 = 1, E015 = 1,
E016H = 2, E016H = 2,
}; };
enum PROTO_GD00X enum GD00X
{ {
GD_V1 = 0, GD_V1 = 0,
GD_V2 = 1, GD_V2 = 1,
}; };
enum BUGSMINI
{
BUGSMINI= 0,
BUGS3H = 1,
};
#define NONE 0 #define NONE 0
#define P_HIGH 1 #define P_HIGH 1
#define P_LOW 0 #define P_LOW 0

View File

@ -468,7 +468,8 @@ const PPM_Parameters PPM_prot[14*NBR_BANKS]= {
PROTO_BUGS PROTO_BUGS
NONE NONE
PROTO_BUGSMINI PROTO_BUGSMINI
NONE BUGSMINI
BUGS3H
PROTO_CABELL PROTO_CABELL
CABELL_V3 CABELL_V3
CABELL_V3_TELEMETRY CABELL_V3_TELEMETRY