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>
This commit is contained in:
Ramon Roche committed 2026-09-28 09:45:09 -07:00
1 parent 89c68cd37f
commit e0dc50d7cc
6 files changed
+12 -89

No files matched your search

-47
View File
@@ -321,53 +321,6 @@ foreach(board_extra_file ${OPTIONAL_BOARD_EXTRAS})
endforeach()
if(config_uavcan_peripheral_firmware)
include(ExternalProject)
foreach(uavcan_peripheral_config ${config_uavcan_peripheral_firmware})
# include the UAVCAN peripheral binaries in ROMFS
message(STATUS "ROMFS: Adding UAVCAN peripheral ${uavcan_peripheral_config} -> /etc/uavcan/fw/")
# ExternalProject_Add() with GIT_SUBMODULES "" initializes no submodules.
cmake_policy(SET CMP0097 NEW)
include(ExternalProject)
ExternalProject_Add(build_${uavcan_peripheral_config}
GIT_REPOSITORY ${CMAKE_SOURCE_DIR}
GIT_TAG ${PX4_GIT_TAG}
GIT_SUBMODULES ""
DOWNLOAD_NO_PROGRESS true
CMAKE_ARGS -DCONFIG=${uavcan_peripheral_config}
INSTALL_COMMAND ""
USES_TERMINAL_BUILD true
BUILD_ALWAYS 1
)
ExternalProject_Get_Property(build_${uavcan_peripheral_config} BINARY_DIR)
add_custom_command(
OUTPUT
${romfs_gen_root_dir}/uavcan/fw/_${uavcan_board_id}.bin
${uavcan_peripheral_config}.stamp
COMMAND ${CMAKE_COMMAND} -E make_directory ${romfs_gen_root_dir}/uavcan/fw/
COMMAND ${CMAKE_COMMAND} -E copy ${BINARY_DIR}/deploy/*.bin ${romfs_gen_root_dir}/uavcan/fw/
COMMAND ls -lsa ${romfs_gen_root_dir}/uavcan/fw/
COMMAND ${CMAKE_COMMAND} -E touch ${uavcan_peripheral_config}.stamp
DEPENDS
build_${uavcan_peripheral_config}
COMMENT "ROMFS: copying ${uavcan_peripheral_config}"
)
list(APPEND extras_dependencies
${uavcan_peripheral_config}.stamp
)
endforeach()
endif()
list(APPEND extras_dependencies
${config_romfs_extra_dependencies}
)
-32
View File
@@ -1,32 +0,0 @@
CONFIG_COMMON_BAROMETERS=n
CONFIG_COMMON_DIFFERENTIAL_PRESSURE=n
CONFIG_COMMON_HYGROMETERS=n
CONFIG_COMMON_TELEMETRY=n
CONFIG_DRIVERS_ADC_ADS1115=n
CONFIG_DRIVERS_GPS=n
CONFIG_DRIVERS_HEATER=n
CONFIG_DRIVERS_IMU_ANALOG_DEVICES_ADIS16448=n
CONFIG_DRIVERS_IMU_INVENSENSE_ICM20948=n
CONFIG_DRIVERS_IRLOCK=n
CONFIG_DRIVERS_PCA9685_PWM_OUT=n
CONFIG_DRIVERS_PWM_INPUT=n
CONFIG_DRIVERS_SMART_BATTERY_BATMON=n
CONFIG_MODULES_ATTITUDE_ESTIMATOR_Q=n
CONFIG_MODULES_CAMERA_FEEDBACK=n
CONFIG_MODULES_ESC_BATTERY=n
CONFIG_MODULES_FW_AUTOTUNE_ATTITUDE_CONTROL=n
CONFIG_MODULES_MC_AUTOTUNE_ATTITUDE_CONTROL=n
CONFIG_MODULES_SIMULATION_SIMULATOR_SIH=n
CONFIG_MODULES_UUV_ATT_CONTROL=n
CONFIG_MODULES_UUV_POS_CONTROL=n
CONFIG_MODULES_UXRCE_DDS_CLIENT=n
CONFIG_SYSTEMCMDS_BL_UPDATE=n
CONFIG_SYSTEMCMDS_DUMPFILE=n
CONFIG_SYSTEMCMDS_GPIO=n
CONFIG_SYSTEMCMDS_I2CDETECT=n
CONFIG_SYSTEMCMDS_LED_CONTROL=n
CONFIG_SYSTEMCMDS_REFLECT=n
CONFIG_SYSTEMCMDS_SYSTEM_TIME=n
CONFIG_SYSTEMCMDS_TOPIC_LISTENER=n
CONFIG_BOARD_UAVCAN_PERIPHERALS="cuav_can-gps-v1_default"
CONFIG_DRIVERS_BAROMETER_MS5611=y
-4
View File
@@ -373,10 +373,6 @@ if(EXISTS ${BOARD_DEFCONFIG})
# ROMFS
if(ROMFSROOT)
set(config_romfs_root ${ROMFSROOT} CACHE INTERNAL "ROMFS root" FORCE)
if(UAVCAN_PERIPHERALS)
set(config_uavcan_peripheral_firmware ${UAVCAN_PERIPHERALS} CACHE INTERNAL "UAVCAN peripheral firmware" FORCE)
endif()
endif()
# ADDITIONAL INIT
+11
View File
@@ -328,6 +328,17 @@ PX4 identifies valid firmware binaries (`.bin`) based on the presence of an **AP
PX4 uses this descriptor to match each binary to the correct node and to determine whether an update is needed.
:::
### Getting Firmware
Every PX4 release publishes the firmware for CAN nodes built by PX4 as `<target>.uavcan.bin` (for example `cuav_can-gps-v1_default.uavcan.bin`), attached to the [GitHub release](https://github.com/PX4/PX4-Autopilot/releases).
When you build a CAN node target yourself with `make <target>`, the `.uavcan.bin` file is written to `build/<target>/`.
::: info
Flight controller builds can no longer embed CAN node firmware in their ROMFS.
The `CONFIG_BOARD_UAVCAN_PERIPHERALS` board option and the `px4_fmu-v5_uavcanv0periph` build that used it (embedding CUAV CAN GPS v1 firmware) were removed after PX4 v1.18.
Copy the node's `.uavcan.bin` to the SD card as described below instead.
:::
### Firmware Directories
Place firmware binaries in one of these locations on the SD card before rebooting:
+1
View File
@@ -32,6 +32,7 @@ Please continue reading for [upgrade instructions](#upgrade-guide).
- `COM_ARM_TRAFF` has been replaced by `COM_TRAFF_AVOID`. The old value 3 ("enforce for mission modes only") is migrated to `COM_TRAFF_AVOID=2`, which blocks arming in all modes, not just mission modes. If you relied on being able to arm manually with traffic detected, set `COM_TRAFF_AVOID=1` (warning only) instead.
- `PCA9685_SCHD_HZ` has been removed. `PCA9685_PWM_FREQ` now sets both the PWM frequency of the PCA9685 and the rate at which values are pushed to it; if you had `PCA9685_SCHD_HZ` set to a non-default value, set `PCA9685_PWM_FREQ` to it after upgrading. Frequencies above 400 Hz (previously only usable in duty-cycle mode) are no longer supported.
- **Flight controller firmware no longer embeds CAN node firmware.** The `px4_fmu-v5_uavcanv0periph` build, which carried CUAV CAN GPS v1 firmware in its ROMFS so the flight controller could update the GPS over DroneCAN, and the `CONFIG_BOARD_UAVCAN_PERIPHERALS` board option behind it have been removed. Use the standard `px4_fmu-v5_default` firmware and update the GPS from the SD card with `cuav_can-gps-v1_default.uavcan.bin` from the release instead; see [DroneCAN Firmware Update](../dronecan/index.md#firmware-update). ([PX4-Autopilot#28870](https://github.com/PX4/PX4-Autopilot/pull/28870))
- **jMAVSim has been removed.** `make px4_sitl jmavsim` and the `10017_jmavsim_iris` airframe (`SYS_AUTOSTART=10017`) no longer exist, and the setup scripts no longer install Java or `ant`. Use [SIH](../sim_sih/index.md) with the [Hawkeye](../sim_hawkeye/index.md) visualizer instead (`make px4_sitl_sih sihsim_quadx`), or [Gazebo](../sim_gazebo_gz/index.md).
- **Re-check motor failure handling on hexarotors.** [CA_FAILURE_MODE](../advanced_config/parameter_reference.md#CA_FAILURE_MODE) = `1` now also stops the motor opposite the failed one on a hexarotor (previously only the failed motor was removed from the allocation). Other airframes are unaffected, and `CA_FAILURE_MODE=0` (the default) is unchanged. See [Motor Failure Recovery](../config/motor_failure_recovery.md). ([PX4-Autopilot#28078](https://github.com/PX4/PX4-Autopilot/pull/28078))
-6
View File
@@ -99,9 +99,3 @@ depends on DRIVERS_UAVCAN || DRIVERS_UAVCANNODE
default 2
---help---
Interface count for UAVCANv0
menuconfig BOARD_UAVCAN_PERIPHERALS
depends on DRIVERS_UAVCAN
string "UAVCAN peripheral firmware"
help
list of UAVCAN peripheral firmware to build and embed