MGL RDAC Plugin #135
Replies: 7 comments
-
Pyefis gets all of the data from the fix gateway using net-FIX protocol https://github.com/makerplane/FIX-Gateway/blob/master/doc/plugins/netfix.rst The FIX-gateway has various plug-ins to communicate with different devices to send or receive data. Regarding the MGL RDAC I have created a plug-in for the MGL CAN protocol https://www.mglavionics.co.za/Docs/MGL%20CAN%20Protocol.pdf Only the RDAC XF portion of the CAN protocol is implemented, this starts on PDF page 11 in the above document. I own an RDAC XG and have tested the plug-in using it, it uses same protocol as thr RDAC XF. The plugin can be configured to receive data from the RDAC or to send data as an emulated RDAC. I am unfamiliar with the RDAC XB that you have and based on the documentation you referenced it does not seem to use CAN for communication so is not supported by the plugin. I did see the RDAX XB listed on MGLs legacy product page https://www.mglavionics.co.za/legacy2.html I can see two options if you want to interface with the legacy RDAC XB:
Regarding the MGL SP-3, it also seems to be a legacy product. It is not listed under their current products or their legacy products but they did have SP-2 and SP-4 listed as legacy. A newer AHRS sensor that supports the MGL CAN protocol is not currently supported but I think the RDAC plug-in could be modified to support other MGL CAN devices like the SP-6 and SP-7. I named the plugin 'mgl' expecting that it would be expanded in the future to support more MGL CAN devices. Example to configure the MGL RDAC plug-in can be found in the default configuration file: FIX-Gateway/fixgw/config/default.yaml Line 404 in 96318e2 |
Beta Was this translation helpful? Give feedback.
-
Also, we have a forum: |
Beta Was this translation helpful? Give feedback.
-
Yes, I am on the forum, but there are mainly questions of a general nature and from pilots or engineers who install/repair devices. When the
When I enter the command, as I understand it, the demo mode starts
but how can I enable |
Beta Was this translation helpful? Give feedback.
-
Edit the configuration file, the path is shown on the output you provided. To get the data from you RDAC over serial you will need to create the plugin and then edit the config file to load it. This plugin gets serial data from a Grand Rapids EIS, might be helpful to look at to understand how to create a plugin that talks to serial port: This other plugin also uses serial port but not directly so not too useful as a serial port example. However this try catch in the main loop that initiates the serial connection allows the plugin to gracefully reconnect to the port in situations where the USB serial adapter is unplugged and then reconnected. The logic in the mavlink will also handle starting fix gateway without the USB connected, then automatically start collecting data when it is plugged in. This is not required for the plugin and I'm no expert on udev so would not be much help but if you will have more than one USB serial port for different devices I highly recommend creating udev rules to give each port a static unique name. Without this you could find that one day your RDAC is ttyUSB0 and some other day it becomes ttyUSB1. My suggestion would be to name them ttyUSB10, ttyUSB11, ttyUSB12, etc for two reasons 1. You cannot rename ttyUSB1 to ttyUSB0 if ttyUSB0 already exists, so renaming to known unused numbers is more reliable and 2. Some security settings, like in apparmor or selinux, will sometimes let you connect to ttyUSB10, etc. but not myCustomMadeUpDeviceName so using standard naming convention is more reliable. |
Beta Was this translation helpful? Give feedback.
-
Thank you for your work and help, I will try to implement the plugin. |
Beta Was this translation helpful? Give feedback.
-
Hello @e100
9 bytes per
The main problem is my By combining the results obtained using the
In the plugins folder I added a new folder
I managed to parse the data and partially decode it.
I also don’t understand why the speed hasn’t changed yet, although the real data is changing, and this is visible: |
Beta Was this translation helpful? Give feedback.
-
If you edit your code so it prints the RPM before writing it to the DB like:
The value you see in the pyEFIS screen should match what is printed out from fix gateway. You do want to use |
Beta Was this translation helpful? Give feedback.
-
Good afternoon @birkelbach and @e100.
Many thanks thank you for creating and developing of this project!
I would like to ask you to create a
discussions
section in theGitHub
repository, and in it you can communicate, like on a forum, and immediately receive information regarding the project code, and this is more convenient than on the forum, and this is not an issue.I wanted to ask about examples and details of using the file:
I wanted to get data from
AHRS
andRDAC
manufactured byMGL
and display onpyEfis
.But due to the lack of sufficient experience and examples, I have difficulties.
I have two such modules:
With
AHRS
, it is not yet clear what protocol comes out of it and whether the block works at all.Regarding
RDAC
, as far as I understand,MGL
used different protocols:Please tell me which protocol is implemented in the code?
I also use
Rasberry
on a single-boardPC
, just a laptop withLinux
installed.Can I transfer data to the
fix-gateway
via aCOM
port inRS-232/UART
format or should data only be received viaCAN
bus and asingle board PC
should be used??Beta Was this translation helpful? Give feedback.
All reactions