Jaeyoung-Lim / px4-offboard

Example of offboard control over microdds using python ROS 2
BSD 3-Clause "New" or "Revised" License
104 stars 51 forks source link

Unable to arm in Offboard mode on hardware #23

Open tirpudevk111 opened 5 months ago

tirpudevk111 commented 5 months ago

Hardware used:

  1. Jetson orin nano
  2. Pixhawk cube+ orange

Software:

  1. ROS2 humble
  2. PX4 v1.14
  3. uXRCE-DDS bridge

Given offboard example is running on gazebo simulator very well but unable to arm in 'offboard mode' while working with hardware.

Jaeyoung-Lim commented 5 months ago

@tirpudevk111 In order to help, you need to share more details (error messages, logs) other than the fact that it doesn't work

tirpudevk111 commented 5 months ago

@Jaeyoung-Lim Thank you for quick response, since I am able run the script successfully, the data is also sent successfully over UART to pixhawk via dds topics. It does not show any error in QGC and no error in running the script. I have done 'ros2 topic echo /fmu/out/vehiclestatus' and found that "pre_flight_checks_pass = false" as it switches to offboard mode. Can you help me find what are the preflight checks in offboard mode. WhatsApp Image 2024-01-30 at 17 48 05

Jaeyoung-Lim commented 5 months ago

@tirpudevk111 Preflight checks are independent of offboard. You need to be able to arm the vehicle without offboard before attempting to fly it with offboard.

tirpudevk111 commented 5 months ago

@Jaeyoung-Lim yes I have already tried arming without offboard and I am able to arm and fly but I am not able to arm once its in the offboard mode. Also it can switch to offboard mode before arming. Additionally, it does not switch to offboard mode when I arm the drone first and then switch to offboard.