52107 Commits
Author SHA1 Message Date
Leonardo Cencetti cd68f944d4 fix(zenoh): honor stop requests while the session is retried (#29925)
The session open retry slept 5 s with sleep() and never checked for a
stop request, so `zenoh stop` timed out and force-deleted the task.
Wait in 100 ms steps instead and return as soon as a stop is requested.

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

Signed-off-by: Leonardo Cencetti <cencetti.leonardo@gmail.com>
2026-11-21 16:05:56 +00:00
Leonardo Cencetti 98e747fa3d fix(zenoh): fail the topic setup when a declaration fails (#29924)
A subscriber that could not be declared called exit(-1). That ended the
module task but left the zenoh-pico tasks running, so the session
stayed up with nothing bridged and `zenoh status` still reported it as
connected.

Return the error instead, and fail the topic setup when a subscriber or
publisher declaration fails.

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

Signed-off-by: Leonardo Cencetti <cencetti.leonardo@gmail.com>
2026-11-21 15:44:20 +00:00
Bogdan Beju - NXP 0e0f3ce8a2 docs(boards/nxp_mr-tropic): Add docs for NXP MR-VMU-TROPIC (#29602) 2026-11-21 15:25:05 +11:00
Ramon Roche 3de5e83add docs(releases): add a v1.18 introduction and how to get the release
The v1.18 notes opened with a single line pointing at v1.17. The new
introduction describes what the release changes for operators and
integrators, and the new section explains how to fly, simulate, build
and integrate with v1.18, including the published containers, which the
notes never mentioned.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Ramon Roche <mrpollo@gmail.com>
2026-11-20 15:34:16 -08:00
Jacob Dahl 0ed8606364 feat(boards/ark/fpv): enable serial passthrough (#29929)
A host tool can then reach a device on a TELEM or GPS port through the FPV's USB, such as an ARK OSD on TELEM1 taking a firmware update, without unplugging it.
2026-11-20 16:16:29 -07:00
Mathéo Taillandier 2a3719006f feat(commander): when disarmed, do not report ESC offline on battery blocking preflight checks (#29523)
* feat(commander): when disarmed, do not report ESC offline on battery blocking preflight checks

* fix(commander): keep the ESC checks with the supply check circuit breaker set

With CBRK_SUPPLY_CHK set the battery check returns without reporting a
missing required battery, so skipping the ESC checks let a vehicle arm
with that battery missing and its ESCs unpowered.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* fix(commander): clear the ESC failure state while a required battery is missing

The skip only cleared the motor failure mask, leaving fd_motor_failure,
fd_esc_arming_failure and the ESC arming hysteresis at their last values:
after a battery dropped in flight and the vehicle disarmed, failsafe_flags
and failure_detector_status disagreed until the battery reconnected.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* feat(commander): give the ESCs time to boot once a required battery connects

Once the battery reconnected the checks resumed against ESC timestamps
from before it was unplugged, so "ESC N offline" still showed while the
ESCs booted. Reuse the boot grace already given to ESC telemetry at
startup.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* perf(commander): only read the batteries in the ESC checks when disarmed

The battery skip only applies on ground, so the armed path no longer
copies every battery instance each cycle.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* test(commander): cover the ESC checks with a required battery missing

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* fix(commander): block arming while the ESCs boot after a required battery connects

* test(commander): keep the failsafe flags across ESC check runs

Commander keeps the failsafe flags across check cycles, so zeroing them
before every run hid any flag the ESC checks forget to clear. Cover the
skip while a required battery is missing clearing a motor failure that
was latched in flight.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

* fix(commander): clear the motor stuck flag while a required battery is missing

The skip for a missing required battery returned before the motor stuck
flag was cleared, so a stuck motor flagged at spool-up stayed set on
the ground, unlike the other failure flags the skip clears.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>

---------

Signed-off-by: Matheo-13 <matheo.taillandier@gmail.com>
2026-11-20 11:28:25 -07:00
Marco HauswirthandMathieu Bresciani 1687722479 fix(ekf2): reset the height on a baro calibration change without a restart (#29922)
* fix(ekf2): reset the height on a baro calibration change without a fusion restart

* Update src/modules/ekf2/EKF/aid_sources/barometer/baro_height_control.cpp

Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>

---------

Co-authored-by: Mathieu Bresciani <brescianimathieu@gmail.com>
2026-11-20 16:56:05 +01:00
Vishal KotakandVishal Kotak 16b1d820c8 test(rover): add unit tests for the rover control helpers (#29836)
* test(rover): add unit tests for the rover control helpers

throttleControl, attitudeControl, speedControl, rateControl and globalToLocalSetpointTriplet drive all three rover modules but had no tests. rateControl was also the only helper without an input check, so a NaN yaw rate reached the PID; it now returns NaN like the others.

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

* test(rover): split rover control tests into single given/when/then cases

Review feedback: tests that set up a scenario should read as
given/when/then, and tests covering several cases should be split so
each failure points at one case.

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

* test(rover): check that NaN inputs leave the controller state untouched

Most NaN cases propagate to a NaN output even without the input check,
so asserting only on the output didn't test the check. Starting from a
known adjusted setpoint and asserting it is unchanged does. Also name
the rateControl clamp tests by sign, since in NED a positive yaw rate
turns right, and use speed_diff_normalized like the callers do.

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

* style(rover): re-indent rateControl test continuation lines for astyle

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

* test(rover): apply given/when/then to the existing rover control tests

Review feedback: use the same scheme for the tests that were already in
the file, so every test checks one case.

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

---------

Co-authored-by: Vishal Kotak <22182951+vishalkotak@users.noreply.github.com>
2026-11-20 11:02:12 +01:00
Balduin e01c2dd44e fix(mavlink): store params read from the receiver thread atomically (#29908)
* fix(mavlink): read MAV_HB_FORW_EN via an atomic snapshot in the receiver

forward_message() reads it on the receiver thread while the main mavlink
thread updates the ModuleParams member in updateParams(). Flagged by TSan
in CI (hex, ThreadSanitizer, multicopter failure injection test).

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

* fix(mavlink): read MAV_FWDEXTSP via an atomic snapshot in the receiver

The receiver thread reads it when handling setpoint messages while the
main mavlink thread updates the ModuleParams member in updateParams().

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

* fix(mavlink): read SYS_FAILURE_EN via an atomic snapshot in the receiver

The receiver thread reads it when handling commands while the main
mavlink thread updates the ModuleParams member in updateParams().

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

* fix(mavlink): read MAV_HASH_CHK_EN via an atomic snapshot in the receiver

MavlinkParametersManager runs on the receiver thread and reads it on
PARAM_SET of _HASH_CHECK while the main mavlink thread updates the
ModuleParams member in updateParams().

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

* fix(mavlink): read MAV_TYPE via an atomic snapshot in the receiver

The receiver thread reads it when handling ODOMETRY while the main
mavlink thread updates the ModuleParams member in updateParams().

Assisted-by: Claude:claude-opus-5-5
2026-11-20 08:44:15 +01:00
Julian Oes 73939d4c36 fix(rc): keep decoder state out of the shared RC buffer (#29847)
All RC decoders share rc_decode_buf. SUMD read its channel count back
from it while receiving a frame, so another decoder writing to the
buffer could move its write index past the end. px4io feeds the same
bytes to DSM, ST24 and SUMD until one locks, and rc_input's protocol
scan resumes decoders after the others have used the buffer.

Keep the SUMD channel count private, and reset ST24 and SUMD when the
rc_input scan switches protocol.

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

Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-19 17:17:19 -07:00
Jacob Dahl 309b338b0b feat(boards/ark/fpv): analog OSD on the external SPI port (#29916)
* fix(atxxxx): fail the probe when the chip doesn't answer

probe() logged a VM0 mismatch but returned the SPI transfer status, so with nothing on the bus the driver started anyway.

* feat(boards/ark/fpv): analog OSD on the external SPI port

OSD_ATXXXX_CFG 1 or 2 starts atxxxx on SPI6 for a MAX7456-compatible OSD such as the ARK OSD. It stays off by default, since many use that port for an external IMU.

* docs(ark_fpv): set up an analog OSD on the SPI or TELEM port

The board can carry an analog OSD on either port, and neither is on by default.
2026-11-19 17:16:47 -07:00
Julian Oes 129446a7ab feat(px4io): regenerate IO firmware binaries with the RAM trim
Built with "make px4io_update" from a clean tree in
ghcr.io/px4/px4-dev:v1.17.0-rc2.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes 1fbfeff942 build(boards/io-v2): trim the RAM NuttX 12.12 added on the IO boards
With NuttX 12.12 the IO firmware has only 424 B of free heap left out of
the F100's 8 KB, down from about 1.8 KB with the same sources on the
previous NuttX.

Each task group now embeds its three std streams with a 64 B buffer each,
once statically for the kernel thread group and once on the heap for the
IO task. Nothing on the IO uses stdio streams (syslog is disabled), so
drop the buffers. The IO also never uses signals, so don't preallocate
signal actions.

This frees 528 B of static RAM plus 192 B of heap: free_memory_bytes in
"px4io status" goes from 424 to 1144 on a Cube Orange+.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes 9dc97d1db8 feat(px4io): regenerate IO firmware binaries after the protocol refactor
Picks up the shared CRC-8 table and px4io_protocol library from main.
43708 B to 43700 B (cubepilot: 43488 B to 43480 B). Built with
"make px4io_update" in ghcr.io/px4/px4-dev:v1.17.0-rc2.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes d696915229 feat(px4io): regenerate IO firmware binaries
Picks up the libc float and lroundf savings: 48692 B to 43708 B
(cubepilot: 48468 B to 43488 B). Built with "make px4io_update" in
ghcr.io/px4/px4-dev:v1.17.0-rc2.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes 7b40898cff perf(rc): use lroundf for the S.Bus scaling
The S.Bus scale constants are float, so lround promoted the argument to
double and pulled soft-double code into FPU-less targets like the IO.
lroundf rounds the same float value identically (checked exhaustively over
all encode and decode inputs) and saves 1104 B on the IO.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes 5377642afb build(boards/io-v2): disable float printf support on the IO boards
The NuttX 12.12 upgrade enabled CONFIG_LIBC_FLOATINGPOINT on the IO
boards, where it is off by default (no FPU, DEFAULT_SMALL). Nothing on the
IO formats floats, and dropping it saves 3880 B of IO flash, which also
ends up in the ROMFS of every FMU that carries the IO firmware.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes 1239c24f99 ci(px4io): reject per-board IO binaries and keep check_px4io read-only
A board that still carries its own px4io binary in extras/ collided with
the one added via CONFIG_BOARD_IO and failed CMake generate with a
duplicate custom rule error. Several open board PRs add one, so fail
configure with a message naming the file to delete instead.

check_px4io copied the build output over the committed binaries, which
leaves changed binaries behind when run with a different toolchain. Compare
with cmp instead. The CI job now only runs check_px4io, which already
builds both IO boards, instead of building them twice.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes de33bf96da feat(px4io): regenerate IO firmware binaries
First regeneration since 2024-03. Picks up the lib/rc fixes (ST24 bounds,
S.Bus clamping, GHST/CRSF changes), the NuttX 12.12 upgrade and the
px4iofirmware changes since then. Built with "make px4io_update" in
ghcr.io/px4/px4-dev:v1.17.0-rc2.

The binary grows from 40160 to 48692 bytes (cubepilot: 39940 to 48468),
still within the IO flash.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes aa34d65fcb ci(px4io): fail the IO firmware check instead of only warning
A passing job with a warning annotation is easy to miss, which defeats the
purpose of the check. Fail the job so stale IO firmware gets regenerated in
the PR that changes its dependencies.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Julian Oes a88edf1abe ci(px4io): keep one IO firmware binary per IO board and check it in CI
The px4io firmware was committed as a copy in the extras of each of the 30
boards using it. "make px4io_update" only knew about 15 of them, so the
copies drifted into 5 different versions, and none had been regenerated
since 2024-03 despite changes to px4iofirmware, lib/rc and NuttX.

Keep a single binary per IO board in boards/<vendor>/<io board>/extras and
let the ROMFS pick it via the existing CONFIG_BOARD_IO option, which every
board with the px4io driver already sets (cubepilot boards override it).
This also replaces the outdated per-board copies on boards that were
missed by "make px4io_update".

The IO build is reproducible with a fixed toolchain (verified across
checkout paths and container vs host with the same GCC), so CI can rebuild
it and compare. "make check_px4io" does that, and a new CI job turns a
mismatch into a warning.

Assisted-by: Claude:claude-opus-5-5
Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-20 12:08:09 +13:00
Anil Kircaliali f8e80858ad fix(commander): compare a GNSS home against GNSS while the global pos is invalid (#29911)
* fix(commander): compare a GNSS home against GNSS while the global position is invalid

* test(commander): check that a GNSS home follows GNSS past the threshold
2026-11-19 13:32:12 -07:00
Anil Kircaliali cb02f47b18 fix(logger): don't lower the vehicle_thrust_setpoint rate in the high rate sensors profile (#29912) 2026-11-19 12:18:33 -07:00
PX4BuildBot adad90119f docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-11-19 18:35:44 +00:00
Jacob DahlandAndrea Bernasconi d04e5623f6 feat(gnss): compare receivers in sensors, limit divergence in commander (#29604)
* feat(sensors/gnss): report how far each receiver is from the selected one

Commander compared the receivers itself, reading the sensors module's antenna offsets and comparing samples taken at different times. The sensors module has the receiver-to-slot matching and the corrected sample times, so it now publishes each receiver's disagreement with the selected one on sensors_status_gnss, horizontally and vertically.

The other receiver is moved along its velocity to the selected sample's time. The antenna baseline is rotated with the attitude, so swapped or misplaced antennas show once the primary estimator's heading is aligned. Before that only the distances are compared, since the yaw is arbitrary.

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

* feat(commander): limit the GNSS divergence with COM_GNSS_H_MAX and COM_GNSS_V_MAX

The divergence gate came from the receivers' reported accuracy floored with EKF2_GPS_P_NOISE, so it was hard to predict and read another module's parameter. Commander now takes the disagreement from sensors_status_gnss and applies fixed horizontal and vertical limits. Three times the receivers' combined reported accuracy still widens them, so standalone receivers don't warn on default parameters.

Before arming a divergence is reported at once and clears after 2 s of agreement. In flight it has to persist for 2 s.

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

* fix(commander): keep the GNSS divergence limits fixed

Widening the limits to three times the receivers' combined reported accuracy made them floors, not limits. With the default GNSS_REQ_EPH and GNSS_REQ_EPV the gate opened to 12.7 m horizontally and 21 m vertically before arming, and to about 210 m in flight once a receiver fell back to the relaxed checks. The limits now apply as set, with defaults of 5 m and 10 m so standalone receivers don't warn.

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

* fix(commander): don't take an unknown GNSS disagreement for agreement

The sensors module leaves the disagreement unknown when the two latest samples are more than 0.5 s apart, while both receivers stay healthy. Commander treated that as nothing to compare, so a divergence before arming cleared for that check and an arm request could pass, and in flight the 2 s timer restarted. It happens on any gap over 0.5 s from a healthy receiver, and on 2 Hz receivers whose latencies differ. An unknown disagreement now keeps the state and its timer. A divergence still clears at once when there is no healthy pair to compare.

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

* docs(commander): swapped GNSS antennas hide behind a moving-base heading

The moving-base heading takes its offset from the same antenna positions. With swapped antennas the heading turns by 180°, and the expected baseline turns with it, so the divergence check sees agreement.

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

* docs(commander): reword the moving-base heading caveat

The sentence didn't say plainly that a moving-base heading from the same receivers stops the check from detecting swapped antennas.

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

* docs(commander): fold the moving-base caveat into the swapped-antenna conditions

The caveat read as a repeat of the alignment sentence. It is one more condition for detecting swapped antennas, so it now sits with the others.

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

* refactor(gnss): rotate the antenna baseline with the attitude as it is

The heading gate kept a limit below twice the antenna baseline from reporting a divergence before the heading aligned. With a mag the heading aligns before the receivers turn healthy. A heading from the same two receivers can't reveal swapped antennas anyway. The gate also never opened with an external INS, since only EKF2 publishes estimator_status_flags. Dropping it saves 168 B of flash on fmu-v2. The attitude age limit goes with it, since the last published attitude is a better guess than level and facing north.

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

---------

Co-authored-by: Andrea Bernasconi <andrea.bernasconi@auterion.com>
2026-11-19 11:28:20 -07:00
Peter van der Perk 28a025cccd fix(nuttx): bump submodule for backport i.MXRT Nuttx Upstream fixes (#29901)
Upstream fixes for i.mxrt NuttX (USB, eDMA, LPUART, LPSPI, LPI2C, ENET, FlexSPI)

Signed-off-by: Peter van der Perk <peter.vanderperk@nxp.com>
2026-11-19 11:22:47 -07:00
PX4BuildBot 4e44c822c9 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-11-19 16:17:26 +00:00
Marco Hauswirth 829f0f412e feat(sensors): keep calibrating the baro on the GNSS altitude until arming (#29876) 2026-11-19 17:10:35 +01:00
Eric Katzfey 67e8a34802 fix(qurt): reclaim task slots after normal exit (#29826)
Returning from a QuRT task bypasses px4_task_exit(), while normal module
shutdown does not call px4_task_join(). Repeated starts and stops therefore
leak task descriptors and eventually exhaust the 24-slot task table.

Route task returns through px4_task_exit() and reap exiting threads before
spawning another task. Keep each slot reserved until pthread_join()
completes, serialize competing joiners without holding the task mutex
across the join, and reject cancellation of tasks waiting on these joins.

Use monotonically increasing task handles so a late join, delete, or signal
cannot act on a replacement task after its table slot has been reused.

Ported from modalai/px4-firmware commit
1fe92691127df29e72af05f99d462c62428d3994 without code changes.


Assisted-by: Codex

Signed-off-by: Eric Katzfey <eric.katzfey@modalai.com>
2026-11-19 09:40:29 -05:00
Daniel Buleandră f65fe36aea feat(mavlink): count received messages dropped for a bad CRC (#29766)
Assisted-by: Claude:claude-opus-5-5

Signed-off-by: danielbuleandra <daniel.buleandra@auterion.com>
2026-11-19 12:59:35 +01:00
Mathéo Taillandier e1e1122af5 feat(simulation): enable airspeed sensor failure injection on gazebo too (#29210)
* feat(simulation): enable failure injection on gazebo sensor too

* docs(failure_injection): remove added dot
2026-11-19 12:58:23 +01:00
Jonas Perolini 5729cf1e3d fix(geofence): keep the Return margin along approximated circle edges (#29884)
Return approximates an exclusion circle by an octagon. The octagon was
drawn around the circle and the margin then added to its vertices, so
its edges cleared the circle by only cos(pi/8), about 92 %, of the
margin. Return flies along those edges.

Grow the circle by the margin first and draw the octagon around that,
as the comment above the code already says.

Assisted-by: Claude:claude-fable-5-2
2026-11-19 11:39:57 +01:00
PX4BuildBot 48814f9409 docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-11-19 08:29:47 +00:00
Matthew Charles Vladislav Busel 5c1a57d6d5 feat(simulation): add a differential rover to SIH (#29852)
* feat(simulation): add a differential rover to SIH

Add SIH_VEHICLE_TYPE 6 (Rover Differential) and the
10048_sihsim_rover_differential airframe, so rover_differential runs
headless with `make px4_sitl_sih sihsim_rover_differential`.

The model is a unicycle: each wheel is driven towards the ground speed
its motor command asks for (2 m/s at full command, matching
RO_MAX_THR_SPEED) up to its traction limit, and a lateral force keeps
the wheels from slipping sideways. Motor 1 is the right wheel and
motor 2 the left, as in the gz differential rover.

Closes #29838

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

* docs(simulation): explain the forces in the SIH differential rover model

Label the longitudinal force block and the force, moment and drag
outputs of generate_rover_differential_dynamics(), as suggested in
review. Comments only, no change in behaviour.

Assisted-by: Claude:claude-opus-5-5
2026-11-19 09:22:21 +01:00
Hamish Willee 6911bf9f56 docs(peripherals): explain where the MAVLink instance count comes from (#29895)
PX4-Autopilot#29573 let boards set the number of MAVLink instances, but
the MAVLink peripherals page didn't say how that number is set or what
limits it.

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

Signed-off-by: Hamish Willee <hamishwillee@gmail.com>
2026-11-19 16:49:49 +11:00
Hamish Willee 07af901e7c chore(mavlink): update submodule to latest (#29893)
Assisted-by: Claude:claude-opus-5-5

Signed-off-by: Hamish Willee <hamishwillee@gmail.com>
2026-11-19 14:27:01 +11:00
Jacob Dahl 0d9ef5f510 fix(atxxxx): draw at the right address and inside the NTSC screen (#29890)
* fix(atxxxx): write the display memory address low byte unchanged

Above address 255 the low byte was computed as the truncated address minus 0xFF, one more than the address itself. Every character from row 8, column 16 on landed one column right, the last PAL cell was written past the 480-entry display memory, and address 256 was never cleared.

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

* fix(atxxxx): keep the flight mode and flight time on the NTSC screen

NTSC shows 13 rows, so the flight time on row 14 was never visible once NTSC could be selected. Both elements are now placed from the bottom row, which leaves the PAL layout unchanged. The row count now follows the same OSD_ATXXXX_CFG check as the PAL bit, so boards that start the driver with the parameter at 0 get the NTSC layout they now run in.

Assisted-by: Claude:claude-opus-5-5
2026-11-18 17:11:01 -07:00
abhijith 5d9263851e feat(mavlink): let boards set the number of MAVLink instances (#29573)
* feat(mavlink): make the MAV_x instance count a per-board Kconfig option

MAV_x_* params and rc.serial were fixed at 3, though up to 6 MAVLink
instances can run. CONFIG_MAVLINK_NUM_CONFIG_INSTANCES (default 3) sets it;
extra instances take instance 2's defaults.

Signed-off-by: abhijithcv <abhijithcv1212@gmail.com>

* feat(boards/agam): enable 5 MAVLink instances on the v6X-RT

Signed-off-by: abhijithcv <abhijithcv1212@gmail.com>

* docs(releases): add per-board MAVLink instance count to main release notes

Signed-off-by: abhijithcv <abhijithcv1212@gmail.com>

* fix(mavlink): share main's --board-config in the instance count generators

main already passes the boardconfig as --board-config to generate_params.py,
so the duplicate option failed every build after a rebase. Both generators now
read it through the shared load_board_config. Kconfig caps the count at 5,
or 3 on constrained-memory boards, leaving a channel for USB, and list
defaults keep their length check unless the count comes from Kconfig.

Signed-off-by: abhijithcv <abhijithcv1212@gmail.com>

---------

Signed-off-by: abhijithcv <abhijithcv1212@gmail.com>
2026-11-19 12:58:56 +13:00
PX4BuildBot 36572dfd1c docs: auto-sync metadata [skip ci]
Co-Authored-By: PX4 BuildBot <bot@px4.io>
2026-11-18 23:57:57 +00:00
Julian Oes 1c279adf75 docs(gps): add newer CubePilot GNSS modules and a Here4 page (#29861)
The docs only covered the discontinued Here2/Here+ and linked Here3
externally with a wrong receiver name. Add Here3+, Here4 and HerePro to
the RTK and DroneCAN lists, linking CubePilot's docs.

Add a Here4 page with what is needed to get it working on PX4: the one
CAN port the firmware supports, enabling the barometer (off by default
on the Here4), updating it from the SD card, and the mandatory
bootloader bulletin.

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

Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-19 12:51:02 +13:00
Julian Oes caf8944d5f docs(cubepilot): use CubePilot name and drop connector/standards note (#29828)
- Rename remaining Hex/HEX/ProfiCNC references to CubePilot, including
  page file names (old pages redirect).
- Use the CubePilot spelling consistently.
- Remove the note on the Cube Black page advising against it for
  standards and patent reasons.

Assisted-by: Claude:claude-opus-5-5
2026-11-19 12:51:01 +13:00
Julian Oes 35223a381e fix(drivers): keep file descriptors on the task that opened them (#29858)
* fix(heater): open and use the PX4IO fd only on the work queue thread

File descriptors on NuttX are per task group. Since the multi-instance
rework (#26325) the PX4IO heater fd was opened in the constructor, i.e.
in the shell task running `heater start`, but used in Run() on
wq:lp_default. There the fd number refers to whatever that task group has
open, so the heater ioctls silently failed (heater never driven on
PX4IO boards) or hit an unrelated file. On a Cube Orange+ this ended in a
hardfault in fat_ioctl() when the number matched an SD card file.

stop() also issued an ioctl from the shell, and the exit path closed the
fd before turning the heater off with it.

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

* fix(cyphal): close the CAN fd on the work queue thread

The CAN socket/device is opened in Run() on wq:uavcan, but was only
closed from the destructor, which runs in the shell calling
`cyphal stop`. File descriptors are per task group on NuttX, so that
close did nothing and the SocketCAN socket stayed bound, keeping
received frames queued in the shared IOB pool. The NuttX CAN device was
never closed at all.

Close the interface in Run()'s exit branch and make close() idempotent.

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

* fix(uavcannode): close the DroneCAN shell pipes on the work queue thread

The shell pipes are created from a service callback on wq:uavcan, but on
`uavcannode stop` they were closed by the destructor in the shell task.
File descriptors are per task group on NuttX, so the work queue ends
stayed open and the spawned shell task never got EOF.

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

* fix(distance_sensor): close serial ports on the work queue thread

CM8JL65, uLanding, LeddarOne, Sony AS-DT1 and Lightware serial open
their UART in Run() on the work queue, but stop() closed it from the
shell calling `<driver> stop`. File descriptors are per task group on
NuttX, so the UART stayed open in the work queue group, leaking it on
every start/stop cycle. stop() also deleted the driver without waiting
for a Run() in progress.

stop() now asks Run() to close the port and waits for it. Error paths
reset the fd so a stale number is not reused, and ports opened in the
shell (LeddarOne init probe, Sony -p mode) are closed there.

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

* fix(uwb_sr150): schedule only after init succeeded

On init failure the instance is deleted in the shell, whose destructor
closes the UART. If Run() had already opened it on the work queue, that
closed an unrelated fd number, as file descriptors are per task group
on NuttX.

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

* fix(sagetech_mxs): schedule only after init succeeded

On init failure the instance is deleted in the shell, whose destructor
closes the serial port. If Run() had already opened it on the work
queue, that closed an unrelated fd number, as file descriptors are per
task group on NuttX.

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

---------

Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-19 12:48:08 +13:00
Jacob Dahl 4395d0bc23 fix(atxxxx): enable the display without forcing PAL (#29889)
enable_screen() ORed 0x48 into VM0, which set the PAL bit whatever OSD_ATXXXX_CFG said, so NTSC was never selected. init_osd() already sets the PAL bit when the parameter asks for it.
2026-11-18 16:47:11 -07:00
Hamish WilleeandRamon Roche bce8453e5b chore(mavlink): update submodule to latest (#29865)
Assisted-by: Claude:claude-opus-5-5

Signed-off-by: Hamish Willee <hamishwillee@gmail.com>
Co-authored-by: Ramon Roche <mrpollo@gmail.com>
2026-11-19 08:13:49 +11:00
Julian Oes 0c74033da4 fix(hardfault_stream): return after cleanup in the stop path (#29859)
exit_and_cleanup() deletes the instance, but Run() carried on into the
state machine and used the freed object.

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

Signed-off-by: Julian Oes <julian@oes.ch>
2026-11-18 11:49:37 -07:00
Matthias Grob c2875ad6a2 perf(nuttx): build the NuttX libraries with parallel make jobs
Each NuttX library and the apps are built by a make invocation that
ninja treats as a single opaque custom command, so they compiled one
file at a time.

Run them through a wrapper that honours a job count given to the
toplevel build (e.g. `make px4_fmu-v5x_default -j1`), which reaches it
through MAKEFLAGS, and otherwise uses the number of CPUs available to
the process. Unlike CMake's logical core count, nproc respects docker
--cpuset-cpus. A load limit keeps the concurrently running NuttX makes
from oversubscribing the host.

Mark the toplevel cmake build recipe as a sub-make with '+'. GNU make
before 4.4 (e.g. Ubuntu 22.04/24.04) passes its jobserver as pipe file
descriptors, which it otherwise closes for that recipe, leaving the
NuttX makes to fall back to serial builds.

Mention how to disable parallel builds in the docker docs.

Assisted-by: Claude Code (claude-opus-5-5)
2026-11-18 18:45:15 +01:00
Matthias Grob 355b900829 fix(nuttx): evaluate NuttX toolchain prefixes once in Make.defs
NuttX's tools/Config.mk defines DEFINE_PREFIX, INCDIR_PREFIX and
INCSYSDIR_PREFIX as exported recursive variables that run a shell
script on every expansion. Because they are exported, make expands
them for every recipe it spawns, serially in its main process.

The NuttX toplevel make hides this by handing the expanded values to
its sub-makes through the environment. PX4 calls the per-directory
sub-makes directly, so each one re-ran define.sh and incdir about 30
times per compiled file. That throttled the NuttX library builds to a
few objects per second regardless of the job count. Since the NuttX
12.12 upgrade, CINCPATH and CFLAGS reference these variables, which
turned this into a build time regression.

Evaluate them once with := after CC is defined. The generated compile
commands are unchanged. Rebuilding sched for fmu-v5x from scratch
drops from 37 s to under 4 s.

Assisted-by: Claude Code (claude-opus-5-5)
2026-11-18 18:45:15 +01:00
Matthias Grob a72242a215 build(style): skip parameter member renames referenced in other files
check_param_names.py --fix only renamed members in the declaring file and its
implementation file. Uses in other files, like the AFBRS50 calibration offsets
in AFBRS50_Calibration.cpp, kept the old name and broke the build, while the
declaration-only check still passed.

--fix now looks for the old name in all tracked sources first. If it appears
in a file whose stem does not declare it as its own parameter member, it skips
that member, reports it for manual renaming and exits with an error. A real use
can't be told apart from an unrelated member with the same name without a
compiler, so it reports both.
2026-11-18 18:40:12 +01:00
Matthias Grob 6d43f6e807 docs(parameters): document the parameter member naming convention
The DEFINE_PARAMETERS example used member names that make check_format now rejects, and the convention itself was never written down.

Assisted-by: Claude:claude-opus-5-5
2026-11-18 18:40:12 +01:00
Matthias Grob dbe4cd3e2e style(modules_drivers): name parameter members after their parameter name
Produced by make format with the new parameter member name check, plus the AFBRS50 calibration offsets used outside the declaring files.
2026-11-18 18:40:12 +01:00