Open murphym18 opened 2 years ago
I was able to get this working. But I needed to bind a button to position control mode. Using the sticks was not reliable. But pressing a button worked every time.
This is how I setup QGroundControl: https://docs.px4.io/master/en/config/joystick.html
(I used an xbox one controller connected via Bluetooth to Linux)
I later found out that the sticks were unreliable in offboard mode because of the default value for COM_RC_OVERRIDE
. I added a small pre-flight method to Drone.py
and that should make RC take over with the sticks more reliable. At this time a mode-change button or moving the sticks let you take control.
If we detect that someone is taking control with the RC transmitter, we need to stop sending commands to the flight controller. I think the easiest way to do this is by exiting the program if the flight controller switches to POSCTL mode.