Trying to start Obstacle Avoidance in NVIDIA Jetson with PX4 Autopilot in Hardware-in-the-Loop (HITL) Simulation with UAV Dynamics Modeled in Simulink

23 views (last 30 days)
Hello, I ran into two problems when working with QGroundControl (QGC), Pixhawk and Jetson as a mission computer. QGC issues the error "Unable to start mission: Vehicle not changing to Mission flight mode". At the same time, the mission is loaded into autopilot, there is a connection between QGC and Pixhawk.
Obstacle Avoidance: The model in Simulink works, but the video viewer does not receive depth frames from Jetson.
In the Jetson log:
[sudo] password for superadmin: No protocol specified
nvbuf_utils: Couild not get EGL display connection
Opening in blocking MODE
State change is async
**starting the model**
I checked the connection beetween Host PC(192.168.1202) and Jetson(192.168.1.201) via wireshark
QGround also see mission computer
In simulink Obstacle Avoidance Model a have such warnings
What could be the cause of the error changing the flight mode to "Mission"? Could it be caused by issues on the Jetson side or in the Simulink model? How can I fix the "Could not get EGL display connection" error on the Jetson so that the obstacle avoidance model can transmit depth frames?
  2 Comments
Arun Mathamkode
Arun Mathamkode on 28 Oct 2025 at 10:07
Can you confirm that the obstacle avoidance model is running in Monitor and Tune simulation mode on the Jetson?
The Jetson should be receiving the video stream from the Simulink 3D Visualization model. Make sure to run the Unreal_3DVisualization model as well in normal simulation on host, so that the Jetson can receive the video stream.
Mick
Mick ungefär 7 timmar ago
To answer the first question: yes.
I fixed everything, and example works fine.
First, in Unreal 3D Visualization, the video send block was configured to use the VP9 video codec instead of JPEG, but the OA model's video receive was configured to use JPEG, so I couldn't see the image. I figured this out from www.mathworks.com/support/search.html/videos/uav-code-development-with-simulink-for-student-competitions-1731649582223.html?fq%5B%5D=asset_type_name:video&fq%5B%5D=category:ecoder/index&page=1 38:30 time
Regarding the first question about the vehicle refusing to arm, I forgot to adjust the actuator positions, so the drone was simply jerking around the yaw axis, causing the "Pre-flight fail high gyro bias" error.
Also, I think there are some issues with the Kaspersky Network Security settings, so I simply disabled it :)

Sign in to comment.

Answers (0)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!