JJRC H20 Hex Quad

More
10 Nov 2015 15:57 - 10 Nov 2015 15:57 #39833 by goebish
Replied by goebish on topic JJRC H20 Hex Quad

goebish wrote: I'd like to crack tx id / rf channels before making a pull request

hmmmm, I think I get it, let me check if it works :)
Last edit: 10 Nov 2015 15:57 by goebish.

Please Log in or Create an account to join the conversation.

More
10 Nov 2015 16:24 - 10 Nov 2015 16:25 #39834 by bmw111
Replied by bmw111 on topic JJRC H20 Hex Quad
Newb here. I've deviated a 7e (w/range mod), 6S, and 10, but not installed any other modules. I have a couple NR modules on order from BG. What module (if any) do I need to use the protocol for this JJRC H20? Also, wondering if it's the same protocol as the JJRC Tarantula X6?
Last edit: 10 Nov 2015 16:25 by bmw111.

Please Log in or Create an account to join the conversation.

More
10 Nov 2015 16:55 #39838 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
This protocol requires a nrf24l01 module, Tarantula X6 requires the same module, but is using another protocol: v202

Please Log in or Create an account to join the conversation.

More
10 Nov 2015 17:00 #39840 by bmw111
Replied by bmw111 on topic JJRC H20 Hex Quad
Great, thanks. I've ordered a couple of the NRF, just have to decide which Tx to install them in.

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 03:45 #39906 by hexfet
Replied by hexfet on topic JJRC H20 Hex Quad

SeByDocKy wrote: @HexFet, can you add this protocol to your combo release ? :)

Combo build is updated. It also has the latest KN changes, which are now merged. This build is from the new_protocols branch in my repo if anyone wants to build it.

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 04:29 #39910 by dc59
Replied by dc59 on topic JJRC H20 Hex Quad

hexfet wrote:

SeByDocKy wrote: @HexFet, can you add this protocol to your combo release ? :)

Combo build is updated. It also has the latest KN changes, which are now merged. This build is from the new_protocols branch in my repo if anyone wants to build it.


Hi Hexfet,
Thank you very much for the new build,this is the answer that I send you a PM. :woohoo:

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 12:22 #39930 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
It's now possible to use an arbitrary tx id, please try the updated build with no id and a few arbitrary fixed id then report if everything is fine :)
If that's ok I'll make a pull request so it's included in nightly builds.

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 12:59 - 11 Nov 2015 12:59 #39932 by Durete
Replied by Durete on topic JJRC H20 Hex Quad
Great Goebish!
I can't test yet because my H8 3D is on the slow boat, but figure out the TX id vs RF channels with only 2 captures is incredible :)
With MJXq protocol we have about 10 captures, and at least me I can't see something obvious :blush:

Good job :P
Last edit: 11 Nov 2015 12:59 by Durete.

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 13:56 - 05 Dec 2015 00:58 #39934 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
For some protocols even a good number of captures won't help (eg v202), in this case you've to tap into the receiver and check a great amount of tx ids to try to figure out how it works.

This one was kinda easy, here are my notes ;)
Stage 1 --> init

3F CD 3F 7F 9C 20         set xn297 debug register  
3E DA 9A B0 79 BB AB 9C   set xn297 debug register
39 0B DF C4 A7 03         set xn297 debug register
30 C4 57 09 65 21         set TX address C4 57 09 65 21
2B C4 57 09 65 21         set RX address pipe 1 C4 57 09 65 21
01 00 -> 3F               get EN_AA -> enabled on all 6 data pipes
02 00 -> 03               get Enabled RX Addresses -> enabled on data pipes 0 & 1
27 70                     clear data ready, data sent, and retransmit
21 00                     disable auto ack
22 02                     enable RX data pipe 1, disable others
23 03                     set 5 bytes address width
25 06                     set RF channel 6
24 00                     disable automatic retransmission 
31 14                     set RX payload size for pipe 0(disabled ?) 20 bytes 
32 14                     set RX payload size for pipe 1 20 bytes
26 01                     set 1Mbps data rate, minimum RF power
70 73                     activate 73
3C 00                     disable dynamic payload length on all pipes
3D 00                     disable features
05 FF -> 06               get RF channel

Stage 2 --> bind

20 1E                     TX mode / power on / 2 bytes crc / int not reflected on irq pin
25 0F                     set RF channel 0F
E1                        flush TX
27 70                     clear interrupts
20 1E                     power on  
A0 13 AE B8 0B 10 00 00 01 81 00 00 00 00 00 00 00 00 00 00 00 (TX1)
A0 13 AF C5 17 00 00 00 01 8B 00 00 00 00 00 00 00 00 00 00 00 (TX2)
07 FF -> 0E               get status
07 FF -> 0E               get status
....
07 FF -> 2E               get status -> TX_DS raised
27 70                     clear interupts

.... repeat stage 2 for 2000 ms

Stage 3 --> data

26 07                     set max RF power
25 0F                     set RF channel 0F

E1
27 70
20 1E
A0 13 AE B8 0B 10 00 08 03 81 00 00 7F 7F 20 20 20 20 00 00 7E <-- payload[5] is an index ? --> 00
07 FF -> 0E
07 FF -> 0E
....
07 FF -> 2E
27 70
25 19                     set RF channel 19 after packet is sent

E1
27 70
20 1E
A0 13 AE B8 0B 10 01 08 03 81 00 00 7F 7F 20 20 20 20 00 00 7E --> 01
07 FF -> 0E
....
07 FF -> 2E
27 70
25 2F                     set RF channel 2F after packet is sent

E1
27 70
20 1E
A0 13 AE B8 0B 10 02 08 03 81 00 00 7F 7F 20 20 20 20 00 00 7E --> 02
07 FF -> 0E
....
07 FF -> 2E
27 70
25 34                     set RF channel 34 after packet is sent

E1
27 70
20 1E
A0 13 AE B8 0B 10 03 08 03 81 00 00 7F 7F 20 20 20 20 00 00 7E --> 03
07 FF -> 0E
....
07 FF -> 2E
27 70
25 0F                     set RF channel 0F after packet is sent

repeat stage 3 ....


packet period: 1800µs

data packet:
[00] = 13   // fixed
[01] = AE   // txid
[02] = B8   // txid
[03] = 0B   // txid
[04] = 10   // txid
[05] = next channel index (0-3) (0 during bind)
[06] = 08   // fixed (0 during bind)
[07] = 03   // fixed (1 during bind)
[08] = 81   // = txid checksum [01-04] & FF
[09] = throttle (00-FF)
[10] = rudder (BC-80-00-3C )
[11] = elevator (43-7F-BB)
[12] = aileron (BB-7F-43)
[13] = trim (neutral 20)
[14] = trim (neutral 20)
[15] = trim (neutral 20)
[16] = trim (neutral 20)
[17] = flags:
|01: flip
|02: mid rate
|04: high rate
|08:
|10: RTH / headless
|20: flip mode: 180° when clear, 360° when set
|40:
|80:
[18] = flags:
|20: accelerometer calibration
[19] = data checksum = ([09] ..+.. [18]) & FF

tx id / channels

TX1
id: AE B8 0B 10     chk: 81
ch: 0F 19 2F 34    

ch0: a+e=18 %0f=09; 06+09=0f -> or 1+8=09, works in both case
ch1: b+8=13 %0f=04; 15+04=19 -> or 1+3 ... 
ch2: 0+b=0b %0f=0b; 24+0b=2f > ...
ch3: 1+0=01 %0f=01; 33+01=34

TX2
id: AF C5 17 00     chk: 8b
ch: 10 17 2C 33 

ch0: a+f=19 %0f=0a; 06+0a=10
ch1: c+5=11 %0f=02; 15+02=17 
ch2: 1+7=08 %0f=08; 24+08=2C
ch3: 0+0=00 %0f=00; 33+00=33

rf_channel[index] = 6+(index*0x0f)+(((txid[index]>>8)+(txid[index]&0x0f))%0x0f);

totally random ids don't work (bind ok but no data...)
seems to be ok with those ranges:
txid[0]  [a0 ; af]
txid[1]  [b0 ; cf]
txid[2]  [00 ; 1f]
txid[3]  [00 ; 10]
Last edit: 05 Dec 2015 00:58 by goebish.

Please Log in or Create an account to join the conversation.

More
11 Nov 2015 16:12 #39938 by Deal57
Replied by Deal57 on topic JJRC H20 Hex Quad
:P :P :P

Flew the H20 with multiple different Fixed ID and without Fixed ID, and it worked every time. I'll fly it a few more times today. This is really nice work and I appreciate seeing your notes.

Thank you!!!!

Deviation Devo7e 3way switch mod, A7105, NRF24L01
Devo6s 2x2 switch mod, trim mod, haptic, multimodule, A7105, NRF24L01, CC2500
Devo12e 4-in-1 with voice mod -- it speaks!!

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 05:30 #39963 by sledgehammer1570
Replied by sledgehammer1570 on topic JJRC H20 Hex Quad
Is there a way to recalibrate the gyro in this protocol? The stock tx calibrates pointing boths sticks down left.

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 08:57 #39970 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
Ah, it seems the TX sets a flag for that.
I'll implement it, thanks for noticing !

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 09:37 - 12 Nov 2015 09:41 #39971 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
Build updated , accelerometer calibration is working now ;)
Note that it will work only with a scaling of 100 on ail/rud/ele.
Last edit: 12 Nov 2015 09:41 by goebish.

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 18:45 #39989 by sledgehammer1570
Replied by sledgehammer1570 on topic JJRC H20 Hex Quad

goebish wrote: Build updated , accelerometer calibration is working now ;)
Note that it will work only with a scaling of 100 on ail/rud/ele.

Tested and works. Thank you!

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 18:56 #39990 by Sicon
Replied by Sicon on topic JJRC H20 Hex Quad
First of all, thank you for this protocol :D
Sorry if I ask something stupid (I am new to devo 7e world :D ), but someone could post a working ini file for a devo 7e for the H83D? I try to let the flip/inverted functions to work but on HOLD1 (ch6) it only works for the 180° and I don't have a ch10 on my 7e

Thank you!!

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 19:44 #39991 by Deal57
Replied by Deal57 on topic JJRC H20 Hex Quad
Do you have the two additional switches installed? I don't have the H83D I have the H20, but the ini file will be very similar except for the channel 10 output. I'll post my ini in the configurations section and update this note.

Deviation Devo7e 3way switch mod, A7105, NRF24L01
Devo6s 2x2 switch mod, trim mod, haptic, multimodule, A7105, NRF24L01, CC2500
Devo12e 4-in-1 with voice mod -- it speaks!!

Please Log in or Create an account to join the conversation.

More
12 Nov 2015 19:47 - 12 Nov 2015 20:16 #39992 by sledgehammer1570
Replied by sledgehammer1570 on topic JJRC H20 Hex Quad

Sicon wrote: First of all, thank you for this protocol :D
Sorry if I ask something stupid (I am new to devo 7e world :D ), but someone could post a working ini file for a devo 7e for the H83D? I try to let the flip/inverted functions to work but on HOLD1 (ch6) it only works for the 180° and I don't have a ch10 on my 7e

Thank you!!


You need to enable ten channels in model setup at "# Channels"

At mixer, change Ch10 to complex.

At complex section, make two mixers.

Page 1
[Switch - FMODE 1]
[Src - FMODE 1]
[Curve - < 0]

Page 2
[Switch - FMODE 0]
[Src - FMODE 0]
[Curve - > 0] ( note the >. different from page 1 )

Save

You already have HOLD1 as your flip switch at Ch6, so no need to change that. Or if you want FMODE to be your flip switch, then choose HOLD switch at the Ch10 mixers and FMODE for Ch6, you know:)

I hope this helps. Ask if you don't get it or this doesn't work.
Last edit: 12 Nov 2015 20:16 by sledgehammer1570.

Please Log in or Create an account to join the conversation.

More
13 Nov 2015 16:50 #40016 by Sicon
Replied by Sicon on topic JJRC H20 Hex Quad
Thank you for your help, could this work?

[channel6]
template=simple
[mixer]
src=HOLD1
dest=Ch6
curvetype=expo
points=0,0

[channel9]
template=simple
[mixer]
src=FMODE1
dest=Ch9
curvetype=zero/max
points=0

[channel10]
template=complex
[mixer]
src=FMODE0
dest=Ch10
switch=FMODE0
usetrim=0
curvetype=greater-than-0
points=0
[mixer]
src=FMODE1
dest=Ch10
switch=FMODE1
usetrim=0
curvetype=less-than-0
points=0

Please Log in or Create an account to join the conversation.

More
18 Nov 2015 15:20 #40184 by goebish
Replied by goebish on topic JJRC H20 Hex Quad
I just created a pull request, please approve it if you've tested that everything works fine with test firmware :)
bitbucket.org/deviationtx/deviation/pull...3d-jjrc-h20-h22/diff

Please Log in or Create an account to join the conversation.

More
19 Nov 2015 00:40 #40196 by dc59
Replied by dc59 on topic JJRC H20 Hex Quad
Tested with my JJRC H22,works very nice!!

Please Log in or Create an account to join the conversation.

Time to create page: 0.098 seconds
Powered by Kunena Forum