Esky150: add sub protocols 4CH and 7CH

This commit is contained in:
pascallanger 2019-11-28 17:01:33 +01:00
parent 6a7497cdf8
commit c803eeb26a
6 changed files with 24 additions and 8 deletions

View File

@ -92,8 +92,8 @@ static void __attribute__((unused)) ESKY150_send_packet()
uint8_t flight_mode=0; uint8_t flight_mode=0;
uint16_t aux_ch6=0; uint16_t aux_ch6=0;
uint8_t aux_ch7=0; uint8_t aux_ch7=0;
if(option==1) if(sub_protocol)
{ { // 7 channels
flight_mode=ESKY150_convert_2bit_channel(CH5); flight_mode=ESKY150_convert_2bit_channel(CH5);
aux_ch6=convert_channel_16b_limit(CH6,1000,2000); aux_ch6=convert_channel_16b_limit(CH6,1000,2000);
aux_ch7=ESKY150_convert_2bit_channel(CH7); aux_ch7=ESKY150_convert_2bit_channel(CH7);

View File

@ -13,7 +13,7 @@
13,CG023,CG023,YD829 13,CG023,CG023,YD829
14,Bayang,Bayang,H8S3D,X16_AH,IRDRONE,DHD_D4 14,Bayang,Bayang,H8S3D,X16_AH,IRDRONE,DHD_D4
15,FrskyX,CH_16,CH_8,EU_16,EU_8 15,FrskyX,CH_16,CH_8,EU_16,EU_8
16,ESky 16,ESky,4CH,7CH
17,MT99xx,MT,H7,YZ,LS,FY805 17,MT99xx,MT,H7,YZ,LS,FY805
18,MJXq,WLH08,X600,X800,H26D,E010,H26WH,PHOENIX 18,MJXq,WLH08,X600,X800,H26D,E010,H26WH,PHOENIX
19,Shenqi 19,Shenqi

View File

@ -108,8 +108,9 @@ const char STR_SUBTYPE_REDPINE[] = "\x04""Fast""Slow";
const char STR_SUBTYPE_POTENSIC[] = "\x03""A20"; const char STR_SUBTYPE_POTENSIC[] = "\x03""A20";
const char STR_SUBTYPE_ZSX[] = "\x07""280JJRC"; const char STR_SUBTYPE_ZSX[] = "\x07""280JJRC";
const char STR_SUBTYPE_FLYZONE[] = "\x05""FZ410"; const char STR_SUBTYPE_FLYZONE[] = "\x05""FZ410";
const char STR_SUBTYPE_FX816[] = "\x03""P38"; const char STR_SUBTYPE_FX816[] = "\x03""P38";
const char STR_SUBTYPE_XN297DUMP[] = "\x07""250Kbps""1Mbps\0 ""2Mbps\0 "; const char STR_SUBTYPE_XN297DUMP[] = "\x07""250Kbps""1Mbps\0 ""2Mbps\0 ";
const char STR_SUBTYPE_ESKY150[] = "\x03""4CH""7CH";
enum enum
{ {
@ -228,7 +229,7 @@ const mm_protocol_definition multi_protocols[] = {
{PROTO_CABELL, STR_CABELL, 8, STR_SUBTYPE_CABELL, OPTION_OPTION }, {PROTO_CABELL, STR_CABELL, 8, STR_SUBTYPE_CABELL, OPTION_OPTION },
#endif #endif
#if defined(ESKY150_NRF24L01_INO) #if defined(ESKY150_NRF24L01_INO)
{PROTO_ESKY150, STR_ESKY150, 0, NO_SUBTYPE, OPTION_NONE }, {PROTO_ESKY150, STR_ESKY150, 2, STR_SUBTYPE_ESKY150, OPTION_NONE },
#endif #endif
#if defined(H8_3D_NRF24L01_INO) #if defined(H8_3D_NRF24L01_INO)
{PROTO_H8_3D, STR_H8_3D, 4, STR_SUBTYPE_H83D, OPTION_NONE }, {PROTO_H8_3D, STR_H8_3D, 4, STR_SUBTYPE_H83D, OPTION_NONE },

View File

@ -19,7 +19,7 @@
#define VERSION_MAJOR 1 #define VERSION_MAJOR 1
#define VERSION_MINOR 3 #define VERSION_MINOR 3
#define VERSION_REVISION 0 #define VERSION_REVISION 0
#define VERSION_PATCH_LEVEL 45 #define VERSION_PATCH_LEVEL 46
//****************** //******************
// Protocols // Protocols
@ -292,6 +292,11 @@ enum TRAXXAS
{ {
RX6519 = 0, RX6519 = 0,
}; };
enum ESKY150
{
ESKY150_4CH = 0,
ESKY150_7CH = 1,
};
#define NONE 0 #define NONE 0
#define P_HIGH 1 #define P_HIGH 1
@ -814,6 +819,9 @@ Serial: 100000 Baud 8e2 _ xxxx xxxx p --
RED_SLOW 1 RED_SLOW 1
sub_protocol==TRAXXAS sub_protocol==TRAXXAS
RX6519 0 RX6519 0
sub_protocol==ESKY150
ESKY150_4CH 0
ESKY150_7CH 1
Power value => 0x80 0=High/1=Low Power value => 0x80 0=High/1=Low
Stream[3] = option_protocol; Stream[3] = option_protocol;

View File

@ -543,7 +543,8 @@ const PPM_Parameters PPM_prot[14*NBR_BANKS]= {
PROTO_ESKY PROTO_ESKY
NONE NONE
PROTO_ESKY150 PROTO_ESKY150
NONE ESKY150_4CH
ESKY150_7CH
PROTO_FLYSKY PROTO_FLYSKY
Flysky Flysky
V9X9 V9X9

View File

@ -827,7 +827,13 @@ A|E|T|R|GYRO|PITCH
## ESKY150 - *35* ## ESKY150 - *35*
ESky protocol for small models since 2014 (150, 300, 150X, ...) ESky protocol for small models since 2014 (150, 300, 150X, ...)
Number of channels are set with option. option=0 4 channels and option=1 7 channels. An invalid option value will end up with 4 channels. ### Sub_protocol 4CH - *0*
CH1|CH2|CH3|CH4
---|---|---|---
A|E|T|R
### Sub_protocol 7CH - *1*
CH1|CH2|CH3|CH4|CH5|CH6|CH7 CH1|CH2|CH3|CH4|CH5|CH6|CH7
---|---|---|---|---|---|--- ---|---|---|---|---|---|---