Simulation sitl_gazebo: Sensors not set up correctly


I have a problem when I try to start my simulator on a different computer I get the following error and warn messages. The commander goes then in an error mode from which I can not arm my model.

[ERROR] [1494416689.197640268, 5.050000000]: FCU: TRANSITION_DENIED: ARMING_STATE_INIT - ARMING_STA
[ERROR] [1494416689.248365273, 5.098000000]: FCU: REJECTING component arm cmd
WARN  [commander] Not ready to fly: Sensors not set up correctly
[ERROR] [1494416693.601933342, 9.408000000]: FCU: Not ready to fly: Sensors not set up correctly

Does anyone has an idea why on one computer the sensors are set up correctly and on another not?

Best regards
Nils Rottmann

Is one computer slower? Try running headless.

eg HEADLESS=1 make posix_sitl_default gazebo_iris

Hi dagar,

First of all thanks for your reply. I tried what you suggested but still I get the same error message. Do you have any other ideas what could be the reason? I have done some further diagnostics to look which thinks are running different on both computers:

commander status (working PC)
WARN  [commander] nav state: 13
WARN  [commander] arming: ARMED

commander status (other)
WARN  [commander] nav state: 0
WARN  [commander] arming: INIT

I think the problem is that I run into the INIT state after testing the sensors. But I checked the sensors status on both computer during simulation and for both the status is the same.


Are there are other differences between them? Is it the exact same version of PX4? Any param changes?

I would make certain the code is identical in both locations, run make distclean, then try the simulation again.

Hi dagar,

thanks for your help. You solved my problem. Indeed it was a problem of the computer speed. Running HEADLESS=1 worked after I added it into the right spot of my launch file.