Commit Graph
1521 Commits
Author SHA1 Message Date
Saibernard 4da3cff386 fix(mc_nn_control): guard the model, the observations and the output (#28504)
* fix(mc_nn_control): reject a model the module cannot feed

The documentation tells users to swap the model array in control_net.cpp,
and the module then wrote 15 floats into whatever input tensor came back
and read 4 outputs from whatever output tensor came back, with no check
of either. A model with a different input width would write past the
tensor in the arena with no diagnostic. Reported in #28417.

Check the schema version before the interpreter is built on the model,
then the number of input and output tensors and the element count and
type of each, and refuse to start with the reason in the log when they
do not match. The checks live in a header without module dependencies so
they can be unit tested, and the operator registration moves to a header
so a test can load the shipped model through the real interpreter.

Assisted-by: Claude:claude-fable-5
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>

* fix(mc_nn_control): guard the observations and the network output

The network was fed whatever the position and attitude topics last held,
with no check of the validity flags, the age or finiteness, and its
output went to the motors with any non finite channel mapped to a stopped
motor while the other three kept thrusting. Reported in #28417.

Check the observations on every cycle, in the mode or not: the position
validity flags, the age of position, attitude and angular velocity
against the same limits the raptor module uses, and finiteness. The
network is not run on observations that fail, and a non finite output is
not sent. In both cases the last command of this session is repeated,
which is what the mixer would apply anyway, and the arming check reply
says the mode cannot run, so the commander leaves it through its own
fallback within one of its external check intervals. The repeat keeps
the actuator topic and the lockstep simulators going, which wait for an
output on every step. The first fault of an outage is reported once. A
non finite output is reported once and the network is not trusted again
until the mode has been left.

The module runs on angular velocity updates, so a lost angular velocity
stream would never have woken it. It is now a scheduled work item that
re-arms a delayed run on every cycle, which keeps it registering,
checking and answering the commander when the updates stop.

The trajectory setpoint starts unset and is reset to the current
position when the mode is entered without one. Before, the member was
never initialized and the reset only happened when a position update
landed on the same cycle as the first angular velocity update.

In SIH, a GPS loss while flying the neural mode produced the fault event
the same instant the position validity dropped, inference stopped, and
the commander was in Descend within its next check. A gyro loss on a
real time build produced the fault event 20 ms after the last sample and
the commander was in failsafe 150 ms later.

Assisted-by: Claude:claude-fable-5
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>

* test(mc_nn_control): cover the model, observation and output checks

Eleven cases on the checks the module runs before trusting its model,
its observations and its output: every position validity flag, each
staleness limit at its boundary and pinned to the raptor module's
values, never set and future stamps, non finite values in each
observation, the order in which faults are reported, every channel of
the output, and every way a model can fail the layout check.

One more loads the shipped model through the real interpreter and runs
the module's layout check on it, so a swapped model array the module
cannot feed fails here before it fails on a vehicle.

Assisted-by: Claude:claude-fable-5
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>

* fix(mc_nn_control): start the observation caches empty

The three cached observations were plain members, so the first
observation check read whatever the memory held before any of the
topics had published, and a stream that had not arrived could pass
that first check by chance.

They start empty now, which the first check reports as an invalid
position. A functional test builds the module in storage filled
beforehand and runs the check with nothing published.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>

* ci(tests): run every mc_nn_control test in tests_neural

The default filter of the target only matched the first test of the
module. It now selects every test of the module, and it is quoted so
the shell does not read the alternation as a pipe.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>

---------

Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>
2026-10-03 11:27:21 -06:00
Jacob Dahl b12d17f632 fix(gps): run a moving base and its rover at 5 Hz on every board (#28986)
* fix(gps): run a moving base and its rover at 5 Hz on every board

PX4-GPSDrivers f6f5c2d89a (PX4/PX4-GPSDrivers#244, with the style pass of #245): a moving base and its rover must share one navigation and measurement rate, and u-blox caps a moving base at 5 Hz on the F9P and the X20P. With the board defaults (F9P 5 Hz, X20P 10 Hz) a mixed pair was mismatched and the X20P rover reported no heading for the epochs its base never observed.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>

* docs(gps): moving base and rover share one navigation rate

The driver now holds both to 5 Hz in the moving base modes; the pages say so and tell the reader to leave GPS_UBX_RATE at 0.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>

---------

Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>
2026-10-02 20:40:28 -06:00
PX4BuildBot 79b27c5429 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-10-02 22:56:36 +00:00
Mathéo Taillandier 03c32c66f6 fix(build): move gz_env.sh out of rootfs (#28977) 2026-10-02 11:51:26 -06:00
PhilandHamish Willee b798249a61 feat(tools): add mavlink_serial_bridge.py reference bridge application (#28782)
* feat(tools): add mavlink_serial_bridge.py reference bridge application

Implements the SERIAL_CONTROL bridge application described in the Bridge Application section of docs/en/uart/serial_passthrough.md: it connects to the vehicle over MAVLink, exposes a virtual serial port (PTY), and translates traffic bidirectionally for any passthrough-capable port (TEL/GPS/ESC bitbang). Existing ESC configuration/flashing tools and GPS/RTK utilities can point at the exposed PTY without native MAVLink support.

Also updates serial_passthrough.md to reference this implementation instead of only describing the pattern in the abstract.

Signed-off-by: Phil-Engljaehringer <philipp.engljahringer@auterion.com>

* fix: add send_serial_control function

* docs: document mavlink_serial_bridge.py usage and limits

Explain what the bridge supports and how to run it safely: the example
connection string only listened on loopback, and --setup reboots the
flight controller with motor outputs disabled without saying so.

Restore the DShot ESC Serial Passthrough section, which was commented
out until a bridge existed, and update the v1.18 and main release notes
so v1.18 users know the bridge on main works with their firmware.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Hamish Willee <hamishwillee@gmail.com>

* fix: removed duplicated port-map

* fix: send_serial_control adjust padding

* fix: set target_system and target_component only once

* fix: implemented changes requested by alex

* fix: implemented changes requested by hamish

* fix: avoid indefinite loop waiting for heartbeat

* fix: no chunking in send function needed

* fix: add lock and avoid trailing 0x00 sent on shutdown

* docs: explained SWITCH <device_id> feature in docs

---------

Signed-off-by: Phil-Engljaehringer <philipp.engljahringer@auterion.com>
Signed-off-by: Hamish Willee <hamishwillee@gmail.com>
Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
2026-10-02 10:37:42 +02:00
PX4BuildBot 33769b8143 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-10-01 16:49:04 +00:00
Andrea Bernasconi 0185d7969c feat(commander): warn on low remaining flight time by default (#28952)
COM_FLTT_LOW_ACT defaulted to None, so a vehicle with a configured
battery capacity flew on silently even when the remaining flight time
was only just enough for a Return. Default to Warning so operators are
told without changing vehicle behaviour.

Assisted-by: Claude:claude-opus-5-5

Signed-off-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>
2026-10-01 18:41:09 +02:00
PX4BuildBot 9be7c6f391 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-10-01 14:38:18 +00:00
airpixel-cz 327b87f324 docs(docs): Add AirPixel TAG-E (Sony ILX-LR1 MAVLink camera controller) (#28878) 2026-10-01 16:13:26 +10:00
SaibernardandHamish Willee 50407621d9 docs(releases): add main notes for the magnetometer voter and the GNSS position loss reason (#28897)
Signed-off-by: Saibernard Yogendran <bernie97@seas.upenn.edu>
Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
2026-10-01 14:59:07 +10:00
PX4BuildBot 7cb65787b3 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 23:51:37 +00:00
PX4BuildBot b2d4f31bcd docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 23:26:29 +00:00
PX4BuildBot bb7df1293a docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 21:33:41 +00:00
PX4BuildBot 59e1100fb0 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 21:10:57 +00:00
PX4BuildBot 358d9df81b docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 18:09:05 +00:00
PX4BuildBot d251f4dd89 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 17:42:36 +00:00
4ad48205df feat(gnss): check each receiver and carry the result on the sample (#28520)
* refactor(gnss): move GnssChecks to src/lib/gnss

The checks judge a receiver, not the estimate, and the sensors module needs one checker per receiver. GnssChecks now takes its thresholds as a params struct and armed, in air and at rest per call instead of referencing EKF2's parameters and control status, and the thresholds become GNSS_CHECK and GNSS_REQ_*, with GNSS_REQ_TIME for the health time. EKF2 still runs it, so the checks behave as before.

Co-authored-by: jonas <jonas.perolini@rigi.tech>
Assisted-by: Claude:claude-opus-5-5

* feat(gnss): carry the GNSS check result on the sample

A latest-wins status can't gate fusion: it describes the newest sample, which runs ahead of the one EKF2 fuses by the GNSS delay plus the EKF buffer. The sensors module now runs one GnssChecks per receiver and stamps the selected receiver's result on each vehicle_gnss sample (usable, and failed_checks in GNSS_CHECK bit order), and EKF2 fuses a sample only if that sample is usable. EKF2 drops its own checker and estimator_gps_status; estimator_status.gps_check_fail_flags forwards the sample's failures in its own bit order until commander reads vehicle_gnss. Every receiver's diagnostics go on sensors_status_gnss.

Co-authored-by: Matheo Taillandier <matheo.taillandier@rigi.tech>
Co-authored-by: jonas <jonas.perolini@rigi.tech>
Assisted-by: Claude:claude-opus-5-5

* feat(commander): count GNSS receivers that pass their checks

A 3D fix says nothing about accuracy, drift, spoofing or jamming, so the redundancy check counted receivers the sensors module rejects. It now counts a receiver while sensors_status_gnss says it passes its checks.

Co-authored-by: jonas <jonas.perolini@rigi.tech>
Assisted-by: Claude:claude-opus-5-5

* fix(boards): drop EKF2::PublishGpsStatus from the i.MX RT ITCM lists

The function went with estimator_gps_status, and the ITCM check fails on a listed symbol that is missing from the ELF.

Assisted-by: Claude:claude-fable-5-1

* fix(ekf2): report GNSS check failures only while GNSS fusion is enabled

EKF2 ran the checks only past its GNSS-intended gate, so with EKF2_GPS_CTRL 0 estimator_status.gps_check_fail_flags stayed 0. Forwarding the sample's failures unconditionally made commander turn a receiver EKF2 ignores into pre-arm failures, and into an arming block with COM_ARM_WO_GPS 0.

Assisted-by: Claude:claude-fable-5-1

* refactor(commander): index the GNSS status by receiver instance

The sensors module fills sensors_status_gnss by sensor_gnss instance, the index the redundancy check already subscribes with, so the device_id lookup was redundant. Its sizeof idiom also tripped clang-tidy's bugprone-sizeof-expression.

Assisted-by: Claude:claude-fable-5-1

* refactor(ekf2): rename the GNSS checks pass time to sample accepted

It is set only for a sample that is both usable and within EKF2_VEL_LIM, so it is the last time a sample was accepted for fusion, not the last time the checks passed.

Assisted-by: Claude:claude-fable-5-1

* docs(msg): keep thresholds and parameters out of the GNSS check comments

Message comments describe the message and its fields, not the code that fills them.

Assisted-by: Claude:claude-fable-5-1

---------

Co-authored-by: Matheo Taillandier <matheo.taillandier@rigi.tech>
Co-authored-by: jonas <jonas.perolini@rigi.tech>
Co-authored-by: Jacob Dahl <dahl.jakejacob@gmail.com>
2026-09-30 11:34:05 -06:00
Jacob Dahl d5223850dd docs(contributing): discourage force-pushing during review (#28931)
* docs(contributing): discourage force-pushing during review

A force-push after review has begun erases the commits a reviewer has read, so they cannot see what changed since. The guidance told contributors to squash and reword instead, which contradicts the commit and pr agent skills. PRs are typically squash-merged, so branch history does not need cleaning up before merge.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>

* ci(workflows): remove commit message check

PRs are squash-merged under the PR title, which is still checked. Flagging the individual commits pushed contributors to rewrite history mid-review.

Assisted-by: Claude:claude-fable-5-1
Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>

---------

Signed-off-by: Jacob Dahl <dahl.jakejacob@gmail.com>
2026-09-30 11:04:19 -06:00
PX4BuildBot 38914a08d3 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 16:53:17 +00:00
PX4BuildBot 596889f8b6 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-30 11:33:48 +00:00
Daniel Buleandră 1dbf64d67e fix(vtx): Update peak thor parameter name and remove Rush MAX SOLO (#28692)
Rename the VTX_DEVICE entry for the Peak THOR so it lists the supported
models, and drop the Rush MAX SOLO device entirely: its VTX_DEVICE enum
value and the DEVICE_RUSH_MAX_SOLO constant in Vtx.msg.

A stored VTX_DEVICE of 10240 (Rush MAX SOLO) is migrated to Generic with
Tramp, the only protocol it speaks.
2026-09-30 13:27:50 +02:00
Daniel BuleandrăandHamish Willee c3afa795c6 docs(debug): add DroneCAN shell guide (#28404)
Peripheral nodes that only have a CAN connection expose no serial debug
port, so their NSH console is reachable only through the
uavcan.protocol.AccessCommandShell service served by the uavcannode
driver. Document how to open that shell, its options and keys, and its
limitations (one session per node, last_exit_status), and link it from
the consoles overview and the docs sidebar.

Signed-off-by: danielbuleandra <daniel.buleandra@auterion.com>
Co-authored-by: Hamish Willee <hamishwillee@gmail.com>
2026-09-30 10:57:05 +02:00
PX4BuildBot 852fc4e9a7 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-29 22:44:52 +00:00
PX4BuildBot 65b67eafa6 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-29 22:09:16 +00:00
Julian Oes 107d8bb038 fix(mavlink): forward received frames unchanged (#28891)
* fix(mavlink): forward received frames unchanged

Forwarded messages were queued as a truncated copy of mavlink_message_t
and re-serialized on the way out. The signature bytes were never
copied, so forwarded signed messages went out with a garbage signature.

Messages which are not in our dialect were not forwarded at all: the
parser can't check their CRC without CRC_EXTRA, reports them as bad CRC,
and mavlink_parse_char() drops them.

Frames are now queued as they arrived, checksum and signature included,
and written out as is. Following the MAVLink routing guide, frames that
can't be processed locally are still forwarded but not handled: unknown
MAVLink 2 messages, and messages whose signature can't be verified. The
signature isn't checked or removed, that's up to the receiver, which
may well have a different key than PX4. SETUP_SIGNING is still never
forwarded.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): only apply SETUP_SIGNING addressed to us

The target of SETUP_SIGNING was ignored, so a key meant for another
system or component, e.g. a companion computer, was applied to PX4 and
all its links instead.

SETUP_SIGNING is now only applied when it is broadcast or addressed to
us. Otherwise it is dropped, as it must never be forwarded, and a
warning tells the user that it didn't reach its target.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* refactor(mavlink): forward messages from one place

Messages which were handled locally were forwarded from the end of
Mavlink::handle_message(), while frames which can only be forwarded
took a separate path in the receive loop. Forwarding is now decided in
one place in the receive loop for both, and Mavlink::handle_message()
only deals with SETUP_SIGNING.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* refactor(mavlink): check forwarding enabled only once

Whether to forward is decided by forward_if_enabled(), so
forward_only_frame() only needs to decide whether a frame is valid but
can't be processed locally. As a result, unknown and incorrectly signed
frames no longer count as parse errors, independent of whether
forwarding is enabled.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* feat(mavlink): count unknown and incorrectly signed messages

Messages which are not in our dialect or whose signature can't be
verified are not processed and no longer count as parse errors. Count
them per link in telemetry_status instead, so they show up in the log
and in mavlink status, e.g. to find a sender using the wrong key.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): count lost messages correctly across sequence wrap-around

The sequence number wraps from 255 to 0, so the gap across the wrap is
seq + 256 - expected, not seq + 255 - expected. Every wrap-around with
loss undercounted by one message.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): report rx message loss as a fraction of all messages

rx_message_lost_rate was lost / received, which exceeds 1 with heavy
loss and is 0/0 before anything was received, and mavlink status then
printed that ratio as a percentage without scaling it. It is now
lost / (received + lost), 0 if nothing was received yet, and printed
as a percentage.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): don't forward unauthenticated frames when signing is active

With a signing key loaded, frames which fail PX4's signature check were
forwarded to the other links. PX4 keeps unauthenticated traffic from
e.g. the radio away from components which don't sign themselves, as the
signing docs describe, so drop them again, and count them as bad
signatures.

Unknown messages are reported as bad CRC by the parser, which doesn't
report their signature result, so apply the same rules to them: with
signing active they are only forwarded if signed with PX4's key or
allowed unsigned.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): don't count forwarded unknown messages as lost

Unknown messages didn't advance the sender's sequence, so the next
message from it counted them as lost. Track their sequence as well, but
only for components we have already seen: the header of an unknown
message isn't CRC checked, and garbage IDs would fill the component
table, which is also used for routing.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): forward signed frames PX4 can't verify

With signing active, a signed frame which fails PX4's check might be
signed with the receiver's key, so forward it for the receiver to
check, as the MAVLink routing guide says, but don't process it.
Unsigned frames are still dropped, apart from the unsigned allowlist,
so an attacker still can't send unsigned messages through PX4.

Suggested by @dakejahl in review.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(mavlink): drop signed frames PX4 can't verify again

This reverts commit 80639d05d8. Setting the signed flag and appending a
random signature is trivial, so forwarding signed frames that fail
verification would let an attacker reach components behind PX4 that
don't check signatures themselves, just like unsigned frames. In
practice all systems share one key anyway, so with signing active only
forward what verifies with PX4's key, or is on the unsigned allowlist.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

* docs(mavlink): signing assumes one shared key

Make explicit that all systems and components share one symmetric key,
that components communicating through PX4 need to use PX4's key, and
that incorrectly signed messages are not forwarded, so they don't reach
components behind PX4 which don't check signatures themselves.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>

---------

Signed-off-by: Julian Oes <julian@oes.ch>
2026-09-30 10:55:25 +13:00
PX4BuildBot 8f106ed256 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-29 17:23:59 +00:00
Jacob Dahl e40501eba0 refactor(msg): rename GPS to GNSS in messages, topics and sensor parameters (#24399)
* refactor(msg): rename SensorGps to SensorGnss and add VehicleGnss

GPS is one constellation; the receivers and the rest of PX4 handle GNSS. Field names lose their units (latitude, speed_accuracy, course, ...), which move into the metadata comments. The sensors module's output becomes VehicleGnss on vehicle_gnss: the selected receiver's sample next to what the sensors module adds to it (corrected sample time, antenna position, selected instance), so a consumer can tell the two apart and later selection and check results have a place to go.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/gps): publish sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/septentrio): publish sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/pps_capture): read sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(lib/gnss): select receivers on sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(sensors): publish VehicleGnss on vehicle_gnss and rename SENS_GPS* to SENS_GNSS*

The sensors module's output nests the selected receiver's sample, with the corrected sample time, antenna position and selected instance next to it. SENS_GPS_MASK/TAU/PRIME and SENS_GPSn_ID/OFFX/OFFY/OFFZ/DELAY take the SENS_GNSS name the heading parameters already use; saved parameters migrate on import, and the EKF2_GPS_POS/EKF2_GPS_DELAY translations now land on the new names directly.

Assisted-by: Claude:claude-opus-5-5

* refactor(logger): log sensor_gnss and vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(ekf2): fuse vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(replay): replay vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(local_position_estimator): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(attitude_estimator_q): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(lib/terrain_estimation): take sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(lib/wind_estimator): read vehicle_gnss in the replay script

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(vision_target_estimator): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(navigator): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(commander): read sensor_gnss and vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(mavlink): stream sensor_gnss and vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(uxrce_dds_client): bridge vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(zenoh): bridge vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(failure_injection): inject GNSS failures on sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/ins): publish sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/uavcan): publish sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/uavcannode): read sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/cyphal): bridge sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/telemetry): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/rc): read vehicle_gnss for telemetry

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/osd): read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(drivers/transponder): read sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(boards/modalai): publish sensor_gnss from the voxl2 drivers

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(examples): publish sensor_gnss and read vehicle_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(simulation): publish sensor_gnss

Follows the SensorGps to SensorGnss and vehicle_gps_position to VehicleGnss rename.

Assisted-by: Claude:claude-opus-5-5

* refactor(gnss): name GNSS variables gnss in the sensors module and receiver drivers

GPS is one constellation. Identifiers that hold or handle GNSS samples, or bind to the renamed parameters, follow the message and parameter rename; classes, files, modules and names tied to parameters that keep GPS stay.

Assisted-by: Claude:claude-opus-5-5

* refactor(gnss): name GNSS variables gnss in the estimators and navigator

GPS is one constellation. Identifiers that hold or handle GNSS samples, or bind to the renamed parameters, follow the message and parameter rename; classes, files, modules and names tied to parameters that keep GPS stay.

Assisted-by: Claude:claude-opus-5-5

* refactor(gnss): name GNSS variables gnss in commander, mavlink and failure injection

GPS is one constellation. Identifiers that hold or handle GNSS samples, or bind to the renamed parameters, follow the message and parameter rename; classes, files, modules and names tied to parameters that keep GPS stay.

Assisted-by: Claude:claude-opus-5-5

* refactor(gnss): name GNSS variables gnss in the remaining drivers and simulation

GPS is one constellation. Identifiers that hold or handle GNSS samples, or bind to the renamed parameters, follow the message and parameter rename; classes, files, modules and names tied to parameters that keep GPS stay.

Assisted-by: Claude:claude-opus-5-5

* docs(gnss): reference sensor_gnss, vehicle_gnss and SENS_GNSS* parameters

The upgrade guide covers the topic, field, ROS 2, parameter and Cyphal register renames.

Assisted-by: Claude:claude-opus-5-5

* fix(boards): name EKF2::UpdateGnssSample in the fmu-v6xrt ITCM lists

The rename left the old UpdateGpsSample symbol in the lists, so the ITCM check fails and the function drops out of ITCM on the boards it doesn't check.

Assisted-by: Claude:claude-opus-5-5

* chore(drivers/gps): bump PX4-GPSDrivers to the merged sensor_gnss rename

The submodule pointed at the PX4-GPSDrivers#243 branch commit; #243 is merged.

Assisted-by: Claude:claude-opus-5-5

* docs(msg): restore WGS84 in SensorGnss and point VehicleGlobalPosition at vehicle_gnss

The rename dropped the only mention of the WGS84 datum and ellipsoid, and left VehicleGlobalPosition referring to the removed vehicle_gps_position topic.

Assisted-by: Claude:claude-opus-5-5

* refactor(msg): drop selected_instance from VehicleGnss

receiver.device_id already names the selected receiver, and 0 while blended. The sensor_gnss instance depends on the order drivers advertise at boot, so it doesn't identify a receiver across boots or logs, and nothing reads it. It would also be meaningless on the per-receiver VehicleGnss instances proposed in #28894.

Assisted-by: Claude:claude-opus-5-5

* refactor(gnss): fuse vehicle_gnss.timestamp_sample directly and document the receiver's corrected time

vehicle_gnss.timestamp is now the sensors module's publish time, so EKF2's check of timestamp_sample against it was always true; the sensors module always fills timestamp_sample. The message docs described receiver.timestamp_sample as the driver's uncorrected value, but the sensors module writes the corrected time into it as well.

Assisted-by: Claude:claude-opus-5-5

* docs(msg): point VehicleGnss users at the top-level timestamp_sample

uXRCE-DDS shifts only top-level timestamp and timestamp_sample into agent time, so receiver.timestamp_sample reaches ROS 2 on the PX4 boot clock even though it holds the same value on uORB.

Assisted-by: Claude:claude-opus-5-5

* docs(releases): tell ROS 2 users which VehicleGnss timestamps to read

Only top-level timestamps are converted to ROS time, so a port that reads receiver.timestamp gets the PX4 boot clock, and vehicle_gnss.timestamp is now the sensors module's publish time rather than the receiver's.

Assisted-by: Claude:claude-opus-5-5
2026-09-29 10:36:49 -06:00
Davide Iafrate ea495a418e docs(simulation): fix name of baylands world sdf file (#28909) 2026-09-29 14:31:08 +01:00
PX4BuildBot e81e29d933 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-29 10:30:13 +00:00
Andrea Bernasconi 0d104226d3 feat(mc_rate_control): add rate loop gain compression for MC (#28719)
* feat(mc_rate_control): add rate loop gain compression

Extend the gain compression already available on fixed-wing to the
multicopter rate controller, so that an oscillation (limit cycle) on the
torque setpoint dynamically reduces the loop gain instead of requiring a
manual retune. The gain recovers to 1.0 once the oscillation stops.

GainCompression3d is templated on the enable and minimum gain parameter
IDs so both airframe types share one implementation while keeping their
own MC_GC_* / FW_GC_* parameters. Behaviour is opt-in: MC_GC_EN defaults
to disabled.

The dt clamp in the spectral damper is widened from 1 ms to 0.125 ms
because multicopter rate loops run well above the 1 kHz that the previous
floor assumed, which would otherwise mis-scale the filter coefficients.
Compression is reset while landed so that ground contact vibration does
not compress the gains before takeoff.

Assisted-by: Claude:claude-opus-5
Signed-off-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>

* fix(rate_control): fully restart gain compression on reset

reset() only restored the scalar compression gains, leaving the spectral
damper history and the cached gain vector untouched. A reset therefore did
not really restart at gain 1: the next cycle still multiplied the torque
setpoint by the previously compressed vector, and the stale HPF/LPF state
could immediately recreate compression. Clear the detector history and the
cached gains so that disarming, a non-rotary-wing transition or ground
contact genuinely restart from an uncompressed loop.

Seed the high-pass filter from the first sample after a reset instead of
zeroing the input history. Since the multicopter controller resets on every
cycle while landed, a zeroed history would make the first airborne sample
look like a step edge and inject a spurious spike into the spectral damper
right at takeoff.

Assisted-by: Claude:claude-opus-5
Signed-off-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>

* docs(mc_rate_control): document multicopter gain compression

Add a feature page for gain compression on multicopters, mirroring the
fixed-wing one but covering the multicopter specifics: it is opt-in
(MC_GC_EN defaults to disabled), and compression is reset while disarmed
or landed so ground contact cannot compress the gains before takeoff.

The fixed-wing block diagram is linked rather than duplicated, since it
contains an airspeed scaling stage that does not exist in the multicopter
rate loop.

Also note in the multicopter PID tuning guide that compression should be
off during manual tuning, as it damps out the very oscillation the tuning
process looks for.

Assisted-by: Claude:claude-opus-5
Signed-off-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>

---------

Signed-off-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>
2026-09-29 12:22:31 +02:00
PX4BuildBot 16922e6694 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-29 02:01:38 +00:00
PX4BuildBot db8bc69c4a docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-28 23:46:19 +00:00
Jacob Dahl eb8f2f9b42 refactor(ekf2): separate GNSS heading from position into independent topic (#27102)
* feat(sensors/vehicle_gps_position): publish GNSS heading on its own topic

Dual-antenna heading was only reachable through the blended
vehicle_gps_position, so it carried the position timestamp, followed the
position blending weights and was published at the position rate.
vehicle_gnss_heading carries one selected source at a time, preferring
sensor_gnss_relative (callback driven) and falling back to
sensor_gps.heading for receivers that do not publish it. Per-receiver
delay and the driver heading offset are resolved by device_id; a sample
timestamp within 10 ms of the publish timestamp is treated as unset so
the configured delay applies.

* refactor(ekf2): fuse GNSS heading from its own sample buffer

Heading rode on gnssSample and was only fused when a position sample was
popped: faster heading was dropped by the observation rate limit, its
timestamp was the position timestamp and a position outage blocked the
start. gnssYawSample has its own TimestampedRingBuffer and pop. Non-finite
yaw is rejected at the interface and a NaN heading_offset is treated as
zero instead of reaching the fusion Jacobian. The test simulator feeds
heading as an independent sensor.

* feat(sensors/vehicle_gps_position): per-receiver baseline rotation SENS_GPSn_ROT

The antenna baseline orientation lived in three places depending on the
transport: the serial driver (GPS_YAW_OFFSET), the Septentrio receiver
(SEP_YAW_OFFS, SEP_PITCH_OFFS) and EKF2 for anything arriving with a NaN
offset, in practice CAN receivers (EKF2_GPS_YAW_OFF). A second receiver
with a different baseline had no parameter at all. Drivers now publish
the raw baseline heading and vehicle_gps_position rotates it into the
body frame from the receiver's SENS_GPSn_* slot, the same Rotation enum
the other sensors use, before blending and before publishing
vehicle_gnss_heading. Bumps PX4-GPSDrivers so sensor_gnss_relative
carries a real UTC time and no parse-time sample timestamp, which lets
the relative-position heading be delay-compensated and PPS-aligned.

* refactor(drivers/gps): drop the UBX heading_offset setting

Bumps PX4-GPSDrivers to PX4/PX4-GPSDrivers#241, which removes the
driver-side heading offset now that SENS_GPSn_ROT is the only place the
baseline is rotated.

Assisted-by: Claude:claude-opus-5-5

* refactor(sensors/vehicle_gps_position): remove sensor_gps.heading_offset

With the baseline rotation in SENS_GPSn_ROT, a finite offset only meant
"the driver already rotated this heading, skip SENS_GPSn_ROT". The only
remaining writer was older DroneCAN node firmware through the Fix2 ECEF
hack, which made a CAN node's heading switch between two conventions
depending on whether a RelPosHeading arrived between Fix2 messages: with
a non-zero SENS_GPSn_ROT yaw the heading jumped by that angle. Every
receiver's heading is now the measured baseline and SENS_GPSn_ROT is the
only rotation. MicroStrain external heading aiding, which recovered the
baseline heading from vehicle_gps_position, reads vehicle_gnss_heading.

Assisted-by: Claude:claude-opus-5-5

* fix(mavlink): report the body-frame GNSS heading in GPS_RAW_INT and GPS2_RAW

sensor_gps now carries the measured baseline heading, so for a baseline
not along the body x axis the yaw field was off by the mounting angle.
The body-frame heading is taken from vehicle_gnss_heading when the
streamed receiver is the heading source.

Assisted-by: Claude:claude-opus-5-5

* fix(replay): replay vehicle_gnss_heading to EKF2

ReplayEkf2 publishes only the topics it lists from inside the lockstep
barrier, so EKF2 replay never received the heading.

Assisted-by: Claude:claude-opus-5-5

* feat(parameters): migrate GNSS heading offsets to SENS_GPSn_YAW

GPS_YAW_OFFSET, SEP_YAW_OFFS and EKF2_GPS_YAW_OFF were removed without a
migration, so an upgraded vehicle silently lost its antenna mounting
offset and its GNSS yaw was off by that angle.

Assisted-by: Claude:claude-opus-5-5

* fix(sensors/vehicle_gps_position): build GNSS heading only where it is consumed

The heading selection, baseline rotation and SENS_GPSn_ROT parameters
overflowed diatone_mamba-f405-mk2 flash by 657 bytes. Boards built
without EKF2 GNSS yaw fusion or MicroStrain have no consumer for
vehicle_gnss_heading, so SENSORS_VEHICLE_GNSS_HEADING defaults on only
with one of them. The parameter migration also drops fmodf, since the
old parameters never exceeded one wrap.

Assisted-by: Claude:claude-opus-5-5

* feat(sensors/vehicle_gps_position): carry the heading receiver's jamming and spoofing state

So that EKF2 can gate GNSS yaw on the receiver providing the heading, which is not necessarily the position receiver.

Assisted-by: Claude:claude-fable-5-1

* fix(ekf2): gate GNSS yaw on the heading, not the position checks

Yaw fusion could only start once the position checks passed, and stopped with them. On an ARK G5 outdoors the heading was good from 36 s after power-up and was first fused at 104 s, held back by EPV while Galileo HAS converged; a 0.45 s PDOP failure while the vehicle was handled on the ground stopped yaw for 10 s with its innovations under 5.4 deg.

The heading is its own observation, often from its own receiver: yaw now starts on fresh data, tilt alignment and the heading receiver's spoofing and jamming state under the EKF2_GPS_CHECK bits, and keeps running when position and velocity fusion stop. The hold-off after a yaw fusion failure was a side effect of the position checks resetting; it is now a yaw timer that withholds the heading from a reset for the GNSS health time.

Assisted-by: Claude:claude-fable-5-1

* fix(sensors/vehicle_gps_position): carry an unknown GNSS sample time as 0

A GNSS sample time within 10 ms of the publish time was treated as unset and replaced by SENS_GPSn_DELAY. An ARK G5 over DroneCAN measures 8.3 to 21.5 ms from epoch to receipt, so 0.4% of its headings were re-stamped 110 ms early; at 20 Hz EKF2 dropped them as out of order, at a lower rate they would have been fused 100 ms late. A stamp meaning unset that crossed a busy bus in more than 10 ms would have been trusted instead.

Unknown is now 0 end to end: the serial driver leaves timestamp_sample at 0, the CAN node sends RelPosHeading's timestamp as UNKNOWN for it, and the autopilot's bridge publishes 0 when the node timestamp can't be used. Any other sample time before the publish time is trusted.

Assisted-by: Claude:claude-opus-5-5

* feat(sensors/vehicle_gps_position): derive the GNSS heading baseline from antenna positions

SENS_GPSn_ROT and its Euler angles carried one number: roll never moves a baseline along x, pitch only flagged a vertical one, and the heading model uses the baseline yaw alone. Nothing checked the heading against the installation either, so a receiver that flagged float solutions as valid reset yaw 87 deg wrong at first fix on an ARK G5 moving-base pair.

As in ArduPilot, the baseline now comes from the antenna positions: SENS_GPSn_HDG selects the other receiver's antenna (moving base, from both slots' SENS_GPSn_OFF) or a custom SENS_GPSn_BLX/Y/Z (single dual-antenna receiver), and a heading is used only when the receiver reports a baseline within 20% of it in length and in its vertical component over the sample's attitude. Those float solutions reported 10.9 m and 1.04 m for a 0.347 m baseline. A source is published once it has passed for 1 s: the headings right after the base antenna was re-plugged passed for 0.9 s while up to 25 deg wrong. vehicle_gnss_heading logs the reported baseline length.

A yaw offset can't be turned into a baseline, so GPS_YAW_OFFSET, SEP_YAW_OFFS and EKF2_GPS_YAW_OFF are not migrated; GNSS yaw stays off, with a warning, until SENS_GPSn_HDG is set.

Assisted-by: Claude:claude-opus-5-5

* fix(ekf2): stop GNSS yaw on a spoofed or jammed heading receiver

The heading receiver's spoofing and jamming state only kept yaw fusion from starting; a receiver that reported spoofing in flight kept feeding yaw, where position fusion stops. Its samples are now not fused, the fusion stops once none has been for the reset timeout, and a reset to its heading waits for the GNSS health time, as for position.

Assisted-by: Claude:claude-opus-5-5

* docs(dronecan): configure the ARK G5 heading baseline on the autopilot

The page still configured the heading offset with the module's SEP_OFFS_YAW, and required GPS blending for the heading to be published, which no longer carries it.

Assisted-by: Claude:claude-opus-5-5

* fix(sensors/vehicle_gps_position): drop a mismatched GNSS heading without restarting the settle

Outdoors on an ARK G5 moving-base pair 0.35 m apart, the reported down component of the baseline scattered by up to 0.16 m while the airframe was turned, and 9 cm at rest, against the 7 cm the vertical check allows. The rejected headings were as good as the accepted ones, but every rejection restarted the 1 s settle, so during 720 deg turns a heading was published for 4 to 62% of the time.

A sample that fails the baseline checks is now only dropped; the settle restarts when the receiver reports no heading. Replayed on that log, 85 to 99% of the turns get a heading.

Assisted-by: Claude:claude-opus-5-5

* fix(sensors/vehicle_gps_position): drop the GNSS heading baseline's vertical check

The check compared the reported down component of the baseline with the configured baseline rotated by the vehicle attitude, within 20% of the baseline length. On an ARK G5 moving-base pair 0.35 m apart the down component scattered by up to 9 cm at rest and 0.16 m while the airframe was turned, so it rejected good headings: across seven outdoor logs it rejected 184 samples under 5 deg of error and 6 over 10 deg, all of which the EKF innovation gate would handle, and nothing the length check missed on a receiver that withholds float headings.

The length check and the near-vertical check on the reported baseline stay. The sensors module no longer reads the vehicle attitude to check the heading.

* feat(sensors/vehicle_gps_position): SENS_GNSSn_HDG with the auxiliary antenna position

The heading parameters are new, so they take the GNSS name the rest of the SENS_GPS family moves to rather than being renamed again shortly. The setup names what the receiver is: the rover of a moving base pair, or a receiver with two antennas. For the latter the second antenna is given by its position, like the main one's SENS_GPSn_OFF, so every setup derives the baseline from antenna positions.

Assisted-by: Claude:claude-opus-5-5

* feat(drivers/septentrio): publish the heading baseline on sensor_gnss_relative

The heading only reached PX4 through sensor_gps, without the baseline the receiver measured, so the sensors module could not check it against the configured one and a heading from float ambiguities, confident on a baseline metres off, was used. AuxAntPositions (dual antenna) or BaseVectorGeod (moving base rover) now go out with the heading of the same epoch on sensor_gnss_relative at EndOfAtt, the heading valid only with fixed ambiguities. Ported from ARK's driver, where it was tested outdoors on mosaic-G5 P3H, P6 and P8.

A receiver that rejects the extra blocks falls back to the previous output without a heading. The heading accuracy is the square root of the reported variance; it was the deg^2 variance scaled as if it were degrees.

Assisted-by: Claude:claude-opus-5-5

* refactor(sensors/vehicle_gps_position): take GNSS heading only from sensor_gnss_relative

The sensor_gps fallback carried no reported baseline, so its headings skipped the length check that rejects a wrong ambiguity fix. Every receiver that matters now reports on sensor_gnss_relative: u-blox, Septentrio, the Unicore UM982 (PX4/PX4-GPSDrivers bump) and DroneCAN RelPosHeading. The heading fields of sensor_gps go, with the paths that filled them: NMEA HDT, Trimble MB-Two, Femtomes, SBG and MicroStrain, the heading in DroneCAN Fix2 on both the node and the autopilot, and the RelPosHeading copy into sensor_gps.

Assisted-by: Claude:claude-opus-5-5

* docs(gps_compass): configure GNSS heading with SENS_GNSSn_HDG

The heading parameters were renamed and the heading now only comes from receivers that report their baseline, so the Trimble MB-Two and Femtomes pages no longer describe a heading setup. The antenna spacing is the recommended 30 cm rather than the 5 cm the code rejects below.

Assisted-by: Claude:claude-opus-5-5

* chore(drivers/gps): point PX4-GPSDrivers at the merged PX4/PX4-GPSDrivers#242

The submodule tracked the PR's branch commit; the squash-merged commit has the same tree.

Assisted-by: Claude:claude-opus-5-5
2026-09-28 17:37:58 -06:00
PX4BuildBot 095b1af76d docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-28 22:52:00 +00:00
Ramon Roche 14cf29bb31 fix(build): check submodules once per configure, never reset changes
Every px4_add_git_submodule call ran check_submodules.sh twice, at
configure and build time, and with CI=true force-updated each submodule
every time, a 2017 workaround for an interactive prompt that is gone.
VS Code and CLion force-updated too, resetting submodule changes under
development.

The check now runs once per configure. A missing submodule is fetched;
one at another commit is kept as it is, with a warning locally and an
error in CI.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-28 11:50:38 -07:00
Ramon Roche 5062756be4 docs(offboard): correct fixed-wing velocity and BODY_NED support
Velocity setpoints are not ignored on fixed-wing. When combined with a
position setpoint, FixedWingModeManager selects FW_POSCTRL_MODE_AUTO_PATH
and follows a path through the position tangent to the horizontal
velocity direction, with the acceleration component normal to the
velocity used as path curvature.

Velocity-only setpoints are not supported: offboard without a position
setpoint clears flag_control_position_enabled, so set_control_mode_current
falls through to FW_POSCTRL_MODE_OTHER and no new lateral/longitudinal
setpoints are published. Since MAV_FRAME_BODY_NED always discards the
position, it cannot be used for fixed-wing.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-28 11:47:03 -07:00
Ramon Roche 6152abde11 docs(offboard): clarify BODY_NED applies to velocity and acceleration setpoints only
BODY_NED position setpoints have never been supported: the receiver
rotates velocity and acceleration into the local frame and sets
position to NAN, and for fixed-wing (position setpoints only) the
frame cannot be used at all. The docs listed input combinations and
coordinate frames as independent lists, implying every combination
works in every frame, which misled users into filing #27617.

Also update stale code links still pointing at FlightTaskOffboard.cpp,
removed in the v1.12 offboard rework (#16739).

Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-28 11:47:03 -07:00
Ramon Roche e0dc50d7cc build(uavcan)!: stop embedding CAN node firmware in flight controller builds
CONFIG_BOARD_UAVCAN_PERIPHERALS made ROMFS clone the PX4 repository and
run a second full build of a CAN node on every build of the flight
controller, to carry that node's firmware in /etc/uavcan/fw/. Its only
user, px4_fmu-v5_uavcanv0periph (CUAV CAN GPS v1), disabled about 30
modules to make room, and was downloaded 40 times in five years, never
through QGroundControl. Releases now publish every CAN node's firmware
standalone as <target>.uavcan.bin, which the DroneCAN firmware server
installs from the SD card on any flight controller.

Remove the option, the ROMFS ExternalProject and the board variant, and
point the DroneCAN docs and the release notes at the SD card path. The
server still serves /etc/uavcan/fw/, which is now empty.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-28 09:45:09 -07:00
PX4BuildBot 898d6056cf docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-28 16:14:41 +00:00
PX4 Build BotandCrowdin Bot 4ce66eb466 docs(i18n): PX4 guide translations (Crowdin) - uk (#28866)
Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
2026-09-27 13:34:48 +10:00
PX4 Build BotandCrowdin Bot 56d5e8661a docs(i18n): PX4 guide translations (Crowdin) - zh-CN (#28867)
Co-authored-by: Crowdin Bot <support+bot@crowdin.com>
2026-09-27 13:34:19 +10:00
e35171c3f9 fix(logger): make logger off close the active log file (#28636)
* fix(logger): make off stop active file logging

Handle logger on and off as explicit requests so logger off closes an active file log without disabling future automatic activations. Continuous logging modes fall back to arm-to-disarm sessions until reboot after their active log is stopped.

Assisted-by: Codex:gpt-5
Signed-off-by: jc-works <jc-works@users.noreply.github.com>

* fix(logger): keep the configured log mode on manual stop

Falling back to LogMode::while_armed by overwriting _log_mode destroyed the
configured mode for the rest of the boot, and nothing reported it: neither
logger status nor LoggerStatus carries the mode.

Only boot_until_shutdown needs the fallback at all, because its early return
would otherwise keep logging disabled once the boot log is stopped. Express
that with a dedicated flag so _log_mode stays the configured value, and say so
on the console when it happens.

arm_until_shutdown needs no fallback. After the forced stop
_prev_file_log_start_state is false, so full_log_continues is false and the
desired state falls back to plain arming. The next arming starts a log and sets
the flag again, so the following disarm keeps logging to shutdown as configured
instead of ending the log early.

Assisted-by: Claude:claude-opus-5
Signed-off-by: Julian Oes <julian@oes.ch>

* fix(logger): restore SDLOG_MODE 2 logging behaviour after rearming

After logger off stops a boot-to-shutdown log, suspend automatic logging only until the next arming. Restore the configured lifecycle when the new log starts so it continues across subsequent disarms until shutdown.

Update the logger message and documentation accordingly.

Assisted-by: Codex:gpt-5
Signed-off-by: jc-works <jc-works@users.noreply.github.com>

* fix(logger): make repeated off requests idempotent

Regression testing found that repeating logger off after the active log had closed cleared the manual stop latch. When the arming or AUX logging condition remained active, automatic logging started a new log.

Preserve the manual stop latch across repeated off requests so logging remains stopped until the automatic logging condition deactivates. The latch is also cleared explicitly by logger on.

Assisted-by: Codex:gpt-5
Signed-off-by: jc-works <jc-works@users.noreply.github.com>

---------

Signed-off-by: jc-works <jc-works@users.noreply.github.com>
Signed-off-by: Julian Oes <julian@oes.ch>
Co-authored-by: jc-works <jc-works@users.noreply.github.com>
Co-authored-by: Julian Oes <julian@oes.ch>
2026-09-27 14:27:50 +13:00
Beniamino Pozzan fba1622d0c docs(uxrce_dds): bump agent version from 3.0.1 to 3.0.2
Flow control now is available in 3.0.2 and only need
cherry-pick for 2.4.2 and 2.4.3

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@gmail.com>
2026-09-26 18:13:37 -07:00
Ramon Roche 39e82389e2 docs(dev_setup): drop the stale JDK sudo note from the macOS guide (#28861)
Assisted-by: Claude:claude-opus-5-5

Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-27 09:18:00 +10:00
LtxxandBeniamino Pozzan d2de298122 fix(uxrce_dds): align SITL namespace prefix (#28338)
* fix(uxrce_dds): align SITL namespace prefix

Use the same uav_ namespace prefix for SITL multi-instance startup and UXRCE_DDS_NS_IDX fallback. This keeps simulation and hardware topic names consistent without changing the existing hardware default.

Assisted-by: OpenAI Codex: GPT-5

* docs(uxrce): update uxrce_dds docs

* docs(release): update `main` release page

---------

Signed-off-by: Beniamino Pozzan <beniamino.pozzan@gmail.com>
Co-authored-by: Beniamino Pozzan <beniamino.pozzan@gmail.com>
2026-09-27 00:12:55 +01:00
Ramon Roche a8b0e91ebe feat(setup): install macOS Gazebo from a locked conda-forge environment
Homebrew rebuilds and drops the gz bottles whenever homebrew-core bumps
protobuf or abseil, which breaks the macOS Gazebo install until the pins
catch up. conda-forge keeps every package it has published, so
Tools/setup/macos/pixi.toml and its lock install the same gz, protobuf,
abseil, OpenCV and GStreamer binaries until the lock is updated on
purpose. OpenCV is the headless build, and GStreamer brings the good,
bad and ugly plugin sets the gz camera plugin's pipeline uses.

macos.sh installs the environment with pixi and loads it from the venv
activation through a small script, since pixi shell-hook would export
the installing shell's PATH. The build and the gz launch do not depend
on that activation: CMake searches the environment like it pins the
.venv Python, and px4-rc.gzsim sources gz_env.sh before it looks for
gz, which loads the environment when it is not already active and puts
its lib dir ahead of Homebrew's in the dyld fallback path.
conda-forge's gz-transport13 does not pull in cppzmq, so the manifest
lists it.

The osrf/simulation pin, the protobuf pin and the weekly bot that
refreshed them are removed. The homebrew-core commit moves into
homebrew-pins.txt unchanged.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-26 15:12:00 -07:00
Ramon Roche de9c69316e docs(simulation): replace jMAVSim with SIH and Hawkeye
The jMAVSim pages become redirects to SIH, examples and HITL options
move to SIH, Gazebo or Gazebo Classic, and SIH on hardware gets Hawkeye
as its 3D display-only view through a MAVLink bridge to its UDP port.
The release notes flag the removal in the upgrade guide.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-09-26 14:28:26 -07:00
PX4BuildBot 5fb15552bb docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-26 02:47:37 +00:00
Andrea Bernasconi b38dcb1f6c fix(navigator): use "Return" instead of "RTL" in user-facing text (#28543) 2026-09-26 12:40:56 +10:00
PX4BuildBot 579f7d161e docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-09-25 17:37:12 +00:00