prickle / Mavpixel

Mavpixel firmware repository
32 stars 12 forks source link

Pixhwak 4 with PX4 #7

Closed d3473r closed 5 years ago

d3473r commented 5 years ago

Hi, I would love to use Mavpixel, but sadly I cannot get it to work with a Pixhawk 4.

I can flash Mavpixel, set up my LED's and if I connect them up the light up in the correct colors. 2019-06-27 17_17_23-Mavpixel GUI Configurator - CLI Mode

The LED's even work when connected to the Pixhawk photo_2019-06-27_17-26-05

But I cannot get MavLink to work (The status LED on the arduino keeps blinking with 5hz pulse)

In the README you want me to configure SERIAL

If Mavpixel indicates there is no Mavlink, confirm your flight controller's SERIALx settings on the appropriate port (i.e. SERIAL2 for Telem 2 port). These should be set to SERIAL_BAUD = 57 and SERIAL_PROTOCOL = 1. Still no luck? Double check all connections between Mavpixel and the flight controller.

But i cannot find anything marked with SERIAL in the PX4 firmware in QGroundcontrol. These are the only three SER_ configurations that I see 2019-06-27 17_30_07-Window

I tested the arduino with both of my TELEM Ports. Both ports are working with a 433MHz Telemetry radio, so MavLink has to be configured correctly :/ 2019-06-27 17_15_36-Window

Do you have any idea what I could have done wrong?

Regards

prickle commented 5 years ago

Hi! Thanks for trying Mavpixel.

Are you running PX4 firmware? Mavpixel is for Arducopter only sorry.

d3473r commented 5 years ago

Yes I am running PX4 right now. I thought Mavlink would be the same regardless the firmware :/ Can I help somehow to get it compatible with PX4?

prickle commented 5 years ago

Sure! But it might be tricky. Big additions would be needed to support the different set of flight modes, different Mavlink usage and many other differences under the hood.

Mavpixel already uses nearly all of the Arduino's memory just for Arducopter. This could be improved by a better programmer than me, but not likely enough for such additions.

A different Mavpixel firmware just for PX4 would probably be required. The MAVLink.ino file contains the communications parser which would need to be adapted for PX4 messages. New flight modes would need to be assigned and IOBoard_Funcs.ino would need be changed to suit. On top of all this the GUI would also need additions to allow configuring the new options. Quite a bit of work involved in all of this.

I dont use PX4 and dont know its style and I cant take this on as a project right now anyway. If anybody else wants to give it a go thats why open source.

Perhaps running Arducopter would be easier?

d3473r commented 5 years ago

Okay, thanks for the detailed explanation! I now flashed Arducoper 3.6.9 and MavPixel is sadly still not working for me (The LED is blinking with 5hz)

2019-07-02 17_14_24-QGroundControl v3 5 3

SERIAL_BAUD and SERIAL_PROTOCOL are now set via Mission Planner:

2019-07-02 17_08_12-GlassPanelForm

I will try to debug it through software serial and open another issue if I find something