This seems to be the appropriate sub forum for this question.
I have several questions about the APM 2.5 telemetry.
I would like to take my own MCU and simply tie in the UART ports of my MCU to the UART ports of the APM and receive the telemetry messages.
I have been looking at references on diydrones and the mavlink site. With that being said
Is MAVLINK still used in the APM 2.5? (Asking because the old wiki for the APM says alot of stuff has been updated so I want to be sure)
Secondly, how do I recieve specific telemetry data as proposed my the MAVLink messages? For some reason I don’t believe to be as simply as sending a command byte over UART and getting data back. I have something like this in mind (psuedo code)
DATA = MCU_UARTRX
I just do not want to looking up and trying to apply outdated information.
Yes, MAVLink is still used.
What you have to do is to send a MAVLink request_data_stream command which indicates to the APM, which class of data you want to receive and how often (per second) it should be sent.
The best point for you to start would be the code of one of the ground station projects.
You can find mine at github.com/sgofferj/uxv-cs.
The thing you are looking for is in MAVLink.ino. Have a look at the start_feeds function. gcs_handleMessage shows how to evaluate the data that’s being sent by the APM.
Thanks for the help! I will delve into this. If I have another further question, would a be PM be fine?
Development questions should go to the developer mailing list. I’m a bit too busy for giving direct support via PM,
You used GCS_Mavlink.h which is the header from the APM code, correct? Would I have the same effect just using the mavlink.h from the mavlink code?
You have to include the whole library. Additionally, some more libraries are needed, such as FastSerial.
Stefan, thanks for the links! I’m doing something similar, using another Arduino to drive a RGB LED display, and I want it to indicate warnings and such. This will be very helpful, thanks!
I should ,also mention that I using a PIC that will be tied into the APM’s telemetry UART port. So I believe I do not need the AP_HAL headers. As I have already written code to interface with my PIC’s SPI and UART communications.
In the mavlink_types.h file I’m having trouble locating #include <inttypes.h>. I managed to locate the source here
opensource.apple.com/source/ … inttypes.h
However, it is still not picking it up. Did you have any issues running this? or it was specific to any arudino library
I can’t help you with that, as I haven’t written the MAVLink libraries. I just include them.
Again, for those kind of questions you should go to the developer mailing list.
[quote=“SamJack”]I should ,also mention that I using a PIC that will be tied into the APM’s telemetry UART port. So I believe I do not need the AP_HAL headers. As I have already written code to interface with my PIC’s SPI and UART communications.[/quote]Samjack, how have you been going with the APM telemetry to PIC decoding, did you get the information you needed ?
I’ve got a need to do a similar PIC based project to convert APM 2.5 telemetry to FrSky protocol. AFAIK nobody has done this with a PIC yet (only Arduino).
I have downloaded your software, uxv-cs but i have problems in compiling it.
Which Arduino compiler do you use? The one suggested in this page dev.ardupilot.com/wiki/building- … o-windows/ as if you were building the ardupilot? And if so, which hal board? none, APM 1.x or APM 2.x?
Or the normal arduino program from arduino.cc as if you were building for an Arduino Mega 2560? In case, are you using the 1.0.3 version or the more recent ones?