Add Seeed XIAO nRF52840 + Wio-SX1262 board support#45
Open
slack-t wants to merge 2 commits into
Open
Conversation
Adds BOARD_XIAO_NRF52840 (0x52) to the nRF52 board range. Integrates the SX1262 driver for the Wio-SX1262 expansion board with pin assignments for CS, RST, DIO1, BUSY and the RXEN RF switch. VALIDATE_FIRMWARE is disabled for this board — the Seeed bootloader does not write the image size at the Adafruit IMG_SIZE_START address, causing false hash failures. Fixes a CSMA preamble IRQ latch bug present on all SX1262 boards: the preamble-detected IRQ is not routed to DIO1, so without an explicit OP_CLEAR_IRQ_STATUS_6X the bit latches and the channel appears perpetually busy under high-frequency CSMA polling. A software timer preserves the correct busy window while the IRQ is cleared immediately. New build target: [env:xiao_nrf52840] in platformio.ini using the Seeed platform-seeedboards. Pass --upload-port at build time — PlatformIO HWID auto-detection crashes on this platform (VID:PID 0x2886:0x0045 is absent from the board JSON hwid list); the board's use_1200bps_touch=true still triggers DFU automatically. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Documents pin mapping, build targets, known limitations (VALIDATE_FIRMWARE disabled, upload-port workaround), and provisioning notes. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds support for the Seeed XIAO nRF52840 paired with the Wio-SX1262 LoRa expansion board.
Changes
Boards.h— definesBOARD_XIAO_NRF52840 0x52(sequential after RAK4631 at0x51).VALIDATE_FIRMWAREis disabled: the Seeed bootloader does not write the image size at the AdafruitIMG_SIZE_STARTaddress, causing false hash-check failures.sx126x.cpp/sx126x.h— XIAO nRF52840 pin assignments (CS, RST, DIO1, BUSY, RXEN RF switch) and board cases in the SX1262 driver guard chains.Also fixes a CSMA preamble IRQ latch bug present on all SX1262 boards: the preamble-detected IRQ is not routed to DIO1, so without an explicit
OP_CLEAR_IRQ_STATUS_6Xthe bit latches and the channel appears perpetually busy under high-frequency CSMA polling. A software timer preserves the correct busy window while the IRQ bit is cleared immediately.RNode_Firmware.ino— board integration: InternalFS filesystem adapter, serial-wait exclusion (matches RAK4631 pattern).Utilities.h— XIAO pin definitions and LED logic.extra_script.py— addsxiao_nrf52840to the provisioning variant table (reuses RAK4631 product/model bytes0x10/0x12— no dedicatedrnodeconfID exists for this board yet).platformio.ini— new[env:xiao_nrf52840]build target using the Seeedplatform-seeedboards. Note: pass--upload-port /dev/ttyACMxat build time — PlatformIO HWID auto-detection crashes on this platform (VID:PID0x2886:0x0045is absent from the board JSON hwid list);use_1200bps_touch=truestill triggers DFU automatically.README.md— pin mapping, build instructions, and known limitations.Testing
Tested on physical hardware as a standalone transport node (TNC mode) and as a host-controlled modem (normal mode). Confirmed RX/TX on 868 MHz.