Reducing PX4 flash usage on CUAV X7 Pro (cuav_x7pro_default) while keeping CAN tools

I’m building PX4 for a CUAV X7+ (target: cuav_x7pro_default) and I’m hitting a flash overflow at link time:

  • .text will not fit in region FLASH

  • FLASH used: ~1,989,072 B / 1,920 KB (overflow ~22,992 bytes)

Goal: I want a working NSH shell and specifically to use candump and cansend on the flight controller (SocketCAN / CAN utils). I don’t need Ethernet or other unused peripherals/features.

Questions:

  1. What are the recommended PX4 features/modules to disable to reduce flash size on this target, while keeping CAN (FDCAN) + candump/cansend working?

  2. In NuttX menuconfig, I see STM32H7_HAVE_ETHERNET=y / ethernet-related options. Where is the correct place to disable ethernet (or does PX4 board support force it on)?

  3. Any known “big hitters” for flash on H7 targets (e.g., uXRCE-DDS, navigator features, flight mode manager tasks, logging, etc.) that are safe to disable for a minimal CAN-testing build?

Info:

  • NuttX config file exists at: build/cuav_x7pro_default/NuttX/nuttx/.config

  • CAN utilities are enabled: CONFIG_CANUTILS_CANDUMP=y, CONFIG_CANUTILS_CANSEND=y

  • Using STM32H7 FDCAN1

If anyone has a minimal working config or a list of BOARD_* / CONFIG_* items to turn off for this target, I’d really appreciate it.

Thanks,
Kirubakkar Ravichandran

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.