mirror of
https://github.com/pascallanger/DIY-Multiprotocol-TX-Module.git
synced 2025-02-04 19:48:11 +00:00
Compare commits
2 Commits
600ffe87d7
...
8685fcae7f
Author | SHA1 | Date | |
---|---|---|---|
|
8685fcae7f | ||
|
6edd2a14a7 |
@ -204,7 +204,7 @@
|
||||
81,0,E010r5,E010r5,1,Flip,LED,CALIB,HLess,RTH,GLIDE
|
||||
82,0,LOLI,Std,0,CH5,CH6,CH7,CH8,1SwSePpPw,2SwSePw,3SwSe,4SwSe,5SwSeSb,6SwSe,7SwSePw,8SwSe
|
||||
83,0,E129,E129,1,TakLan,EmStop,TrimA,TrimE,TrimR
|
||||
83,1,E129,C186,1,TakLan,EmStop,TrimA,TrimE,TrimR,Loop,Flip
|
||||
83,1,E129,C186,1,TakLan,EmStop,TrimA,TrimE,TrimR,Loop,Flip,Debug
|
||||
84,0,JOYSWAY,Std,0
|
||||
85,0,E016H,Std,1,Stop,Flip,n-a,HLess,RTH
|
||||
87,0,IKEA
|
||||
|
@ -41,7 +41,8 @@ static void __attribute__((unused)) E129_build_data_packet()
|
||||
}
|
||||
else
|
||||
{
|
||||
packet[ 1] = 0xA6;
|
||||
packet[ 1] = 0xA6; // Set to A5 every few packets??
|
||||
|
||||
//Flags
|
||||
if(sub_protocol == E129_E129)
|
||||
packet[ 2] = 0xF7; // High rate 0xF7, low 0xF4
|
||||
@ -53,11 +54,18 @@ static void __attribute__((unused)) E129_build_data_packet()
|
||||
packet[15] = bit_reverse(rx_tx_addr[0]);
|
||||
packet[16] = bit_reverse(rx_tx_addr[1]);
|
||||
}
|
||||
packet[ 3] = GET_FLAG(CH10_SW, 0x40) // C159 loop flight 0x40, flag 0x04 is also set on this heli
|
||||
| GET_FLAG(CH11_SW, 0x08); // C129V2 flip
|
||||
// Other flags in packet[3] => E129 Mode: short press=0x20->0x00->0x20->..., long press=0x10->0x30->0x10->... => C186 throttle trim is doing the same:up=short press and down=long press
|
||||
packet[ 3] = GET_FLAG(CH10_SW, 0x40) // C159: loop flight 0x40
|
||||
| GET_FLAG(CH11_SW, 0x08); // C129V2: flip
|
||||
//Other flags seen in packet[3]
|
||||
// Flag 0x04 is set on some helis (C159/C190)
|
||||
// E129 Mode: short press=0x20->0x00->0x20->..., long press=0x10->0x30->0x10->... => C186 throttle trim is doing the same:up=short press and down=long press
|
||||
packet[ 4] = GET_FLAG(CH5_SW, 0x20) // Take off/Land 0x20
|
||||
| GET_FLAG(CH6_SW, 0x04); // Emergency stop 0x04
|
||||
| GET_FLAG(CH6_SW, 0x04) // Emergency stop 0x04
|
||||
| GET_FLAG(CH12_SW, 0x80); // C190: debug mode->remote THR trim down sets 0x80
|
||||
//Other flags seen in packet[4]
|
||||
// C190 remote LANDING sets 0x10
|
||||
// C190 remote THR trim down sets 0x80
|
||||
|
||||
//Channels and trims
|
||||
uint16_t val = convert_channel_10b(AILERON,false);
|
||||
uint8_t trim = convert_channel_8b(CH7) & 0xFC;
|
||||
|
@ -436,6 +436,7 @@
|
||||
#undef Q303_CCNRF_INO
|
||||
#undef Q90C_CCNRF_INO
|
||||
#undef V911S_CCNRF_INO
|
||||
#undef SGF22_NRF24L01_INO
|
||||
#endif
|
||||
|
||||
//OpenTX 2.3.x issue
|
||||
|
@ -138,11 +138,11 @@ uint16_t XK2_callback()
|
||||
debug(" %02X",packet[i]);
|
||||
debugln("");
|
||||
#endif
|
||||
//phase = XK2_BIND1;
|
||||
//return 500;
|
||||
crc8 = 0xBF;
|
||||
for(uint8_t i=0; i<XK2_PAYLOAD_SIZE-1; i++)
|
||||
crc8 += packet[i];
|
||||
//phase = XK2_BIND1;
|
||||
//return 500;
|
||||
if(crc8 != packet[8])
|
||||
{
|
||||
phase = XK2_BIND1;
|
||||
@ -199,3 +199,93 @@ void XK2_init()
|
||||
|
||||
#endif
|
||||
|
||||
/*
|
||||
XK A160 Piper CUB
|
||||
|
||||
Bind
|
||||
----
|
||||
Plane sends these packets:
|
||||
RX: 0us C=71 S=Y A= CC CC CC CC CC P(9)= 9C BB CC DD 38 12 10 00 19
|
||||
P[0] = 9C bind phase 1
|
||||
P[1] = Dummy TX_ID
|
||||
P[2] = Dummy TX_ID
|
||||
P[3] = Dummy TX_ID
|
||||
P[4] = RX_ID[0]
|
||||
P[5] = RX_ID[1]
|
||||
P[6] = RX_ID[2]
|
||||
P[7] = 00
|
||||
P[8] = sum P[0..7] + BF
|
||||
|
||||
TX responds to plane:
|
||||
RX 9D 66 4F 47 38 12 10 00 B3
|
||||
P[0] = 9D bind phase 2
|
||||
P[1] = TX_ID[0]
|
||||
P[2] = TX_ID[1]
|
||||
P[3] = TX_ID[2]
|
||||
P[4] = RX_ID[0]
|
||||
P[5] = RX_ID[1]
|
||||
P[6] = RX_ID[2]
|
||||
P[7] = 00
|
||||
P[8] = sum P[0..7] + C0
|
||||
|
||||
Planes ack:
|
||||
RX: 4299us C=71 S=Y A= CC CC CC CC CC P(9)= 9B 66 4F 47 38 12 10 00 B0
|
||||
RX: 26222us C=71 S=Y A= CC CC CC CC CC P(9)= 9B 66 4F 47 38 12 10 00 B0
|
||||
RX: 8743us C=71 S=Y A= CC CC CC CC CC P(9)= 9B 66 4F 47 38 12 10 00 B0
|
||||
P[0] = 9B bind phase 3
|
||||
P[1] = TX_ID[0]
|
||||
P[2] = TX_ID[1]
|
||||
P[3] = TX_ID[2]
|
||||
P[4] = RX_ID[0]
|
||||
P[5] = RX_ID[1]
|
||||
P[6] = RX_ID[2]
|
||||
P[7] = 00
|
||||
P[8] = sum P[0..7] + BF
|
||||
|
||||
Normal
|
||||
------
|
||||
TX sends
|
||||
C=65,69,73,77 -> only one channel when telemetry is working
|
||||
250K C=69 S=Y A= 66 4F 47 CC CC P(9)= 32 32 00 32 E0 00 01 5A 50
|
||||
P[0] = A 00..32..64
|
||||
P[1] = E 00..32..64
|
||||
P[2] = T 00..64
|
||||
P[3] = R 00..32..64
|
||||
P[4] = alternates 20,60,A0,E0
|
||||
trims
|
||||
A 01..20..3F
|
||||
E 41..60..7F
|
||||
R 81..A0..BF
|
||||
telemetry
|
||||
E0 present when the telemetry works
|
||||
6g/3d
|
||||
C1 few times if P[6] flag 00->08
|
||||
C0 few times if P[6] = flag 08->00
|
||||
P[5] = flags
|
||||
01=high rate
|
||||
20=hover=long_press_left
|
||||
08=6g/3d=short_press_right sequece also switches for a few packets to C1 if 8 C0 if 0
|
||||
P[6] = 00 telemetry nok
|
||||
01 telemetry ok but sometimes switch to 1 also when telemetry is nok...
|
||||
P[7] = 5A
|
||||
P[8] = sum P[0..7] + 7F
|
||||
|
||||
Telemetry
|
||||
RX on channel: 69, Time: 3408us P: 66 4F 47 00 00 00 00 00 C8
|
||||
P[0] = TX_ID[0]
|
||||
P[1] = TX_ID[1]
|
||||
P[2] = TX_ID[2]
|
||||
P[8] = sum P[0..7] + CC
|
||||
|
||||
Timing when plane is not detected:
|
||||
RF
|
||||
2469 110713 0
|
||||
2473 114560 3847
|
||||
2477 120291 5731
|
||||
2465 135684 15393
|
||||
2469 142138 6454
|
||||
2473 145984 3846
|
||||
2477 151753 5769
|
||||
2465 155330 3577
|
||||
|
||||
*/
|
@ -635,16 +635,18 @@ Models: Eachine E129/E130 and Twister Ninja 250
|
||||
### Sub_protocol C186 - *1*
|
||||
Models: RC ERA C186/E120, C127/E110, K127, C159, C189, C129v2
|
||||
|
||||
The FC of the heli seems to store the trims Trim A/E/R=CH7..9. If you use these trims, make sure to center them after powering off the heli or they will be added to the previous trims and over correct.
|
||||
The FC of the heli store the trims Trim A/E/R=CH7..9. If you use these trims, make sure to reset them to 0 after powering off the heli or they will be added to the previous trims therefore over correctting.
|
||||
|
||||
CH10|CH11
|
||||
---|---
|
||||
Loop|Flip
|
||||
CH10|CH11|CH12
|
||||
---|---|---
|
||||
Loop|Flip|Debug
|
||||
|
||||
Loop: circular flight on the C159 (others?)
|
||||
|
||||
Flip: flip/aerobatic on the C129v2 (others?)
|
||||
|
||||
Debug: you must know what you are doing!!! The new values are stored at power off. The rudder trim is used to change the pitch value (relative to the previously stored value). Ail end Ele trims are used to better trim the FC.
|
||||
|
||||
## J6Pro - *22*
|
||||
|
||||
CH1|CH2|CH3|CH4|CH5|CH6|CH7|CH8|CH9|CH10|CH11|CH12
|
||||
@ -1432,7 +1434,7 @@ Rate: -100% High, +100% Low
|
||||
Models: WLtoys V911S, XK A110
|
||||
|
||||
### Sub_protocol E119 - *1*
|
||||
Models: Eachine E119, JJRC W01-J3, XK A220 P-40, XK A800 R2, F959S R2, A160 R2, A280
|
||||
Models: Eachine E119, JJRC W01-J3, XK A220 P-40, (TX X4-A800) A800 R2, F959S R2, (TX X4-A800) A160 R2, A280
|
||||
|
||||
CH1|CH2|CH3|CH4|CH5|CH6|CH7|CH8|CH9
|
||||
---|---|---|---|---|---|---|---|---
|
||||
@ -1478,7 +1480,7 @@ Models: WLtoys cars 284131/284161/284010/124016/124017/144010 and Eachine EAT14
|
||||
## XK2 - *99*
|
||||
|
||||
### Sub_protocol X4 - *0*
|
||||
Transmitter: XK X4, model: XK A160S
|
||||
Transmitter: XK X4-A160, model: XK A160S
|
||||
|
||||
**Only 1 ID and might only work with my plane**
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user