Skip to content

feat(boards): Add support for the NewBeeDrone PixNova#26966

Closed
LYNHQQ wants to merge 4 commits into
PX4:mainfrom
newbeedrone:boards/NewBeeDrone-PixNova
Closed

feat(boards): Add support for the NewBeeDrone PixNova#26966
LYNHQQ wants to merge 4 commits into
PX4:mainfrom
newbeedrone:boards/NewBeeDrone-PixNova

Conversation

@LYNHQQ
Copy link
Copy Markdown

@LYNHQQ LYNHQQ commented Apr 3, 2026

Summary

This PR adds initial board firmware support for the NewBeeDrone PixNova.

PixNova is derived from the PX4 FMUv6X reference design, and we would like to align the implementation with the current PX4 / Pixhawk standards as closely as possible.

Questions / points where we would appreciate guidance

1. REV / VER resistor and EEPROM logic

PixNova follows the FMUv6X design direction and currently uses the DS-019 config 7 approach by default, where the actual revision/version information is read from EEPROM.

For a custom NewBeeDrone board derived from V6X:

  • is this still the correct approach?
  • or should we adjust anything specifically for a custom implementation?

2. board_id for PixNova

We would like to request a proper board_id for NewBeeDrone PixNova.

Could the PX4 / Pixhawk team please advise on:

  • what board_id would be appropriate here
  • and what the preferred allocation process is?

3. io-v2 ADC divider update for 0–36V detection

On our io-v2 hardware, we changed the servo voltage ADC divider to 100k / 10k so the board can detect 0–36V.

We would like to confirm:

  • does this change require any update to the existing px4_io-v2_default.bin used in extras?
  • if so, is the recommended way to create a NewBeeDrone-specific io-v2 target/fork under the PX4 tree?

4. DS-012 Sensor Set (Rev 5) and rc.board_sensors

PixNova uses DS-012 Sensor Set (Rev 5).

We would appreciate feedback on:

  • whether the current rc.board_sensors setup for PixNova looks correct / reasonable
  • how PX4 would recommend handling multiple sensor groups in the future, if we want to support more than one sensor configuration like some other boards do

Notes

Our intention is to upstream PixNova support cleanly and keep it compatible with PX4 conventions and Pixhawk standards.

Any feedback is very welcome. Thanks!

LYNHQQ added 4 commits April 3, 2026 21:41
Use the expected <vendor>_<model>_bootloader.bin filename so ROMFS handling treats the PixNova bootloader asset correctly during packaging and constrained flash builds.

Made-with: Cursor
Align PX4_GPIO_INIT_LIST continuation lines with PX4 astyle rules (CI check_format).

Made-with: Cursor
Copy link
Copy Markdown
Contributor

@mrpollo mrpollo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Welcome, and great to see NewBeeDrone bringing board support upstream!

To answer your questions from the PR description:

Q1 (REV/VER and EEPROM): Since you have your own board target with HW_INFO_INIT_PREFIX "PixNova", you define your own HW_FMUM_ID values via resistor detection. No DS-019 EEPROM lookup is needed. This is the same approach ARK and ZeroOne use for their v6X derivatives. See my inline comment on board_config.h for details. Your pixhawk/Pixhawk-Standards#67 PR can be closed.

Q2 (board_id): You need a unique board ID registered in PX4-Bootloader. See PX4/PX4-Bootloader#260 for a recent example. I'd suggest reserving range 5900-5909 for NewBeeDrone. See inline comments on firmware.prototype and hw_config.h.

Q3 (IO v2 36V ADC divider): The stock px4_io-v2_default.bin works fine for your hardware. PWM output is completely decoupled from the voltage ADC. The only impact is that servo rail voltage telemetry will read wrong (capped at ~9.9V instead of 36V) because the IO firmware hardcodes a 3:1 divider assumption in registers.c:541. This is not a safety issue. I filed #26970 to properly wire up the existing VSERVO_SCALE register so boards can configure their own divider ratio. For now, shipping with the stock binary is fine.

Q4 (DS-012 sensors / rc.board_sensors): Your sensor startup looks correct. The PixNova000/PixNova001 variant pattern is the right approach for supporting multiple sensor configurations in the future.

Flight logs: Please upload 2-3 logs to https://logs.px4.io and link them here. At least one should be from an actual flight (not just a bench test).

See inline comments for specific issues to fix.

#include <px4_platform/gpio.h>
#include <px4_platform/board_determine_hw_info.h>
#include <px4_platform/board_dma_alloc.h>
#include <px4_platform/gpio/mcp23009.hpp>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This header (px4_platform/gpio/mcp23009.hpp) doesn't exist in the PX4 codebase. The MCP23009 is a runtime I2C driver started from init scripts, not a compile-time dependency.

See how boards/auterion/fmu-v6x/init/rc.board_defaults does it:

mcp23009 start -b 3 -X -D 0xf0 -O 0xf0 -P 0x0f -M 0 -U 10

You need to:

  1. Remove this #include and the mcp23009_register_gpios() call at line 289
  2. Remove the platform_gpio_mcp23009 dependency from CMakeLists.txt
  3. Add the equivalent mcp23009 start command to your init/rc.board_defaults

This is what's causing the CI build failure.

nuttx_arch # sdio
nuttx_drivers # sdio
px4_layer
platform_gpio_mcp23009
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

platform_gpio_mcp23009 doesn't exist as a CMake target. Remove this. The MCP23009 driver is built separately when CONFIG_DRIVERS_GPIO_MCP23009=y is set in your .px4board (which you already have).

@@ -0,0 +1,13 @@
{
"board_id": 53,
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Board ID 53 is already assigned to TARGET_HW_PX4_FMU_V6X. The PixNova needs its own unique ID.

Submit a PR to PX4-Bootloader to reserve your ID in board_types.txt. See PX4/PX4-Bootloader#260 for a recent example.

Suggested range: 5900-5909 for NewBeeDrone. So:

# IDs 5900-5909 reserved for NewBeeDrone
TARGET_HW_NEWBEEDRONE_PIXNOVA        5900

#define INTERFACE_USART 1
#define INTERFACE_USART_CONFIG "/dev/ttyS0,1500000"
#define BOOT_DELAY_ADDRESS 0x000001a0
#define BOARD_TYPE 53
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same issue: BOARD_TYPE must match your new unique ID from PX4-Bootloader once reserved, not 53.

CONFIG_CDCACM_PRODUCTSTR="PixNova BL V6X.x"
CONFIG_CDCACM_RXBUFSIZE=600
CONFIG_CDCACM_TXBUFSIZE=12000
CONFIG_CDCACM_VENDORID=0x3185
Copy link
Copy Markdown
Contributor

@mrpollo mrpollo Apr 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

VID 0x3185 is registered to Auterion AG. As we discussed, switch to the Dronecode VID 0x3643 with PID 0x0050 (assigned for PixNova).

So in both this file and nsh/defconfig:

CONFIG_CDCACM_VENDORID=0x3643
CONFIG_CDCACM_PRODUCTID=0x0050
CONFIG_CDCACM_VENDORSTR="NewBeeDrone"

CONFIG_CDCACM_PRODUCTSTR="PixNova"
CONFIG_CDCACM_RXBUFSIZE=600
CONFIG_CDCACM_TXBUFSIZE=12000
CONFIG_CDCACM_VENDORID=0x3185
Copy link
Copy Markdown
Contributor

@mrpollo mrpollo Apr 4, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here. Update to:

CONFIG_CDCACM_VENDORID=0x3643
CONFIG_CDCACM_PRODUCTID=0x0050
CONFIG_CDCACM_VENDORSTR="NewBeeDrone"

#define GPIO_PPM_IN /* PI5 T8C1 */ GPIO_TIM8_CH1IN_2

/* RC Serial port */
#define RC_SERIAL_PORT "/dev/ttyS5"
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

RC_SERIAL_PORT and PX4IO_SERIAL_DEVICE (line 62) both point to /dev/ttyS5. The reference v6x doesn't define RC_SERIAL_PORT in board_config.h at all. Is this intentional, or a leftover from the copy?

* POSSIBILITY OF SUCH DAMAGE.
*
************************************************************************************/
#ifndef __NUTTX_CONFIG_PX4_FMU_V6X_INCLUDE_BOARD_H
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Header guard still references v6x. Should be something like __NUTTX_CONFIG_NEWBEEDRONE_PIXNOVA_INCLUDE_BOARD_H.

Also throughout this file, comments reference "PX4 FMUV6X" and "px4_fmu-v6x" where they should say PixNova. And the LED definitions comment block (around lines 317-330) is duplicated. General template cleanup pass needed.

CONFIG_DRIVERS_POWER_MONITOR_PM_SELECTOR_AUTERION=y
CONFIG_DRIVERS_PWM_OUT=y
CONFIG_DRIVERS_PX4IO=y
CONFIG_DRIVERS_RC_INPUT=y
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

New boards should use CONFIG_DRIVERS_COMMON_RC instead of the legacy CONFIG_DRIVERS_RC_INPUT.

Also, CONFIG_DRIVERS_POWER_MONITOR_PM_SELECTOR_AUTERION on line 40 -- is this intentional for your hardware, or leftover from the v6x copy?


#define BOARD_NUM_SPI_CFG_HW_VERSIONS 2
// Base/FMUM
#define PixNovaV6X000 HW_FMUM_ID(0x0) // PixNova V6X, Sensor Set RevA
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Answer to your Q1 (REV/VER): This is exactly the right pattern. Since you have your own board target with HW_INFO_INIT_PREFIX "PixNova", these HW_FMUM_ID values are yours to manage via resistor detection. No DS-019 EEPROM lookup needed.

See how other v6X derivatives do the same thing:

  • ARK: ARKV6X_0 HW_FMUM_ID(0x0), ARKV6X_1 HW_FMUM_ID(0x1) (2 variants)
  • ZeroOne: ZeroOneX6_0 through ZeroOneX6_2 (3 variants, one reserved)

To add sensor variants later, define PixNovaV6X002 HW_FMUM_ID(0x2) and bump BOARD_NUM_SPI_CFG_HW_VERSIONS.

Your pixhawk/Pixhawk-Standards#67 PR can be closed.

@LYNHQQ
Copy link
Copy Markdown
Author

LYNHQQ commented Apr 7, 2026

Welcome, and great to see NewBeeDrone bringing board support upstream!

To answer your questions from the PR description:

Q1 (REV/VER and EEPROM): Since you have your own board target with HW_INFO_INIT_PREFIX "PixNova", you define your own HW_FMUM_ID values via resistor detection. No DS-019 EEPROM lookup is needed. This is the same approach ARK and ZeroOne use for their v6X derivatives. See my inline comment on board_config.h for details. Your pixhawk/Pixhawk-Standards#67 PR can be closed.

Q2 (board_id): You need a unique board ID registered in PX4-Bootloader. See PX4/PX4-Bootloader#260 for a recent example. I'd suggest reserving range 5900-5909 for NewBeeDrone. See inline comments on firmware.prototype and hw_config.h.

Q3 (IO v2 36V ADC divider): The stock px4_io-v2_default.bin works fine for your hardware. PWM output is completely decoupled from the voltage ADC. The only impact is that servo rail voltage telemetry will read wrong (capped at ~9.9V instead of 36V) because the IO firmware hardcodes a 3:1 divider assumption in registers.c:541. This is not a safety issue. I filed #26970 to properly wire up the existing VSERVO_SCALE register so boards can configure their own divider ratio. For now, shipping with the stock binary is fine.

Q4 (DS-012 sensors / rc.board_sensors): Your sensor startup looks correct. The PixNova000/PixNova001 variant pattern is the right approach for supporting multiple sensor configurations in the future.

Flight logs: Please upload 2-3 logs to https://logs.px4.io and link them here. At least one should be from an actual flight (not just a bench test).

See inline comments for specific issues to fix.

Awesome, thanks Roman! I'll take a look and get these fixed.

@LYNHQQ
Copy link
Copy Markdown
Author

LYNHQQ commented Apr 7, 2026

Welcome, and great to see NewBeeDrone bringing board support upstream!

To answer your questions from the PR description:

Q1 (REV/VER and EEPROM): Since you have your own board target with , you define your own values via resistor detection. No DS-019 EEPROM lookup is needed. This is the same approach ARK and ZeroOne use for their v6X derivatives. See my inline comment on for details. Your pixhawk/Pixhawk-Standards#67 PR can be closed.HW_INFO_INIT_PREFIX "PixNova"``HW_FMUM_ID``board_config.h

Q2 (board_id): You need a unique board ID registered in PX4-Bootloader. See PX4/PX4-Bootloader#260 for a recent example. I'd suggest reserving range 5900-5909 for NewBeeDrone. See inline comments on and .firmware.prototype``hw_config.h

Q3 (IO v2 36V ADC divider): The stock works fine for your hardware. PWM output is completely decoupled from the voltage ADC. The only impact is that servo rail voltage telemetry will read wrong (capped at ~9.9V instead of 36V) because the IO firmware hardcodes a 3:1 divider assumption in . This is not a safety issue. I filed #26970 to properly wire up the existing register so boards can configure their own divider ratio. For now, shipping with the stock binary is fine.px4_io-v2_default.bin``registers.c:541``VSERVO_SCALE

Q4 (DS-012 sensors / rc.board_sensors): Your sensor startup looks correct. The / variant pattern is the right approach for supporting multiple sensor configurations in the future.PixNova000``PixNova001

Flight logs: Please upload 2-3 logs to https://logs.px4.io and link them here. At least one should be from an actual flight (not just a bench test).

See inline comments for specific issues to fix.

Hi Roman, I'm closing this PR for the time being. We'll likely need to make some changes to the sensors, and I'll reopen it once the new tests are good to go.

@LYNHQQ LYNHQQ closed this Apr 7, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants