Page 1 of 1

eepe and telemetry simulator

Posted: Sat Nov 05, 2016 10:22 pm
by elaerico
Hi. I have a Tgy-9x, with atmega128, flashed with er9x. I made the mod for telemetry. I connect a usb-to-ttl adapter in my pc to the rx and tx lines of the atmega, opened EEPE and try to simulate the telemetry.
The data are sending, I can see that becouse of the status light in the adapter, but the TX telemetry screen arent changing at all.
I opened a serial console to check, becouse when I first start the TX, the rx light of the serial adapter blinks, saying that there is a data, but, despiste the baudrate I select, nothing shows.
What can that be?
Thanks!

Re: eepe and telemetry simulator

Posted: Sat Nov 05, 2016 11:32 pm
by MikeB
I assume you are using the Telemetry item from the menu bar in eepe. This has 3 tabs "Telemetry", "Module" and "SportUart".
The telemetry tab simulates the (now no longer sold) Winged Shadow How High device, sending telemetry data to the Tx.
The module tab is for connecting to a FrSky DJT module. It reports some of the telemetry items FROM the DJT, and also allows you read and set the alarms in the DJT.
The SportUart tab is for configuring the FrSky Uart sensor(s).
Of these, only the telemetry tab sends anything that might appear on the Tx display, and then only if you have the "Usr Proto" set to "WSHhi".

Are you just trying to test you have the mod correct?

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 12:13 am
by elaerico
I assume the mod is done correctly becouse I can program it with the ISP, and are the same wires, right? (rxd0 and txd0 in the atmega128)
I am actually trying to display some data im receiving from the airplane in a diy receiver I made with nrf24l01 and an Arduino, and display it in the 9x screen. What is the best way to do that?
Thanks

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 9:37 am
by MikeB
OK, we need some more details. I'm guessing you are receiving data from the airplane using this unit, and the Arduino is sending serial data, in some format, to the radio.
What format is the data in?
What baudrate are you using?
What protocol for the Tx module are you using?

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 12:45 pm
by elaerico
HI Mike, thanks for the reply. I didn't write the protocol part yet, becouse I need to know which one can I use.
For the arduino, I'm using the UART protocol.
I was checking the frsky protocol becouse your firmware accepts it, but I send a string via serial with the arduino to the tx to see if it dispayed something, but nothing happens.
This is the string used for testing: 0x5E 0x06 0x18 0x34 0x5E
What do you think?
Thanks

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 2:16 pm
by MikeB
From a DJT, the telemetry data is "wrapped" in a telemetry packet of type "user", so the data you are sending is not recognised.
If you have flashed a recent test version of er9x, then there is an option of "FrHub" available inthe "Usr Proto". This is the protocol you are sending.

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 4:45 pm
by elaerico
Hi MikeB. I have the revision 820, this hex: http://www.er9x.com/er9x-128.hex . I can't find the "Usr Proto" or the "FrHub" options. Do you think I need another version?
Thanks

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 5:48 pm
by MikeB
Ah, sorry, I've confused er9x and ersky9x (for ARM processors). Er9x doesn't have "FrHub". The Usr Proto is in the telemetry menu.

Have a look at: http://www.frsky-rc.com/download/view.p ... -Telemetry, to see what a DJT would send.

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 6:57 pm
by elaerico
MikeB, the only protocol that can I use is the DJT protocol? Cant I use the frsky v2 protocol, or another in the er9x?

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 9:15 pm
by MikeB
The telemetry protocol used and, in particular the baudrate for it, depends on the Tx module protocol (e.g. PPM, PXX).
What Tx module are you using, and what is the protocol set for it?
The only telemetry protocols currently processed are FrSky Hub (DJT), FrSky SPort (XJT) and DSM.

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 10:14 pm
by MikeB
I think I can add raw hub processing fairly easily for the '128 and '2561 processors. This is basically the data you are currently trying.
I'll need to try test it, and it may be a couple of days before I can post a test version.

Mike.

Re: eepe and telemetry simulator

Posted: Sun Nov 06, 2016 11:28 pm
by elaerico
Mike. I'm currently using the original tx and rx module, so, PPM protocol. What telemetry protocol that use? Can I use other protocol with that module?
I think that I should use the original module and a custom telemetry to check the reliability of my DIY link before making a full module conversion.
If you think you could add raw hub processing will be amazing to me, so we could easily make our own DIY modules easily!
Thanks!!

Re: eepe and telemetry simulator

Posted: Thu Nov 10, 2016 11:03 pm
by MikeB
I've just posted a test version of er9x-128 (here: viewtopic.php?f=5&t=4598).
This has an option in "Usr Proto" of HBRAW (for Hub Raw). With PPM as the module protocol and this selected, then the raw, FrSky hub protocol is accepted. Don't forget this will still need "byte stuffing" if 0x5D or 0x5E appear in the data.

Mike.

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 12:16 am
by elaerico
Thanks a lot Mike! I'll test it rightnow!

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 3:07 am
by elaerico
Hi Mike, I'm sending this message through the serial port via the Arduino: 0x5E 0x06 0x18 0x34 0x5E every 200ms. What is the baud rate I need?
Thanks

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 3:41 am
by elaerico
Problem solved. 9600 bps. Thanks a lot!!! Works flawlessly.

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 2:50 pm
by elaerico
Mike, If I now want to send all data, even the PPM data over the serial port, can I do that?

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 3:39 pm
by MikeB
It is, in theory, possible to send the control information (PPM etc.) over the serial port, but that would need a specific protocol to be defined and implemented in er9x. I would suggest having a look at using the "Multi" protocol as that is already supported. This sends control data at 100,000 baud, and also receives the telemetry at the same rate. Any Tx module would then also need to use the same protocols.

Mike.

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 7:48 pm
by elaerico
Excellent Mike. I will make a module, passing to the TGY 9X the telemetry data and receiving from the tgy the controls data via PPM. Is the TGY, in the FRHub telemetry mode, sending some data via the serial port?

Re: eepe and telemetry simulator

Posted: Fri Nov 11, 2016 10:18 pm
by MikeB
I think it still sends some FrSky DJT packets to set/clear the alarms in the DJT.

Mike.

Re: eepe and telemetry simulator

Posted: Sat Nov 12, 2016 4:12 pm
by elaerico
Hi again Mike, sorry to bother you, again. I was seeing the telemetry more detailed, and I could see an A1, A2, and the RSSI values, GVAR, etc, but they are not in the DataID table from the FrSky protocol. How does that work? Is that table incomplete? What if I write a dataID which is not in the table?
Thanks

Re: eepe and telemetry simulator

Posted: Sat Nov 12, 2016 5:19 pm
by MikeB
If you look at the document from FrSky, I linked above, you will see the A1, A2, RxRSSI and TxRSSI values are sent by the DJT in a "Link" packet. This is separate from the hub protocol (carried in a DJT user packet).
If you send raw hub protocol, you can't have A1, A2, RxRSSI and TxRSSI.
GVARs are internal to the radio, so are not actual telemetry values.

Mike.