QGC Not Ready due to system health failure

I am running PX4 as SITL and I am unable to run any python code because of a system health failure. But how could there be a system failure when in SITL?

Please share the full output from your terminal in a text file.

Greetings,

Thank you for responding to me.
Unfortunately, I did not save off the output (I know, I should know better).

I wrestled with this for 6-7 hours.
In the past, restarting QGC or PX4 worked.
I re-started both QGC and PX4 several times.
I tried disconnecting the QGC from the vehicle after killing PX4, and that did not work
I am not sure why it suddenly started working near the end of the work day.

My concern is, if our team goes this route, will other developers on the team lose a day of work due to this?

The errors that I saw are outlined below.
– something about setting pre-flight value(s)
– system health status was bad
– strong magnetic interference

Map Positioning – Another question that I had
Also, when creating a mission, can I dynamically move the QGC map to the correct part of the world?
It seems to default to Germany.

I had to create a .sdf file and kick off PX4 by setting the PX4_GZ_WORLD variable to my world file.
Is there a better way to position the world for SITL/simulation development?

Without the exact details of the error it is going to be impossible to help. I would suggest asking in the simulation channel on PX4 Discord for faster responses. There’s also a discussion there about adding support for changing the world coordinates.

I have some output now after getting the same problem today.
Below is the QGC output
afoster@TRI-LT-1PXGV44:~$ code .
afoster@TRI-LT-1PXGV44:~$ ./QGroundControl-x86_64.AppImage
qgc.qgcapplication: Settings location “/home/afoster/.config/QGroundControl.org/QGroundControl Daily.ini” Is writable?: true
Filter rules “Log.debug=false\nqgc..debug=false\nGStreamerAPILog.debug=true\nqt.qml.connections=false”
LocalizationLog: Qt lib localization for “C” is not present
LocalizationLog: Error loading source localization for “C”
LocalizationLog: Error loading json localization for “C”
qt.multimedia.ffmpeg: Using Qt multimedia with FFmpeg version 7.1 LGPL version 2.1 or later
qt.multimedia.ffmpeg: Available HW decoding frameworks:
qt.multimedia.ffmpeg: Available HW encoding frameworks:
PX4ParameterMetaDataLog: Invalid max value, name: “VTQ_TELEM_IDS_1” type: 5 max: “4294967295” error: “Value must be within 0 and 2147483647”
PX4ParameterMetaDataLog: Invalid value for bitmask, bit: 31
PX4ParameterMetaDataLog: Invalid max value, name: “VTQ_TELEM_IDS_1” type: 5 max: “4294967295” error: “Value must be within 0 and 2147483647”
PX4ParameterMetaDataLog: Invalid value for bitmask, bit: 31
PX4ParameterMetaDataLog: Invalid max value, name: “VTQ_TELEM_IDS_1” type: 5 max: “4294967295” error: “Value must be within 0 and 2147483647”
PX4ParameterMetaDataLog: Invalid value for bitmask, bit: 31
Error loading text-to-speech plug-in “speechd”
qgc.audio.audiooutput: Failed to set the TTS engine.
VideoReceiverLog: Stop called on empty URI
VideoReceiverLog: Stop called on empty URI
qt.positioning.geoclue2: Unable to obtain the client: “org.freedesktop.DBus.Error.ServiceUnknown” “The name org.freedesktop.GeoClue2 was not provided by any .service files”
qgc.positionmanager.positionmanager: QGCPositionManager::_setPositionSource(QGCPositionSource)::<lambda(QGeoPositionInfoSource::Error)> QGeoPositionInfoSource::AccessError
PX4ParameterMetaDataLog: Invalid max value, name: “VTQ_TELEM_IDS_1” type: 5 max: “4294967295” error: “Value must be within 0 and 2147483647”
PX4ParameterMetaDataLog: Invalid value for bitmask, bit: 31
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
ComponentInformationTranslationLog: Locale “C” not found in json
ComponentInformationTranslationLog: Locale “C” not found in json
FirmwarePluginLog: Unable to parse version info from file “https://api.github.com/repos/PX4/Firmware/releases
ParameterManagerLog: Attemping load from cache
ParameterManagerLog: Parameters cache match failed /home/afoster/.config/QGroundControl.org/ParamCache/1_1.v2
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
qml: onPressed 28 187
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
PX4ParameterMetaDataLog: Invalid max value, name: “VTQ_TELEM_IDS_1” type: 5 max: “4294967295” error: “Value must be within 0 and 2147483647”
PX4ParameterMetaDataLog: Invalid value for bitmask, bit: 31
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
ComponentInformationTranslationLog: Locale “C” not found in json
qgc.audio.audiooutput: AudioOutput not initialized. Call init() before using say().
ComponentInformationTranslationLog: Locale “C” not found in json
ParameterManagerLog: Attemping load from cache
ParameterManagerLog: Parameters cache match failed /home/afoster/.config/QGroundControl.org/ParamCache/1_1.v2
FirmwarePluginLog: Unable to parse version info from file “https://api.github.com/repos/PX4/Firmware/releases

And here is the PX4 output
px4 starting.

INFO [px4] startup script: /bin/sh etc/init.d-posix/rcS 0
INFO [init] found model autostart file as SYS_AUTOSTART=8011
INFO [param] selected parameter default file parameters.bson
INFO [param] importing from ‘parameters.bson’
INFO [parameters] BSON document size 536 bytes, decoded 536 bytes (INT32:17, FLOAT:9)
INFO [param] selected parameter backup file parameters_backup.bson
INFO [dataman] data manager file ‘./dataman’ size is 1208528 bytes
INFO [init] Gazebo simulator
INFO [init] Starting gazebo with world: /home/afoster/PX4-Autopilot/Tools/simulation/gz/worlds/ulster.sdf
INFO [init] Waiting for Gazebo world…
INFO [init] Gazebo world is ready
INFO [init] Spawning model
INFO [gz_bridge] world: ulster, model: omnicopter_0
INFO [lockstep_scheduler] setting initial absolute time to 4196000 us
INFO [commander] LED: open /dev/led0 failed (22)
WARN [health_and_arming_checks] Preflight Fail: ekf2 missing data
INFO [tone_alarm] home set
INFO [uxrce_dds_client] init UDP agent IP:127.0.0.1, port:8888
INFO [mavlink] mode: Normal, data rate: 4000000 B/s on udp port 18570 remote port 14550
INFO [mavlink] mode: Onboard, data rate: 4000000 B/s on udp port 14580 remote port 14540
INFO [mavlink] mode: Onboard, data rate: 4000 B/s on udp port 14280 remote port 14030
INFO [mavlink] mode: Gimbal, data rate: 400000 B/s on udp port 13030 remote port 13280
INFO [logger] logger started (mode=all)
INFO [logger] Start file log (type: full)
INFO [logger] [logger] ./log/2025-03-31/16_38_58.ulg
INFO [logger] Opened full log file: ./log/2025-03-31/16_38_58.ulg
INFO [mavlink] MAVLink only on localhost (set param MAV_{i}BROADCAST = 1 to enable network)
INFO [mavlink] MAVLink only on localhost (set param MAV
{i}_BROADCAST = 1 to enable network)
INFO [px4] Startup script returned successfully
pxh> INFO [mavlink] partner IP: 127.0.0.1
ERROR [mavlink] vehicle_command_ack lost, generation 1 → 24
ERROR [mavlink] vehicle_command_ack lost, generation 2 → 24
ERROR [mavlink] vehicle_command_ack lost, generation 2 → 24
ERROR [mavlink] vehicle_command_ack lost, generation 2 → 24
WARN [health_and_arming_checks] Preflight Fail: Strong magnetic interference
WARN [health_and_arming_checks] Preflight Fail: Strong magnetic interference
INFO [mavlink] partner IP: 127.0.0.1

Looks like you’re using a custom world. If you have plugins defined in your world file you need to remove them and use the server.config. Likely missing the magnetometer plugin.

My custom world is just the default.sdf with the name and location changed

And, is there a way to move the map and home position without creating a custom world?

Does the location in the world affect which plugins are needed?

I just looked at the server.config and it has the magnetometer plugin
This file is located in
~/PX4-Autopilot/src/modules/simulation/gz_bridge/server.config
on my system

And, is there a way to move the map and home position without creating a custom world?

Not yet, but it should be easy to add. See the discussion on discord here.

Does the location in the world affect which plugins are needed?

No it shouldn’t

Does the sim work with the default world?

I re-ran the python code using the default world.
Then I ran on the cmd line the discord re-position cmd
The map moved to the right location, although it took a minute or so to do it.
And the status was ready to fly.

Is there a way to re-position the map dynamically in python code?

In any case, that may have gotten me past the not ready status.
I only say may have, because the status seems to be hit and miss sometimes.
But, that may be a workaround.
Time will tell.

Is there a way to re-position the map dynamically in python code?

This needs to happen in the startup script. We need a PR to change the world coordinates after the world is loaded but before the model is spawned. If you want to add that feature it would be welcomed.

What do you mean by a startup script?
I was running a python3 .py

is that incorrect?

What do you mean by a startup script?

The gz startup script is here

I think that you are telling me that it is not possible to move the map in python?

When I do the cmd
make px4_sitl gz_x500
gazebo starts up automatically.
I have been running the code below in a shell script that I created from another terminal to move the position.

gz service
-s /world/default/set_spherical_coordinates
–reqtype gz.msgs.SphericalCoordinates
–reptype gz.msgs.Boolean
–timeout 2000
–req “surface_model: EARTH_WGS84, latitude_deg: $lat, longitude_deg: $lon, elevation: $alt”

When I do the cmd
make px4_sitl gz_x500
gazebo starts up automatically.

Yes and this make command calls the startup script I linked above

I have been running the code below in a shell script that I created from another terminal to move the position.

Yes and I am suggesting you add that shell command to the startup script to set the location. Take a look at the startup script and you will see other gz commands for: spawning model, setting sim speed, camera follow, etc. I am suggesting that we implement env variables for a non-default lan/lon/alt in the same way that the other simulators allow this.
PX4_HOME_LAT
PX4_HOME_LON
PX4_HOME_ALT

AAH, that makes sense, thank you

If anyone is checking because of the original health error.
For me, that was happening because the map position was too far from the launch point.