Mavlink data displayed on Taranis, without converter

3689620635?profile=original

Having already got my OpenLRS set up to send Mavlink data back from my plane (using the gitsly OpenLRS branch), the next step was to get Mavlink data displayed on my Taranis.

The Taranis need inverted levels to serial pin in the module bay so I build an inverter from the schematic here. 

I saw this topic a while back: MAVLink data displayed on OpenTX (9X/9XR/etc) radio screen via OpenLRS, plus telemetry pass-thru to PC and assumed this would also work on Taranis. No such luck! There is no EXT=MAVLINK option for Taranis in the configurator. 

However I managed to get the OpenTX build environment set up on Ubuntu following the instructions here without too many difficulties. Then is was a matter of redirecting the telemetry bytes into the existing mavlink code, and displaying the Mavlink settings and telemetry screens rather than the Frsky ones. I was quite surprised when it all worked however!  The Mavlink serial is also available from the serial connector on the OpenLRS module so that can be connected to a PC or Android device.

In the original 9X Mavlink firmware it was not possible to select which telemetry protocol to use except by reflashing. I need a mixture of S.Port and Mavlink telemetry depending on which plane I'm flying so that didn't suit me too well. I added an option in the model menu telemetry options to use Mavlink rather than S.Port or Dbus, so each model can have it's Mavlink or Frsky telemetry received and displayed :) . 

I also thought it would be useful to have the radio read the flight modes as they are receiver over Mavlink, this wasn't too hard to incorporate either. I created sound files for each Arduplane mode and added code to play them on receipt of a new mode.

Something else I would like do is to copy the Mavlink data into the normal Frsky variables so that they can be used in the normal way, i.e. read out, used in Lua scripts and for vario sounds etc.. It's on the to-do list.

Hopefully this will be useful to some people out there, I will post the code after I get a chance to clean it up slightly as it is a bit of a hack! For now the binary and sound files are here (they need to be in the SOUNDS/en folder):

https://drive.google.com/folderview?id=0B4xnWmfKh4FrVFl4YlU1Zm9nQU0&usp=sharing

Cheers,
Sam

3689620752?profile=original3689620710?profile=original

E-mail me when people leave their comments –

You need to be a member of diydrones to add comments!

Join diydrones

Comments

  • The USB=MASSSTORAGE firmware is now in the Google drive folder.
    Cheers, Sam
  • Well done that was quick work! See your messages. I haven't tried with that version it would be interesting to see if it's better - with the gitsly branch I was getting lots of lost packets within 300m when transmitting serial but could go several km without.
  • Well, I got it compiled, and it seems to work well. Here are the options used:

    make PCB=TARANIS PCBREV=REVPLUS EXT=FRSKY-MAVLINK HELI=YES LUA=YES USB=MASSSTORAGE

    Sam, let me know if you want me to send you the file, maybe you could store it along with the other files you got.

    -Håvard

  • I'm using ULRS 2.0 beta, have you tried range testing with that? It seems to handle the distance and data transfer better.

    I'll install Ubuntu and give it a go, there's a first time for everything. I don't have to make any changes to the code, just use the correct options for the make command, right?

    -Håvard

  • Hello all, unfortunately haven't done any work on this lately. I found that the range from the OpebLRS system was drastically reduced when passing through the serial MavLink data (on the gitsly branch). I'd like to try it with the current OpenLRS code eventually but won't be for a while.
    I think it was probably USB = JOYSTICK. I'll recompile if I get round to it but your best bet might be to download the code from my github and make any changes, it's pretty straightforward to build (and a good reason to set up a Ubuntu partition!).
    Cheers
    Sam
  • Hi Sam,

    I'm using your firmware, but I can't enter bootloader mode to use the USB for OpenTX Companion.

    Was the firmware compiled with option USB = JOYSTICK? If so, could you please compile another hex-file with option USB = MASSSTORAGE instead?

    (As far as I know Linux is needed for compiling, I only use Windows...)

    -Håvard

  • Hi Sam, have you made any progress regarding the conversion to FrSky variables?

  • Does this require any hardware mods to the radio?

  • Hi Sam,

    I'm new to long range and telemetry with taranis.

    At the moment I'm using this solution to get a solide telemetry but this is only for the x8r.

    http://diydrones.com/forum/topics/amp-to-frsky-x8r-sport-converter

    I still don't know what hardware I should buy best. Thinking about 

    http://www.hobbiesfly.com/transmitter-receiver/Transmitters/dtf-uhf...

    and the 

    http://www.hobbiesfly.com/transmitter-receiver/Receivers/brotronics...

    because of the sbus.

    Would your solution work with this hardware as well? I haven't bought it yet so I'm absolutly open to what I have to buy.

    I would realy have a solution like the teensy one but on a UHF device.

    Sorry for my lack of knowledge,  but the topic is quite complex.

    Thans for your help

  • Very interesting accomplishment Sam- thanks for sharing this with everyone.  I am presently sending frsky D protocol mavlink messages from pixhawk (AC 3.3 rc12) through an rs232-ttl converter to a D8R-XP rx.  The frsky-mavlink data is received in my Taranis Plus running OpenTX 2.0.17. I believe the format of the received data is frsky hub protocol. 

    Would it be possible to use your taranis plus build to display the received mavlink frsky hub protocol data as in your example screenshots?

This reply was deleted.