From d63d6d4b39c0ad06448dfb23f6b56a91072aa2fa Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Tue, 8 Sep 2026 14:00:34 +0200 Subject: [PATCH 1/6] Add files via upload --- src/boards/meshtastic_6.1.1/board.h | 67 +++++++++++++++++++++++++ src/boards/meshtastic_6.1.1/board.mk | 3 ++ src/boards/meshtastic_6.1.1/pinconfig.c | 19 +++++++ src/boards/meshtastic_7.3.0/board.h | 67 +++++++++++++++++++++++++ src/boards/meshtastic_7.3.0/board.mk | 4 ++ src/boards/meshtastic_7.3.0/pinconfig.c | 19 +++++++ 6 files changed, 179 insertions(+) create mode 100644 src/boards/meshtastic_6.1.1/board.h create mode 100644 src/boards/meshtastic_6.1.1/board.mk create mode 100644 src/boards/meshtastic_6.1.1/pinconfig.c create mode 100644 src/boards/meshtastic_7.3.0/board.h create mode 100644 src/boards/meshtastic_7.3.0/board.mk create mode 100644 src/boards/meshtastic_7.3.0/pinconfig.c diff --git a/src/boards/meshtastic_6.1.1/board.h b/src/boards/meshtastic_6.1.1/board.h new file mode 100644 index 000000000..55af55f24 --- /dev/null +++ b/src/boards/meshtastic_6.1.1/board.h @@ -0,0 +1,67 @@ +/* + * The MIT License (MIT) + * + * Copyright (c) 2018 Ha Thach for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef _MESHTASTIC_H +#define _MESHTASTIC_H + +#define _PINNUM(port, pin) ((port)*32 + (pin)) + +/*------------------------------------------------------------------*/ +/* LED + *------------------------------------------------------------------*/ +#define LEDS_NUMBER 0 +//#define LED_PRIMARY_PIN _PINNUM(0, 24) // Green +//#define LED_STATE_ON 0 + +/*------------------------------------------------------------------*/ +/* BUTTON + *------------------------------------------------------------------*/ +#define BUTTONS_NUMBER 2 +#define BUTTON_1 _PINNUM(0, 18) // unusable: RESET +#define BUTTON_2 _PINNUM(0, 18) // unusable: RESET +#define BUTTON_PULL NRF_GPIO_PIN_PULLUP + +//--------------------------------------------------------------------+ +// BLE OTA +//--------------------------------------------------------------------+ +#define BLEDIS_MANUFACTURER "Meshtastic" +#define BLEDIS_MODEL "Meshtastic" + +//--------------------------------------------------------------------+ +// USB +//--------------------------------------------------------------------+ +#define USB_DESC_VID 0x239A +#define USB_DESC_UF2_PID 0x0029 +#define USB_DESC_CDC_ONLY_PID 0x002A + +//--------------------------------------------------------------------+ +// UF2 +//--------------------------------------------------------------------+ +#define UF2_PRODUCT_NAME "Meshtastic" +#define UF2_VOLUME_LABEL "MESHBOOT" +#define UF2_BOARD_ID "Meshtastic" +#define UF2_INDEX_URL "https://github.com/meshtastic/firmware.git" + + +#endif /* _MESHTASTIC_H */ diff --git a/src/boards/meshtastic_6.1.1/board.mk b/src/boards/meshtastic_6.1.1/board.mk new file mode 100644 index 000000000..0bdf19fdc --- /dev/null +++ b/src/boards/meshtastic_6.1.1/board.mk @@ -0,0 +1,3 @@ +MCU_SUB_VARIANT = nrf52840 +CFLAGS += -DDEVICE_NAME='"MESH_DFU"' + diff --git a/src/boards/meshtastic_6.1.1/pinconfig.c b/src/boards/meshtastic_6.1.1/pinconfig.c new file mode 100644 index 000000000..a983e4ab4 --- /dev/null +++ b/src/boards/meshtastic_6.1.1/pinconfig.c @@ -0,0 +1,19 @@ +#include "boards.h" +#include "uf2/configkeys.h" + +__attribute__((used, section(".bootloaderConfig"))) +const uint32_t bootloaderConfig[] = +{ + /* CF2 START */ + CFG_MAGIC0, CFG_MAGIC1, // magic + 5, 100, // used entries, total entries + + 204, 0x100000, // FLASH_BYTES = 0x100000 + 205, 0x40000, // RAM_BYTES = 0x40000 + 208, (USB_DESC_VID << 16) | USB_DESC_UF2_PID, // BOOTLOADER_BOARD_ID = USB VID+PID, used for verification when updating bootloader via uf2 + 209, 0xada52840, // UF2_FAMILY = 0xada52840 + 210, 0x20, // PINS_PORT_SIZE = PA_32 + + 0, 0, 0, 0, 0, 0, 0, 0 + /* CF2 END */ +}; diff --git a/src/boards/meshtastic_7.3.0/board.h b/src/boards/meshtastic_7.3.0/board.h new file mode 100644 index 000000000..55af55f24 --- /dev/null +++ b/src/boards/meshtastic_7.3.0/board.h @@ -0,0 +1,67 @@ +/* + * The MIT License (MIT) + * + * Copyright (c) 2018 Ha Thach for Adafruit Industries + * + * Permission is hereby granted, free of charge, to any person obtaining a copy + * of this software and associated documentation files (the "Software"), to deal + * in the Software without restriction, including without limitation the rights + * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell + * copies of the Software, and to permit persons to whom the Software is + * furnished to do so, subject to the following conditions: + * + * The above copyright notice and this permission notice shall be included in + * all copies or substantial portions of the Software. + * + * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR + * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, + * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER + * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, + * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN + * THE SOFTWARE. + */ + +#ifndef _MESHTASTIC_H +#define _MESHTASTIC_H + +#define _PINNUM(port, pin) ((port)*32 + (pin)) + +/*------------------------------------------------------------------*/ +/* LED + *------------------------------------------------------------------*/ +#define LEDS_NUMBER 0 +//#define LED_PRIMARY_PIN _PINNUM(0, 24) // Green +//#define LED_STATE_ON 0 + +/*------------------------------------------------------------------*/ +/* BUTTON + *------------------------------------------------------------------*/ +#define BUTTONS_NUMBER 2 +#define BUTTON_1 _PINNUM(0, 18) // unusable: RESET +#define BUTTON_2 _PINNUM(0, 18) // unusable: RESET +#define BUTTON_PULL NRF_GPIO_PIN_PULLUP + +//--------------------------------------------------------------------+ +// BLE OTA +//--------------------------------------------------------------------+ +#define BLEDIS_MANUFACTURER "Meshtastic" +#define BLEDIS_MODEL "Meshtastic" + +//--------------------------------------------------------------------+ +// USB +//--------------------------------------------------------------------+ +#define USB_DESC_VID 0x239A +#define USB_DESC_UF2_PID 0x0029 +#define USB_DESC_CDC_ONLY_PID 0x002A + +//--------------------------------------------------------------------+ +// UF2 +//--------------------------------------------------------------------+ +#define UF2_PRODUCT_NAME "Meshtastic" +#define UF2_VOLUME_LABEL "MESHBOOT" +#define UF2_BOARD_ID "Meshtastic" +#define UF2_INDEX_URL "https://github.com/meshtastic/firmware.git" + + +#endif /* _MESHTASTIC_H */ diff --git a/src/boards/meshtastic_7.3.0/board.mk b/src/boards/meshtastic_7.3.0/board.mk new file mode 100644 index 000000000..16bd37bd3 --- /dev/null +++ b/src/boards/meshtastic_7.3.0/board.mk @@ -0,0 +1,4 @@ +MCU_SUB_VARIANT = nrf52840 +CFLAGS += -DDEVICE_NAME='"MESH_DFU"' +SD_VERSION = 7.3.0 + diff --git a/src/boards/meshtastic_7.3.0/pinconfig.c b/src/boards/meshtastic_7.3.0/pinconfig.c new file mode 100644 index 000000000..a983e4ab4 --- /dev/null +++ b/src/boards/meshtastic_7.3.0/pinconfig.c @@ -0,0 +1,19 @@ +#include "boards.h" +#include "uf2/configkeys.h" + +__attribute__((used, section(".bootloaderConfig"))) +const uint32_t bootloaderConfig[] = +{ + /* CF2 START */ + CFG_MAGIC0, CFG_MAGIC1, // magic + 5, 100, // used entries, total entries + + 204, 0x100000, // FLASH_BYTES = 0x100000 + 205, 0x40000, // RAM_BYTES = 0x40000 + 208, (USB_DESC_VID << 16) | USB_DESC_UF2_PID, // BOOTLOADER_BOARD_ID = USB VID+PID, used for verification when updating bootloader via uf2 + 209, 0xada52840, // UF2_FAMILY = 0xada52840 + 210, 0x20, // PINS_PORT_SIZE = PA_32 + + 0, 0, 0, 0, 0, 0, 0, 0 + /* CF2 END */ +}; From d6f4a656328a61bc29c3f411eac114d8cf85d0af Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Tue, 8 Sep 2026 14:32:28 +0200 Subject: [PATCH 2/6] Add files via upload --- src/boards/meshtastic_6.1.1/board.cmake | 1 + 1 file changed, 1 insertion(+) create mode 100644 src/boards/meshtastic_6.1.1/board.cmake diff --git a/src/boards/meshtastic_6.1.1/board.cmake b/src/boards/meshtastic_6.1.1/board.cmake new file mode 100644 index 000000000..25daf71d0 --- /dev/null +++ b/src/boards/meshtastic_6.1.1/board.cmake @@ -0,0 +1 @@ +set(MCU_VARIANT nrf52840) From 2fe1b9b28ad718643cd9b8fedc38a2706f251937 Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Tue, 8 Sep 2026 14:32:48 +0200 Subject: [PATCH 3/6] Add files via upload --- src/boards/meshtastic_7.3.0/board.cmake | 1 + 1 file changed, 1 insertion(+) create mode 100644 src/boards/meshtastic_7.3.0/board.cmake diff --git a/src/boards/meshtastic_7.3.0/board.cmake b/src/boards/meshtastic_7.3.0/board.cmake new file mode 100644 index 000000000..25daf71d0 --- /dev/null +++ b/src/boards/meshtastic_7.3.0/board.cmake @@ -0,0 +1 @@ +set(MCU_VARIANT nrf52840) From 39efb4fdcf19f1e308f19aaebee358ec506a2056 Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Tue, 8 Sep 2026 14:36:02 +0200 Subject: [PATCH 4/6] Update README.md --- README.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/README.md b/README.md index 52e770196..56eeb22f1 100644 --- a/README.md +++ b/README.md @@ -81,6 +81,7 @@ bootloader and SoftDevice zip package"). - LilyGO T-Echo - Minewsemi MX25LE01 - MuziWorks Base Uno / Base Duo / Superbase +- Meshtastic Generic - Nologo ProMicro NRF52840 (aka SuperMini NRF52840) - RAK 3401 - RAK 4631 ([See note](#notes-on-rak4631-bootloader)) @@ -109,6 +110,7 @@ When in OTA DFU mode, devices advertise using a board-specific name rather than | LILYGO T-Echo | `LGTE_DFU` | | Minewsemi MX25LE01 | `MX25_DFU` | | MuziWorks Base / Superbase | `MUZI_DFU` | +| Meshtastic Generic | `MESH_DFU` | | ProMicro NRF52840 | `PROM_DFU` | | RAK 4631 | `4631_DFU` | | RAK 3401 | `3401_DFU` | From 06058b4a899b70f561c4cb2ae1ea5fcc41426b61 Mon Sep 17 00:00:00 2001 From: Mark Trevor Birss Date: Tue, 8 Sep 2026 14:37:05 +0200 Subject: [PATCH 5/6] Update README.md --- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.md b/README.md index 56eeb22f1..fde4a6322 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ bootloader and SoftDevice zip package"). - LilyGO T-Echo - Minewsemi MX25LE01 - MuziWorks Base Uno / Base Duo / Superbase -- Meshtastic Generic +- Meshtastic Generic SoftDevive v6.1.1 and v7.3.0 - Nologo ProMicro NRF52840 (aka SuperMini NRF52840) - RAK 3401 - RAK 4631 ([See note](#notes-on-rak4631-bootloader)) From 4eb0e45c19c1e2b3064f703808c97a9010c2b8aa Mon Sep 17 00:00:00 2001 From: James Rich <2199651+jamesarich@users.noreply.github.com> Date: Tue, 27 Oct 2026 05:42:43 -0500 Subject: [PATCH 6/6] fix(meshtastic_generic): separate Board-ID per SoftDevice, drop CMake files, document --- README.md | 2 +- changelog.md | 1 + src/boards/meshtastic_6.1.1/board.cmake | 1 - src/boards/meshtastic_6.1.1/board.h | 4 ++-- src/boards/meshtastic_7.3.0/board.cmake | 1 - src/boards/meshtastic_7.3.0/board.h | 4 ++-- 6 files changed, 6 insertions(+), 7 deletions(-) delete mode 100644 src/boards/meshtastic_6.1.1/board.cmake delete mode 100644 src/boards/meshtastic_7.3.0/board.cmake diff --git a/README.md b/README.md index 491ef0456..031dea526 100644 --- a/README.md +++ b/README.md @@ -81,7 +81,7 @@ bootloader and SoftDevice zip package"). - LilyGO T-Echo - Minewsemi MX25LE01 - MuziWorks Base Uno / Base Duo / Superbase -- Meshtastic Generic SoftDevive v6.1.1 and v7.3.0 +- Meshtastic Generic, S140 6.1.1 (`meshtastic_6.1.1`) and 7.3.0 (`meshtastic_7.3.0`), for DIY boards with no board-specific bootloader: no LED or button - Nologo ProMicro NRF52840 (aka SuperMini NRF52840) - RAK 3401 - RAK 4631 ([See note](#notes-on-rak4631-bootloader)) diff --git a/changelog.md b/changelog.md index 83fa7075f..d552a2673 100644 --- a/changelog.md +++ b/changelog.md @@ -8,6 +8,7 @@ provenance. - The project is renamed the Meshtastic nRF52 Bootloader (repo `meshtastic/nRF52_Bootloader`), and releases are tagged plain `x.y.z` from 2.6.0, continuing the OTAFIX numbering. Board-IDs, BLE names and asset file names are unchanged. - New board: Seeed Studio Wio Tracker L1 Pro 1W (OTA DFU advertising name `WTLP_DFU`). +- New boards: `meshtastic_6.1.1` and `meshtastic_7.3.0`, generic nRF52840 bootloaders for DIY boards with no board-specific one, for S140 6.1.1 and 7.3.0 (Board-IDs `nRF52840-Meshtastic-Generic-S140v6` and `-S140v7`, OTA DFU name `MESH_DFU`). They drive no LED, and their required button is the reset pin P0.18 so it claims no free GPIO. They share USB `0x239A:0x0029` with the RAK4631, RAK3401, T-Echo, WisMesh Tag and MX25LE01, so their update UF2 installs over those boards' bootloaders and the reverse. - A board with a valid application that sits in DFU for 6 minutes with no activity boots its application. A BLE connection or DFU write, a UF2 drive read or write, USB enumeration, and serial DFU traffic each restart the 6 minutes; a board with no valid application keeps waiting. - A SoftDevice flash timeout during a BLE or serial transfer, or the activation settings save, is retried every 100 ms, up to 20 times, instead of resetting the bootloader. - `INFO_UF2.TXT` shows a `Last-Fault: id=0x.. pc=0x.. info=0x..` line for a SoftDevice or SDK fault the bootloader recorded since the last UF2 drive session. It appears only if the next boot reaches the drive before an application boots, since the application's RAM use wipes the record. The record lives in a 16-byte RAM region behind a magic word and is cleared once printed; for an SDK error `info` is the error code. diff --git a/src/boards/meshtastic_6.1.1/board.cmake b/src/boards/meshtastic_6.1.1/board.cmake deleted file mode 100644 index 25daf71d0..000000000 --- a/src/boards/meshtastic_6.1.1/board.cmake +++ /dev/null @@ -1 +0,0 @@ -set(MCU_VARIANT nrf52840) diff --git a/src/boards/meshtastic_6.1.1/board.h b/src/boards/meshtastic_6.1.1/board.h index 55af55f24..eceafd95a 100644 --- a/src/boards/meshtastic_6.1.1/board.h +++ b/src/boards/meshtastic_6.1.1/board.h @@ -58,9 +58,9 @@ //--------------------------------------------------------------------+ // UF2 //--------------------------------------------------------------------+ -#define UF2_PRODUCT_NAME "Meshtastic" +#define UF2_PRODUCT_NAME "Meshtastic Generic" #define UF2_VOLUME_LABEL "MESHBOOT" -#define UF2_BOARD_ID "Meshtastic" +#define UF2_BOARD_ID "nRF52840-Meshtastic-Generic-S140v6" #define UF2_INDEX_URL "https://github.com/meshtastic/firmware.git" diff --git a/src/boards/meshtastic_7.3.0/board.cmake b/src/boards/meshtastic_7.3.0/board.cmake deleted file mode 100644 index 25daf71d0..000000000 --- a/src/boards/meshtastic_7.3.0/board.cmake +++ /dev/null @@ -1 +0,0 @@ -set(MCU_VARIANT nrf52840) diff --git a/src/boards/meshtastic_7.3.0/board.h b/src/boards/meshtastic_7.3.0/board.h index 55af55f24..9d4e50256 100644 --- a/src/boards/meshtastic_7.3.0/board.h +++ b/src/boards/meshtastic_7.3.0/board.h @@ -58,9 +58,9 @@ //--------------------------------------------------------------------+ // UF2 //--------------------------------------------------------------------+ -#define UF2_PRODUCT_NAME "Meshtastic" +#define UF2_PRODUCT_NAME "Meshtastic Generic" #define UF2_VOLUME_LABEL "MESHBOOT" -#define UF2_BOARD_ID "Meshtastic" +#define UF2_BOARD_ID "nRF52840-Meshtastic-Generic-S140v7" #define UF2_INDEX_URL "https://github.com/meshtastic/firmware.git"