Skip to content

Add Xiao rp2040 plus support #19253

Open
cumin777 wants to merge 1 commit into
micropython:masterfrom
cumin777:xiao_rp2040_plus
Open

Add Xiao rp2040 plus support #19253
cumin777 wants to merge 1 commit into
micropython:masterfrom
cumin777:xiao_rp2040_plus

Conversation

@cumin777
Copy link
Copy Markdown

Summary

This PR adds board support for the Seeed Studio XIAO RP2040 Plus to the rp2 port.

It introduces a dedicated SEEED_XIAO_RP2040_PLUS board definition with:

  • board metadata
  • RP2040 Plus pin mappings
  • 2 MB flash configuration
  • onboard WS2812/NeoPixel and power-enable definitions
  • corrected dual-I2C defaults for the Plus board:
    • I2C0 on GPIO20/GPIO21
    • I2C1 on GPIO6/GPIO7

The main goal is to make the board usable as a first-class MicroPython target with correct default peripheral mappings for the hardware actually routed on the XIAO RP2040 Plus.

Testing

Tested on a Seeed Studio XIAO RP2040 Plus board.

The following were verified with locally built MicroPython firmware for SEEED_XIAO_RP2040_PLUS:

  • firmware builds successfully for the rp2 port
  • board boots and enters the MicroPython REPL
  • I2C0 works on GPIO20/GPIO21
  • I2C1 works on GPIO6/GPIO7
  • SPI works on the expected board pins
  • UART works on the expected board pins
  • GPIO tests passed
  • ADC tests passed
  • PWM tests passed
  • onboard LED test passed
  • onboard NeoPixel/WS2812 test passed

I2C was specifically re-checked after fixing the bus/pin mapping to match RP2040 hardware function constraints.

Trade-offs and Alternatives

This change is board-local and does not alter shared rp2 port behavior for other boards.

The only meaningful alternative would have been to keep the previous I2C mapping, but that would leave one of the buses assigned to pins that do not match the intended MicroPython hardware I2C instance usage for this board. The submitted mapping reflects the actual validated working configuration on hardware.

Generative AI

I used generative AI tools when creating this PR, but a human has checked the
code and is responsible for the code and the description above.

Signed-off-by: cumin <13809292481@163.com>
@cumin777 cumin777 force-pushed the xiao_rp2040_plus branch from 2d79f3d to 703559a Compare May 21, 2026 11:44
@github-actions
Copy link
Copy Markdown

Code size report:

Reference:  docs/library/rp2.DMA: Correct and add pack_ctrl defaults. [8f3a416]
Comparison: rp2/boards: Add Seeed Studio XIAO RP2040 Plus board definition. [merge of 703559a]
  mpy-cross:    +0 +0.000% 
   bare-arm:    +0 +0.000% 
minimal x86:    +0 +0.000% 
   unix x64:    +0 +0.000% standard
      stm32:    +0 +0.000% PYBV10
      esp32:    +0 +0.000% ESP32_GENERIC
     mimxrt:    +0 +0.000% TEENSY40
        rp2:    +0 +0.000% RPI_PICO_W
       samd:    +0 +0.000% ADAFRUIT_ITSYBITSY_M4_EXPRESS
  qemu rv32:    +0 +0.000% VIRT_RV32

@agatti agatti added port-rp2 board-definition New or updated board definition files. Combine with a port- label. labels May 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

board-definition New or updated board definition files. Combine with a port- label. port-rp2

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants