PX4 / PX4-Autopilot

PX4 Autopilot Software
https://px4.io
BSD 3-Clause "New" or "Revised" License
8.48k stars 13.5k forks source link

[Bug] Wrong comment on filter_control_status_u after https://github.com/PX4/PX4-Autopilot/pull/19944 #22632

Open sverrevr opened 9 months ago

sverrevr commented 9 months ago

Describe the bug

Im pretty sure that after https://github.com/PX4/PX4-Autopilot/pull/19944 the following comments are wronge (the "primary height reference" part)

https://github.com/PX4/PX4-Autopilot/blob/a38abdbf9d5590a8572651ab1d0baecccd2cb7bb/src/modules/ekf2/EKF/common.h#L574C2-L576

baro_hgt, rng_hgt, and gps_hgt now represent whether the source is active, not whether its the primary height source, if I have understood the code correct.

For example rng_hgt is here set to true independent on what height_sensor_ref is https://github.com/PX4/PX4-Autopilot/blob/a38abdbf9d5590a8572651ab1d0baecccd2cb7bb/src/modules/ekf2/EKF/range_height_control.cpp#L191C34-L191C42

To Reproduce

N/A

Expected behavior

N/A

Screenshot / Media

No response

Flight Log

N/A

Software Version

https://github.com/PX4/PX4-Autopilot/commit/a38abdbf9d5590a8572651ab1d0baecccd2cb7bb

Flight controller

N/A

Vehicle type

None

How are the different components wired up (including port information)

No response

Additional context

No response

dagar commented 9 months ago

Yes you're absolutely correct it's a bit out of date now, if you'd like to open a pull request to update the wording I'll review it.