Compare commits

..

3027 Commits

Author SHA1 Message Date
mverch67
6b05f090dc reduce PSRAM allocated to lvgl 2025-09-18 10:17:58 +02:00
Manuel
e9b87f7a81 Merge branch 'master' into arduino-esp32-v3.2 2025-09-18 09:48:51 +02:00
Ben Meadors
173b75a1c0 Merge pull request #7526 from DaneEvans/ci/merge-queue 2025-09-17 19:07:00 -05:00
Ben Meadors
b0dae54c97 Merge branch 'master' into ci/merge-queue 2025-09-17 19:06:24 -05:00
Thomas Göttgens
71d84404c6 add WIP for Unit C6L (#7433)
* add WIP for Unit C6L
* adapt to new config structure
* Add c6l BLE and screen support (#7991)
* Minor c6l fix
* Move out of PRIVATE_HW
---------
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Jason P <Xaositek@users.noreply.github.com>
Co-authored-by: Markus <Links2004@users.noreply.github.com>
2025-09-17 22:40:55 +02:00
github-actions[bot]
6f5bdd73cb Upgrade trunk (#7868)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-09-17 06:09:18 -05:00
github-actions[bot]
cc3c568501 Update protobufs (#8005)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-16 07:20:44 -05:00
renovate[bot]
13ebceb3bc Update meshtastic/device-ui digest to 9ed5355 (#7987)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-16 06:42:08 -05:00
Ben Meadors
70724bef72 Fix overflow of time value (#7984)
* Fix overflow of time value

* Revert "Fix overflow of time value"

This reverts commit 0847969201.

* That got boogered up
2025-09-14 08:12:38 -05:00
Mike Robbins
bf4e2e8e86 Fix GPS gm_mktime memory leak (#7981) 2025-09-14 06:36:16 -05:00
Ben Meadors
2dc7760508 Scale probe buffer size based on current baud rate (#7975)
* Scale probe buffer size based on current baud rate

* Throttle bad time validation logging and fix time comparison logic

* Remove comment

* Missed the other instances

* Copy pasta
2025-09-14 06:31:17 -05:00
Tom Fifield
d201f6a1ed Guard bad time warning logs using GPS_DEBUG (#7897)
In 2.7.7 / 2.7.8 we introduced some new checks for time accuracy.

In combination, these result in a spamming of the logs when a bad time is found

When the GPS is active, we're calling the GPS thread every 0.2secs.

So this log could be printed 4,500 times in a no-lock scenario :)

Reserve this experience for developers using GPS_DEBUG.

Fixes https://github.com/meshtastic/firmware/issues/7896
2025-09-14 05:00:42 -05:00
Ben Meadors
9977035499 Fix DRAM overflow on old esp32 targets 2025-09-13 20:14:10 -05:00
Ben Meadors
096afa07f8 Tweak maximums 2025-09-13 18:57:00 -05:00
Ben Meadors
760471d620 Fix json report crashes on esp32 (#7978) 2025-09-13 18:52:46 -05:00
renovate[bot]
6165b4f7a9 Update meshtastic-esp8266-oled-ssd1306 digest to 0cbc26b (#7977)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-13 16:31:56 -05:00
Ben Meadors
ae814b5463 Drop the limit 2025-09-13 12:07:14 -05:00
Ben Meadors
4ee07226e4 Missed 2025-09-13 11:59:58 -05:00
Ben Meadors
78dfb05eeb Portduino dynamic alloc 2025-09-13 11:59:50 -05:00
Ben Meadors
9211b1bb4b Static memory pool allocation (#7966)
* Static memory pool

* Initializer

* T-Lora Pager: Support LR1121 and SX1280 models (#7956)

* T-Lora Pager: Support LR1121 and SX1280 models

* Remove ifdefs

---------

Co-authored-by: WillyJL <me@willyjl.dev>
2025-09-13 07:01:07 -05:00
Ben Meadors
70ac3601b0 Trunk 2025-09-13 06:57:12 -05:00
Ben Meadors
51acd92a37 Trunk 2025-09-13 06:51:18 -05:00
WillyJL
6d2093650a T-Lora Pager: Support LR1121 and SX1280 models (#7956)
* T-Lora Pager: Support LR1121 and SX1280 models

* Remove ifdefs
2025-09-13 06:50:53 -05:00
github-actions[bot]
b6dd99917d Update protobufs (#7973)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-13 06:37:58 -05:00
Ben Meadors
d00b2afe1d Merge pull request #7964 from compumike/compumike/fix-nimble-bluetooth-memory-leak
Fix memory leak in `NimbleBluetooth`: allocate `BluetoothStatus` on stack, not heap
2025-09-12 18:30:28 -05:00
Ben Meadors
e49b07ac8c Merge pull request #7965 from compumike/compumike/fix-nrf52-bluetooth-memory-leak
Fix memory leak in `NRF52Bluetooth`: allocate `BluetoothStatus` on stack, not heap
2025-09-12 18:30:01 -05:00
Ben Meadors
8989de118c Only queue 2 client notification 2025-09-12 16:07:27 -05:00
Ben Meadors
1914fa0321 Formatting 2025-09-12 15:49:56 -05:00
Manuel
d47d249550 Merge branch 'master' into arduino-esp32-v3.2 2025-09-12 21:15:43 +02:00
Mike Robbins
962e5d513c Fix memory leak in NextHopRouter: always free packet copy when removing from pending 2025-09-12 13:16:48 -05:00
Ben Meadors
ac4bcd2f56 Cleanup 2025-09-11 18:57:30 -05:00
Ben Meadors
e17c50bb86 Put guards in place around debug heap operations (#7955)
* Put guards in place around debug heap operations

* Add macros to clean up code

* Add pointer as well
2025-09-11 07:57:42 -05:00
Tom Fifield
abc0eb196a Fix build error in rak_wismesh_tap_v2 (#7905)
In the logs was:
"No screen resolution defined in build_flags. Please define DISPLAY_SIZE."

set according to similar devices.
2025-09-10 16:28:49 -05:00
Ben Meadors
701028b749 Unify build epoch to add flag in platformio-custom.py (#7917)
* Unify build_epoch replacement logic in platformio-custom

* Missed one
2025-09-11 06:29:50 +10:00
Ben Meadors
108bdf7b0d Close should set heartbeatReceived = false 2025-09-09 19:11:39 -05:00
Ben Meadors
f267b5f5f7 Exclude trackball if we aren't a trackball device 2025-09-09 11:15:55 -05:00
Ben Meadors
0cd860e300 RangeTest must be enabled 2025-09-09 10:53:18 -05:00
Ben Meadors
31fdb36987 Detection sensor add module only when enabled 2025-09-09 10:46:33 -05:00
Jonathan Bennett
e7741c20e4 Add LOG_HEAP log type, and more heap debug messages (#7937) 2025-09-09 10:29:07 -05:00
Ben Meadors
d1d16fc25f Make phone queues use a static pointer queue (#7919)
* Make phone queues use a static pointer queue

* Static init

* Compile time constants now

* Instead, lets just use the normal pointerqueue for linux native builds and static for IoT platforms

* Add missing method

* Missing methods

* Update variant.h
2025-09-09 08:21:46 -05:00
Ben Meadors
c8afbe68b5 Use char buffer for probeResponse (#7870)
* Use char buffer for probeResponse

* \Update src/gps/GPS.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Revert "\Update src/gps/GPS.cpp"

This reverts commit 54d64e19f7.

* Remove string

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-09 06:34:38 -05:00
Ben Meadors
803e96800e ATAK module should be disabled for non-TAK roles (#7928) 2025-09-08 17:21:55 -05:00
renovate[bot]
6c69780615 chore(deps): update meshtastic/device-ui digest to 3677476 (#7925)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-08 16:52:21 -05:00
Manuel
ff28355e16 Merge branch 'master' into arduino-esp32-v3.2 2025-09-08 19:20:15 +02:00
Tom Fifield
d5bb566276 Only log good times. (It's not always a good time then) (#7904)
Further to https://github.com/meshtastic/firmware/pull/7897 ,
there was another log line that was triggering indiscriminantly on
GPS_INTERVAL_THRESHOLD .

Rather than logging a bad time 4000 times, let's just log one good time
when it is set.
2025-09-08 05:59:37 -05:00
Manuel
39ff880506 reorganize 8MB partition for MUI devices (#7860)
* reorganize 8MB partition for MUI devices

* update device-install scripts to MUI 8MB partition scheme
2025-09-08 05:56:47 -05:00
renovate[bot]
209157c9dd chore(deps): update meshtastic/device-ui digest to 233d18e (#7890)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-08 05:55:44 -05:00
Manuel
fb59d68edd fix uninitialized kbchar (#7889) 2025-09-08 05:45:11 -05:00
Manuel
351cbd723b Merge branch 'master' into arduino-esp32-v3.2 2025-09-08 10:41:14 +02:00
github-actions[bot]
7b854fb5ca Update protobufs (#7903)
Co-authored-by: fifieldt <1287116+fifieldt@users.noreply.github.com>
2025-09-08 11:12:52 +10:00
Tom Fifield
f8b160595f Fix merge conflict with test changes (#7902)
289f90bdbe

merged a commit that relied on

5b9db81819

but the latter commit was not merged.

This does manual wrangling to make sure the same file that exists on develop
right now ends up on master.
2025-09-08 11:02:29 +10:00
HarukiToreda
37d14f942e Reverting changes made by PR #7520 and adjusting ADC (#7878)
* ADC value adjustment for T114
2025-09-06 06:26:08 -05:00
GUVWAF
4594ae474e Upon receiving ACK/reply directly, only update next-hop if we’re the *sole* relayer (#7859) 2025-09-06 06:23:43 -05:00
Jeremiah K
f26e657577 Fix esptool detection and baud rate issues in Windows batch scripts (#7856)
- Fix esptool detection to use 'version' subcommand instead of no arguments
- Fix device-update.bat to use 115200 bps for flashing, 1200 bps only for reset
- Add missing closing quotes in debug messages

Replace magic numbers with named constants for better maintainability

- Add RESET_BAUD=1200 constant for reset baud rate
- Add UPDATE_OFFSET=0x10000 constant for update flash offset
- Use constants instead of hardcoded values throughout script

Extract magic numbers to constants in shell scripts for consistency

- Add FLASH_BAUD, RESET_BAUD, UPDATE_OFFSET constants to device-update.sh
- Add RESET_BAUD, FIRMWARE_OFFSET constants to device-install.sh
- Replace hardcoded values with named constants throughout
- Maintain consistency with batch script improvements

Fix Python path quoting and remove unreachable code

- Quote Python interpreter paths to handle spaces in paths like 'C:\Program Files\Python\python.exe'
- Remove unreachable GOTO statements after EXIT /B commands
- Improve robustness when custom Python interpreters are specified

Fix esptool detection for pipx installations

- Change from checking ERRORLEVEL GEQ 2 to EQU 9009
- Pipx-installed esptool returns exit code 2 when showing help (normal)
- Only treat Windows 'command not found' error (9009) as truly not found
- Add debug output to show actual exit codes for troubleshooting
2025-09-06 06:20:57 -05:00
GUVWAF
a25bfd264c Only stop retransmissions when receiving implicit ACK over LoRa (#7872)
* Only stop retransmissions when receiving implicit ACK over LoRa

* trunk fmt
2025-09-05 12:00:23 -05:00
Manuel
ec9f3fa6ea T-Lora Pager: fix keyboard and improve rotary wheel haptic (#7869)
* update RotaryEncoder: use interrupts

* increase rotary encoder processing interval

* remove disabling peripherals during LS
2025-09-05 07:42:51 -05:00
Ben Meadors
8356ad97e4 Cleanup file list 2025-09-05 07:18:29 -05:00
Ben Meadors
bf51c38975 Don't add heap allocations while debugging the heap 2025-09-05 07:18:03 -05:00
Ben Meadors
3df3c876cc TFTDisplay destructor 2025-09-05 06:22:21 -05:00
Ben Meadors
68f07c5f9d Board extras 2025-09-04 18:39:02 -05:00
renovate[bot]
7fb96ce2ba chore(deps): update meshtastic/device-ui digest to a04bc94 (#7857)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 12:53:46 -05:00
renovate[bot]
12687a1073 chore(deps): update actions/github-script action to v8 (#7858)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 12:53:21 -05:00
github-actions[bot]
89de499198 Update protobufs (#7855)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-04 07:32:59 -05:00
Sam Duffield
4881362340 Add support for the Challenger rp2040 lora (#7826)
* Firmware Built... awaiting parts for test

* Add board_level key/value as per suggestion from vidplace7

* Trunk formatting applied
2025-09-04 06:50:25 -05:00
Marco Veneziano
18000ccf21 Fix INA3221 higher current wrong readings (#7607)
* chore(deps): update meshtastic/device-ui digest to 10f0244 (#7840)

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>

* use branch of ina3221 library with fixes

* using commit hash instead of branch name

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 06:43:44 -05:00
Davide Cavalca
7776ec15b6 Add TSL2561 sensor (#7675)
* Add TSL2561 sensor

* Update platformio.ini

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/modules/Telemetry/Sensor/TSL2561Sensor.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update protobufs

* Clarify magic number in TSL2561Sensor.h

* Use the correct version for Adafruit TSL2561

* Lint fixes

* Fix typo

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2025-09-04 06:39:00 -05:00
Daniel.Cao
e4c7fca716 Add RAK WisMesh Tap V2 (ESP32S3) Hardware Variant (#7741)
* Add initial variant and platformio configuration for RAK WISMESHTAP V2

* Add initial variant and platformio configuration for rak wismesh tap v2

* Remove unnecessary Meshtastic build flags from rak_wismesh_tap_v2 configuration

* Enable LGFX button support in rak_wismesh_tap_v2 configuration

* Revert "Enable LGFX button support in rak_wismesh_tap_v2 configuration"

This reverts commit 2bd2c1a03b.

---------

Co-authored-by: Daniel.Cao <daniel.cao@rakwireless.com>
2025-09-04 06:38:31 -05:00
Chloe Bethel
5b63bd9331 Add RF switch settings for STM32WL variants (#7813)
* Add RF switch settings for STM32WL variants

* Shuffle ifdefs in STM32WLE5JCInterface to make it not get built by other targets
2025-09-04 06:38:05 -05:00
TN
289f90bdbe merge create_test_packet duplicate usage into a shared function (#7752) 2025-09-04 06:31:35 -05:00
Jonathan Bennett
09a0df3a1f Enable bmx160 on native (#7844) 2025-09-04 06:24:04 -05:00
Andrew Yong
fe329892de feat: New ESP32 variant 9m2ibr_aprs_lora_tracker (#7828)
9M2IBR APRS LoRa Tracker: ESP32-WROOM-32 + EBYTE E22-400M30S
https://shopee.com.my/product/1095224/21692283917

Originally developed for LoRa_APRS_iGate and GPIO assignment is similar to https://github.com/richonguzman/LoRa_APRS_iGate/blob/main/variants/ESP32_DIY_1W_LoRa_Mesh_V1_2/board_pinout.h

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-09-04 06:18:28 -05:00
renovate[bot]
2681332678 chore(deps): update actions/setup-node action to v5 (#7848)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 06:17:23 -05:00
renovate[bot]
f994eb185f chore(deps): update actions/setup-python action to v6 (#7849)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 06:17:11 -05:00
github-actions[bot]
55c23dec13 Upgrade trunk (#7853)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-09-04 06:15:47 -05:00
github-actions[bot]
4dfc062abd Automated version bumps (#7843)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-04 06:15:24 -05:00
renovate[bot]
0be21d90c1 chore(deps): update actions/stale action to v10 (#7846)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-04 06:14:22 -05:00
renovate[bot]
a0c0388dd9 chore(deps): update meshtastic/device-ui digest to 10f0244 (#7840)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-03 13:00:08 -05:00
github-actions[bot]
e8367894f2 Upgrade trunk (#7835)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-09-03 06:45:14 -05:00
Manuel
8aae4f1b9d Update device-install scripts for T-LoRa Pager (#7833)
* add tlora-pager to device install scripts + fixes

* replace deprecated commands (write_flash)
2025-09-03 06:22:57 -05:00
github-actions[bot]
8a8f60d129 Update protobufs (#7831)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-02 19:08:05 -05:00
renovate[bot]
b59409bec0 chore(deps): update caveman99-stm32-crypto digest to 1aa30eb (#7808)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-02 18:01:31 -05:00
renovate[bot]
c66125114f chore(deps): update meshtastic/device-ui digest to 8019704 (#7830)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-02 16:17:00 -05:00
renovate[bot]
edb7ec58c6 chore(deps): update platform-native digest to c490bcd (#7814)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-09-02 11:58:57 -05:00
Ben Meadors
655c6b51fe Try-fix Cardkb detection (#7825)
* Try-fix: CardKB detection regression

* Correct macro
2025-09-02 09:50:15 -05:00
Chloe Bethel
0bd4cefad3 Make ExternalNotification show up in excluded_modules, more STM32 modules (#7797)
* Show ExternalNotification as excluded if it is

* Enable ExternalNotification, SerialModule and RangeTest on STM32WL

* Misc fixes for #7797 - ARCH_STM32 -> ARCH_STM32WL, use less flash by dropping weather station support for serialmodule, set tx/rx pins before begin

* Enable Serial1 on RAK3172, make SerialModule use it (console is on LPUART1)

* Fix SerialModule on RAK3172, fix board definition of RAK3172 to include the right pin mapping.
2025-09-02 07:09:15 -05:00
github-actions[bot]
9b1fb795d7 Upgrade trunk (#7822)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-09-02 06:41:48 -05:00
Tom Fifield
3040e5a7bb Fix GPS that hard code 2080 as the start time. (#7803)
* Fix GPS that hard code 2080 as the start time.

Some GPS chips, such as the AG3335 in T1000e and L96 have a hardcoded
time of 2080-01-05 when they start up.

To fix that in a way that seems permanent, let's ignore times that
are more than 40 years since the firmware was built. We should followup
in late 2039 to see if any changes are needed.

Reported-By: @b8b8

* Update src/gps/RTC.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Put FORTY_YEARS in header and use in both places.

* Restore Ben's nicer log lines.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-09-02 06:41:26 -05:00
Ben Meadors
3b82d55176 Revert "Add gat562_mesh_tracker_pro device. (#7815)" (#7824)
This reverts commit 7d1300ab66.
2025-09-02 06:17:01 -05:00
Tom Fifield
a6b8202cd4 Hold for 20s after GPS lock (#7801)
* Hold for >20s after GPS lock

GPS chips are designed to stay locked for a while to download some data and save it.
This data is important for speeding up future locks, and making them higher quality.
Our present configuration could make every lock perform similar to first lock.

This patch sets a hold of between 20s and 10% of the lock search time after lock
is acquired. This should allow the GPS to finish its work before we turn it off.

Fixes https://github.com/meshtastic/firmware/issues/7466

* Remove T1000E-specific GPS holds

The new code does the same thing, for all devices.

* Fix publishing settings

* Cleanups, removing unused variables.

* ifdef log line with GPS_DEBUG

* fixQual is not a bool.
2025-09-02 06:06:06 -05:00
Jason P
cfc1bf10c9 If usePreset is False, show value as Custom (#7812) 2025-09-02 06:05:55 -05:00
Wilson
7d1300ab66 Add gat562_mesh_tracker_pro device. (#7815) 2025-09-02 13:06:24 +08:00
Jonathan Bennett
bd3cbfc1ad Add support for the RV-3028 on native Linux (#7802) 2025-09-01 08:04:04 -05:00
github-actions[bot]
fddc4e00ca Automated version bumps (#7790)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-09-01 08:03:03 -05:00
github-actions[bot]
5f7eec5504 Upgrade trunk (#7804)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-09-01 07:58:01 -05:00
Manuel
6b94c297b9 fix: T-LoRa Pager / T-Deck Pro shutdown (#7792)
* power down during LS and shutdown

* fix T-Deck Pro shutdown

* use device specific define

* slightly rephrase the power off display message
2025-09-01 07:57:49 -05:00
Onyx Clawe
edeb25cab5 Update variant.h (#7520)
Updated ADC, Full charge now results in 100% charge being reported instead of 95% charge

Co-authored-by: OnyxtheDragon <58921814+OnyxtheDragon@users.noreply.github.com>
2025-09-01 07:57:15 -05:00
Tom Fifield
44688e8363 Fix device-install.bat baud rate (#7486)
As reported by @gruberaaron , work to improve the 1200bps reset for
esptool caused all runs of device-install.bat to use 1200bps as
the baud rate.

This change removes the general SET "ESPTOOL_BAUD=1200" that was causing
the issues and places the baud settings for reset mode inside the conditional.

Fixes https://github.com/meshtastic/firmware/issues/7172
2025-09-01 14:16:24 +10:00
github-actions[bot]
5ae4ff9162 Upgrade trunk (#7763)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-08-29 13:59:40 -05:00
github-actions[bot]
ed394f5f9d Update protobufs (#7784)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-29 13:58:32 -05:00
Tom Fifield
11db6d4dcc Can't trust RTCs to tell the time. (#7779)
Further to https://github.com/meshtastic/firmware/pull/7772 ,
we discovered that some RTCs have hard-coded start times well in the
past.

This patch gives RTCs the same treatment as GPS - if the time is
earlier than BUILD_EPOCH, we don't use it.

Fixes #7771
Fixes #7750
2025-08-29 13:23:14 -05:00
Ben Meadors
4e03df5ea7 Fix freetext hang (#7781)
* Fixed freetext hangs by adding canned modules back to self-sourced packets and transition to SENDING_ACTIVE state

* Update meshmodule handling
2025-08-29 12:09:22 -05:00
Tom Fifield
d3e3a91096 We don't gotTime if time is 2019. (#7772)
There are certain GPS chips that have a hard-coded time in firmware
that they will return before lock. We set our own hard-coded time,
BUILD_EPOCH, that should be newer and use the comparison to not set
a bad time.

In https://github.com/meshtastic/firmware/pull/7261 we introduced
the RTCSetResult and improved it in https://github.com/meshtastic/firmware/pull/7375 .

However, the original try-fix left logic in GPS.cpp that could
still result in broadcasting the bad time.

Further, as part of our fix we cleared the GPS buffer if we didn't
get a good time. The mesh was hurting at the time, so this was a reasonable
approach. However, given time tends to come in when we're trying to get
early lock, this had the potential side effect of throwing away valuable
information to get position lock.

This change reverses the clearBuffer and changes the logic so if time
is not set it will not be broadcast.

Fixes https://github.com/meshtastic/firmware/issues/7771
Fixes https://github.com/meshtastic/firmware/issues/7750
2025-08-29 09:09:13 -05:00
Tom Fifield
b0e8321514 Only send Neighbours if we have some to send. (#7493)
* Only send Neighbours if we have some to send.

The original intent of NeighborInfo was that when a NeighbourInfo
was sent all of the nodes that saw it would reply with NeighbourInfo.
So, NeighbourInfo was sent even if there were no hop-zero nodes in
the NodeDB.

Since 2023, when this was implemented, our understanding of running city-wide
meshes has improved substantially. We have taken steps to reduce the impact
of NeighborInfo over LoRa.

This change aligns with those ideas: we will now only send NeighborInfo
if we have some neighbors to contribute.

The impact of this change is that a node must first see another directly
connected node in another packet type before NeighborInfo is sent. This means
that a node with no neighbors is no longer able to trigger other nodes
to broadcast NeighborInfo. It will, however, receive the regular periodic
broadcast of NeighborInfo, and will be able to send NeighborInfo if it
has at least 1 neighbor.

* Include all the things

* AvOid memleak
2025-08-28 18:45:46 -05:00
Ben Meadors
6c7cff7de2 Merge pull request #7777 from meshtastic/create-pull-request/bump-version
Bump release version
2025-08-28 06:04:37 -05:00
Ben Meadors
834c3c5cc2 Add this back in 2025-08-27 16:24:57 -05:00
Ben Meadors
25a19b49ad This one is not working yet 2025-08-27 15:18:26 -05:00
Ben Meadors
a4d96bebfb Drop for now 2025-08-27 14:35:29 -05:00
renovate[bot]
d21d6d2085 Update meshtastic/device-ui digest to a3e0e1b (#7766)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-27 13:53:34 -05:00
Ben Meadors
26c38ffc8e Remove debug logging 2025-08-27 11:55:27 -05:00
Ben Meadors
237b8908f7 Chainsaw took too much off the top 2025-08-27 09:54:39 -05:00
Ben Meadors
06bccef462 Reinstitute previous streamapi readStream 2025-08-27 07:17:46 -05:00
Ben Meadors
3120bb8fd7 Fix check 2025-08-27 06:50:53 -05:00
Ben Meadors
0903ed8232 Mesh solar integrate (#7764)
* Added HELTEC MeshSolar board. (#7499)

* Added HELTEC MeshSolar board.

* Set emergency shutdown pin as high impedance

* Set emergency shutdown pin as high impedance

Set emergency shutdown pin as high impedance

* Update variants/nrf52840/heltec_mesh_solar/variant.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update variants/nrf52840/heltec_mesh_solar/variant.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update variants/nrf52840/heltec_mesh_solar/variant.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update I2C SCL pin definition in variant.h

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Updates

---------

Co-authored-by: Quency-D <55523105+Quency-D@users.noreply.github.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-27 06:02:54 -05:00
Ben Meadors
f8ba392a24 Add BaseUI support for L1 EInk (#7751)
* Add BaseUI support for L1 EInk

* Fix Eink offset

* Add joystick

* Updates

* Adjust Seeed Wio Tracker L1 E-Ink variant (#7326)

* Rename variant
Needs the -inkhud suffix to work correctly with the web flasher

* Display driver for ZJY122250_0213BAAMFGN

* Remove dead code from nicheGraphics.h
Remnants of T-Echo's nicheGraphics.h file, which was used as a template.

* Use ZJY122250_0213BAAMFGN driver
Improves display health. We don't need as many full refreshes now.

* Tidying

* board_check = true

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Consolidation

* Add hack for existing InkHUD button functionality

---------

Co-authored-by: todd-herbert <herbert.todd@gmail.com>
2025-08-26 20:29:11 -05:00
Ben Meadors
3dd384dd53 Null check 2025-08-26 19:45:26 -05:00
Jonathan Bennett
2c071a3283 Don't use pin 0 on RAK for input (#7755)
* Don't use pin 0 on RAK for input

* Use boolean instead of define

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-26 13:41:33 -05:00
Manuel
596cd7e0b6 enable device telemetry (#7757) 2025-08-26 13:39:43 -05:00
Manuel
3f5c30e3b3 T-Lora Pager (#7613)
* initial commit

* preset rotary1 encoder

* define TAB+ESC

* haptic feedback

* allow switch off haptic feedback

* enable audio amplifier

* include PR4684

* fix for tft target

* add ES8311 audio codec

* fix KB scan duplicate

* display workaround to avoid debris

* fix debris on display

* keyboard backlight

* enable screen options

* fsm based bounce-free rotary encoder implementation

* use fsm RotaryEncoder only for T-Lora Pager

* change inputbroker default config to allow using rotary wheel for screens AND menues

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-26 09:35:25 -05:00
github-actions[bot]
1a279c6053 Upgrade trunk (#7677)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-08-26 06:31:38 -05:00
renovate[bot]
3d825c51dd Update meshtastic/device-ui digest to 0f32b64 (#7728)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-24 14:44:51 -05:00
Jonathan Bennett
915f882e1f Pkc fix (#7722) 2025-08-24 10:13:18 -05:00
Dane Evans
18d005d7e6 explicit ignores 2025-08-24 08:12:40 +10:00
Dane Evans
8791cd7851 touching to check grandfathering 2025-08-24 08:12:40 +10:00
Dane Evans
590db89643 lint etc 2025-08-24 08:12:40 +10:00
Dane Evans
ea1d968777 update comment 2025-08-24 08:12:40 +10:00
Dane Evans
40d728a14b kerning in yaml. 2025-08-24 08:12:40 +10:00
Dane Evans
e39b56547e try vars 2025-08-24 08:12:40 +10:00
Dane Evans
a7f63d5783 add merge queue 2025-08-24 08:12:40 +10:00
Lewis He
5136c8ba24 The T-Deck-Pro 4G version sets the modem to be disabled by default. (#7715)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-23 06:46:59 -05:00
Ben Meadors
8b42bf7a95 Don't reboot when setting lora config with portduino sim radio (#7716) 2025-08-23 05:47:51 -05:00
Ben Meadors
1daf5aad1f Revert "Add on-screen keyboard implementation on Trackball device. (#7625)" (#7704)
This reverts commit fe3f14a63e.
2025-08-21 06:29:23 -05:00
Wilson
fe3f14a63e Add on-screen keyboard implementation on Trackball device. (#7625)
* Add on-screen keyboard implementation on Wio Tracker L1.

* Update On-Screen Keyboard to new layout.

* The on-screen keyboard dynamically adjusts the key size based on the screen.

* Improve input box display on small screens.

* Optimize the virtual keyboard layout and cursor movement logic, and adjust the keyboard starting position for small and wide screens.

* Optimize the text alignment of numeric keys on ssd1306.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-21 18:01:31 +08:00
renovate[bot]
7574bfb7cb Update meshtastic/device-ui digest to 3dc7cf3 (#7698)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-20 14:18:33 -05:00
Jonathan Bennett
ce75bf4496 Initial stab at rak6421 autoconf (#7691)
* Initial stab at rak6421 autoconf

* trunk

* Add crc check to eeprom autoconf

* Trunk again
2025-08-20 14:18:20 -05:00
Jonathan Bennett
5ce47045e7 Add SDL option to BaseUI on Native (#7568)
* Add SDL option to BaseUI on Native

* Update to latest LovyanGFX PR and use LGFX_SDL define

* Move SDL backend to native-sdl target
2025-08-20 12:51:14 -05:00
Austin
57e1725419 Revert "Update platformio/espressif32 to v6.12.0 (#7523)" (#7695)
This reverts commit 11309662a9.
2025-08-20 10:10:39 -04:00
renovate[bot]
11309662a9 Update platformio/espressif32 to v6.12.0 (#7523)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-20 09:08:14 -04:00
github-actions[bot]
890357d579 Update protobufs (#7693)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-20 05:53:20 -05:00
Wilson
f413c49555 Add Meshtiny device (#7676)
* Add Meshtiny device - nRF52 OLED upDown encoder

* Update platformio.ini

* Update platformio.ini

* Add GPS Exclude to Meshtiny.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-20 11:52:10 +08:00
Ben Meadors
c19f573b49 Fix TLS port bug on default mqtt validation 2025-08-19 20:10:47 -05:00
Jonathan Bennett
5de61b1a3d Only gate PKC behind the simradio CLI flag (#7681)
* Only gate PKC behind the simradio CLI flag

* Hide router.cpp simradio check behind #if ARCH_PORTDUINO
2025-08-19 14:15:05 -05:00
renovate[bot]
1c1462e776 Update meshtastic/device-ui digest to 8f5094b (#7633)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-19 14:14:12 -05:00
renovate[bot]
eb6ef1cbea Update meshtastic-esp8266-oled-ssd1306 digest to 9573abb (#7686)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-19 14:13:53 -05:00
renovate[bot]
9654f5b218 Update platform-native digest to 37d9864 (#7684)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-19 14:13:25 -05:00
Austin
68726a1b0e Docker: fix web assets location (#7683) 2025-08-19 14:06:43 -05:00
Ben Meadors
5b62bbe8e6 Disable for now 2025-08-19 11:30:19 -05:00
jake-b
e55084629a Move heartbeat response before !available guard. (#7672)
* Move heartbeat response before !available guard.

* fix formatting.

---------

Co-authored-by: Jake-B <jake-b@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-19 08:10:53 -05:00
Ben Meadors
1691e885f2 Display test results 2025-08-19 06:00:29 -05:00
renovate[bot]
2d7818797d Update platform-native digest to cd32f4e (#7662)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-19 05:43:10 -05:00
github-actions[bot]
f65e2c639e Update protobufs (#7679)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-19 05:35:25 -05:00
Jonathan Bennett
95200e8f6b Adds rfswitch on Portduino (#7663)
* Initial attempt to get rfswitch working on Portduino

* Make portduino_config global
2025-08-18 16:33:52 -05:00
github-actions[bot]
36e8dc74f4 Upgrade trunk (#7665)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-08-18 05:52:02 -05:00
Manuel
78c5309e9a apply 180 degree hw roration Indicator BaseUI (#7660) 2025-08-17 14:48:24 -05:00
Thomas Göttgens
9feb1d378e Support for T-Echo Lite, credits to @Szetya for doing all the heavy lifting! (#7636)
* Support for T-Echo Lite, credts to @Szetya for doing all the heavy lifting!
* move define to ini file
2025-08-17 13:37:12 +02:00
Jonathan Bennett
e5e8683cdb Don't update the NodeDB if the nodeinfo has a mismatching public key (#7652) 2025-08-17 05:56:06 -05:00
Jonathan Bennett
d538ad170c Add onboard message for devices with screens (#7655)
* Add onboard message for devices with screens

* Add message for TFT
2025-08-17 05:55:00 -05:00
Jonathan Bennett
c64c196778 Wait for lead up before enable longlong action (#7648) 2025-08-16 06:10:44 -05:00
github-actions[bot]
8e552a9f0c Upgrade trunk (#7626)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-08-16 05:57:20 -05:00
Ben Meadors
a02017a5c8 Remove JSON serialization from most NRF52 targets (#7640)
* Remove JSON serialization from most NRF52 targets

* Slin networking base down for NRF52 by removing syslog

* Update platformio.ini
2025-08-15 19:45:41 -05:00
github-actions[bot]
0046d957f1 Update protobufs (#7647)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-15 21:42:51 +02:00
Jonathan Bennett
4a241deb96 Thinknode button and backlight fixes (#7641)
* Thinknode button and backlight fixes

* Save backlight value between reboots
2025-08-15 14:41:21 -05:00
GUVWAF
8d5ae1d5d2 Fix marking LoRa transport mechanism (#7634) 2025-08-15 19:09:25 +02:00
Ben Meadors
e1e89a5e62 Don't include OLED fonts for international character sets by default (#7639) 2025-08-15 09:03:21 -05:00
Ben Meadors
a7be93449e Spacing 2025-08-15 09:00:09 -05:00
Ben Meadors
c8694f9f2d Fix Tracerouter warnings (#7637)
* Static cast to avoid signed comparison

* Another one
2025-08-15 07:03:14 -05:00
Austin
062168cd42 Docker: Update Debian images to trixie (#7621) 2025-08-15 06:19:49 -05:00
Ford Jones
1877a2c531 Prompt user to select destination upon launch of canned message module (#7624)
Co-authored-by: Jason P <applewiz@mac.com>
2025-08-15 05:31:11 -05:00
Austin
52f0e5a3db Fix 'buildroot' target (OpenWRT) (#7620) 2025-08-14 12:31:25 -05:00
github-actions[bot]
ac8c372349 Upgrade trunk to 1.25.0 (#7432)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-08-13 06:26:08 -05:00
github-actions[bot]
1bfa429c38 Automated version bumps (#7614)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-12 19:40:35 -05:00
Jonathan Bennett
ddd149945a More spoof remediation (#7612)
* More spoof remediation

* Fix signed comparison error

* Only fire self-bound messages into the routing module

* Update src/mesh/MeshModule.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* String const

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-12 16:08:03 -05:00
Constantine
e3dd8164a4 nRF52840 promicro deepsleep fix with some additions (#7407)
* Pro-Micro DeepSleep Quick Fix
It is noticed that some nRF52840 boards (pro-micro in particular)
stopped waking up from the deep sleep state (shutdown state)
with a press of a button.
The problem is in a Serial1.end() call.

* Clear GPREGRET before setting
There are some troubles with that register:
it is recommended to clear it with 0xFF mask
and only after that perform a setting.

* Pro-Micro button SENSE signal
Added SENSE signal on the user button.
It is explicitly enabled now for this platform.

* nRF52 pre-sleep main serial check
Added another usage check for the main Serial.
It could save some nerves in case the port is not in use by any means.
Applied trunk fmt to the file.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-12 11:23:34 -05:00
Max
9b8149f14e Adding medium and large RU fonts. Fixing RU string width calculation (#7498)
* Adding  medium and large RU fonts. Fixing string width calculation for RU font

* Update src/graphics/draw/MessageRenderer.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-08-12 07:22:37 -05:00
renovate[bot]
05f1518951 chore(deps): update actions/download-artifact action to v5 (#7559)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-11 21:47:21 -05:00
Jonathan Bennett
e26de85b5f Mark meshPackets based on which interface received. (#7589) 2025-08-11 21:47:04 -05:00
renovate[bot]
a2df80e833 chore(deps): update actions/checkout action to v5 (#7605)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-11 20:58:54 -05:00
Ben Meadors
db238ef524 Log when this happened 2025-08-11 19:49:35 -05:00
Jonathan Bennett
f2b935f48f Stop the bleeding with malicious NodeDB overwrites (#7596) 2025-08-11 15:52:28 -05:00
Thomas Göttgens
e69da71d4e reorder for correct recognition (#7604) 2025-08-11 11:53:01 +02:00
Manuel
be1a724ab4 Merge branch 'master' into arduino-esp32-v3.2 2025-08-10 00:11:27 +02:00
mverch67
04f98cf20e update config; include wifi 2025-08-09 23:49:16 +02:00
mverch67
75a1a41d8c fix duplicate Syslog classes 2025-08-09 23:43:45 +02:00
Ben Meadors
7505fe7a7c Update device-ui deps 2025-08-09 10:38:09 -05:00
Ben Meadors
f6857f1bcb Heartbeat has a nonce now 2025-08-09 10:17:08 -05:00
github-actions[bot]
7fe2c74139 Update protobufs (#7588)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2025-08-09 09:14:22 -05:00
github-actions[bot]
be60f9612e Update protobufs (#7587)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-09 08:14:04 -05:00
github-actions[bot]
2de9f015b1 Automated version bumps (#7586)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-08-09 08:12:24 -05:00
Ben Meadors
c1f4f79d4a Revert "128row display (#7511)"
This reverts commit d1f3c3c982.
2025-08-09 06:11:56 -05:00
renovate[bot]
7b874cf597 chore(deps): update meshtastic/device-ui digest to d044c01 (#7578)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-08 11:31:49 -05:00
mverch67
344efa6675 update device-ui (fix native compilation) 2025-08-08 17:29:02 +02:00
Jonathan Bennett
8568b56ac6 Fix a crash on Native reboot (#7570) 2025-08-07 12:28:01 -05:00
renovate[bot]
f2a880f813 chore(deps): update adafruit shtc3 to v1.0.2 (#7557)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-08-07 13:56:17 +02:00
Jonathan Bennett
691327b2db Initial support for the ThinkNode M5 (#7502)
* Initial support for the ThinkNode M5

* Update variants/esp32s3/ELECROW-ThinkNode-M5/platformio.ini

Co-authored-by: Austin <vidplace7@gmail.com>

* Cleanup variant.h for Elecrow Thinknode M5

* Properly detect battery voltage

* Turn backlight off when screen sleeps

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-08-07 06:28:15 -05:00
oscgonfer
a23c58c10a Avoid acquiring lock twice (#7555)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-06 06:38:36 -05:00
mverch67
e919b3da9c cleanup 2025-08-06 10:36:04 +02:00
Manuel
155783c782 Merge branch 'master' into arduino-esp32-v3.2 2025-08-06 09:15:44 +02:00
Jonathan Bennett
27c6b24e3a Rather than mysteriously rebooting, regenerate the keys and infrom the user. (#7558) 2025-08-05 19:53:25 -05:00
Manuel
76bcd05259 Merge branch 'master' into arduino-esp32-v3.2 2025-08-06 00:09:37 +02:00
mverch67
2d29cbc34c device-ui: use fast mem for critical draw functions 2025-08-06 00:08:54 +02:00
mverch67
2b77864192 fix attachInterrupt issue 2025-08-05 23:59:37 +02:00
mrab
384436e937 fix: ina226 was not calibrated during init (#7547)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-08-05 06:34:52 -05:00
Jason P
eb30aae486 Create better log message for users (#7548) 2025-08-04 16:32:27 -05:00
Jason P
079286da04 Only toggle screen wake, don't break banners (#7545)
* Only toggle screen wake, don't break banners
* Fix code - only needed a small line change
2025-08-04 19:33:45 +02:00
tg-mw
0130899b3b Fix Melopero RV3028 RTC Settings (#7524) 2025-08-04 18:42:39 +02:00
Thomas Göttgens
d1f3c3c982 128row display (#7511)
* Fix 128 row monochrome display
* trunk fmt
* fix assignment
2025-08-04 17:25:31 +02:00
mverch67
10aa4cbfee don't exclude I2C 2025-08-02 19:07:34 +02:00
mverch67
c24a174490 don't exclude I2C 2025-08-02 19:05:07 +02:00
Manuel
3e5e19efec Merge branch 'master' into arduino-esp32-v3.2 2025-08-01 21:50:40 +02:00
mverch67
ea2c247024 pr: update device-ui for indicator 2025-08-01 21:45:40 +02:00
mverch67
0b463b6443 update references to fixed io expander 2025-08-01 20:54:57 +02:00
mverch67
7d3c804279 update wdt task 2025-08-01 20:54:15 +02:00
mverch67
1fa7d9f40e try-fix watchdog trigger 2025-08-01 09:23:01 +02:00
Jacob Powers
3b6eefa8bb feat: event mode - limit smart position updates to at most every 5m (#7505)
* feat: event mode - limit smart position updates to at most every 5m

* fix: convert 600 to 600000ms for 5min threshold

* fix: correct 5min threshold to 300000ms

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-31 21:45:34 -05:00
HarukiToreda
5107531425 Remember destination fix (#7427)
* T-watch screen misalignment fix

* Trunk fix

* Rember Last Receipient Node or channel

When a new freetext or preset message is sent and a destination is selected, the next message would forget the previously selected destination and would need to be selected again. With this fix it will remember the last destination selected until changed again.

* Fix for reply function to remember last messaged

* trunk check

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Jason P <applewiz@mac.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-31 07:36:03 -05:00
Ben Meadors
88655ffc44 Move BLE toggle menu option and add confirmation for canned messages in L1 (#7516)
* Move bluetooth to system menu and add confirmation for canned messages

* Cruft

* Handle else

* Warn

* Fixed screen reset
2025-07-31 07:34:41 -05:00
mikecarper
10bd10b9d1 bugfix Syntax error: "(" unexpected in device-update.sh (#7514)
* Update device-update.sh to use /bin/bash

* Update meshtasticd.postinst to use /bin/bash

* Update meshtasticd.postrm to use /bin/bash
2025-07-31 06:02:09 -05:00
renovate[bot]
956a0f102b Update platformio/ststm32 to v19.3.0 (#7512)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-31 06:00:58 -05:00
Tom Fifield
bdedd0e1fe Airoha GPS - ignore estimated fixes (#7429)
TinyGPS Fix Quality has this information:
				0 - fix not available,
				1 - GPS fix,
				2 - Differential GPS fix (values above 2 are 2.3 features)
				3 = PPS fix
				4 = Real Time Kinematic
				5 = Float RTK
				6 = estimated (dead reckoning)
				7 = Manual input mode
				8 = Simulation mode

the previous Airoha code would allow quality >0 , which includes
estimated positions. These wouldn't be passed through to the mesh
due to other checks, but would affect the Airoha GPS_FIX_HOLD_TIME
calculations.

Changes the calculation to 1 >= quality <=5 .
2025-07-31 12:21:10 +10:00
mverch67
aa7abb1d3e use ng-io-expander 3.3.0 2025-07-30 23:37:09 +02:00
mverch67
effb454af0 comment out assert on watchdog creation 2025-07-30 23:24:31 +02:00
Tom Fifield
4c901033b2 Workaround Webserver needing to stay up while Wifi is turned off (#7484)
Expertly triaged by @philon- , turning off wifi using the HTTP API
did not work. That was because we only served the HTTP API if Wifi
was deemed to be available, but mid-way through turning it off Wifi
was still available, but the configuration we were checking said it wasn't.

This patch introduces an additional way the system can determine if Wifi
is available, by referring to the WiFi.status(). This means that in that
limbo state where Wifi has been set to be turned off, but the configuration
has not been saved and it is still up, the HTTP API will stay up long enough
to save the configuration.

Fixes https://github.com/meshtastic/firmware/issues/6965
2025-07-30 07:47:00 -05:00
Ben Meadors
7d926da98c Heartbeat response (#7506)
* Heartbeat response

* Move it

* Add debug log for visibility
2025-07-30 07:40:27 -05:00
github-actions[bot]
1b793d1f23 Update protobufs (#7508)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-30 06:29:03 -05:00
mverch67
27bb42ed3b git ignore new toolchain tmp files 2025-07-29 22:08:07 +02:00
mverch67
05dc8caed8 platformio updates 2025-07-29 22:07:18 +02:00
mverch67
f3734d407d remove OTA partition for now until fw size got smaller again 2025-07-29 22:06:21 +02:00
mverch67
bc8e509a8c fix copy&paste 2025-07-29 22:05:29 +02:00
mverch67
74d0472834 fix merge again 2025-07-29 21:55:34 +02:00
mverch67
5afc43ebc1 try-out WDT timer issue --> needs revert 2025-07-29 21:07:28 +02:00
mverch67
6cdb92b7a8 fix merge error 2025-07-29 21:06:19 +02:00
Thomas Göttgens
0e1872398a Merge remote-tracking branch 'remotes/origin/master' into arduino-esp32-v3.2
# Conflicts:
#	arch/esp32/esp32.ini
#	src/graphics/draw/MenuHandler.cpp
#	src/modules/Modules.cpp
#	variants/esp32s3/seeed-sensecap-indicator/platformio.ini
2025-07-29 13:06:13 +02:00
Chloe Bethel
b5a8e8f51b DEBUG_MUTE correctness (#7492)
* treewide: make 'ifdef DEBUG_PORT' guards also take into account DEBUG_MUTE

* stm32wl: Add a guard against having debug prints turned on without PIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF defined

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-29 08:51:38 +10:00
Ben Meadors
cc5d00e211 Core portnums rebroadcast mode whitelist instead of blacklist (#7487) 2025-07-28 12:37:37 -05:00
Ben Meadors
1a8ab2aadc NodeDB count on MyNodeInfo for client progress reporting (#7489) 2025-07-28 12:23:59 -05:00
Thomas Göttgens
608fdc6f52 Santa may be checking his list twice, but we only need this in the platformio.ini (#7490) 2025-07-28 09:47:46 -05:00
rradillen
1d8638b47d [7353] Add all telemetry fields to json output (#7363)
* Serializer bugfix

* Remove duplicate test

* fix tests

* fix float precision issues

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-28 09:23:04 -05:00
Ben Meadors
3ecff48722 Set firmware edition (for events) from userprefs (#7488)
* Set firmware edition (for events) from userprefs

* Spaces in the right places
2025-07-28 07:31:33 -05:00
mikecarper
aa3b14ce72 bugfix Add rssi and snr to the store and forward code. (#7462)
* Update StoreForwardModule.cpp

* Update StoreForwardModule.h

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-27 20:03:01 -05:00
Ben Meadors
28aeb0f09e Validate Serial config console override modes (#7470)
* Validate serial config console override modes

* Update src/modules/SerialModule.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Disable

* Guard serial module

* Guards

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-07-26 19:55:54 -05:00
github-actions[bot]
7c5e2c5393 Update protobufs (#7473)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-26 16:21:49 -05:00
Tom Fifield
df8b629c2c Clear position on GPS deactivation, unless using fixed position (#7464)
* Clear position on GPS deactivation, unless using fixed position

As reported by @dreimal8 , and confirmed by @tuxmobil , when using
and then subsequently disabling GPS the last position retrieved from
the GPS was stored and continued to be broadcast.

This change introduces a check to see if we are transitioning from
GPS Enabled to GPS Disabled or Not Present. If we are, and fixed
position is not in use, then we clear the local position.

This will prevent inaccurate and undesired position broadcasts for those
who disable their GPS.

Fixes https://github.com/meshtastic/firmware/issues/7228

* Update triple click to also clear position

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-26 08:09:26 -05:00
Ben Meadors
a506dc6b65 Fix MQTT config bugs (#7446)
* Fix mqtt config bugs

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Add client notification

* Verbiage

* Update src/mqtt/MQTT.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/mqtt/MQTT.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/mqtt/MQTT.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/mqtt/MQTT.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Remove test that is no longer true

* This test no longer exists

* Fix client notification crap

* Suppress false positive

* Revert "Suppress false positive"

This reverts commit bead96eaee.

* Try macro exclusion

* Derp

* Fix

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Jason P <applewiz@mac.com>
2025-07-26 05:38:24 -05:00
Iris
fc1e6ccb8c Rename Platformio.ini to platformio.ini (#7468) 2025-07-26 05:13:02 -05:00
Iris
bbc638ab82 Create Platformio.ini (#7450) 2025-07-25 15:36:37 -05:00
Austin
4f57a2e248 Build RP2350 (Pi Pico 2) (#7441) 2025-07-25 22:25:50 +02:00
Jason P
4c6db2c5bd Fix MHz label (#7455) 2025-07-25 08:10:35 -05:00
Pedro
bbe548bc98 Add BRT3 timezone option to TZPicker menu (#7438) 2025-07-24 22:42:42 -05:00
Pedro
d1fbf65c5d Fix timezone definition for UTC in TZPicker function (#7442) 2025-07-24 21:57:40 -05:00
Wilson
7a4a915312 Add Trace Route on BaseUI (#7386)
* Add TraceRoute function to menus and modules to support node path tracing

* Adjust text spacing and line wrapping logic in trace route result result.

* Add HAS_SCREEN for TraceRouteModule drawFrame.

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-24 17:23:45 -05:00
Austin
4f895f744b Take control of our PRs! (#7445) 2025-07-24 06:13:23 -05:00
Austin
66a831dfa8 Actions: Combine embedded builds // split by variant subdir (#7417) 2025-07-23 13:41:08 -04:00
Pedro
516597a73e Add NP_865 and BR_902 to device menu (#7434) 2025-07-23 14:56:22 +02:00
Tom Fifield
4eb6c9fb8e Add BR_902, Brazil 902MHz-907.5MHz (#7399)
As reported by @barbabarros , the Brazilian government has specific support for LoRA[1] across multiple frequencies[2][3].
We currently support Brazil through the ANZ/AU915 band. However, Brazil also has another frequency available for use:
902 - 907.5 MHz , 1W power limit, no duty cycle restrictions

[1]  https://sistemas.anatel.gov.br/anexar-api/publico/anexos/download/a028ab5cc4e3f97442830bba0c8bd1dd 
[2] 
https://informacoes.anatel.gov.br/legislacao/resolucoes/2025/2001-resolucao-772 
[3] https://informacoes.anatel.gov.br/legislacao/atos-de-certificacao-de-produtos/2017/1139-ato-14448#item10

Protobuf patch: https://github.com/meshtastic/protobufs/pull/737

Fixes https://github.com/meshtastic/firmware/issues/3741

Co-authored-by: Austin <vidplace7@gmail.com>
2025-07-23 14:55:17 +02:00
saiman pokhrel
46e2ae8860 Add Nepal 865 MHz to 868 MHz (#7380)
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-07-23 14:54:43 +02:00
renovate[bot]
54c0cbeb66 Update meshtastic/device-ui digest to c75d545 (#7435)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-23 07:46:34 -05:00
Jonathan Bennett
82ddf4732a Deprecate disable_triple_click config (#7425) 2025-07-23 05:57:17 -05:00
Austin
ed0cdefb44 Use platformio-core to build the matrix (#7424)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-22 21:01:29 -05:00
Tom Fifield
8836be0f47 AG3335 GPS: Use NAVIC in India/Nepal, L1+L5 elsewhere. (#7413)
As determined by @b8b8 , enabling NAVIC meant the more modern L5 GPS
signal was not used (L1 GPS is always available).

NAVIC, India's GNSS, probably provides the best coverage in India and
the neighbouring region. However, outside of NAVIC's coverage area, L5
GPS is highly desirable.

This patch amends the AG3335-family GPS configuration to enable L5 GPS
coverage by default. If the Lora region is set to India or Nepal,
NAVIC will be enabled instead.
2025-07-22 21:00:34 -05:00
github-actions[bot]
96f63f3945 Update protobufs (#7422)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-22 13:49:53 -05:00
Jonathan Bennett
d80dcd6afd Fix InkHUD shutdown code 2025-07-22 08:49:33 -05:00
Jonathan Bennett
2087629a47 Add a verbose mode flag to meshtasticd (#7416) 2025-07-22 06:22:23 -05:00
github-actions[bot]
878d68c5ef Upgrade trunk (#7420)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-07-22 06:22:07 -05:00
Jonathan Bennett
86960cdb1d Moves the shutdown thread into the Power class, make shutdown and reboot private (#7415) 2025-07-22 06:21:51 -05:00
Jonathan Bennett
fff12979a2 Set canned_message.enabled to true when setting defaults (#7414)
* Set canned_message.enabled to true when setting defaults

* Re-split canned messages on update
2025-07-21 19:31:07 -05:00
Austin
6c12baf4ed Migrate remaining variants to new dir structure (#7412) 2025-07-21 19:28:14 -05:00
whywilson
29449a71d4 When outputting RTTTL ringtones, you can still hear a periodic buzzing sound. This problem is fixed in this commit. 2025-07-21 14:44:41 -05:00
Austin
9b983b6487 nRF52840: Migrate variants to new structure (#7396) 2025-07-21 14:13:02 -05:00
Austin
806bfa54b5 Renovate: Use github-tags for XPowersLib updates (#7411) 2025-07-21 14:04:46 -05:00
Austin
920aeeeba5 Actions: pull_request_target is fun (#7398) 2025-07-21 14:03:13 -05:00
github-actions[bot]
32418448de Update protobufs (#7410)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-07-21 20:32:55 +02:00
Manuel
b3525c2569 T-Deck Pro support (#6936)
* initial draft

* fix touchscreen

* fix touchscreen

* optimize GPS

* battery management

* cleanup comments

* enable vibration motor

* refactored TCA8418Keyboard

* update HW_VENDOR id

* manual fixes after merge

* fix keyboard/BQ27220 detection

* add BQ27220

* modify charge voltage and current

* update XpowerLib

* design capacity

* try-fix charge behavior

* improve Vbus detection

* moved variant into esp32s3 folder

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2025-07-21 19:33:24 +02:00
github-actions[bot]
19dc2873c5 Upgrade trunk (#7400)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-07-21 20:07:45 +10:00
Austin
25b8d9b0ca ARCH_STM32*WL* macro fix (#7397) 2025-07-20 23:30:52 -04:00
Ben Meadors
8aef3c44f4 Text message rate limiting should return routing error instead (#7365)
* Text message rate limiting should return routing error instead

* Proper rooting

* Update PhoneAPI.cpp

* Update PhoneAPI.cpp
2025-07-20 20:12:10 -05:00
Ben Meadors
8345c21eff STM32 doesn't play 2025-07-20 20:02:32 -05:00
Jonathan Bennett
36b94cf823 Unify the shutdown proceedure (#7393)
* Unify the shutdown proceedure

* Don't double save nodeDB on shutdown

* Re-tool button shutdown to better correspond to tones

* Beep then save

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-20 18:53:40 -05:00
Austin
475cfe4af2 ESP32s3: Migrate variants to new structure (#7343) 2025-07-20 16:47:37 -05:00
Thomas Göttgens
b851b15a73 fix UDP builds on nRF (#7394)
* fix UDP builds on nRF
* fix rp2040 too
2025-07-20 23:13:50 +02:00
github-actions[bot]
73347c2542 Update protobufs (#7395)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-20 15:03:56 -05:00
Jason P
bc9023399d Restore High Resolution Hour Hand (#7392)
* Restore High Resolution Hour Hand

* Drop the int16_t
2025-07-20 13:43:54 -05:00
Thomas Göttgens
a9c9b96eb6 UDP for RAK4631 Eth Gw and the t-eth-elite. Solves #7149 (#7385)
* UDP for RAK4631 Eth Gw and the t-eth-elite. Also enable IP output on Portduino. Solves #7149

* Copilot suggestion

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix portduino build

* initialize local port

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-20 06:22:00 -05:00
Austin
1c2a3c620f STM32: Migrate variants to new structure (#7389) 2025-07-20 06:21:17 -05:00
Austin
9313d04726 RP2040/RP2350: Migrate variants to new structure (#7345) 2025-07-20 06:20:57 -05:00
github-actions[bot]
44518fea14 Upgrade trunk (#7349)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-07-20 06:20:07 -05:00
Jonathan Bennett
91049d0db3 Misc cppcheck fixes (#7370) 2025-07-20 06:19:45 -05:00
Austin
855514b4f3 ESP32c3: Migrate variants to new structure (#7342) 2025-07-19 19:55:33 -05:00
Austin
974741a366 ESP32: Initial sort variants by platform (#7340) 2025-07-19 18:41:59 -05:00
Austin
5d98f7e307 Actions: Enforce PR labels (#7379) 2025-07-19 11:38:05 -05:00
github-actions[bot]
3ca45ae99c automated bumps (#7383)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-19 10:41:01 -05:00
Ben Meadors
cf574c71d8 Fix build 2025-07-18 09:24:34 -05:00
Tom Fifield
abe0a34fc0 Add additional Epoch check for time set (#7375)
We have two perhapsSetRTC functions, which are called to set the time.

The one with 3 parameters had a helpful check to reject an invalid time,
by comparing the time from the source against when the firmware was compiled.
The one with 2 parameters, which is called from the GPS lookForTime did not.

As a result, certain GPS with bad time handling could set a time that was
in the past.

This patch adds the same epoch check code to the other perhapsSetRTC method.

Fixes https://github.com/meshtastic/firmware/issues/7364
2025-07-18 05:49:19 -05:00
mverch67
f25544c7e0 updated platform references 2025-07-18 03:16:54 +02:00
mverch67
f40b2ba153 temp workaround for nimble compile 2025-07-18 03:14:45 +02:00
mverch67
5033fd1f9f fix MESHTASTIC_EXCLUDE_I2C compile errors 2025-07-17 12:40:02 +02:00
Jason P
71b6508ad3 BaseUI Updates (#7358)
* Calculate the length of the right string and use it

* Improve readability of Version Number

* Prevent negative message IDs and proactively favorite DM'd nodes

* Patch up Remove Favorite functionality

* Fix warnings for TFT_MESH_* and hasSupportBrightness

* Fix warning around casting variables

* Correct Favorite Node Behavior to rebuild favorite nodes when updated.

* Resolve bool kb_found issue not working for second discovery keyboards

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-07-16 19:44:23 -05:00
Thomas Göttgens
55fc4fcd90 clean up double i2c init/scan code (#7359) 2025-07-17 00:40:29 +02:00
Jonathan Bennett
c3b2b474c6 Drop NodeInfo packets if the is_licensed bit doesn't match owner (#7361) 2025-07-16 16:05:34 -05:00
mverch67
cd170fb011 boot_freq 120MHz 2025-07-16 20:50:25 +02:00
Ben Meadors
39716ed1ba Fix L1 EInk HWModel (#7346) 2025-07-14 21:14:07 -05:00
Jason P
625a529f6c Message frame New Message Options and Clock / TDeck / Brightness Refinements (#7344)
* Clock updates and some TDeck corrections

* TDeck Brightness Works in TFT Builds

* Remove HAS_TFT from enabling Brightness, disable Brightness for TDeck

* Add default textMessage frame actions and adjust SharedUIDisplay

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-14 20:59:22 -05:00
Ben Meadors
31d56c16d5 Map report should work over devices which do not have network hardware (with client proxy) (#7341)
* Map report should work over devices which do not have network hardware (with client proxy)

* Fix else
2025-07-14 20:13:34 -05:00
Austin
5776385e8c STM32 PlatformIO cleanup (#7339) 2025-07-14 12:52:21 -05:00
mverch67
fa169a5e43 compare IDF versions 2025-07-14 17:14:21 +02:00
github-actions[bot]
8f10de5684 [create-pull-request] automated change (#7338)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-14 09:46:43 -05:00
Daniel.Cao
e864fcf9a8 feat: add support for RAK Wismesh Tag hardware platform (#6853)
* add new platform rak_wismeshtag
* Remove RTC and Ethernet definitions from variant.h
* Remove unused EINK and Ethernet definitions from variant.h and platformio.ini
* Add WISMESH_TAG hardware model definition in architecture.h and update build flags in platformio.ini
* Remove unused build flags and dependencies
---------
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: daniel <daniel.cao@rakwireless.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2025-07-14 16:29:42 +02:00
Ben Meadors
86af5f5252 Trunk 2025-07-14 05:44:29 -05:00
Quency-D
daa1d582cb The screen display of the heltec wireless tracker is abnormal. (#7337)
The screen of the heltec wireless tracker uses the same power source as the GPS. If the GPS turns off the power during the screen shutdown period and then turns on the power, the screen will not function properly. So initialize the screen every time it starts.
2025-07-14 05:43:25 -05:00
github-actions[bot]
f197f0e5ec Upgrade trunk (#7336)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-07-14 05:12:52 -05:00
Chloe Bethel
3599ca6845 Add heap info via standard mallinfo() function for STM32 (#7327)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-14 05:12:38 -05:00
Chloe Bethel
1be4fc5ae9 GPS for STM32WL (#7297)
* Enable GPS for Wio-E5 variant on Serial2

* Add ability to override GPS serial port using GPS_SERIAL_PORT, and make RAK2560 use it.

* Don't try to send ATAK packets if ATAK is disabled, +4k flash
2025-07-14 05:12:26 -05:00
Thomas Göttgens
ac3e5684d6 get git url part from local repo (#7331) 2025-07-14 05:11:26 -05:00
Austin
29cca4d621 Revert "Actions: Move all Linux packaging into subdir (#7332)" (#7334)
This reverts commit f3ff80963a.
2025-07-13 20:54:52 -04:00
Austin
f3ff80963a Actions: Move all Linux packaging into subdir (#7332) 2025-07-13 20:48:17 -04:00
Austin
45e428eb25 PPA: Add Ubuntu Questing (25.10) to daily builds (#7329) 2025-07-13 16:22:42 -04:00
Thomas Göttgens
16d2650236 add pioenv to version string in debug log (#7328) 2025-07-13 19:16:14 +02:00
TSAO
2ecbf704d0 Improve OLED UI Responsiveness and Force Redraws for Canned message module (#7324)
* No delay between UI frame rendering for OLED

* force redraw the display

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jason P <applewiz@mac.com>
2025-07-13 08:28:05 -05:00
Styne13
5e28ee6d1e NodeDB.cpp: Fix iOS bluetooth crash by ensuring UINT32_MAX is not used (#7312)
Signed-off-by: Marcel <6253936+Styne13@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-13 06:26:35 -05:00
Neil Hanlon
622023de8b fix(device-update.sh): safely filter args without breaking parsing (#7305)
The previous method of removing `--change-mode` from the argument list used a
string (`NEW_ARGS`) and `eval set -- $NEW_ARGS` to reconstruct the positional
parameters. This was both unsafe and incorrect.

Because `NEW_ARGS` was built using quoted literal `$arg` strings instead of the
actual values, it resulted in all filtered arguments being set to the same last
value of `$arg`. This caused `getopts` to receive incorrect input and silently
fail to parse options like `-p` and `-f`, leading to broken behavior and unset
variables (e.g., `ESPTOOL_CMD` never got a port).

This patch rewrites the logic to use an array (`NEW_ARGS+=("$arg")`), and
resets positional parameters via `set -- "${NEW_ARGS[@]}"`. This preserves
argument integrity and avoids the unsafe use of `eval`.

Example of the broken behavior before this fix:

  ./device-update.sh -p /dev/ttyACM0 -f firmware.bin

Resulted in:

  set -- firmware.bin firmware.bin firmware.bin firmware.bin

Now:

  set -- -p /dev/ttyACM0 -f firmware.bin

as expected.

Signed-off-by: Neil Hanlon <neil@shrug.pw>
2025-07-13 06:19:58 -05:00
Andrew Yong
b49e59b904 xiao_ble README.md updates (#7283)
* docs(xiao_ble): Simplify building and flashing instructions

- **Update Bootloader** - deleted this section, as Meshtastic now builds-in a compatible SoftDevice
- **PlatformIO Environment Preparation** - deleted this section, as Meshtastic now builds-in a compatible SoftDevice
- **Build Meshtastic** - simplified it greatly by referring to Meshtastic documentation
- **Flash the firmware to the Xiao BLE** - simplified it greatly as Meshtastic now builds firmware.uf2; added some observations for a succesful flash

Light cleanup of Markdown and renumbering of sections.

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Replace some HTML with Markdown, cleanup Markdown

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Update SX126X_TXEN definition location

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Fresher information about E22 modules

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Instructions for E22...M33S modules

Also re-order the Build section to come after the Wiring section since the build instructions require special attention if the wiring/modules differ from the variant's expected pins/module.

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Rename all XIAO BLE to XIAO nRF52840

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): Remove note about Linux since shell script is gone

Signed-off-by: Andrew Yong <me@ndoo.sg>

* docs(xiao_ble): trunk fmt and fix links

Signed-off-by: Andrew Yong <me@ndoo.sg>

---------

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-07-13 06:17:50 -05:00
Andrew Yong
0133c5dc9e feat: New variant esp32c3_super_mini (#7133)
https://www.espboards.dev/esp32/esp32-c3-super-mini/

DIY build by @AntonKartajaya on Meshtastic Discord and a PCB version WIP by https://github.com/NomDeTom.

- I2C
  - I2C_SDA: 1
  - I2C_SCL: 0
  - OLED: SSD1306
- GPS
  - GPS_RX_PIN: 20
  - GPS_TX_PIN: 21
- Button
  - BUTTON_PIN: 9
- SPI
  - SCK: 10
  - MISO: 6
  - MOSI: 7
  - CS: 8
- LoRa: SX1262
  - LORA_RESET: 5
  - LORA_DIO1: 3
  - LORA_RXEN: 2
  - LORA_BUSY: 4

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-07-13 06:12:24 -05:00
Andrew Yong
fd414ed149 feat: DIY Seeed XIAO nRF52840 + EBYTE E22 variants, pin-compatible with Wio-SX1262 kit (#7105)
These DIY builds are functionally similar to the legacy xiao_ble variant, but use a pinout harmonized with the officially-supported XIAO nRF52840 & Wio-SX1262 Kit for Meshtastic (SKU 102010710).

An additional E22-900M33S variant is provided to ensure SX1262 transmit power is set below the maximum PA input for that module, to avoid damaging it.

- seeed_xiao_nrf52840_e22_900m30s:
  - XIAO nRF52840 + EBYTE E22-900M30S
  - EBYTE E22 pinout matching Wio-SX1262 (SKU 113010003)
  - I2C
    - SDA: D6
    - SCL: D7
  - User button: D0
  - Gain is programmed in firmware - user Tx power setting is the desired final output power
- seeed_xiao_nrf52840_e22_900m33s:
  - XIAO nRF52840 + EBYTE E22-900M33S
  - EBYTE E22 pinout matching Wio-SX1262 (SKU 113010003)
  - I2C
    - SDA: D6
    - SCL: D7
  - User button: D0
  - Gain is programmed in firmware - user Tx power setting is the desired final output power

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-07-13 15:58:01 +08:00
Austin
77768e9023 Remove Ubuntu oracular (#7322) 2025-07-13 12:39:20 +08:00
Austin
86be2ac12f userPrefs: Set default ringtone nag time (#7314) 2025-07-12 16:26:25 -05:00
Jonathan Bennett
4342d51f5a Bump Framework-native and set version string. (#7317) 2025-07-12 14:44:58 -05:00
Austin
41f52a6566 Build: Update platformio with pkg install (#7315) 2025-07-12 14:35:57 -05:00
Jonathan Bennett
cb47325f08 Seesaw Rotary (#7310)
* Initial add of Adafruit seesaw encoder

* Fully wire up seesaw

* Trunk

* Add #include configuration.h back to unbreak logging

* Tryfix the dumb compilation error

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-12 12:36:44 -05:00
Austin
deed6cd96a STM32: Properly ignore OneButton (#7311) 2025-07-12 06:27:45 -05:00
renovate[bot]
05c32c99e4 Update meshtastic/device-ui digest to 86a09a7 (#7308)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-11 18:46:29 -05:00
Jonathan Bennett
1ca0584ba0 Add first config override for Native (#7306) 2025-07-11 16:09:59 -05:00
Ben Meadors
5ae8021aa6 I'm dumb 2025-07-11 08:28:21 -05:00
Ben Meadors
9798a91e7b Delete ringtone.proto file for factory reset (#7303) 2025-07-11 08:22:50 -05:00
Austin
e9a551ae90 Load ringtone from userPrefs (#7298)
* Load ringtone from userPrefs

* Apply suggestion from @Copilot

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-07-11 08:09:46 -05:00
Mictronics
d42bde135f Support native configuration Waveshare Pico LoRa module on Orange Pi Zero3 (#7295)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

* Remove static declaration for admin keys from userPrefs.h. Load hard coded admin keys in case config file has empty slots.

* Removed newlines from log.

* Fix issue #5665.

* Fix build for Pico2 RP2350 platform.

* Enable Wifi client on Pico2W.

* Use correct processor on Pico2.

* Fix deprecated warning.

* Update platform and framework for RP2350.

* Added Pico2W variant including Wifi support.

* Fix typo in used variant.

* Remove obsolete define.

* Fix for native Linux build.

* Simplify RP2350 platform tag reference.

Co-authored-by: Austin <vidplace7@gmail.com>

* Cast user prefs strings.

* Update to last successfully building platform package.

* Define I2C GPIOs to ensure usage of both ports. Possibly fixes #5361

* RAK11310 support for RAK12002 RTC added.

* Update platform and framework packages to 4.4.3.

* Use RP2040 base platform and framework package. Use RAK11300 board definition in arduino-pico framework.

* Use RAK11300 board definition in arduino-pico framework.

* Fix build when MESHTASTIC_EXCLUDE_GPS is defined.

* Added configuration for Waveshare Pico LoRa module in combination with Orange Pi Zero3.

* Equal to upstream master.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-07-11 06:54:37 -05:00
github-actions[bot]
72f3d19d5a Upgrade trunk (#7278)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-07-11 06:51:33 -05:00
renovate[bot]
f7ecf141b5 Update meshtastic/device-ui digest to 404c6e0 (#7302)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-11 06:45:18 -05:00
todd-herbert
1063ef9034 Shorter audio feedback for InkHUD buttons (#7301) 2025-07-11 17:30:48 +12:00
Jonathan Bennett
13ac182142 Pick up nodedb.h in Screen.cpp regardless of HAS_SCREEN state 2025-07-10 23:19:58 -05:00
Jonathan Bennett
4bab148e3b Make the shouldWake function always available, and remove the bool (#7300) 2025-07-10 22:51:43 -05:00
Jason P
be75f11156 Update Screen Wake Default Behavior (#7282)
* feat(display): enable screen wake on received messages

* feat(menu): add Screen Wakeup option in system menu

* feat(ui): update wake on message configuration and refactor save logic

* feat(TextMessageModule): conditionally trigger screen wake on received message

* Refactoring system menu options for notification and screen.

* Fix MUI options in the system menu.

* Build out Reboot/Shutdown Menu and consolidate options within it

* Trunk fixes

* Protobuf ref

* Revert generated files

* Update plumbing for screen_wakeup_menu

* Begin work on crafting a method to stop screen wake for received messages

* SharedUIDisplay.cpp doesn't need ExternalNotificationModule.h

* Stop screen wake if External Notification is enabled

* Removing extra log lines

* Add role and battery state checks for not waking screen. Menu updates to resolve some Back options not being linked

* Resolve some additional merge conflict related issues

* Shouldn't throttle the power menu

* Finalize renames of some menus

* Flip Flop MUI Menu to avoid accidental clicks

* NULL check for powerStatus

* Remove "Wakeup" eNum

* Update src/graphics/Screen.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* CoPilot was close this should fix the builds

---------

Co-authored-by: whywilson <m.tools@qq.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-07-10 19:49:15 -05:00
renovate[bot]
093868f3ed Update dorny/test-reporter action to v2.1.1 (#7284)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-10 17:12:39 -05:00
renovate[bot]
fe534eae37 Update Adafruit BusIO to v1.17.2 (#7277)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-10 17:12:25 -05:00
Kongduino
1aad442ccc Update platformio.ini (#7289)
The link to the product should point to the vendor's website, not a random distributor.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-07-10 17:11:19 -05:00
renovate[bot]
57c1c9286b Update RadioLib to v7.2.1 (#7287)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-10 17:11:00 -05:00
Jonathan Bennett
6030bf50e0 Unbreak the macro 2025-07-10 11:40:02 -05:00
github-actions[bot]
6d8c815558 automated bumps (#7293)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-10 11:31:40 -05:00
Jonathan Bennett
5f5698ccc0 Explicitly include meshUtils.h 2025-07-10 10:29:33 -05:00
Jonathan Bennett
74c735d5fb Gate screen code behind IF_SCREEN() 2025-07-10 10:20:44 -05:00
Jonathan Bennett
107dec22bd Remove bogus validation check 2025-07-10 10:12:02 -05:00
Jonathan Bennett
0795b21c2b Key verification flow on BaseUI (#7240) 2025-07-10 09:45:36 -05:00
renovate[bot]
a7e516d6f6 Update Adafruit INA260 to v1.5.3 (#7270)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-09 15:11:05 +08:00
Austin
f6d378255c Actions: Re-Add nrf52 hex release (rak4631) (#7276) 2025-07-08 23:53:51 -04:00
Austin
19d831d20d Whoops! Re-Add nRF52 OTA zips (#7275) 2025-07-08 21:33:59 -04:00
Austin
00495140bd GitHub Actions faster!! (#7268)
Use new meshtastic/gh-action-firmware Action

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-08 15:14:05 -05:00
Ben Meadors
354f149338 Make PacketHistory logging less chatty (#7272) 2025-07-08 15:12:44 -05:00
Jason P
999e1207a5 Show user which option is currently elected (#7271) 2025-07-08 14:38:38 -05:00
Jason P
916587c2a6 Update Bluetooth Toggle to match other variants (#7269) 2025-07-08 13:38:07 -05:00
todd-herbert
db4e4e6e53 Heltec Wireless Paper, VM-E213 Hardware Revisions (#7258)
* Tests to identify display model

* (InkHUD) SSD1682 controller IC
Has a few quirks, gets its own base class

* (InkHUD) E0213A367 Display
For Heltec Wireless Paper V1.1.1, V1.2
For Heltec VM-E213 V1.1

* (InkHUD) Select display model at boot

* (BaseUI) Wrapper to combine multiple GxEPD2 drivers
Workaround for issue of GxEPD2_BW objects not having a shared base class. Allows us to select a driver at runtime.
https://github.com/meshtastic/firmware/issues/6851#issuecomment-2905353447

* (BaseUI) Select E-Ink model at boot

* (InkHUD) SSD1682 deep sleep

* (InkHUD) No deep sleep for SSD1682

* (InkHUD) Fully no-op deep sleep for SSD1682
2025-07-08 13:01:48 -05:00
Jason P
9c08220d24 TFT_MESH Fixes Across Various Devices (#7247)
* Rename "r,g,b" variables to having a TFT_MESH_ prefix

* Reboot and then user options

* Restore TFT_MESH on any ST7789Spi driver
2025-07-08 06:24:12 -05:00
HarukiToreda
88b299dd41 Modules and favorite screen fix (#7264)
* T-watch screen misalignment fix

* Trunk fix

* Fix for favorite frame when module screen is enabled
2025-07-08 06:22:57 -05:00
github-actions[bot]
19af2d9e3b Upgrade trunk (#7266)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-07-08 06:22:24 -05:00
Jonathan Bennett
fa23be4424 Revert "GitHub Actions faster!! (#7244)" (#7262)
This reverts commit f2fb473ecf.
2025-07-07 19:50:44 -05:00
Ing. Jan Kaláb
e1f40c2db9 Fix install script (#7259)
This partially reverse 2ab717c (#7143), fixing the install script. It looks like a bad/missed copy/paste.
2025-07-07 19:36:21 -05:00
Ben Meadors
415dc4aa47 Try-fix: L76K spamming bad times can crash nodes (#7261)
* Try-fix: Clear GPS buffer when we encounter a bad time in NMEA

* Fix signed int warnings
2025-07-07 19:35:57 -05:00
Austin
f2fb473ecf GitHub Actions faster!! (#7244)
Use new meshtastic/gh-action-firmware Action

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-07 19:34:25 -05:00
Max
f95c77b8bd Fast fix, remove saving tx power inside limitPower() (#7255) 2025-07-07 07:50:13 -05:00
github-actions[bot]
09d4ee1ea7 Upgrade trunk (#7254)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-07-07 06:37:15 -05:00
Jonathan Bennett
40c586ca97 Automatically bail user out of displaymode_color when not HAS_TFT (#7248) 2025-07-06 16:36:22 -05:00
renovate[bot]
708978911b chore(deps): update meshtastic/device-ui digest to 8c7092c (#7238)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-05 19:26:20 -05:00
Jonathan Bennett
2a26209889 Trunk 2025-07-05 12:56:29 -05:00
Aiden Fox Ivey
1378657206 Fix documentation comments. 2025-07-05 12:50:33 -05:00
Aiden Fox Ivey
98d010761e Add constant time compare to AES-CCM
Signed-off-by: Aiden Fox Ivey <aiden@aidenfoxivey.com>
2025-07-05 12:50:24 -05:00
Ben Meadors
798b1f4d86 Add HWIDs for T1000-E in DFU mode (#7235) 2025-07-05 07:35:20 -05:00
Jonathan Bennett
29893e0c28 Don't run ble getFromRadio() unless the phone has requested a packet (#7231) 2025-07-04 14:22:59 -05:00
github-actions[bot]
1994bb3cd1 automated bumps (#7227)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-04 08:10:23 -05:00
Jonathan Bennett
f35ca812a3 Add a WiFi menu that can toggle back to Bluetooth (#7226)
* Add Kazakhstan to the BaseUI LoRa chooser

* Add a WiFi menu that can toggle back to Bluetooth
2025-07-04 05:30:56 -05:00
renovate[bot]
abbeb4874d chore(deps): update xpowerslib to v0.3.0 (#7210)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-04 13:12:24 +08:00
Jonathan Bennett
0f96bd7a26 Add Kazakhstan to the BaseUI LoRa chooser (#7224) 2025-07-04 10:31:09 +08:00
renovate[bot]
dfb07e8bd2 chore(deps): update meshtastic-esp32_https_server digest to 3223704 (#7225) 2025-07-03 20:16:53 -05:00
Matt Smith
ff4eed08bc Fixed --change-mode option since it was broken (#7144)
getopts can't parse double-dash options so it had to be done separately.  Also fixed where CHANGE_MODE was checked since it wasn't working either.
2025-07-03 19:41:17 -05:00
Tom Fifield
f13dc5b903 Add Kazakhstan frequencies (#7209)
As reported by @KZ1R , Kazakhstan has frequencies in use for Lora devices that are not covered by our existing band selections.

This adds
* KZ_433 433.075 - 434.775 MHz <10 mW EIRP, Low Powered Devices (LPD)
* KZ_863 863 - 868 MHz <25 mW EIRP, 500kHz channels allowed, must not be used at airfields

Legal ref provided in https://github.com/meshtastic/firmware/issues/7204 and verified.

https://www.gov.kz/memleket/entities/mdai/press/article/details/6128
 Order of the Ministry of Investments and Development of the Republic of Kazakhstan No. 34 dated January 21, 2015.
 Published on 01 July 2024 19:03 Updated on 01 July 2024

Fixes https://github.com/meshtastic/firmware/issues/7204
2025-07-03 18:34:46 -05:00
Jonathan Bennett
c1431f4f9a Disable low brightness, as this soft-bricks at least the L1 (#7223) 2025-07-03 18:34:04 -05:00
Jason P
93132fad28 Battery Layout Updates and Icons Changes (#7221)
* Testing battery states with some info lines in the drawCommonHeader

* Update logic of USB connected, update images for states

* Tweak battery layout for isHighResolution

* Hide the magic 101%

* Adjust padding for SENSECAP_INDICATOR

* Excessive logs are unnecessary as troubleshooting is done.

* Reduce excess code - simplify readability

* Restore Lightning Bolt for Charging and related alignment issues

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-07-03 17:20:51 -05:00
todd-herbert
2254d551f4 Honor custom userPrefs boot-screens in InkHUD (#7217)
* Honor custom boot screen from userPrefs.jsonc

* Meshtastic logo when powered off, userPrefs logo at boot

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-03 15:40:43 -05:00
Austin
f2d3f54824 No routers allowed! (#7220) 2025-07-03 13:10:35 -07:00
mverch67
c6e2a53a02 exclude not needed modules 2025-07-03 17:08:29 +02:00
github-actions[bot]
6fa597bc5d [create-pull-request] automated change (#7216)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-03 08:17:42 -05:00
Jonathan Bennett
b02e58521d Add GPIO edge for Native Trackball/Joystick (#7212)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-03 06:53:27 -05:00
Jonathan Bennett
81828c6244 Don't set non-existent pin on e290 (#7213)
* Don't set non-existent pin on e290

* Don't twiddle imaginary pins on the e213, either
2025-07-03 14:52:55 +10:00
Jonathan Bennett
549250b91a Good bot -- make array large enough to handle all the possible options 2025-07-02 22:39:29 -05:00
Ben Meadors
409dfe22ae Fix Seeed L1 board to enable consistent PIO flashing (#7211) 2025-07-02 20:58:15 -05:00
Jonathan Bennett
a6be2e46ed 2.7 fixes w2 (#7148)
* Initial work on splitting notification renderer into components for reuse

* More progress

* Fix notification popup

* more fix, less crash

* Adjustments for OLED on keeping menus tidy, added Bluetooth Toggle to Home frame. Also widen the frame slightly if you have a scroll bar

* Small changes for EInk to not crowd elements

* Change System frame menu over to better match actions; added color picker for T114

* Fix build errors and add T190 for testing

* Logic gates are hard sometimes

* Screen Color Picker changes, defined Yellow as a Color.

* Additional colors and tuning

* Abandon std::sort in NodeDB, and associated fixes (#7175)

* Generate short name for nodes that don't have user yet

* Add reboot menu

* Sort fixes

* noop sort option to avoid infinite loop

* Refactor Overlay Banner

* Continuing work on Color Picker

* Add BaseUI menus to add and remove Favorited Nodes

* Create TFT_MESH_OVERRIDE for variants.h and defined colors

* Trigger a NodeStatus update at the end of setup() to get fresh data on display at boot.

* T114 defaults to White, Yellow is now bright Yellow

* Revert "T114 defaults to White, Yellow is now bright Yellow"

This reverts commit 8d05e17f11.

* Only show OEM text if not OLED

* Adjust OEM logo to maximize visible area

* Start plumbing in Color Picker changes

* Finished plumbing

* Fix warning

* Revert "Fix warning"

This reverts commit 2e8aecd52d.

* Fix display not fully redrawing

* T-Deck should get color too

* Emote Revamp

* Update emotes.cpp

* Poo Emote fix

* Trunk fix

* Add secret test menu and number picker

* Missed bits

* Save colors between reboots

* Save Clock Face election to protobuf

* Make reboot first, then settings

* Add padding for single line pop-ups

* Compass saving and faster menus

* Resolve build issue with Excluding GPS

* Resolve issue with memory bars on EInk

* Add brightness settings for supported screen (#7182)

* Add brightness menu.

* add loop destination selection.

* Bring back color (and sanity) to the menus!

* Trunk

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jason P <applewiz@mac.com>
Co-authored-by: HarukiToreda <116696711+HarukiToreda@users.noreply.github.com>
Co-authored-by: Wilson <m.tools@qq.com>
2025-07-02 20:50:49 -05:00
renovate[bot]
3fdefe8289 chore(deps): update sensirion i2c scd4x to v1.1.0 (#7207)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-07-03 10:22:14 +10:00
todd-herbert
1f85e2a02a Additional larger font for InkHUD UI (#7201)
* Add 12pt fonts

* Add fontMedium
In addition to fontSmall and fontLarge

* Set fonts in nicheGraphics.h

* Change all uses of fontLarge to fontMedium
fontLarge was previously set at 9pt. fontLarge is now 12pt, fontMedium is 9pt. (NB: fonts may be customized per-variant)

* Use fontLarge with "All Messages" and "DMs" applets

* Documentation
2025-07-02 19:18:34 -05:00
Austin
f99ac2104c Add customizable boot logo based on resolution (#7146) 2025-07-02 11:53:12 -07:00
Austin
553fc0cb1b Renovate comment for sensirion/Sensirion I2C SCD4x (#7202) 2025-07-02 09:11:39 -05:00
Austin
f39c7ad47e mDNS: Remove HTTP/HTTPS. Advertise shortname. (#7162) 2025-07-02 07:20:40 -05:00
Razurac
e505ec847e Added option to invert screen on InkHUD (#7075)
* Added option to invert screen on InkHUD

* Rewrite to make use of existing config.display.displaymode

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-02 06:06:02 -05:00
Daniel.Cao
90e99b2bac feat: add support for RAK3312 (New RAKwireless wiscore ESP32-S3 + SX1262) (#7115)
* Add support for RAK3112 variant with necessary configurations and definitions

* Add the configuration of the LED pin

* Refactor rak3112 variant configuration: update name, remove unused files,

* Update RAK3112 configuration: refine memory settings,  adjust GPS pin definitions

* Update RAK3112 hardware vendor definition to use correct model

* configure LED pins and update module definitions

* Update USB mode configuration for RAK3112 board

* Update power and battery configuration in rak3112 variant

* Cancel the modification of mesh.pb.h

* Rename RAKwireless RAK3112 to RAK3312

---------

Co-authored-by: daniel <daniel.cao@rakwireless.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-02 06:03:42 -05:00
github-actions[bot]
d25240b33b [create-pull-request] automated change (#7199)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-02 06:03:00 -05:00
Chloe Bethel
d494c23a88 Enable telemetry and I2C sensors on STM32WL (except accelerometers) (#7008)
* Update platformio inis for stm32 platform and wio-e5 variant for enabling i2c

* Don't reference timezone functions if MESHTASTIC_EXCLUDE_TZ is defined

* Use custom pow_of_two in RadioInterface instead of floating-point pow()

* First pass: enable sensors for STM32wL

* Fix AirQualityTelemetryModule being created if the PM25AQI header is missing

* Link in power sensor libraries

* more ini tweaks

* Add =1 to EXCLUDE defines, fix indentation.

* Drop HAS_WIRE in ini, it's defined in architecture.h

* Fix build when power sensor libraries are missing

Make MAX sensor integration into Power.cpp optional based on its library header existing.
Also make NullSensor expose a voltage and current sensor, because Power calls directly into these for INA sensors.
This lets us remove all the deps for the STM32WL platform.

* Change default I2C for RAK3172 to be I2C1, not I2C2

* Respect the laws of mathematics (oops)
2025-07-02 06:01:45 -05:00
Ben Meadors
a286c06271 Merge branch 'master' into arduino-esp32-v3.2 2025-07-02 06:00:44 -05:00
Mictronics
17f8303e01 Fix build when MESHTASTIC_EXCLUDE_GPS is defined (#7154)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

* Remove static declaration for admin keys from userPrefs.h. Load hard coded admin keys in case config file has empty slots.

* Removed newlines from log.

* Fix issue #5665.

* Fix build for Pico2 RP2350 platform.

* Enable Wifi client on Pico2W.

* Use correct processor on Pico2.

* Fix deprecated warning.

* Update platform and framework for RP2350.

* Added Pico2W variant including Wifi support.

* Fix typo in used variant.

* Remove obsolete define.

* Fix for native Linux build.

* Simplify RP2350 platform tag reference.

Co-authored-by: Austin <vidplace7@gmail.com>

* Cast user prefs strings.

* Update to last successfully building platform package.

* Define I2C GPIOs to ensure usage of both ports. Possibly fixes #5361

* RAK11310 support for RAK12002 RTC added.

* Update platform and framework packages to 4.4.3.

* Use RP2040 base platform and framework package. Use RAK11300 board definition in arduino-pico framework.

* Use RAK11300 board definition in arduino-pico framework.

* Fix build when MESHTASTIC_EXCLUDE_GPS is defined.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-07-02 05:59:43 -05:00
dylanli
aadea89202 fix bug of cant't switch between two applets side-by-side (#7195) 2025-07-02 05:49:47 -05:00
github-actions[bot]
53013e9a7e Upgrade trunk (#7151)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-07-02 18:34:51 +10:00
Tymoteusz Jankowski
30eec01f55 Fix hydra radio (#7192)
Added missing defines to variant.h
2025-07-02 13:41:56 +10:00
dylanli
cc961d7762 update seeed device battery level map (#7194) 2025-07-02 13:39:51 +10:00
github-actions[bot]
a7528d777a [create-pull-request] automated change (#7193)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-07-01 20:20:22 -05:00
todd-herbert
13013a272f Limited emoji support for InkHUD (#7176)
* Cram a few emoji into AdafruitGFX fonts
Values which would normally be assigned to unprintable control characters

* Another sneaky string which may contain UTF-8 chars

* Document emoji

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-01 20:18:14 -05:00
Max
3ea96bb6e1 Log TX power after limits applyng and store it in config (#7065)
* Log and save in config lora tx_power after limits applyng

* Log and save in config lora tx_power after limits applyng

* Trunk fmt

* Remove duplicate logic

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-07-01 08:47:42 -05:00
Tom Fifield
baf0e9c7e6 Add detection framework for multiple AirQuality sensors (#7187)
* Add detection framework for multiple AirQuality sensors

Now we have the ability to detect multiple AirQualitySensors,
follow the lead of other sensor types and create supporting methods
and objects for using this information.

Continued cherry-picking to get #4601 over the line :)

Co-Authored-By: @Coloradohusky

* Update src/main.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-07-01 21:27:44 +10:00
dylanli
598eebfb10 fix t1000-e battery level map (#7186) 2025-07-01 20:16:48 +10:00
Tom Fifield
5841c889ba Add detection code for SCD4X (#7185)
* Add detection code for SCD4X

This patch adds I2C detection support SCD40/SDC41 CO2 sensors.

It's a start to get #4601 over the line :)

Co-Authored-By: @Coloradohusky

* Remove SCD4X from Portduino
2025-07-01 19:34:03 +10:00
Manuel
dda4b90e34 Merge branch 'master' into arduino-esp32-v3.2 2025-07-01 00:56:56 +02:00
mverch67
cc5dc5046c indicator: adaptations for arduino-esp32 v3.2 2025-07-01 00:48:11 +02:00
renovate[bot]
4bd416413a chore(deps): update meshtastic/device-ui digest to 4b7bf36 (#7178)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-30 16:04:12 -05:00
github-actions[bot]
be06a7d881 automated bumps (#7155)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-30 06:05:43 -05:00
Andrew Yong
26df4f8142 fix(xiao_ble): Define xiao_ble I2C pins in parent variant (fixes #7163) (#7164)
This restores the previously-defined I2C pins that got lost in the cleanup (#7024)

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-06-30 06:05:24 -05:00
Jonathan Bennett
b6a13f1114 Add check for theoretically impossible comparison, and drop nodenum comparison (#7165) 2025-06-28 22:54:03 -05:00
Jonathan Bennett
2bcf608654 Last second fixes (#7156)
* Ditch the 30 second delay for button presses

* Only order strictly weakly

* Too many comments!

* Only sort the populated meshNodes
2025-06-28 08:19:31 -05:00
Jonathan Bennett
705515ace2 Resize meshNodes to MAX + 1 to avoid crash during sort 2025-06-27 11:46:33 -05:00
Jonathan Bennett
a97df4bb52 Sanity check incoming UDP 2025-06-27 11:22:16 -05:00
porkcube
f6743798e2 cleanup Shutting down -> Shutting Down awkwardness (#7099)
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-06-27 11:09:04 -05:00
Ben Meadors
2ea70927c8 Revert "automated bumps (#7097)"
This reverts commit 4308bbc156.
2025-06-27 11:07:58 -05:00
Jonathan Bennett
de5b55921e Extra check on UDP packets 2025-06-27 11:06:19 -05:00
Ben Meadors
2b97576b18 NRF52 BLE fixes / tweaks (#7152)
* Try-fix: Flaky NRF52 bluetooth pairing for some users

* Safe access for screen pointer
2025-06-27 06:26:34 -05:00
Jason P
29e7a71c97 2.7 Miscellaneous Fixes - Week 1 (#7102)
* Update Favorite Node Message Options to unify against other screens

* Rebuild Horizontal Battery, Resolve overlap concerns

* Update positioning on Message frame and fix drawCommonHeader overlay

* Beginnings of creating isHighResolution bool

* Fixup determineResolution()

* Implement isHighResolution in place of SCREEN_WIDTH > 128 checks

* Line Spacing bound to isHighResolution

* Analog Clock for all

* Add AM/PM to Analog Clock if isHighResolution and not TWatch

* Simple Menu Queue, and add time menu

* Fix prompt string for 12/24 hour picker

* More menu banners into functions

* Fix Action Menu on Home frame

* Correct pop-up calculation size and continue to leverage isHighResolution

* Move menu bits to MenuHandler

* Plumb in the digital/analog picker

* Correct Clock Face Picker title

* Clock picker fixes

* Migrate the rest of the menus to MenuHandler.*

* Add compass menu and needle point option

* Minor fix for compass point menu

* Correct Home menu into typical format

* Fix emoji bounce, overlap, and missing commonHeader

* Sanitize long_names and removed unused variables

* Slightly better sanitizeString variation

* Resolved apostrophe being shown as upside down question mark

* Gotta keep height and width in expected order

* Remove Second Hand for Analog Clock on EInk displays

* Fix Clock menu option decision tree

* Improvements to Eink Navigation

* Pause Banner for Eink moved to bottom

* Updated working for 12-/24-hour menu and Added US/Arizona to timezone picker

* Add Adhoc Ping and resolve error with std::string sanitized

* Hide quick toggle as option is available within Action Menu, commented out for the moment

* Remove old battery icon and option, use drawCommonHeader throughout, re-add battery to Clock frames

* fix misc build warnings. NFC

* Update Analog Clock on EInk to show more digits

* Establish Action Menu on all node list screens, add NodeDB reset (with confirmation) option

* Add Toggle Backlight for EInk Displays

* Suppress action screen Full refresh for Eink

* Adjust drawBluetoothConnectedIcon on TWatch

* Maintain clock frame when switching between Clock Faces

* Move modules beyond the clock in navigation

* addressed the conflicts, and changed target branch to 2.7-MiscFixes-Week1

* cleanup, cheers

* Add AM/PM to low resolution clock also

* Small adjustments to AM/PM replacement across various devices

* Resolve dangling pointer issues with sanitize code

* Update comments for Screen.cpp related to module load change

* Trunk runs

* Update message caching to correct aged timestamp

* Menu wording adjustments

* Time Format wording

* Use all the rows on EInk since with autohide the navigation bar

* Finalize Time Format picker word change

* Retired drawFunctionOverlay code

No longer being used

* Actually honor the points-north setting

* Trunk

* Compressed action list

* Update no-op showOverlayBanner function

* trunk

* Correct T_Watch_S3 specific line

* Autosized Action menu per screen

* Finalize Autosized Action menu per screen

* Unify Message Titles

* Reorder Timezones to match expectations

* Adjust text location for pop-ups

* Revert "Actually honor the points-north setting"

This reverts commit 20988aa4fa.

* Make NodeDB sort its internal vector when lastheard is updated. Don't sort in NodeListRenderer

* Update src/graphics/draw/NodeListRenderer.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/mesh/NodeDB.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Pass by reference -- Thanks Copilot!

* Throttle sorting just a touch

* Check more carefully for own node

* Eliminate some now-unneeded sorting

* Move function after include

* Putting Modules back to position 0 and some trunk checks found

* Add Scrollbar for Action menus

* Second attempt to move modules down the navigation bar

* Continue effort of moving modules in the navigation

* Canned Messages tweak

* Replicate Function + Space through the Menu System

* Move init button parameters into config struct (#7145)

* Remove bundling of web-ui from ESP32 devices (#7143)

* Fixed triple click GPS toggle bungle

* Move init button parameters into config struct

* Reapply "Actually honor the points-north setting"

This reverts commit 42c1967e7b.

* Actually do compass pointings correctly

* Tweak to node bearings

* Menu wording tweaks

* Get the compass_north_top logic right

* Don't jump frames after setting Compass

* Get rid of the extra bearingTo functions

* Don't blink Mail on EInk Clock Screens

* Actually set lat and long

* Calibrate

* Convert Radians to Degrees

* More degree vs radians fixes

* De-duplicate draw arrow function

* Don't advertise compass calibration without an accell thread.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: HarukiToreda <116696711+HarukiToreda@users.noreply.github.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: csrutil <keming.cao@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-26 22:11:20 -05:00
Ben Meadors
18fbc2149d Fix iOS bluetooth crash: Ensure UINT32_MAX is not used (#7147) 2025-06-26 19:23:08 -05:00
renovate[bot]
50424d1035 chore(deps): update meshtastic/web to v2.6.4 (#7017)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-26 12:39:03 -05:00
Ben Meadors
e87c991975 Fixed triple click GPS toggle bungle 2025-06-26 11:19:54 -05:00
Ben Meadors
2ab717cebb Remove bundling of web-ui from ESP32 devices (#7143) 2025-06-26 10:57:33 -05:00
Ben Meadors
ad23c065f6 Rate limiting fix and added 2 second rate limiting to text messages (#7139)
* Rate limiting fix and added 1.5 second rate limiting to text messages

* Remove copy-pasta

* Update src/mesh/Default.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Two is more reasonable

* Two too

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-26 07:56:34 -05:00
dylanli
eeb52a1221 support seeed_wio_tracker_L1_eink (#7125)
* initial commit of eink version

* fit for ssd1682 initial test run hud

* update to solve mirroring problem

* change eink screen ic to ssd1680

* remove HINK_E0213A367

* trunk fmt

* fix wrong type

* fix some fmt
2025-06-26 06:30:45 -05:00
Manuel
8ae05f6b33 defcon tft display size definitions (#7142) 2025-06-26 05:44:51 -05:00
github-actions[bot]
f6630cd31d Upgrade trunk (#7084)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-26 18:31:14 +10:00
Austin
c144bd03dc MeshAdv-Mini: Correct autoconf settings (#7117) 2025-06-25 20:17:47 -05:00
Ben Meadors
7512673b09 Do not beacon Device telemetry by default anymore (#7116)
* Do not beacon Device telemetry by default anymore

* Update

* Old default interval for sensor

* Added userpref

* Addd tracker to default telemetry roles

* Let the macro do its job in router mode
2025-06-25 16:36:33 -05:00
github-actions[bot]
3870d81bf6 [create-pull-request] automated change (#7134)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-06-25 20:18:55 +02:00
Kongduino
a7dcf580ad Update RedirectablePrint.cpp (#7114)
Bug fix to my hexDump code. Because `log()` adds a carriage return, hexdump lines were split over 3 lines. This fixes it.
2025-06-25 19:54:57 +02:00
todd-herbert
ecfaf3a095 Canned Messages via InkHUD menu (#7096)
* Allow observers to respond to AdminMessage requests
Ground work for CannedMessage getters and setters

* Enable CannedMessage config in apps for InkHUD devices

* Migrate the InkHUD::Events AdminModule observer
Use the new AdminModule_ObserverData struct

* Bare-bones NicheGraphics util to access canned messages
Handles loading and parsing. Handle admin messages for setting and getting.

* Send canned messages via on-screen menu

* Change ThreadedMessageApplet from Observer to Module API
Allows us to intercept locally generated packets ('loopbackOK = true'), to handle outgoing canned messages.

* Fix: crash getting empty canned message string via Client API

* Move file into Utils subdir

* Move an include statement from .cpp to .h

* Limit strncpy size of dest, not source
Wasn't critical in ths specific case, but definitely a mistake.
2025-06-25 06:04:18 -05:00
Ben Meadors
91bcf072a0 Tweak interval trottling (#7113) 2025-06-24 05:27:40 -05:00
renovate[bot]
4802cef3ca chore(deps): update radiolib to v7.2.0 (#7098)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-24 15:56:02 +10:00
renovate[bot]
38896198f2 chore(deps): update meshtastic/device-ui digest to cdc6e5b (#7112)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-23 12:04:55 -05:00
Jonathan Bennett
012f88e56f Make the 4-way on the L1 work on press instead of release (#7108) 2025-06-22 20:57:39 -05:00
Jonathan Bennett
0808f5215f fix mismatch between Exclude FSM include names (#7107) 2025-06-22 18:48:16 -05:00
Jonathan Bennett
247e05bb10 Get the unphone to stop bootlooping: increase MAX_THREADS everywhere (#7106) 2025-06-22 16:59:04 -05:00
github-actions[bot]
4308bbc156 automated bumps (#7097)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-22 05:54:32 -05:00
Jonathan Bennett
ce1480df98 Initialize value to fix warning 2025-06-21 23:56:14 -05:00
Jonathan Bennett
0108ad7992 Don't write the config unless the setting changed 2025-06-21 23:19:41 -05:00
Jonathan Bennett
e1df4e19e5 Default to very short updownDebounce values 2025-06-21 20:47:11 -05:00
whywilson
8ba98ae873 Add a debounce time parameter and use it in the runOnce method to debounce the key. 2025-06-21 20:40:34 -05:00
whywilson
7a38368494 Optimize key event processing and add debounce logic. 2025-06-21 20:40:24 -05:00
oscgonfer
195b7cc30a Do not add variables to json if not present (#7048) 2025-06-21 06:44:07 -05:00
Jonathan Bennett
4feaec651f Unify the native display config between legacy display and MUI (#6838)
* Add missed include

* Another Warning fix

* Add another HAS_SCREEN

* Namespace fixes

* Removed depricated destination types and re-factored destination screen

* Get rid of Arduino Strings

* Clean up after Copilot

* SixthLine Def, Screen Rename

Added Sixth Line Definition Screen Rename, and Automatic Line Adjustment

* Consistency is hard - fixed "Sixth"

* System Frame Updates

Adjusted line construction to ensure we fit maximum content per screen.

* Fix up notifications

* Add a couple more ifdef HAS_SCREEN lines

* Add screen->isOverlayBannerShowing()

* Don't forget the invert!

* Adjust Nodelist Center Divider

Adjust Nodelist Center Divider

* Fix variable casting

* Fix entryText variable as empty before update to fix validation

* Altitude is int32_t

* Update PowerTelemetry to have correct data type

* Fix cppcheck warnings (#6945)

* Fix cppcheck warnings

* Adjust logic in Power.cpp for power sensor

---------

Co-authored-by: Jason P <applewiz@mac.com>

* More pixel wrangling so things line up NodeList edition

* Adjust NodeList alignments and plumb some background padding for a possible title fix

* Better alignment for banner notifications

* Move title into drawCommonHeader; initial screen tested

* Fonts make spacing items difficult

* Improved beeping booping and other buzzer based feedback (#6947)

* Improved beeping booping and other buzzer based feedback

* audible button feedback (#6949)

* Refactor

---------

Co-authored-by: todd-herbert <herbert.todd@gmail.com>

* Sandpapered the corners of the notification popup

* Finalize drawCommonHeader migration

* Update Title of Favorite Node Screens

* Update node metric alignment on LoRa screen

* Update the border for popups to separate it from background

* Update PaxcounterModule.cpp with CommonHeader

* Update WiFi screen with CommonHeader and related data reflow

* It was not, in fact, pointing up

* Fix build on wismeshtap

* T-deck trackball debounce

* Fix uptime on Device Focused page to actually detail

* Update Sys screen for new uptime, add label to Freq/Chan on LoRa

* Don't display DOP any longer, make Uptime consistent

* Revert Uptime change on Favorites, Apply to Device Focused

* Label the satelite number to avoid confusion

* Boop boop boop boop

* Correct GPS positioning and string consistency across strings for GPS

* Fix GPS text alignment

* Enable canned messages by default

* Don't wake screen on new nodes

* Cannedmessage list emote support added

* Fn+e emote picker for freetext screen

* Actually block CannedInput actions while display is shown

* Add selection menu to bannerOverlay

* Off by one

* Move to unified text layouts and spacing

* Still my Fav without an "e"

* Fully remove EVENT_NODEDB_UPDATED

* Simply LoRa screen

* Make some char pointers const to fix compilation on native targets

* Update drawCompassNorth to include radius

* Fix warning

* button thread cleanup

* Pull OneButton handling from PowerFSM and add MUI switch (#6973)

* Trunk

* Onebutton Menu Support

* Add temporary clock icon

* Add gps location to fsi

* Banner message state reset

* Cast to char to satisfy compiler

* Better fast handling of input during banner

* Fix warning

* Derp

* oops

* Update ref

* Wire buzzer_mode

* remove legacy string->print()

* Only init screen if one found

* Unsigned Char

* More buttonThread cleaning

* screen.cpp button handling cleanup

* The Great Event Rename of 2025

* Fix the Radiomaster

* Missed trackball type change

* Remove unused function

* Make ButtonThread an InputBroker

* Coffee hadn't kicked in yet

* Add clock icon for Navigation Bar

* Restore clock screen definition code - whoops

* ExternalNotifications now observe inputBroker

* Clock rework (#6992)

* Move Clock bits into ClockRenderer space

* Rework clock into all device navigation

* T-Watch Actually Builds Different

* Compile fix

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>

* Add AM/PM to Digital Clock

* Flip Seconds and AM/PM on Clock Display

* Tik-tok pixels are hard

* Fix builds on Thinknode M1

* Check for GPS and don't crash

* Don't endif til the end

* Rework the OneButton thread to be much less of a mess. (#6997)

* Rework the OneButton thread to be much less of a mess. And break lots of targets temporarily

* Update src/input/ButtonThread.h

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* fix GPS toggle

* Send the shutdown event, not just the kbchar

* Honor the back button in a notificaiton popup

* Draw the right size box for popup with options

* Try to un-break all the things

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* 24-hour Clock Should have leading zero, but not 12-hour

* Fixup some compile errors

* Add intRoutine to ButtonThread init, to get more responsive user button back

* Add Timezone picker

* Fix Warning

* Optionally set the initial selection for the chooser popup

* Make back buttons work in canned messages

* Drop the wrapper classes

* LonPressTime now configurable

* Clock Frame can not longer be blank; just add valid time

* Back buttons everywhere!

* Key Verification confirm banner

* Make Elecrow M* top button a back button

* Add settings saves

* EInk responsiveness fixes

* Linux Input Fixes

* Add Native Trackball/Joystick support, and move UserButton to Input

* No Flight Stick Mode

* Send input event

* Add Channel Utilization to Device Focused frame

* Don't shift screens when we draw new ones

* Add showOverlayBanner arguments to no-op

* trunk

* Default Native trackball to NC

* Fix crash in simulator mode

* Add longLong button press

* Get the args right

* Adjust Bluetooth Pairing Screen to account for bottom navigation.

* Trackball everywhere, and unPhone buttons

* Remap visionmaster secondary button to TB_UP

* Kill ScanAndSelect

* trunk

* No longer need the canned messages input filter

* All Canned All the time

* Fix stm32 compile error regarding inputBroker

* Unify tft lineheights (#7033)

* Create variable line heights based upon SCREEN_HEIGHT

* Refactor textPositions into method -> getTextPositions

* Update SharedUIDisplay.h

---------

Co-authored-by: Jason P <applewiz@mac.com>

* Adjust top distance for larger displays

* Adjust icon sizes for larger displays

* Fix Paxcounter compile errors after code updates

* Pixel wrangling to make larger screens fit better

* Alert frame has precedence over banner -- for now

* Unify on ALT_BUTTON

* Align AM/PM to the digit, not the segment on larger displays

* Move some global pin defines into configuration.h

* Scaffolding for BMM150 9-axis gyro

* Alt button behavior

* Don't add the blank GPS frames without HAS_GPS

* EVENT_NODEDB_UPDATED has been retired

* Clean out LOG_WARN messages from debugging

* Add dismiss message function

* Minor buttonThread cleanup

* Add BMM150 support

* Clean up last warning from dev

* Simplify bmm150 init return logic

* Add option to reply to messages

* Add minimal menu upon selecting home screen

* Move Messages to slot 2, rename GPS to Position, move variables nearer functional usage in Screen.cpp

* Properly dismiss message

* T-Deck Trackball press is not user button

* Add select on favorite frame to launch cannedMessage DM

* Minor wording change

* Less capital letters

* Fix empty message check, time isn't reliable

* drop dead code

* Make UIRenderer a static class instead of namespace

* Fix the select on favorite

* Check if message is empty early and then 'return'

* Add kb_found, and show the option to launch freetype if appropriate

* Ignore impossible touchscreen touches

* Auto scroll fix

* Move linebreak after "from" for banners to maximize screen usage.

* Center "No messages to show" on Message frame

* Start consolidating buzzer behavior

* Fixed signed / unsigned warning

* Cast second parameter of max() to make some targets happy

* Cast kbchar to (char) to make arduino string happy

* Shorten the notice of "No messages"

* Add buzzer mode chooser

* Add regionPicker to Lora icon

* Reduce line spacing and reorder Position screen to resolve overlapping issues

* Update message titles, fix GPS icons, add Back options

* Leftover boops

* Remove chirp

* Make the region selection dismissable when a region is already set

* Add read-aloud functionality on messages w/ esp8266sam

* "Last Heard" is a better label

* tweak the beep

* 5 options

* properly tear down freetext upon cancel

* de-convelute canned messages just a bit

* Correct height of Mail icon in navigation bar

* Remove unused warning

* Consolidate time methods into TimeFormatters

* Oops

* Change LoRa Picker Cancel to Back

* Tweak selection characters on Banner

* Message render not scrolling on 5th line

* More fixes for message scrolling

* Remove the safety next on text overflow - we found that root cause

* Add pin definitions to fix compilation for obscure target

* Don't let the touchscreen send unitialized kbchar values

* Make virtual KB just a bit quicker

* No more double tap, swipe!

* Left is left, and Right is right

* Update horizontal lightning bolt design

* Move from solid to dashed separator for Message Frame

* Single emote feature fix

* Manually sort overlapping elements for now

* Freetext and clearer choices

* Fix ESP32 InkHUD builds on the unify-tft branch (#7087)

* Remove BaseUI branding

* Capitalization is fun

* Revert Meshtastic Boot Frame Changes

* Add ANZ_433 LoRa region to picker

* Update settings.json

---------

Co-authored-by: HarukiToreda <116696711+HarukiToreda@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jason P <applewiz@mac.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-21 06:36:04 -05:00
Andrew Yong
82b7cb5dd0 fix(xiao_ble): Typo preventing SX1262 init (SX126X_CS gets stuck) (#7094)
Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-06-21 06:17:46 -05:00
Austin
30bbb449db Specify branch for create-pull-request (#7090) 2025-06-20 22:59:45 -05:00
Tom Fifield
14421c3609 Add ANZ_433 Region (#7036)
As reported by @monkeypants, the MY_433 region is not legal in ANZ due to
power limits being too high. This patch introduced an ANZ_433 region to match
the requirements in Australia and New Zealand.

433.05 - 434.79 MHz, 25mW EIRP max, No duty cycle restrictions
AU Low Interference Potential https://www.acma.gov.au/licences/low-interference-potential-devices-lipd-class-licence
NZ General User Radio Licence for Short Range Devices https://gazette.govt.nz/notice/id/2022-go3100

Fixes https://github.com/meshtastic/firmware/issues/7032#issuecomment-2972013077

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-06-20 21:39:42 -05:00
Ben Meadors
2cf7e51061 Version bump the old fashion way 2025-06-20 20:55:57 -05:00
github-actions[bot]
7fd12782a1 Bump release version (#7083)
* automated bumps

* Update version.properties

* Update changelog

* Update org.meshtastic.meshtasticd.metainfo.xml

* Update bin/org.meshtastic.meshtasticd.metainfo.xml

Co-authored-by: Austin <vidplace7@gmail.com>

---------

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-06-20 19:33:31 -05:00
renovate[bot]
c914a62d93 Update meshtastic/device-ui digest to d99edaf (#7088)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-21 08:24:02 +10:00
Ben Meadors
12680ad9cd Update README.md 2025-06-19 20:35:40 -05:00
github-actions[bot]
0561f2ca4b [create-pull-request] automated change (#7082)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-19 18:57:18 -05:00
Andrew Yong
58743021c8 XIAO BLE cleanup (supporting changes to seeed_xiao_nrf52840_kit too) (#7024)
* chore(seeed_xiao_nrf52840_kit): Use build flag for L76K GNSS, rename variant.h ifdef

Signed-off-by: Andrew Yong <me@ndoo.sg>

* feat(seeed_xiao_nrf52840_kit): Support multiple SX126x pinouts via build flags

Signed-off-by: Andrew Yong <me@ndoo.sg>

* feat(seeed_xiao_nrf52840_kit): Pin D0 as user button if pin is unused

Signed-off-by: Andrew Yong <me@ndoo.sg>

* feat: EBYTE E22 and NiceRF gain and SX1262 max power defines

Signed-off-by: Andrew Yong <me@ndoo.sg>

* chore(xiao_ble): Move variant to DIY and extend from seeed_xiao_nrf52840_kit

Signed-off-by: Andrew Yong <me@ndoo.sg>

* feat(seeed_xiao_nrf52840_kit): Pin D6, D7 as I2C SDA, SCL if pins are unused

Signed-off-by: Andrew Yong <me@ndoo.sg>

---------

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-06-19 18:51:33 -05:00
Justin E. Mann
2fb46ce5d5 Add rak12035 VB Soil Monitor Tested & Working (#6741)
* [WIP] Add RAK12035VB Soil Moisture Sensor support

Introduce the RAK12035 sensor as an environmental telemetry sensor,
including necessary calibration checks and default values. Update
relevant files to integrate the sensor into the existing telemetry system.

This hardware is not just one module, but a couple.. RAK12023 and
RAK12035 is the component stack, the RAK12023 does not seem to matter
much and allows for multiple RAK12035 devices to be used.

Co-Authored-By: @Justin-Mann

* [WIP] Add RAK12035VB Soil Moisture Sensor support

Introduce the RAK12035 sensor as an environmental telemetry sensor,
including necessary calibration checks and default values. Update
relevant files to integrate the sensor into the existing telemetry system.

This hardware is not just one module, but a couple.. RAK12023 and
RAK12035 is the component stack, the RAK12023 does not seem to matter
much and allows for multiple RAK12035 devices to be used.

Co-Authored-By: @Justin-Mann

* [WIP] Add RAK12035VB Soil Moisture Sensor support

Introduce the RAK12035 sensor as an environmental telemetry sensor,
including necessary calibration checks and default values. Update
relevant files to integrate the sensor into the existing telemetry system.

This hardware is not just one module, but a couple.. RAK12023 and
RAK12035 is the component stack, the RAK12023 does not seem to matter
much and allows for multiple RAK12035 devices to be used.

Co-Authored-By: @Justin-Mann

* [WIP] Add RAK12035VB Soil Moisture Sensor support

Introduce the RAK12035 sensor as an environmental telemetry sensor,
including necessary calibration checks and default values. Update
relevant files to integrate the sensor into the existing telemetry system.

This hardware is not just one module, but a couple.. RAK12023 and
RAK12035 is the component stack, the RAK12023 does not seem to matter
much and allows for multiple RAK12035 devices to be used.

Co-Authored-By: @Justin-Mann

* Update to 1.0.4 release of RAK12035_SoilMoisture

* cleanup

* cool

* .

* ..

* little bit of cleanup and recompile/upload/test on RAK WISBLAOCK STACK: RAK19007/RAK4631/RAK12035VB/RAK12500

looks like soil monitor is working correctly, new environmental metrics are comming thru [new protos soil_moisture, soil_temperature] and GPS is working again with the RAK 12500.

improvements could be made around the configuration of the monitor.

next steps include updating the client(s) to react to, log and display the new proto metrics for soil temp and humidity.

* . comments about current limitations and TODOs

* trunk update

* trying to autoformat..

* fix formatting attempt 2

* ..

* ...

* ...

* .

* some corrections and local build success

* correction in temp code

* grr formatting

* cleanup after a few experiments

* remove temp code to overwrite values for temp and humidity protos.. next step just update the clients to know about soil_temperature and soil_humidity protos.

* update some values in varient for rak wistap

* working out trunk formatting..

* wip
. corrections to other build variants

* .

* protobuffs?

* protobufs?

* Update protobufs ref

* Protobufs ref

* Trunk

* Update RAK12035Sensor.cpp

* Fmt

* comment changes

* dumb mistakes... resolved, actually built and tested.. all good..

* Update src/modules/Telemetry/Sensor/RAK12035Sensor.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Update src/modules/Telemetry/Sensor/RAK12035Sensor.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* . proto submod

* proto

* proto

* merge master

* mabe a fix for GPS pin conflict, waiting on a new gps module to try

* merge master, attempt to fix gps (RAK12500) pin conflict with RAK12023/12035

* .

* .

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-06-19 18:51:03 -05:00
Marek
8be76a56c7 PacketHistory - option to track entries' aging to log (#7067)
* PacketHistory debloat RAM allocations

* Removed FLOOD_EXPIRE_TIME option. We have static buffer now.

* Remove mx_ prefix from recentPackets

* Remember no less than 100 packet not to make reflood hell

* Cleanup

* PacketHistory max no less than 100

* no less than 100 means max of 100 or a given value of course.

* Care to not do duplicate entries. Cleanups.

* Packet History - option to log aging of entries

* Update comments for PACKET_HISTORY_TRACE_AGING and VERBOSE_PACKET_HISTORY definitions

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-19 18:48:35 -05:00
Hannes Fuchs
2c206febab Fix nugget s3 lora variant issues (#7070)
* Fix serial communication for nugget s3 lora

Without setting `ARDUINO_USB_CDC_ON_BOOT=1` the serial interface on the
nugget s3 lora board does not work.

* Fix nugget s3 lora variant definitions
2025-06-19 18:48:22 -05:00
github-actions[bot]
db1eac12af Upgrade trunk (#7073)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-20 09:22:03 +10:00
Jeremiah K
56e67cb434 Fix position exchange throttling issue (#7079)
* Fix position exchange throttling race condition

Separate tracking of position broadcasts vs replies to fix exchange position functionality.

Previously, allocReply() would refuse to send position replies if any position packet
(broadcast or reply) was sent within the last 3 minutes. This caused the exchange
position feature to fail when a device had recently sent a position broadcast.

Changes:
- Add lastSentReply member to track position reply timestamps separately
- Update allocReply() to only throttle based on previous replies, not broadcasts
- This allows position exchange to work even after recent position broadcasts

The fix maintains the 3-minute throttling for replies to prevent spam while allowing
legitimate position exchange functionality to work properly.

* Remove unused lastSentToMesh variable

Variable was no longer used after separating reply throttling logic.
2025-06-19 18:20:20 -05:00
Matt Smith
e9d5e36738 Replace blocking delay for wifi reconnect with non-blocking to keep button/display interactivity (#6983)
* Update WiFiAPClient.cpp to replace blocking delay() with non-blocking

* Update WiFiAPClient.cpp - fix extra endif

* Update WiFiAPClient.cpp remove duplicate section

* Update WiFiAPClient.cpp

* Update trunk_annotate_pr.yml

* Update trunk_annotate_pr.yml

* Update trunk_check.yml

* Update trunk_check.yml

* Update trunk_format_pr.yml

* Update trunk_annotate_pr.yml

* Attempted to address comments, and fix my other mess.
Thanks for your patience.

* Revert "Update trunk_annotate_pr.yml"

This reverts commit 7db4ff6444.

* Last mess cleanups (hopefully)

* Undid trunk.yaml changes

* Trunk format

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-06-19 18:18:55 -05:00
Jonathan Bennett
f71fdef3fd Update HostMetrics.cpp - don't try to print the user string (#7081)
* Update HostMetrics.cpp - don't try to print the user string

* Make Trunk Happy
2025-06-19 17:05:22 -05:00
Jonathan Bennett
5e92145324 Ensure incoming hostMetrics userstring is null terminated (#7068)
* Ensure incoming hostMetrics  userstring is null terminated

* Only null terminate user_string when has_user_string is true
2025-06-18 16:41:43 -05:00
github-actions[bot]
89a4589b68 Upgrade trunk (#7060)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-18 06:20:10 -05:00
Marek Veselý
20991d8b53 Add recognition for SHT40 with serial number starting with 0xc8d (#7061)
* Add recognition for SHT40 with serial number starting with 0xc8d

* fix a dumb typo :/
2025-06-18 06:19:52 -05:00
Jonathan Bennett
3ab9005b2f Make sure host_metrics user_string is null terminated 2025-06-17 11:11:36 -05:00
Marek
aabc5b7cf2 PacketHistory debloat RAM allocations (#7034)
* PacketHistory debloat RAM allocations

* Removed FLOOD_EXPIRE_TIME option. We have static buffer now.

* Remove mx_ prefix from recentPackets

* Remember no less than 100 packet not to make reflood hell

* Cleanup

* PacketHistory max no less than 100

* no less than 100 means max of 100 or a given value of course.

* Care to not do duplicate entries. Cleanups.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-17 07:18:59 -05:00
dylanliacc
afcd97c154 trunk fmt 2025-06-16 16:16:14 -05:00
Dylanliacc
cbdd7eae70 fix IIC port 2025-06-16 16:15:59 -05:00
Austin
6374ffea35 Run daily packaging earlier (PPA) (#7057) 2025-06-16 07:52:20 -05:00
Nivek-domo
1a6bb97f16 Fix RCWL9620Sensor for rak11310 support (#6617)
* Update RCWL9620Sensor.cpp

test on rak11310, work very wel now

* Update RCWL9620Sensor.cpp

* Trunk

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-16 06:54:55 -05:00
github-actions[bot]
4f0b95e910 Upgrade trunk (#7053)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-16 06:24:26 -05:00
github-actions[bot]
a81b41cbfb automated bumps (#7050)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-16 06:11:10 -05:00
todd-herbert
465fe18a89 Dismiss ExternalNotification nagging on InkHUD button press (#7056)
* Expose ExternalNotification::isNagging

* Dismiss external notification on button press
2025-06-16 06:09:55 -05:00
Taha
bd0e25f3f5 Fix Critical Error #3 for LilyGo T-Echo (#6791)
* Fix Critical Error #3

* clang format
2025-06-16 13:32:28 +10:00
Austin
9861e82f0a Manual bump metainfo version (#7049) 2025-06-15 20:16:33 -05:00
Ben Meadors
fcefd592e2 Update version.properties 2025-06-15 19:27:17 -05:00
Jonathan Bennett
8a8a7cdefc cppcheck-supress to ignore intentional error 2025-06-15 16:37:19 -05:00
Ben Meadors
8f9e569825 Create FUNDING.yml 2025-06-15 07:52:38 -05:00
Ben Meadors
b0c5327585 Trunk 2025-06-15 07:40:45 -05:00
Andy Shinn
f1dd623ce9 allow overriding INA3221 channels (#7035)
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-06-15 07:39:49 -05:00
Ben Meadors
ac52edd11a Add the ability to share ignored contacts (for blacklisting problematic nodes) (#7044) 2025-06-15 07:34:03 -05:00
github-actions[bot]
66d5dde956 [create-pull-request] automated change (#7043)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-15 06:45:00 -05:00
github-actions[bot]
7dfbcc8f1d Upgrade trunk (#7030)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-15 06:16:59 -05:00
renovate[bot]
28244148a2 chore(deps): update meshtastic/device-ui digest to 301f11e (#7042)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-15 06:14:53 -05:00
Jonathan Bennett
e623c70bd0 More clear key warning messages. 2025-06-14 19:35:57 -05:00
todd-herbert
425f384b1f InkHUD DIY builds for ProMicro & Heltec T114 (#7039)
* DIY InkHUD variants (ProMicro & T114)

* Fix file encoding
> We’ve detected the file encoding as ISO-8859-1. When you commit changes we will transcode it to UTF-8.

* Update comment justifying trunk suppression
2025-06-15 09:39:46 +10:00
Jonathan Bennett
1557219bad More low-entropy keys, and don't issue a false warning when changing … (#7041)
* More low-entropy keys, and don't issue a false warning when changing node name

* CopyPasta Wasn't Tasty

* When the phone sets the publickey size to 0, regenerate right away
2025-06-14 17:09:22 -05:00
Jonathan Bennett
691917b956 Add config for RAK 13300 on RAK6421 (#7037) 2025-06-14 09:59:25 -05:00
Ben Meadors
cc0fbfbd21 Fixed breaking of inkhud / tft suffix convention 2025-06-13 06:59:05 -05:00
Csrutil
5d0bf03b01 add support for GAT562 Mesh Trial Tracker (#6984)
* add support for GAT562 Mesh Trial Tracker

* Hardware Model Definition for GAT562_MESH_TRIAL_TRACKER

* Added RAK4630 for led pin 2 (blue)

* Added RAK4630 for led pin 2 (blue) comment

* don't touch src/mesh/NodeDB.cpp

* set fixed baudrate for gat562_mesh_trial_tracker

* adjust the order of the HW_VENDOR defines

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-06-13 17:27:48 +10:00
Jonathan Bennett
8ff99437cb Don't include the blank hash 2025-06-12 22:56:40 -05:00
todd-herbert
ba93097bb7 Add InkHUD driver for WeAct Studio 1.54" display module (#7000)
* Strip redundant code from E-Ink driver

* Begin polling for E-Ink update completion sooner
In some cases, we might be waiting longer than we need to.

* E-Ink driver for WeAct 1.54" display
Currently identical to the popular GDEY0154D67 model. Kept separate now in case the drivers need to diverge in future.

* Put back code which sets the number of gate lines
2025-06-12 19:59:28 -05:00
todd-herbert
de098cca4c E-Ink driver for WEAct 2.13" BW (#7001) 2025-06-12 19:58:38 -05:00
Christian Crank
8faa04afdb Validate short and long names so whitespace or empty names cannot be used (#6993)
* Say issue #6867 about adding validation for long_name and short_name. Firmware should expect at least 1 non-whitespace character for both long_name and short_name. added the USERPREFS_CONFIG_DEVICE_ROLE example to userPrefs.jsonc

* Validation for user long_name and short_name implemented. No longer can use whitespace characters. Return BAD_REQUEST error responses when validation fails and warning logs when validation rejects invalid names.

* Improve whitespace validation for user names with ctype.h, ensure logging works

* Add whitespace validation to ham mode to prevent validation bypass and to match python cli command

* punctuation change

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-12 19:58:15 -05:00
github-actions[bot]
fede1b8597 Upgrade trunk (#7006)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-12 19:56:53 -05:00
Tom Fifield
8557bd031d Remove GPS Baudrate locking for Seeed Xiao NRF52840 Kit (#7016)
The Seeed Xiao NRF52840 Kit's default GPS is an L76K which operates
at 9600 baud, so when this variant was defined that baud rate was
specified.

However, this is a development board and it is expected that users
can attach their own devices. This includes GPS, which may operate
at a different baud rate. The current fixed baud rate prevents this,
so this patch removes that setting.

This will revert to the regular automatic probe method. This will
sucessfully detect the L76K as before (probably the same as before
since 9600 baud is the first baud rate checked), but also allow other
GPSes at other baud rates to be detected.

Fixes https://github.com/meshtastic/firmware/issues/7012

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-12 19:56:40 -05:00
Chloe Bethel
4e6418b635 Don't use assert() with side effects in a couple more places (#7009)
* Don't use assert for Lock

* Don't use assert for MQTT messages

* Split assert in getMacAddr to always run the function

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-12 19:55:35 -05:00
Jonathan Bennett
a1a5503fe9 Another known key 2025-06-12 15:18:26 -05:00
Jonathan Bennett
3b94981e56 Key erase (#7018)
* Wipe keys if low entropy

* Client Notification Payload variant

* Don't call service before it's created

* Lucky Number 14

* Catch for low-entropy keys even before region is set
2025-06-12 12:13:39 -05:00
renovate[bot]
f299447216 chore(deps): update platform-native digest to 681ee02 (#7022)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-12 05:55:51 -05:00
github-actions[bot]
5f0c8863fd [create-pull-request] automated change (#7019)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-11 20:18:47 -05:00
renovate[bot]
f9d17cdee0 chore(deps): update platform-native digest to 49634e9 (#7020)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-11 20:18:28 -05:00
Ben Meadors
68a28a177f Add elecrow panels to BIGDB_16MB 2025-06-11 16:11:32 -05:00
Ben Meadors
60ec05e536 elecrow-adv-35-tft 2025-06-11 10:54:08 -05:00
Ben Meadors
730cd388d6 Fix pio 2025-06-11 08:49:20 -05:00
Ben Meadors
6549b0477c Missed a spot 2025-06-11 06:10:34 -05:00
Ben Meadors
8304cae010 Fix issue with CI not picking up elecrow panels due to confusing env 2025-06-11 06:09:25 -05:00
Ben Meadors
0ad9758cfd Revert "chore(deps): update meshtastic/web to v2.6.4 (#6950)" (#7015)
This reverts commit 76f7207463.
2025-06-10 18:51:54 -05:00
Jonathan Bennett
e5f6804421 Add boolean to only warn a user of a duplicated key once per boot 2025-06-10 13:28:36 -05:00
Mark Trevor Birss
720add72b2 Create lora-lyra-picocalc-wio-sx1262.yaml (#7010) 2025-06-10 16:07:24 +02:00
github-actions[bot]
693b11db1d [create-pull-request] automated change (#7007)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-10 06:47:41 -05:00
Jonathan Bennett
4bf2dd04ae Warn users about low entropy keys (#7003)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-10 06:33:13 -05:00
Andreas 'count' Kotes
c6c2a4d4dd Improve support for Heltec Wireless Bridge (#6647)
* Use BLE_LED where present for CONNECTED/DISCONNECTED

* Use WIFI_LED where present for WiFi started/stopped (as AP) or connected/disconnected (as Station)

* improve support for Heltec Wireless Bridge

* satisfy 'trunk fmt'
2025-06-10 13:54:07 +10:00
github-actions[bot]
79b8e7b1cf Upgrade trunk (#6998)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-10 13:53:04 +10:00
Travis Hardiman
cf4f088337 Update URL for ThinkNode M1 (#7005) 2025-06-10 13:52:30 +10:00
Travis Hardiman
22cb20d294 Update heltec t114 URL (#7004) 2025-06-10 13:51:37 +10:00
Clément Hampaï
1eacdd0629 [Variant] nomadstar meteor pro (#6742)
* Initial support for NomadStar Meteor Pro

* Cleaned up Platformio variant comments

* Removed RTC & ETH deps.

* Removed RGB NCP5623 deps, Enabled AmbientLight by default

* Added HWID mapping

* Updated Armduino-Semihosting lib dep with archived version.

* Fixed trunk linting in AmbientLightingThread.h and hydra variant
2025-06-10 07:48:52 +10:00
renovate[bot]
67e3d57412 chore(deps): update meshtastic/device-ui digest to 1b520fc (#6991)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-09 05:56:48 -05:00
Manuel
7924ef87b5 enable custom driver (#6988)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-09 05:41:41 -05:00
HarukiToreda
3dec521f75 T-watch screen misalignment fix (#6996)
* T-watch screen misalignment fix

* Trunk fix
2025-06-09 05:27:52 -05:00
renovate[bot]
57a33790ed chore(deps): update meshtastic/device-ui digest to 2fd19f8 (#6982)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-08 04:02:47 -05:00
renovate[bot]
484af8eb9f chore(deps): update platformio/ststm32 to v19.2.0 (#6901)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-08 17:54:20 +10:00
Christian Crank
b8970d66a1 Addition of Device Role inside of userPrefs.jsonc (#6972)
* addition of device.role via userprefs. USERPREFS_CONFIG_DEVICE_ROLE now usable, ROUTER*, LOST_AND_FOUND, and REPEATER disabled.

* Removing added IS_ONE_OF macro definition since meshUtils.h exists - thanks Ben!

* Fix clang-format issues in NodeDB.cpp utilizing Trunk
2025-06-08 16:51:37 +10:00
Mario Murphy
e78033bb85 Clean up install & update shell scripts (#6839)
Fixed quoting of the `FILENAME` variable to work when the path of the
passed argument contains a space. Also fixed syntactical issues called
out by `shellcheck` in multi-condition `if` statements.

Also normalized indentation chars (was mix of tabs & spaces) and
trailing whitespace.

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-06-08 14:04:31 +10:00
Austin
8bd7adca47 Update Alpine to 3.22 (#6927) 2025-06-08 07:49:24 +10:00
renovate[bot]
f67aec40e8 chore(deps): update platformio/espressif32 to v6.11.0 (#6900)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-08 07:48:34 +10:00
github-actions[bot]
46c7d74760 Upgrade trunk (#6968)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-07 07:58:01 -05:00
Tom
15d2ae17f8 Add note to hydra to note that the button pin has no pull-up (#6979)
Add note to hydra to note that the button pin has no pull-up. Use an external resistor or remove the `#define`.
2025-06-07 06:55:58 -05:00
github-actions[bot]
91579c4650 [create-pull-request] automated change (#6980)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-07 06:55:25 -05:00
Andrew Yong
79b710a108 fix: Respect LED_STATE_ON for power and user LED (#6976)
Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-06-07 06:44:54 -05:00
todd-herbert
ba296db701 Add InkHUD driver for WeAct Studio 2.9" display module (#6963)
* Driver for WeAct Studio 2.9" ePaper module

* Clarify that flex connector marking is not a unique id

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-06 17:35:47 +12:00
github-actions[bot]
c0e1616382 Upgrade trunk (#6948)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-06-05 10:11:43 -05:00
Andrew Yong
070deb290f seeed_xiao_nrf52840_kit improvements (#6930)
* feat: seeed_xiao_nrf52840_kit improvements
- LEDs:
  - Change RGB LED to be active low as it is common anode
  - Remove re-definition of LED_PIN
  - Use red LED to indicate flash writes
  - Use blue LED as user LED (External Notification module)
- GPIO: Re-word unused BUTTON_PIN comment
- Wire: Set I2C pins to match XIAO nRF52840 Sense's LSM6DS3TR IMU
- Battery:
  - Use charge LED to detect charging state
  - Move voltage divider boilerplate out of src/main.cpp and into initVariant()
  - Fix dependencies for above in related XIAO BLE DIY variants

Build tested variants:
- seeed_xiao_nrf52840_kit
- xiao_ble
- seeed-xiao-nrf52840-wio-sx1262

Flashed to and tested on hardware:
- seeed_xiao_nrf52840_kit

Signed-off-by: Andrew Yong <me@ndoo.sg>

* chore(seeed_xiao_nrf52840_kit): Re-order generic GPIO definitions

Signed-off-by: Andrew Yong <me@ndoo.sg>

* chore: Use ADC_CTRL for XIAO nRF52840

Signed-off-by: Andrew Yong <me@ndoo.sg>

---------

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-06-05 06:45:43 -05:00
renovate[bot]
76f7207463 chore(deps): update meshtastic/web to v2.6.4 (#6950)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-04 15:15:51 -05:00
Jonathan Bennett
55b2bbf937 Generate keys when Lora Region is set (#6951)
* Generate keys when Lora Region changes

* Nest the ifs

* Even more entropy

* Namespacing
2025-06-04 12:16:37 -05:00
github-actions[bot]
a5716cf25c automated bumps (#6944)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-06-03 07:08:46 -05:00
Kalle Lilja
4d81280ac2 Add --1200bps-reset param to device-install/update scripts (#6752)
* add change-mode support

* add change-mode support

* tab to space

* fix if check

* change param name to 1200bps-reset

* update help section

* missed one in help seciton

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-02 20:35:26 -05:00
renovate[bot]
9ce44556ce chore(deps): update meshtastic/device-ui digest to 649e095 (#6943)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-02 06:29:41 -05:00
github-actions[bot]
be0c7d73a3 Upgrade trunk (#6941)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-06-02 06:16:24 -05:00
renovate[bot]
d833a9ea61 chore(deps): update meshtastic/device-ui digest to 04e3a07 (#6942)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-06-02 06:16:01 -05:00
Jonathan Bennett
5cd74f4b53 Don't give LOG_INFO a null 2025-06-01 21:03:38 -05:00
renovate[bot]
284b8bcff2 chore(deps): update meshtastic/device-ui digest to 37e2fb8 (#6925)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-31 06:15:37 -05:00
github-actions[bot]
9799f10e63 Upgrade trunk (#6922)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-30 08:38:13 -05:00
ArgoNavi
f9d4fdbb52 Update TSL2591Sensor.cpp (#6921)
Lower gain and timing to avoid saturation in bright light
2025-05-30 06:00:20 -05:00
Austin
b6cb0b148c Fix renovate for Adafruit PCT2075 (#6919) 2025-05-30 07:33:10 +10:00
Ben Meadors
7a7166d575 Revert "Add a new screen for heltec_wireless_paper. (#6894)" (#6918)
This reverts commit ba53543354.
2025-05-29 10:17:20 -05:00
Quency-D
ba53543354 Add a new screen for heltec_wireless_paper. (#6894)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-29 09:10:25 -05:00
dmarman
cb9429e83e Added full support for LTR390UV readings of UV and Lux (#6872)
* Added full support for LTR390UV readings of UV and Lux

* Trunk formatting

* Added full support for LTR390UV readings of UV and Lux

* Trunk formatting

* fix library check and unnecessary bit resolution change

* fixed log info messages and removed unused dependency

* Hopefully fixes git mess

* fix variable scope and getMetrics returns

* set metrics flags bavk to false in case something wrong happens while reading LTR390UV  mode

---------

Co-authored-by: Domingo <domingo@waxman.local>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-29 09:09:33 -05:00
github-actions[bot]
f972b62d89 Upgrade trunk to 1.24.0 (#6915)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-29 09:06:52 -05:00
Ben Meadors
7849a3d291 Trunk 2025-05-29 06:35:18 -05:00
dylanli
c0c2ec195f add support for seeed wio tracker L1 (#6907)
* add support for seeed  wio tracker l1

* add support in nrf52 arch

* fix ADC problem and comments incorrect

* fix gps wakeup pin

* fix gps pin
2025-05-29 06:33:22 -05:00
renovate[bot]
e31cd0bc77 chore(deps): update meshtastic/device-ui digest to 3dfcc97 (#6912)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-29 06:27:36 -05:00
todd-herbert
5195815df0 Parse own short name in LogoApplet (#6913) 2025-05-29 06:21:09 -05:00
Ben Meadors
42a80d8aed Coerce user.id to always be derive from the nodenum (#6906)
* Coerce user.id to always be derive from the nodenum

* Additionally null it out on send

* Revert "Additionally null it out on send"

This reverts commit 22a2d68723.
2025-05-28 11:30:59 -05:00
github-actions[bot]
da69d88790 [create-pull-request] automated change (#6909)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-28 06:20:51 -05:00
Thomas Göttgens
96c18d9908 Add LINK32 (Lilygo) Board with Light+Environment sensors (#6899)
* Add LINK32 (Lilygo) Board with Light+Environment sensors
TODO: replace PRIVATE_HW with actual HWID

* Add LINK32 (Lilygo) Board with Light+Environment sensors
TODO: replace PRIVATE_HW with actual HWID

* Update to real HWID and trunk fmt
2025-05-27 18:11:32 -05:00
GUVWAF
8908805894 Don't cancel sending ReTx for relayer if we're ROUTER(_LATE)/REPEATER (#6904)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-27 18:10:14 -05:00
github-actions[bot]
158c88ddef [create-pull-request] automated change (#6905)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2025-05-27 15:41:35 -05:00
github-actions[bot]
138dc89442 Upgrade trunk (#6898)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-27 06:19:35 -05:00
Austin
baefda213a Linux: Adjust udev rules for gpio (#6891) 2025-05-26 06:31:10 -05:00
github-actions[bot]
106dd08710 automated bumps (#6890)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-25 16:53:02 -05:00
todd-herbert
f223b8a55d Add missing parsing of UTF-8 chars (#6889) 2025-05-25 13:12:52 -05:00
Ben Meadors
75a49d3486 Add heap metrics to Local stats (#6887) 2025-05-25 11:08:56 -05:00
Michael Cullen
7d95b487ef Add PCT2075 Temperature Sensor (#6829)
This is an I2C temperature sensor. It is intended to be a drop-in
compatible sensor for the LM75, however it is more accurate.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-25 07:29:02 -05:00
Ben Meadors
2e72850d99 Fix is_unmessagable plumbing (#6886) 2025-05-25 07:24:28 -05:00
renovate[bot]
5fbdf4b6dc chore(deps): update meshtastic/device-ui digest to e63b219 (#6883)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-25 07:12:03 -05:00
github-actions[bot]
c47bdd11f9 [create-pull-request] automated change (#6885)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-25 06:56:21 -05:00
github-actions[bot]
d3b16c1e47 Upgrade trunk (#6843)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-25 06:29:00 -05:00
Andrew Yong
e29588d2e2 feat(RadioInterface): Tx power gain calculation rework (#6796)
- Rename REGULATORY_GAIN_LORA to TX_GAIN_LORA
- Move gain-based Tx power clamping from RadioInterface::applyModemConfig() to RadioInterface::limitPower()
  - User-configured Tx power now matches the Tx power out of the device connector
- Re-order [LoRa Chip]Interface.cpp limitPower() to take place before the final Tx power clamping so we clamp based on the pre-PA Tx power rather than user-configured Tx power

Tested on XIAO BLE variant.

Signed-off-by: Andrew Yong <me@ndoo.sg>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-25 06:26:31 -05:00
Chiho Sin
9b69c2a9af graphics: Add GDEY0213B74 E-Ink display driver (#6879)
Implement the GDEY0213B74 driver with configuration methods for scanning, waveform, update sequence, and polling for refresh completion. This driver supports both fast and full update types for the 2.13 inch E-Ink display.

Signed-off-by: ChihoSin chihosin@icloud.com

Signed-off-by: ChihoSin chihosin@icloud.com
2025-05-25 06:08:41 -05:00
renovate[bot]
30e83d36b7 Update meshtastic/device-ui digest to 2fba9de (#6882)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-24 19:55:19 -05:00
renovate[bot]
2c9e169451 Update meshtastic/device-ui digest to 0e9bb79 (#6880)
fix bluetooth fixedPin during restart (#135)
2025-05-24 11:33:21 +02:00
Austin
067d01b832 Bosch bsec2: Switch back to official releases (#6870) 2025-05-23 22:35:13 +02:00
renovate[bot]
3aed7b4190 Update Adafruit PM25 AQI Sensor to v2 (#6778) 2025-05-23 15:51:26 +02:00
dylanli
c01db98819 update seeed solar node led pin (#6871) 2025-05-23 08:04:17 -05:00
Ben Meadors
beba1b4882 Added map report precision bounds (#6862)
* Added map report precision bounds

* Log warning

* Precision range should be 12-15

* Missed commit

* Update tests

* That method was renamed

* Removed now-defunct test call

* Remove defunct test
2025-05-22 20:33:46 -05:00
todd-herbert
ba1ef45024 InkHUD Extended ASCII (#6768)
* Custom AdafruitGFX fonts with extended ASCII encodings

* AppletFont handles re-encoding of UTF-8 text

* Manual parsing of text which may contain non-ASCII chars

* Display emoji reactions, even when unprintable
Important to indicate to users that a message has been received, even if meaning is unclear.

* Superstitious shrink_to_fit
I don't think these help, but they're not hurting!

* Use Windows-1252 fonts by default

* Spelling

* Tidy up nicheGraphics.h

* Documentation

* Fix inverted logic
Slipped in during a last minute renaming while tidying up to push..
2025-05-22 18:16:53 -05:00
renovate[bot]
b12e9d43be Update meshtastic/device-ui digest to 405ca49 (#6865)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-22 14:53:16 -05:00
Ben Meadors
7cd50d7044 If a contact is add from a QR, it's "verified" manually (#6858)
* If a contact is add from a QR, it's "verified" manually

* Update src/mesh/NodeDB.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-22 07:40:36 -05:00
Jonathan Bennett
41c1b29d70 Add basic handling for is_manually_validated (#6856) 2025-05-20 21:29:29 -05:00
Ben Meadors
6041357cbb Increase the debt ceiling 2025-05-20 20:31:01 -05:00
github-actions[bot]
cf3f35d566 [create-pull-request] automated change (#6857)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-20 19:51:03 -05:00
Jonathan Bennett
e0f878872f Hostmetrics user string (#6850) 2025-05-20 13:04:05 -05:00
renovate[bot]
c70fa0ef13 Update meshtastic/device-ui digest to c9a55f6 (#6845)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-19 19:10:22 +02:00
HarukiToreda
16994c8725 Fix for ICM-20948 not initializing (#6827)
* Fix for ICM-20948 not initializing

* trunk fix
2025-05-19 06:49:38 -05:00
renovate[bot]
3dd6dc0296 Update meshtastic/device-ui digest to 48e963f (#6841)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-18 14:37:54 -05:00
renovate[bot]
b2d81b740f Update dorny/test-reporter action to v2.1.0 (#6833)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-18 21:11:02 +10:00
Jonathan Bennett
61e4eb12e6 Use the _init_zero macro correctly for HostMetrics (#6837) 2025-05-17 14:02:39 -05:00
github-actions[bot]
5b312ab917 [create-pull-request] automated change (#6836)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2025-05-17 12:29:18 -05:00
github-actions[bot]
a50a94150a [create-pull-request] automated change (#6834)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2025-05-17 10:44:02 -05:00
renovate[bot]
3398a52a34 Update meshtastic/device-ui digest to 55f7152 (#6830)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-17 06:15:44 -05:00
Jonathan Bennett
066609a718 Remove incomplete compass boot calibration (#6825)
The made it in from testing unintentionally.
2025-05-16 12:29:08 +10:00
Jonathan Bennett
1ef4caea05 Host metrics (#6817)
* Add std::string exec() function to PortduinoGlue for future work

* MVP for HostMetrics module.

* Fix compilation for other targets

* Remove extra debug calls

* Big numbers don't do well as INTs.

* Add HostMetrics to config.yaml
2025-05-15 09:23:37 -05:00
Austin
7d8f9c7f6d Stop the madness! Run as a user (not root) (#6718)
* Stop the madness! Run as a user (not root)

* Trigger fsdir migration for < 2.6.9

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-15 06:40:46 -05:00
github-actions[bot]
c2d5862161 automated bumps (#6820)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-15 06:40:07 -05:00
Tom Fifield
6bba17d463 Add suppport for Quectel L80 (#6803)
* Add suppport for Quectel L80

Another PMTK family chip, requires only a modification to the
probe code.

* Update support for L80 based on testing.
2025-05-15 19:26:41 +10:00
Ben Meadors
ef9d0d7805 Go 2025-05-14 20:22:01 -05:00
Ben Meadors
60d2cb35e0 Namespace 2025-05-14 18:55:27 -05:00
github-actions[bot]
ed6de5095e [create-pull-request] automated change (#6815)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-14 17:54:21 -05:00
Ben Meadors
b63b73ab84 Fix 2025-05-14 17:16:46 -05:00
Ben Meadors
3901ae8956 Default 2025-05-14 16:44:32 -05:00
Ben Meadors
7cffd9ba70 Added new map report opt-in for compliance and limit map report (and default) to one hour (#6813)
* Added new map report opt-in for compliance and limit map report (and default) to one hour

* Trunk
2025-05-14 15:31:28 -05:00
Ben Meadors
fc64bea698 Unmessagable implementation and defaults (#6811)
* Unmessagable implementation and defaults

* Router and router late are unmessagable by default

* Update src/modules/AdminModule.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-14 15:28:09 -05:00
github-actions[bot]
a51a6b8c47 [create-pull-request] automated change (#6812)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-14 14:41:37 -05:00
github-actions[bot]
1af4a0bdc9 Upgrade trunk (#6797)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-14 14:10:45 -05:00
github-actions[bot]
bc313da064 [create-pull-request] automated change (#6810)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-14 13:48:14 -05:00
Austin
f16402dec1 MQTT userprefs (#6802) 2025-05-14 13:39:46 -05:00
todd-herbert
feafd2bc0c Protect T-Echo's touch button against phantom presses in OLED UI (#6735)
* Guard T-Echo touch button during LoRa TX

* Guard for T-Echo only

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-14 06:33:51 -05:00
rcarteraz
b1955c34aa Update Seeed Solar Node (#6763)
* Update Seeed Solar Node

* Update Seeed Solar Node

* updates

* updates

* updates

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-14 06:32:24 -05:00
Ben Meadors
94af3bd1ab Formatting 2025-05-14 06:31:18 -05:00
Richard Zhang
d9ad2322e8 Fixes BUG #6243 Heltec Tracker (#6781)
* fix wireless tracker screen issues

* fix SHTC3 BUG

* Remove the 32K crystal oscillator option for the Wireless Paper and Vision Master series.

* Correct spelling errors

* Update src/graphics/Screen.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-14 06:29:05 -05:00
Ben Meadors
0a8bd1e4be Add contact admin message (for QR code) (#6806) 2025-05-14 05:33:51 -05:00
Chris Vogel
a7415791a5 device-install.sh: detect t-eth-elite as s3 device (#6767)
device-install.sh: detect t-eth-elite as s3 device
fixes https://github.com/meshtastic/firmware/issues/6754#issuecomment-2857468902
Thanks @mverch67!
2025-05-13 15:10:57 +02:00
Thomas Göttgens
cc66f7c79b Crowpanel 4.3, 5.0, 7.0 support (#6611)
* SD software SPI control
* fix notification crash;
* allow wake on touch
* don't build non-MUI variants
* use pwm buzzer
* Finalize support for Crowpanel TFT 2.4, 2.8 and 3.5
* add hardware ID for TFT panels
* Add stubs for the bigger panels. WIP!
* fix braces
* elecrow 4.3, 5.0, 7.0 support
* completed implementation 4.3, 5.0, 7.0 variants
* NodeDB default config & simplified light sleep macros
* trunk fmt
* remove flags
* removed leftovers (note: rtc gpios are only needed for deep sleep; the remove section caused issues with the elecrows)
---------
Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-05-13 14:15:52 +02:00
github-actions[bot]
e1417cff2e [create-pull-request] automated change (#6804)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-13 06:59:26 -05:00
Ben Meadors
b9fcd9da23 Add some no-nonsense coercion for self-reporting node values (#6793)
* Add some no-nonsense coercion for self-reporting node values

* Update src/mesh/PhoneAPI.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-05-11 18:08:29 -05:00
Ben Meadors
2a06b058fd Only send nodes on want_config of 69421 (#6792) 2025-05-11 15:18:53 -05:00
Tom
62e1974d09 Add clarifying note about AHT20 also being included with AHT10 library (#6787)
* Update AHT10.h

Add clarifying note about AHT20 also being included

* Update AHT10.cpp

Add clarifying note about AHT20 also being included
2025-05-11 17:17:37 +08:00
renovate[bot]
b208e1924f chore(deps): update meshtastic/device-ui digest to 7dee10a (#6786)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-11 00:59:38 +02:00
Austin
b17bb49a63 Actions: Fix end to end tests (#6776) 2025-05-10 16:21:23 -05:00
renovate[bot]
7c9296b0f4 chore(deps): update meshtastic/device-ui digest to 027f5a5 (#6783)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-10 18:48:39 +02:00
renovate[bot]
23fe093a65 chore(config): migrate renovate config (#6784)
* chore(config): migrate config renovate.json

* Prettier: Ignore renovate

---------

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: vidplace7 <vidplace7@gmail.com>
2025-05-10 11:49:01 -04:00
renovate[bot]
c2a38357f1 chore(deps): update meshtastic/device-ui digest to 09b1780 (#6782)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-10 14:54:58 +02:00
github-actions[bot]
3aee4bfc6b Upgrade trunk (#6758)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-10 19:01:03 +08:00
Ben Meadors
981ecfdb61 Add client notification before role based power saving (sleep) (#6759)
* Add client notification before role based power saving (sleep)

* Unsigned
2025-05-07 21:20:32 -05:00
Tom
ca9bf6b31a Update XIAO_NRF_KIT RXEN Pin definition (#6717)
The XIAO NRF kit comes with a hat which has a slightly different pinout than the one supplied with the XIAO S3. At the last update, the RXEN pin was not moved with the rest.
2025-05-07 21:20:15 -05:00
renovate[bot]
ff2a12d579 chore(deps): update adafruit bme280 to v2.3.0 (#6708)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-08 08:32:01 +08:00
Jonathan Bennett
3a6fc668d8 20948 compass support (#6707)
* Add __has_include blocks for sensors

* Put BMP and BME back in the right sensors

* Split environmental_base to environmental_extra, to compile the working sensor libs for Native

* Remove hard-coded checks for ARCH_PORTDUINO

* Un-clobber bmx160

* Move BusIO to environmental_extra due to Armv7 compile error

* Move to forked BusIO for the moment

* Switch to Meshtastic ICM-20948 lib for Portduino support

* Use 20948 for compass direction

* Compass is more than just RAK4631

* Cleanup for 20948 compass

* use Meshtastic branch of 20948 lib

* Check for HAS_SCREEN for showing calibration screen

* No accelerometerThread on STM32
2025-05-07 18:38:42 -05:00
renovate[bot]
b657ba1abb chore(deps): update sparkfun 9dof imu breakout icm 20948 to v1.3.2 (#6761)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-07 13:27:44 -05:00
Ben Meadors
6f256c06f6 Fix warning 2025-05-07 09:26:10 -05:00
Benjamin Faershtein
86217111b2 Update SECURITY.md (#6757) 2025-05-07 06:28:18 -05:00
Austin
57d6c1fa85 Fix event templates (names, PSKs) (#6753) 2025-05-06 18:05:22 -04:00
Austin
62421a83fd Fix EVENT_MODE on mqttless targets (#6750) 2025-05-06 13:12:25 -04:00
Austin
867f50ab11 Don't run test-native for event firmwares (#6749) 2025-05-06 12:03:01 -05:00
renovate[bot]
1e81ebed06 chore(deps): update meshtastic/device-ui digest to 35576e1 (#6747)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-06 11:14:45 -05:00
github-actions[bot]
dd2cf633b0 Upgrade trunk (#6745)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-06 11:09:25 -05:00
github-actions[bot]
fdbe16f650 Bump release version (#6743)
* automated bumps

* Bump org.meshtastic.meshtasticd, fix GHA

---------

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: vidplace7 <vidplace7@gmail.com>
2025-05-06 11:09:14 -05:00
Austin
a2903921cd Renovate: fix device-ui match (#6748) 2025-05-06 11:09:01 -05:00
Austin
2d6181fca0 update bosch bsec2 (#6727)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-05 06:03:36 -05:00
github-actions[bot]
a32e45f8f2 Upgrade trunk (#6737)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-05 05:16:51 -05:00
Austin
055fdcb7f6 Renovate: Add changelogs for device-ui, cleanup (#6733) 2025-05-05 08:08:39 +08:00
Austin
8bb1f3e869 Update template for event userprefs (#6720) 2025-05-04 13:18:48 -05:00
github-actions[bot]
d75c91a760 [create-pull-request] automated change (#6732)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-05-04 08:39:59 -05:00
renovate[bot]
9d31d9f43b chore(deps): update meshtastic-device-ui digest to b9e2ad1 (#6729)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-03 22:18:39 +02:00
Austin
152b8b1b02 Revert "router: on linux add a mutex around the queue (#6709)" (#6726)
This reverts commit 987623567a.
2025-05-02 13:53:25 -04:00
todd-herbert
10693c4569 Lock SPI bus while in use by InkHUD (#6719)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-05-02 06:20:56 -05:00
renovate[bot]
7da8aea1df chore(deps): update meshtastic-device-ui digest to aa38459 (#6706)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-05-02 06:16:53 -05:00
github-actions[bot]
baae2503d5 Upgrade trunk to 1.22.15 (#6608)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-05-02 16:24:21 +08:00
Ferdia McKeogh
947191a797 Add PA1010D GPS support (#6691) 2025-05-02 10:11:09 +08:00
Jorropo
987623567a router: on linux add a mutex around the queue (#6709)
UDP reception happens on an other thread, avoid data races and potential data corruption issues.
2025-05-01 06:32:20 -05:00
Manuel
a8ab6e82e6 MUI framebuffer support (#6703)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-30 20:50:30 -05:00
todd-herbert
5c005aaed5 Restore InkHUD to defaults on factory reset (#6637)
* Erase InkHUD settings on factory reset

* Documentation

* Captialn't
Lower case m. Also move the include statement to .cpp, because it doesn't really need to be in the .h
2025-05-01 12:28:05 +12:00
renovate[bot]
f9fbc3ff86 Update platform-native digest to 622341c (#6702)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-30 15:55:13 -05:00
renovate[bot]
124f4daa71 Update meshtastic-device-ui digest to 33aa689 (#6705)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-30 22:14:38 +02:00
renovate[bot]
00e2ac33ad Update platform-native digest to e19f77e (#6701)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-30 06:24:47 -05:00
Jonathan Bennett
845088e45b Add 100 msecond delay in tft_task_handler when deviceScreen is null (#6695)
* Add 100 msecond delay in tft_task_handler when deviceScreen is null, to fix 100% usage bug

* move portduino tft task creation into tftSetup

* remove superfluous check

* update platform-native commit

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2025-04-30 06:17:24 -05:00
Ben Meadors
e0b1fdb5e8 Rate limit waypoints and alerts and increase to allow every 10 seconds instead of 5 (#6699)
* Rate limit waypoints and alerts and increase to allow every 10 seconds instead of 5.

* Update src/mesh/PhoneAPI.cpp

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* Doot

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
2025-04-30 06:08:10 -05:00
Jorropo
a7ef9e9c08 udp-multicast: remove the thread from the multicast thread API (#6685)
* udp-multicast: remove the thread from the multicast thread API

The whole API is parallel & asynchronous we don't need to start a thread ourself,
the implementation probably does when we call start listening already.

* Take copilot advice and call it a handler

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-30 05:52:42 -05:00
Austin
216fbf2343 Update 'Adafruit BusIO' to 1.17.1 (#6694) 2025-04-29 19:24:00 -04:00
Jorropo
635de2d229 udp-multicast: bump platform-native to fix UDP read of unitialized memory bug (#6686)
* udp-multicast: bump platform-native to fix UDP read of unitialized memory bug

Fixes: #6683

* Update portduino.ini

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-29 06:31:53 -05:00
Colin
72eae42b81 PMSA003I: add support for driving SET pin low while not actively taking a telemetry reading (#6569)
* support manually shutting off power to the PMSA003I sensor when we aren't doing a telemetry reading

* add comment about PMSA003I_WARMUP_MS to AirQualityTelemetry.cpp

* fix typos, use arduino gpio defines instead of magic numbers

* support manually shutting off power to the PMSA003I sensor when we aren't doing a telemetry reading

* add comment about PMSA003I_WARMUP_MS to AirQualityTelemetry.cpp

* fix typos, use arduino gpio defines instead of magic numbers

* RAK4631: add PMSA003I_ENABLE_PIN define

* fix indentation

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-29 06:31:01 -05:00
renovate[bot]
b4e8f7dbb6 Update Adafruit BusIO digest to 159f86a (#6681)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-28 20:32:19 -05:00
Jonathan Bennett
473ef1bc03 Step one of Linux Sensor support (#6673)
* First addition of __has_include for sensor support

* Add __has_include blocks for sensors

* Put BMP and BME back in the right sensors

* Make TelemetrySensor::setup() a pure virtual finction

* Split environmental_base to environmental_extra, to compile the working sensor libs for Native

* Remove hard-coded checks for ARCH_PORTDUINO

* Un-clobber bmx160

* Move BusIO to environmental_extra due to Armv7 compile error

* Move to forked BusIO for the moment

* Enable HAS_SENSOR for Portduino

* Move back to Adafruit BusIO after patch
2025-04-28 18:35:13 -05:00
renovate[bot]
ca8c177363 Update meshtastic-device-ui digest to 8113d4f (#6677)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-29 08:24:00 +10:00
Kalle Lilja
77e6868d5d Fix create pull request (#6680)
* add base property

* bump to 2.6.7 - manual

* disable pip version check
2025-04-28 15:47:09 -05:00
Ben Meadors
54c1423039 Use the last GOOD version 2025-04-26 06:17:08 -05:00
Austin
03f19bca0e Downgrade web to 2.5.4 (#6669) 2025-04-25 11:30:20 -05:00
todd-herbert
89df9d7686 Fix WiPhone variant.h (#6664) 2025-04-24 20:40:48 -05:00
renovate[bot]
45fcd479f6 Update meshtastic-device-ui digest to 189ed6c (#6657)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-23 20:50:35 +02:00
GUVWAF
b1e35cd8b3 Fix preamble detected IRQ flag (#6653) 2025-04-22 14:21:29 -05:00
todd-herbert
70ced735d9 Correct a typing error in InkHUD display driver (#6651)
* Fix LCMEN2R13EFC1 LUT
A typing error when the driver was initially created.

* Spelling..
2025-04-22 06:25:53 -05:00
Manuel
24e9539d40 remove buzzer (#6652) 2025-04-22 06:25:07 -05:00
Austin
72dd5bd88d Publish firmware all together (#6642) 2025-04-20 16:31:47 -04:00
Austin
8812eadd44 Revert "Add IP Address Frame (#6615)" (#6639)
This reverts commit 5d48d2c0a7.
2025-04-20 09:49:21 -05:00
Ben Meadors
48dc0e014c Revert "Lib Update (#6510)" (#6640)
This reverts commit e2f6600cb9.
2025-04-20 09:48:07 -05:00
Austin
e03f3de185 Build and deploy event firmwares (#6628) 2025-04-20 09:45:58 -05:00
Nivek-domo
5d48d2c0a7 Add IP Address Frame (#6615)
* Update Screen.cpp

add ip on screen if has ethernet pcb like w5500 spi

* Run Trunk Format and Translate Comments FR->EN

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-04-20 20:06:39 +10:00
Nivek-domo
2b57ffafd7 Rak13800 Ethernet works on rak11310 too
we can use rak13800 on rak11310 too
2025-04-20 18:51:01 +10:00
renovate[bot]
a30f431b6a Update Kongduino-Adafruit_nRFCrypto digest to 5f838d2 (#6634)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-19 18:49:05 +02:00
Austin
916afb5098 appdata.xml: Add date to all releases (#6632) 2025-04-19 10:56:41 -04:00
Austin
d26b50b78c docker alpine: Add available.d config templates (#6631) 2025-04-19 00:29:59 -04:00
Austin
c6e5ec055f RPM: Build native-tft target (#6613) 2025-04-19 10:48:32 +10:00
renovate[bot]
5ab1db0142 chore(deps): update meshtastic-device-ui digest to 65eb74f (#6624)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-18 09:36:23 -05:00
Austin
64a1cd3f99 Docker is fun (#6623) 2025-04-18 10:29:39 -04:00
Austin
9da141aa8c Add TFT docker builds (for CI) (#6614) 2025-04-18 07:27:38 -05:00
todd-herbert
74b3dc34e4 Fix crash when clearing NRF52 BLE bonds (#6609)
* Fix crash before clearing BLE bonds

* Prevent clients re-pairing BLE during factory reset
Clients seem able to re-pair BLE after clearing bonds during factory reset, even after advertising disabled. This seems to primarily occur on Android devices, which seem to more actively maintain the BLE connection.
As a workaround, `NRF52Bluetooth::shutdown` swaps the BLE pairing callback to one which actively rejects new connections.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-17 17:11:42 -05:00
Thomas Göttgens
e2f6600cb9 Lib Update (#6510)
* Lib Update

Draft because PIN display doesn't work yet.

* pin entry still no worky

* Fix for missing PIN code issue (#6574)

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Alexander Begoon <alex@begoonlab.tech>
2025-04-17 15:58:28 -05:00
Thomas Göttgens
ef14967fbf Crowpanel 2.4,2.8 and 3.5 support (#6355)
Co-authored-by: mverch67 <manuel.verch@gmx.de>
2025-04-17 16:03:37 +02:00
github-actions[bot]
c177c6d655 [create-pull-request] automated change (#6610)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-04-17 05:33:42 -05:00
Benjamin Kyd
a36f21b29a Fix compiler error in PowerFSM when WiFi is excluded (#6603) 2025-04-17 11:36:19 +02:00
dylanli
d74359abf0 add support for Seeed solar panel (#6597)
* add seeed_solar_node

* fix RF_SW problem

* fix IIC problem

* Update Button redefination

* Add on-board flash pin defination

* fix missing a ','

* update seeed sorlar panel defination

* fix word spell

* fix upstream change

* fix upstream change

* fix upstream change

* fix formate

* Restore the FLASH definition that was deleted by mistake and pull down the CS pin to ensure low power consumption

* fix led defination conflict

* Delete lib/device-ui directory

* Restore protobufs submodule

---------

Co-authored-by: WayenWeng <jinyuan.weng@seeed.cc>
2025-04-17 16:11:17 +10:00
Benjamin Kyd
5fd64d4114 Fix uninitialised memory read (adminModule) (#6605) 2025-04-16 14:42:08 -05:00
github-actions[bot]
816d948ee5 Upgrade trunk (#6592)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-16 06:15:33 -05:00
Niklas
e0dafc3618 fix: set upload_speed for tlora_v1 (#6601) 2025-04-16 06:15:16 -05:00
Mark Trevor Birss
4a9a59342a Create lora-piggystick-lr1121.yaml (#6600) 2025-04-16 11:23:52 +02:00
Austin
5699d8632e Debian: use native-tft compile target (#6580) 2025-04-16 11:21:31 +02:00
Aaron.Lee
e5cd0d613c Make startup screen show the short ID (#6591)
* Update the short ID show on the boot up screen function
2025-04-16 11:20:12 +02:00
Benjamin Kyd
64c8bde04a Update platformio.ini to exclude unused modules from t1000-e (#6584)
* Update platformio.ini to exclude unused modules
* Add No EXT GPIO flag and also correct some exclusions in main
* CANNEDMSG != CANNEDMESSAGES
* Remove NO_EXT_GPIO
2025-04-16 10:12:23 +02:00
github-actions[bot]
4477031971 [create-pull-request] automated change (#6599) 2025-04-16 09:46:06 +02:00
Niklas
1138f74e2c fix: set upload_speed for tlora_v1_3 & tlora_v2_1_16 (#6595) 2025-04-15 20:39:13 -05:00
todd-herbert
cf5c8de92e Fix spurious button presses on some T-Echos (#6590)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-15 20:33:44 -05:00
Kalle Lilja
7e8294dfad FlatHub: bump metainfo.xml on release (#6578)
* add bump_metainfo.py

* bump org.meshtastic.meshtasticd.metainfo.xml on release

* update bump-version job to trigger on published

* use defusedxml.ElementTree parse

* move bump_metainfo, use requirements.txt

* add bin/bump_metainfo/requirements.txt to renovate

* Switch to short version string

* Bump version.properties to 2.6.6

* change version format

* remove url

* Add url back in

* Update url format

* manual add 2.6.6

* consolidate into one PR

* update run steps

* add ability to add date if missing

* update pull request title

* add comments

* remove quote changes

---------

Co-authored-by: Austin <vidplace7@gmail.com>
2025-04-15 18:57:21 -04:00
Tom Fifield
98411d408a Trunk fixes for heltec mesh pocket. (#6588)
https://github.com/meshtastic/firmware/pull/6533 was merged
without running trunk. This patch fixes the newly introduced
trunk errors.
2025-04-15 16:37:09 -05:00
Ben Meadors
040a34fca8 Switch to actually maintained thingsboard pubsubclient (#5204)
* Switch to actually maintained thingsboard pubsubclient

* .0

* TBPubSubClient

* SetBufferSize is split into Send and Receive.

* Update TBPubSubClient to 2.11

* Update platformio.ini

Co-authored-by: Austin <vidplace7@gmail.com>

* Re-add setBufferSize fix

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-04-15 10:50:24 -05:00
renovate[bot]
ecd9f015d8 chore(deps): update meshtastic-device-ui digest to da8fb5e (#6593)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-15 06:41:52 -05:00
github-actions[bot]
4e30023a4b [create-pull-request] automated change (#6589)
Co-authored-by: fifieldt <1287116+fifieldt@users.noreply.github.com>
2025-04-15 06:41:33 -05:00
Aaron.Lee
b46aad85cc Add new hardware: Heltec MeshPocket (#6533)
* Add Heltec MeshPocket.

* MeshPocket source code update

* Optimiz code for refresh border during full update.

* Update Heltec MeshPocket json file info.
2025-04-15 13:34:30 +10:00
renovate[bot]
c4dc3472ac chore(deps): update meshtastic-device-ui digest to 3fde170 (#6586)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-15 01:09:32 +02:00
github-actions[bot]
28e62e53e5 Upgrade trunk (#6581)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-14 07:50:09 -05:00
renovate[bot]
3eb845eaae chore(deps): update meshtastic-device-ui digest to 3cdb8a6 (#6572)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-12 19:28:37 -05:00
renovate[bot]
e4c2730f71 chore(deps): update meshtastic-device-ui digest to 13f69c5 (#6567)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-12 19:47:36 +02:00
Austin
e7d0837d01 Add Meshtastic Linux desktop metadata (#6568) 2025-04-11 15:54:53 -05:00
Tavis
e7ce910c3b Add generic thread module (#5484)
* compiling, untested

* use INCLUDE not EXLUDE for option to include module

* protobuf update

* working genericthread module

Update protobufs

* use EXCLUDE style instead of INCLUDE

* Update Modules.cpp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-11 19:38:44 +02:00
github-actions[bot]
e957009019 Upgrade trunk (#6564)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-11 07:48:13 -05:00
Kevin Jahaziel Leon Morales
7079f538ed feat: Add Electronic Cats variant for Catsniffer (#6483)
* feat: Add Electronic Cats variant for catsniffer
* fix: Trunk fmt
* fix: Variant error
2025-04-11 13:26:30 +02:00
Ken Piper
baa05aacf5 fix: Correct underlying cause of T-Watch not functioning when set to a 16MB filesystem (#6563)
* Fix maximum flash size in T-Watch S3 board definition
* Revert "Fix: T-Watch-S3 has 8MB Flash (#6407)"
This reverts commit 769f0623be.
2025-04-11 13:04:37 +02:00
Austin
4ef9eae695 Portduino: Set C standard to 17 (#6561) 2025-04-11 13:02:55 +02:00
renovate[bot]
854d74f8db chore(deps): update meshtastic-device-ui digest to acf343b (#6559)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-10 22:18:42 +02:00
Austin
91f38797a8 Don't renovate toolchain-gccarmnoneeabi (#6554) 2025-04-09 19:23:15 -05:00
todd-herbert
06ce6f3e8a fix: remove redundant GPS code targeting Heltec T114 (#6497) 2025-04-10 09:48:40 +10:00
Austin
3694805938 renovate: Link PIO deps to PlatformIO page (#6548) 2025-04-10 08:40:14 +10:00
renovate[bot]
5c13f3451c chore(deps): update meshtastic-device-ui digest to 9345b03 (#6552)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 16:10:01 -05:00
Austin
1008a08c99 Revert "chore(deps): update platformio/toolchain-gccarmnoneeabi to v1.140201.…"
This reverts commit 1888342a57.
2025-04-09 17:07:14 -04:00
renovate[bot]
e98da27446 chore(deps): update ubuntu to v24 (#6541)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 13:38:21 -05:00
renovate[bot]
daa03aba30 chore(deps): update meshtastic-esp32_https_server digest to 896f177 (#6542)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 13:02:42 -05:00
renovate[bot]
456f94511f chore(deps): update libch341-spi-userspace digest to af9bc27 (#6539)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 12:57:43 -05:00
renovate[bot]
1888342a57 chore(deps): update platformio/toolchain-gccarmnoneeabi to v1.140201.0 (#6546)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 12:57:21 -05:00
renovate[bot]
8e40d88e24 chore(deps): update platform-native digest to 46f509b (#6540)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 12:56:36 -05:00
renovate[bot]
0d8e39cc2a chore(deps): update ntpclient to v3.2.1 (#6545)
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
2025-04-09 12:46:58 -05:00
Austin
78fa4c5c70 Setup RenovateBot (#6535) 2025-04-09 12:31:40 -05:00
todd-herbert
536b6d87c6 InkHUD support for LilyGo T3S3 E-Paper (#6503)
* Purge an incomplete E-Ink driver

* Use the deep-sleep mode of SSD16XX E-Ink displays

* TwoButton doesn't need to store pin mode

* Fix false positive button presses after light sleep

* E-Ink driver for DEPG0213BNS800

* InkHUD support for LilyGo T3S3 E-paper

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-09 10:41:51 -05:00
Andrik45719
5256ae90dc DIY v1/v1_1 add TCXO_OPTIONAL make it so that the firmware can try both TCXO and XTAL (#6534)
* EBYTE_E22 TCXO_OPTIONAL

* EBYTE_E22

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-09 10:40:38 -05:00
Thomas Göttgens
fc3d9f2a15 fix power pin definition 2025-04-09 14:55:23 +02:00
GUVWAF
69f938ea98 Send UDP packet even if it's encrypted (#6524)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-09 06:13:49 -05:00
Tom Fifield
ec298199ee remove checkov from trunk config (#6532)
We don't have terraform, cloudformation, helm templates ... and this check pushes out new versions very frequently which is annoying with out automation :)
2025-04-09 05:40:12 -05:00
Austin
0d800b7a22 meshtasticd docker: Support webui (#6482) 2025-04-08 16:14:39 -05:00
Ikko Eltociear Ashimine
1b1d4625aa chore: update ubx.h (#6522)
usefull -> useful
2025-04-08 14:04:33 -05:00
Manuel
fb2010552f MUI: update commit reference (#6526)
new feature: map locations filtering
bugfix: boot logo / bt logo
2025-04-08 13:50:58 -05:00
Thomas Göttgens
c94dd1e331 Minor adjustment of blink codes and 'unstick' the M2 button. (#6521) 2025-04-08 10:46:39 -05:00
Austin
cfc2a96a45 Update web, use centrally defined version (#6500) 2025-04-08 09:09:23 -05:00
github-actions[bot]
c0dab4a672 Upgrade trunk (#6519)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-08 08:27:58 -05:00
Eric Wolak
12d1305618 Fix device-specific logic in install script (#6508)
* Fix device-specific logic in install script

These new for loops to check for variants in a list should be checking for the string to _be empty_, not _non-empty_, if a match is found causing the replacement to fire.

* simplify logic per review feedback

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-07 19:34:16 -05:00
Thomas Göttgens
a084073cc1 inkhud doesn't have a button thread (#6513) 2025-04-07 08:35:51 -05:00
Mark Trevor Birss
e2933bcb5b Update platformio.ini (#6512) 2025-04-07 07:04:31 -05:00
Thomas Göttgens
606abfc116 Fix several features of M1 and M2 (i know what the 7 is now ...) (#6507)
* Fix several features of M1 and M2 (i know what the 7 is now ...)

* 'THe' should be 'The'.

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>

* remove floating definition

---------

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-07 05:46:22 -05:00
github-actions[bot]
860e8eca5a [create-pull-request] automated change (#6511)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-04-07 11:51:05 +02:00
github-actions[bot]
5a9d70b445 Upgrade trunk (#6509)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-07 10:39:45 +02:00
Nasimovy
2125c03974 Fix for PSRAM detection on ESP32-S3R8 and t-beam (#6504)
* remove duplicate HAS_LP5562  introduced by #6422

* T190 PSRAM fix

* all the boards with a ESP32-S3R8

* T-beam V1.1 PSRAM
2025-04-06 20:27:46 -05:00
Chris LaFlash
56eb0c08b2 Add support for Quectel-L96, a MT3333 module (#6498) 2025-04-06 11:49:01 +08:00
Nasimovy
1b33189fe6 remove duplicate HAS_LP5562 introduced by #6422 (#6494) 2025-04-04 08:35:15 -05:00
todd-herbert
25237a15ff feat: menu entry to send adhoc-ping (#6492) 2025-04-04 05:53:54 -05:00
Ben Meadors
0110275494 Revert "Try-fix ESP32 wifi disconnects (#6363)" (#6493)
This reverts commit a902776e57.
2025-04-04 04:59:31 -05:00
github-actions[bot]
4dfba50304 [create-pull-request] automated change (#6490)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-04-03 20:23:44 -05:00
Nasimovy
7494106170 TCA8418 initial config + basic 3x4 keypad config (#6422)
* TCA8418 with base config for 3x4 keypad

* replaced k with uppercase K

* change detection method

* reflect changes  #6381

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-03 14:18:18 -05:00
Jason B. Cox
0665802823 Improve PKC unit test coverage (#6485)
* Cleanup PKC unit test a bit

* Add unit test coverage for encryptCurve25519

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-03 14:17:36 -05:00
rcarteraz
1017f6af35 remove very long slow (#6486) 2025-04-03 09:07:43 -05:00
Thomas Göttgens
11bafae287 update OLED library (#6489) 2025-04-03 16:02:46 +02:00
github-actions[bot]
31130fd49e Upgrade trunk to 1.22.12 (#6487)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-03 06:52:39 -05:00
Thomas Göttgens
594cb0cc1e reinstate M1 Backlight (#6484) 2025-04-02 19:15:12 -05:00
Austin
ef18a9b5b5 meshtasticd: Set available.d dir in yaml (#6481) 2025-04-02 06:55:14 -05:00
github-actions[bot]
67fddcc214 Upgrade trunk (#6480)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-04-02 05:41:36 -05:00
Clément Hampaï
f6ed10f329 Added initial support for Texas Instruments LP5562 (#6381)
* Added initial support for Texas Instrument LP5562
* Added proper support for Ambient Lighting
* Code merge for all RBG_LED enabled devices
* Fixed forgotten log_info & added firstRGBLED()
2025-04-01 22:39:40 +02:00
Benjamin Faershtein
644849126c Fixes #6315 (#6475)
* Fixed Canned Messages send to non broadcast

* Small fix

* Fix formatting for singular canned message

* Trunk fmt

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-04-01 12:50:10 -05:00
Manuel
ea4ce8d827 MUI unPhone-tft: fix defaults (#6477) 2025-04-01 08:53:15 -05:00
todd-herbert
128c347c64 fix: T-Echo frontlight on at boot when using OLED UI (#6474) 2025-04-01 05:26:46 -05:00
todd-herbert
ae88759059 draft an InkHUD variant for Elecrow Thinknode M1 (#6473)
Only an initial guess. No hardware here yet for testing. Button assignments are largely placeholder.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-31 19:08:23 -05:00
Austin
2c01fad798 meshtasticd: Add FrequencyLabs MeshAdv-Mini Hat (#6458) 2025-03-31 07:31:54 -05:00
Ben Meadors
a5efbfccd7 Disable bluetooth config on rp2040, portduino (for now), and stm32 (#6465)
* Disable bluetooth config on rp2040, portduino (for now), and stm32

* Add comments and exclude C6
2025-03-31 06:32:54 -05:00
todd-herbert
886bffe8f3 fix: honor user button customization (#6400)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-31 06:03:44 -05:00
Ben Meadors
39408fd3b1 Disable network config for non-eth_gateway nrf52 and non-W RP2040 targets (#6462)
* Disable network config for non-eth_gateway nrf52 and non-W RP2040 targets

* Use HAS_ETHERNET logic
2025-03-31 05:50:53 -05:00
github-actions[bot]
3314b00fcc Upgrade trunk (#6471)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-31 11:16:13 +02:00
Ben Meadors
72db671e00 Try-fix some import of configuration inconsistencies (#6364) 2025-03-31 09:54:27 +02:00
todd-herbert
bd2d2981c9 Add InkHUD driver for WeAct Studio 4.2" display module (#6384)
* chore: todo.txt

* chore: InkHUD documentation
Word salad for maintainers

* refactor: don't init system applets using onActivate
System applets cannot be deactivated, so we will avoid using onActivate / onDeactivate methods entirely.

* chore: update the example applets

* fix: SSD16XX reset pulse
Allow time for controller IC to wake. Aligns with manufacturer's suggestions.
T-Echo button timing adjusted to prevent bouncing as a result(?) of slightly faster refreshes.

* fix: allow timeout if display update fails
Result is not graceful, but avoids total display lockup requiring power cycle.
Typical cause of failure is poor wiring / power supply.

* fix: improve display health on shutdown
Two extra full refreshes, masquerading as a "shutting down" screen. One is drawn white-on-black, to really shake the pixels up.

* feat: driver for display HINK_E042A87
As of Feb. 2025, these panels are used for "WeActStudio 4.2in B&W" display modules.

* fix: inkhud rotation should default to 0

* Revert "chore: todo.txt"

This reverts commit bea7df44a7.

* fix: more generous timeout for display updates
Previously this was tied to the expected duration of the update, but this didn't account for any delay if our polling thread got held up by an unrelated firmware task.

* fix: don't use the full shutdown screen during reboot

* fix: cooldown period during the display shutdown display sequence
Observed to prevent border pixels from being locked in place with some residual charge?
2025-03-31 09:17:24 +02:00
todd-herbert
da26ff5b95 feat: more toggles for InkHUD menu (#6469)
GPS on/off
Wifi off -> Bluetooth on
12 / 24 hour clock
2025-03-31 09:15:54 +02:00
Plant Daddy
f626f02005 Add 'bluetooth' option to the LilyGo T-Watch-S3 definition. 2025-03-31 09:14:48 +02:00
Austin
f18f60cd0b meshtasticd: CH341 / HAT+ Auto Configuration (#6446) 2025-03-30 20:47:15 -05:00
Jason B. Cox
850d21dcb9 Add a static_assert to verify assumption about NodeInfoLite size (#6428)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-30 20:39:01 -05:00
Tavis
e08177ba98 update to handle ws80 as well (#6440)
Small change to make the string parsing of Name = value less brittle.  Adds a function to parse a line without knowing how many spaces are after the = sign.  This allows it to also work with the ws80 serial output.
2025-03-30 20:38:24 -05:00
Mark Trevor Birss
b52c355f2f Update ScreenFonts.h (#6412) 2025-03-30 20:37:08 -05:00
github-actions[bot]
e79d4492e8 [create-pull-request] automated change (#6468)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-30 20:33:22 -05:00
Andrew Yong
95523a9659 Fix: Update xiao_ble E22-900M30S regulatory gain to 7 dB (#6466)
Allow 3 dBm increase in power from previous value of 10 dB gain, based on actual measurements from https://github.com/S5NC/EBYTE_ESP32-S3/blob/main/E22-900M30S%20power%20output%20testing.txt

Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-03-30 19:21:47 -05:00
github-actions[bot]
32d91ed859 [create-pull-request] automated change (#6464)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-30 14:35:51 -05:00
Thomas Göttgens
a93d779ec0 Update library deps and nrf Toolchain (#6450) 2025-03-30 08:13:18 -05:00
Ben Meadors
38c8c20a2b Update version.properties 2025-03-30 08:12:56 -05:00
Manuel
b89355ffa6 MUI: node list <-> map navigation (#6456)
device-ui lib update:
- node list <-> map navigation
- customizable boot logo / screen
2025-03-29 15:44:13 -05:00
Ben Meadors
8a4a0cc932 Remove unused lfs_dir_tell function 2025-03-29 14:32:56 -05:00
Ben Meadors
cbcdc3ed00 fix STM32 build (#6455)
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2025-03-29 14:30:59 -05:00
Jason P
d663d44647 Fix Bold and Inverted Displays to actually show Uptime (#6413)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-29 08:21:57 -05:00
Thomas Göttgens
3148e7277d Fix a couple of warnings (#6445)
* Fix a couple of warnings

* fix build error

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-29 08:14:24 -05:00
Thomas Göttgens
7df327664e add missing C8H10N4O2 2025-03-29 14:13:01 +01:00
Ben Meadors
a902776e57 Try-fix ESP32 wifi disconnects (#6363)
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2025-03-29 07:18:03 -05:00
Thomas Göttgens
ea9485657e Speed up builds by referencing github zips for shallow checkouts (#6441)
* Speed up builds by referencing github zips for shallow checkouts

* sadly the zips don't include submodules OR submodule metadata
2025-03-29 06:19:05 -05:00
Thomas Göttgens
0491c890d7 recognize M1 2025-03-29 08:26:30 +01:00
github-actions[bot]
4a3991a8c6 [create-pull-request] automated change (#6438)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-28 20:14:15 -05:00
Ben Meadors
c602bfecbd Update version.properties 2025-03-28 20:13:19 -05:00
Thomas Göttgens
6c7c0770f9 add ThinkNode M2 Support (#6354)
* [WIP] Base firmware pending support for 2nd button

* Update button behaviour. Still WIP

* [WIP] Base firmware pending support for 2nd button

* Update button behaviour. Still WIP

* change env to lowercase

Co-authored-by: rcarteraz <robert.l.carter2@gmail.com>

* yea - well - what else is new?

* fix secondary button behavior and update trunk

---------

Co-authored-by: rcarteraz <robert.l.carter2@gmail.com>
2025-03-28 19:55:00 -05:00
Jorropo
89cde1a8e6 udp-multicast: bump platform-native to UDP with error handling support (#6433)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-28 16:10:33 -05:00
Austin
02237f5ac6 Portduino: Return CH341 Product Strng (#6436) 2025-03-28 15:59:42 -05:00
Thomas Göttgens
4a12b4eb32 add Thinknode-M1 (#6435)
* ThinkNode M1
* Update Epaper Driver
* Your day isn't complete unless trunk has complained about your formatting at least once.
2025-03-28 21:22:17 +01:00
Manuel
a2387c79ee fix: SenseCAP Indicator sporadic touch crash (#6432)
* fix indicator touch crash

* replace wrong .ini

* delete wrong .ini
2025-03-28 10:18:47 -05:00
Marco Veneziano
d7504921fb Add missing board definition for MESHLINK (#6404)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-28 06:45:04 -05:00
Austin
4e1030ef9c Fix USERPREFS_EVENT_MODE compile error (#6408) 2025-03-28 06:31:24 -05:00
Ben Meadors
1e41c994b3 Add attestations and PR template 2025-03-27 10:06:11 -05:00
Ben Meadors
4590ef2e7b Revert "TCA8418 initial config + basic 3x4 keypad config (#6320)" (#6410)
This reverts commit 13101c1bab.
2025-03-27 08:31:57 -05:00
Austin
769f0623be Fix: T-Watch-S3 has 8MB Flash (#6407) 2025-03-27 07:46:16 -05:00
Mark Trevor Birss
52527b24a7 Update lora-Adafruit-RFM9x (#6402)
* Update lora-Adafruit-RFM9x

* Update variant.h

* Update variant.h
2025-03-27 12:02:27 +02:00
Mark Trevor Birss
6c17694b64 CrowPanel e-Ink Updates for 4.2 and 2.9 inch (#6401)
* Update platformio.ini

* Update EInkDisplay2.cpp

* Update EInkDisplay2.h
2025-03-27 11:06:41 +02:00
Thomas Göttgens
640e731ad2 Remove button fix for further investigation 2025-03-26 15:18:21 +01:00
Thomas Göttgens
ba81a8ad87 Fix default pin assignment 2025-03-26 15:02:53 +01:00
github-actions[bot]
83d8e3cb09 Upgrade trunk (#6398)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-26 06:07:22 -05:00
Jorropo
6429eca5e4 udp-multicast: do not listen for incoming udp multicast packets if disabled (#6397)
Currently the config flag only control if packets are sent, not received.

As we discussed in VC this is not what was intended.
2025-03-26 18:10:56 +11:00
Nasimovy
13101c1bab TCA8418 initial config + basic 3x4 keypad config (#6320)
* add TCA8418 to configuration.h

added the TCA8418

* add TCA8418 to ScanI2C.cpp

add TCA8418

* add TCA8418KB to ScanI2C.h

add TCA8418KB

* add TCA8418KB ScanI2CTwoWire.cpp

add TCA8418KB

* Create TCA8418Keyboard.cpp

Create TCA8418Keyboard.cpp

* Create TCA8418Keyboard.h

Create TCA8418Keyboard.h

* add TCA8418 to kbI2cBase.cpp

add TCA8418

* add TCA8418 to kbI2cBase.h

add TCA8418

* add TCA8418KB to main.cpp

add TCA8418KB

* add TCA8418KB to cardKbI2cImpl.cpp

add TCA8418KB

* Update TCA8418 kbI2cBase.cpp

* enable debug TCA8418

* Nokia 5130 config

* Update TCA8418Keyboard.h

old version in initial commit

* Update ScanI2CTwoWire.cpp

* add tap_interval and backlight_on to constructor

* Create TCA8418-layouts.cpp

TCA8418-layout

3x4 should work

Nokia 5130 needs editing.

* put layouts in different file + adjusted code for variable matrix sizes

* rename TCA8418-layouts.cpp to TCA8418Layouts.cpp + add endif

* Update TCA8418Keyboard.cpp name change layouts

* forgot a \

* Create TCA8418Layouts.h

* Update TCA8418Keyboard.cpp

* add include

forgot include

* Update TCA8418Keyboard.cpp

* Update TCA8418Keyboard.h

* Update TCA8418Layouts.h

* revert to keyboard layout in main TCA8418Keyboard.cpp

* fixed the address

* changed ordering of constructor

* reflect changes #6371

* edit config.h

* bug fix fast pressing multiple buttons + clean up scanI2CTwoWire.cpp

* trunked

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2025-03-26 13:29:18 +11:00
Ben Meadors
d28af68b5a Update version.properties 2025-03-25 18:49:22 -05:00
nledevil
53a7afff41 Adding Variants for Hackerboxes ESP32C3 OLED kit and the ESP32 IO Kit (#6319) 2025-03-25 22:57:06 +01:00
github-actions[bot]
eb375d8e62 [create-pull-request] automated change (#6396)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-25 14:55:37 -05:00
Austin
33f2b7144f Default to UDP enabled if it's available (#6394) 2025-03-25 11:39:19 -05:00
github-actions[bot]
e5f8218d34 Upgrade trunk (#6383)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-25 07:00:54 -05:00
Austin
0ddb507055 userPrefs: Add WiFi SSID/PW, and UDP multicast configs (#6387) 2025-03-24 19:38:47 -05:00
Jorropo
3afe84c4f4 linux-native: allow multiple processes to all bind to the same multicast 2tuple (#6391)
* cleanup UdpMulticastThread.h preprocessor rules a tiny bit

* bump platform-native to allow for multiple multicast listeners on the same machine

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-24 19:30:47 -05:00
Manuel
e9d8a3d7f9 MUI: increase stack, cache and drawbuffer (#6389)
* increase stack, cache and drawbuffer

* bump device-ui lib

* T-Deck map: switch to full redraw
2025-03-24 19:30:17 -05:00
Chloe Bethel
e722a97987 Don't use assert() in MeshService to guard queueing packets (#6388) 2025-03-24 23:26:59 +01:00
Andrew Yong
daa4186d65 [esp32] Define BUTTON_PIN (-1) by default, fixes #6213 (#6371)
Signed-off-by: Andrew Yong <me@ndoo.sg>
2025-03-23 16:32:55 +01:00
Thomas Göttgens
1ee800e901 add MUI/inkHUD to bug report template (#6376) 2025-03-23 12:33:26 +01:00
dfsx1
cf7f0f9d08 Fix NodeInfo exploit overwriting publicKey in NodeDB (#6372)
Co-authored-by: dfsx1 <dfsx1@users.noreply.github.com>
2025-03-23 05:49:06 -05:00
Tom Fifield
1e4a0134e6 Remove unnecessary null pointer check (#6370)
Further pointed out by @elfring, this patch removes one more unnecessary null pointer check.

https://github.com/meshtastic/firmware/issues/6170#issuecomment-2744002798
2025-03-21 19:55:11 -05:00
Thomas Göttgens
0951fdd49b Add support for Heltec HRI-3621 industrial sensor hub (#6366) 2025-03-21 16:12:49 +01:00
Thomas Göttgens
848a3ed6a1 implement littlefs for stm32 (#5987)
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Daniel Peter Chokola <dan.chokola@gmail.com>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-03-21 16:12:27 +01:00
github-actions[bot]
fd7a1f2ccb [create-pull-request] automated change (#6365) 2025-03-21 14:28:23 +01:00
Tom Fifield
5acaf8f897 Enable range test on Linux Native (#6356)
The Range Test Module was defined-out by architecture.

No reason it shouldn't work, so add PORTDUINO to the list of
architectures that compile this module.

Tested on Ubuntu. Enables without crashing, will send packets on
the set time. However, for now the CSV file download does not appear
to work.

Partially fixes https://github.com/meshtastic/firmware/issues/5618
2025-03-21 05:59:20 -05:00
Tom Fifield
cff93adb5e [WIP] LS20031 setup support (#5737)
LS20031 is a MTK3339-based chip. Therefore, it should share some
heritage with other MTK3333 or MTK3339 chips. Re-use the L76B
commands for setup.
2025-03-21 05:58:52 -05:00
github-actions[bot]
e4d3ec1f59 Upgrade trunk (#6360)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-21 05:54:57 -05:00
Tom Fifield
ae27aaaf43 Remove unnecessary null pointer checks (#6358)
As reported by @elfring, we had several points in our code where
it was unnecessary to check pointers were non-null before deleting them.

Fixes https://github.com/meshtastic/firmware/issues/6170
2025-03-21 05:54:42 -05:00
Mike
31c0e8fa2c Support WiFi OTA (#6352)
* Support WiFi OTA

* Fix trunk warnings

* Make getVersion() check for project name too

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-20 13:39:33 -05:00
raulperdomo
0d95b1afcc Added bounds checking to memcpy and use memory-safe strlcpy (#6351)
* Added bounds checking to memcpy and use memory-safe strlcpy for reading serial data in processWXSerial() function.

* Fixed linting with trunk
2025-03-20 10:40:13 -05:00
Austin
46235f6f8b RP2xx0: Add UDP Multicast support (#6327) 2025-03-20 08:49:28 -05:00
Jorropo
d1068fd1e4 Add UDP multicast support on linux. (#6342)
* Add UDP multicast support on linux.

Closes #6326

We tested it an it works.

This is really hacky to say the least.

* Add libuv to Linux packaging

* Trunkadunk

* Correct ref

* Add libuv1-dev to setup-native

---------

Co-authored-by: vidplace7 <vidplace7@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-20 08:47:39 -05:00
Jorropo
f41afb14b1 raise the multicast UDP TTL limit (#6343)
Since 96ba94843b we don't spray packets to all machines on the network.

So we can allow ourself to raise the TTL limit, this allows users who run L3 IGMP Routing infrastructure to pass meshtastic frames over UDP.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-20 05:41:29 -05:00
Ben Meadors
f8ad02aab3 Update version.properties 2025-03-19 06:20:50 -05:00
github-actions[bot]
077759e15d Upgrade trunk (#6347)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-19 05:11:42 -05:00
Bob Reese
22aa2d7582 Fixed UF2 generation problem with sys.executable path has spaces in it (#6346) 2025-03-18 20:20:15 -05:00
Austin
6673cb9292 Increase MAX_NUM_NODES on high-flash ESP32_S3 (#6311) 2025-03-18 20:19:51 -05:00
Kalle Lilja
8efc9702d3 device-install/update: fix esptool --port (#6341)
* fix errorlevel check

* add esptool --port if supplied

* match device-install

* add --port if supplied

* update logmessage

* bump version

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-17 20:16:16 -05:00
Austin
2876eec7ed MeshToad - USB 1W 'MeshStick' (#6339) 2025-03-17 20:14:01 -05:00
Ben Meadors
9cc13e628a Stubbed out backup / restore methods for now and fixed bug 2025-03-17 19:24:47 -05:00
Jorropo
af8b64e84e pass pointer to UDP multicast packet to protobuf decoder (#6333)
The packet.readBytes API is not available on all targets:
- RP2040 & RP2340
- yet to be written portduino API

Instead pass the data buffer as-is.
It also removes a memcpy which do not need to exists.

I've tested it successfully on a tbeam.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-16 19:36:33 -05:00
Jorropo
96ba94843b Send UDP packets to multicast address rather than broadcast address (#6331)
A smart router or switch is able to snoop the multicast address to
only send the packets to nodes listening on the multicast address.

Before all machines reachable on the L2 layer would receive the packet.
2025-03-16 19:36:02 -05:00
Thomas Göttgens
2d565c2921 trunk'd 2025-03-16 16:18:12 +01:00
HarukiToreda
2525111c39 E-ink partial refresh limitation removed for free text screen (#6201) 2025-03-16 16:15:33 +01:00
dylanli
64b9cfe199 update seeed-xiao-nrf52840-kit board defination (#6318)
- Due to the lack of pins, we have temporarily removed the button. There are some technical solutions that can solve this problem, and we are currently exploring and researching them
2025-03-16 16:04:24 +01:00
Ben Meadors
dc100e4d3e Cleanup 2025-03-16 08:19:46 -05:00
Thomas Göttgens
1640fb105d new device: Lilygo T-Eth-Elite (#6321) 2025-03-15 14:15:35 +01:00
github-actions[bot]
99e42b4d22 [create-pull-request] automated change (#6323)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-03-15 07:03:53 -05:00
Thomas Göttgens
79233fe99d mainline tlora v3 (#6322) 2025-03-15 11:30:58 +01:00
Chris Danis
f66784ed2a Don't allow is_managed without any valid admin_keys (#6310) 2025-03-14 10:10:38 -05:00
github-actions[bot]
f198d5d49f Upgrade trunk to 1.22.11 (#6316)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-14 06:58:08 -05:00
dependabot[bot]
4d34b3d73c Bump dorny/test-reporter from 1.9.1 to 2.0.0 in /.github/workflows (#6309)
Bumps [dorny/test-reporter](https://github.com/dorny/test-reporter) from 1.9.1 to 2.0.0.
- [Release notes](https://github.com/dorny/test-reporter/releases)
- [Changelog](https://github.com/dorny/test-reporter/blob/main/CHANGELOG.md)
- [Commits](https://github.com/dorny/test-reporter/compare/v1.9.1...v2.0.0)

---
updated-dependencies:
- dependency-name: dorny/test-reporter
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-13 08:32:49 -05:00
paragonnov
8efe8a2ea3 Fix KR920's Tx power limitation (#6307) 2025-03-13 18:14:41 +08:00
Kalle Lilja
499ea56e3b update devcontainer (#6299) 2025-03-12 15:32:34 -05:00
Ben Meadors
2473af6995 45 days stale 2025-03-12 12:43:55 -05:00
github-actions[bot]
508ab171d6 Upgrade trunk (#6295)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-12 06:22:24 -05:00
Manuel
ec59f7d7dd fix packet queue full (#6292) 2025-03-11 18:59:44 -05:00
Kalle Lilja
f4c79530ec update gitattributes for windows (#6289) 2025-03-11 13:05:51 -05:00
Mark Trevor Birss
e9effb9fff Update platformio.ini (#6286) 2025-03-11 15:45:20 +02:00
Mark Trevor Birss
cb6dfb66d2 Update ME25LS01/MS24SF1 comment out upload port (#6285)
* Update platformio.ini

* Update platformio.ini

* Update platformio.ini
2025-03-11 14:56:12 +02:00
github-actions[bot]
8795a63427 Upgrade trunk (#6283)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-11 06:26:45 -05:00
Mark Trevor Birss
186e509607 Update esp32-s3-pico.json (#6284)
* Update esp32-s3-pico.json

* Update esp32-s3-pico.json
2025-03-11 13:11:11 +02:00
Manuel
7c3eddebc2 device-ui: exFat support (#6279) 2025-03-10 16:42:29 -05:00
Ben Meadors
78b4eff568 Bump 2025-03-10 11:57:39 -05:00
Kalle Lilja
3c1f92ce84 Update device-install scripts (#6267)
* fix example

* check for firmware- filename

* add powershell formatter setting

* add crlf for ps1

* formatting

* check for firmware- filename

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-09 06:43:16 -05:00
todd-herbert
5de6bc1851 Fix excluded_modules metadata with InkHUD (#6272) 2025-03-08 19:06:32 -06:00
Austin
c54fc5b7c5 Thread in harmony (#6271) 2025-03-08 16:36:55 -06:00
github-actions[bot]
94de2315c1 [create-pull-request] automated change (#6266)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-08 06:22:11 -06:00
Chris Danis
7f17747d8c NodeInfo exchange: don't bother if too far away (#6260)
When we receive a NodeInfo from a new node, if it is more than 2 hops
beyond our configured hop limit away from us, don't bother to send a
NodeInfo back to it.

In my dense urban environment, I see many nodes that are >= 5 hops away,
but sending their NodeInfo with a hopStart of 6 or 7.  In most cases
I can imagine, this seems like a waste of airtime.
2025-03-08 09:33:23 +08:00
Austin
16a0dce83c Ebyte E77 (STM32) DevKit support (#6255) 2025-03-07 17:37:54 -06:00
Austin
3fd47d9713 Actions: Move version bump into release_channels (#6258) 2025-03-07 06:38:15 -06:00
Tom Fifield
284598ed56 Add detection support for LTR390UV Sensor (#6009)
* Add detection support for LTR390UV Sensor

The LTR390 is a UV sensor. This patch adds detection support, for
a future patch that will add the full sensor support.

* Update ScanI2C.h
2025-03-07 18:51:38 +08:00
github-actions[bot]
2a3e1f904d Upgrade trunk (#6257)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-07 09:12:08 +01:00
Mark Trevor Birss
60e46cd765 Update platformio.ini (#6245) 2025-03-07 14:21:06 +08:00
Tom Fifield
563747c5cd Flag semgrep to not run on self-hosted (#6256)
The semgrep action runs inside a docker container,
and docker in podman just doesn't work.
2025-03-07 11:54:32 +08:00
Chris Danis
5c77d42345 i2c: 0x45 can also be an SHT35 (#6249) 2025-03-07 09:49:55 +08:00
Tom Fifield
f0a2ae9ff3 Give Semgrep permission to write its report (#6253)
Previously semgrep had read-all permission. This patch limits read
slightly and adds write permissions to security-events.
2025-03-07 08:52:54 +08:00
Kalle Lilja
f7afa9a81e [Task]: 2.6 device-install scripts (#6248)
* update device-install.bat

* add device-install unittest

* update device-update.bat

* update uf2-convert.bat

* update regen-protos.bat

* update rem

* bump version

* update device-install.sh

* add esptool

* move esptool to setup.sh

* trunk check+fmt

* update uf2-convert.bat
2025-03-06 16:58:08 -06:00
Ben Meadors
c8bd6c32cc Correct HW_MODEL 2025-03-06 08:43:03 -06:00
Mark Trevor Birss
f6a9e7d741 Add initial support for CrowPanel ESP32 5.79” E-paper HMI (#6233) 2025-03-06 11:28:43 +01:00
todd-herbert
e6a98b1d6b InkHUD refactoring (#6216)
* chore: todo.txt
* chore: comments
* fix: no fast refresh on VME290
Reverts a line of code which was accidentally committed
* refactor: god class
Divide the behavior from the old WindowManager class into several subclasses which each have a clear role.
* refactor: cppcheck medium warnings
Enough to pass github CI for now
* refactor: updateType selection
* refactor: don't use a setter for the shared AppletFonts
* fix: update prioritization
forceUpdate calls weren't being prioritized
* refactor: remove unhelpful logging
getTimeString is used for parsing our own time, but also the timestamps of messages. The "one time only" log printing will likely fire in unhelpful situations.
* fix: " "
* refactor: get rid of types.h file for enums
* Keep that sneaky todo file out of commits
2025-03-06 11:25:41 +01:00
Tavis
b2ef92a328 add rain data from ws85 (#6242)
add rain data as 1h and 24h
2025-03-06 10:55:08 +01:00
Andrik45719
b25db1f42c E22-400M SX126X_DIO3_TCXO_VOLTAGE fix (#6232)
Added TCXO voltage setting for SX1268 based module to fix error:
Calibration failed, device errors: 0x20
SX126x init result -707
2025-03-06 09:44:53 +01:00
Austin
a924b9d94a Small Fix: Don't run Dependabot on protobufs (#6241) 2025-03-06 09:36:27 +01:00
Chris Danis
f5e0e282b6 environment: add DPS310 high-accuracy barometer (#6237)
* dps310: initial scan support

* dps310 sensor support

* new protobufs

* new protobufs

* address cr

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-06 11:58:18 +08:00
github-actions[bot]
a3a9b2fe84 [create-pull-request] automated change (#6240)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-05 20:50:20 -06:00
Ben Meadors
6c8058e1d8 Update SEEED_XIAO_NRF52840_KIT (#6239) 2025-03-06 09:44:22 +08:00
dylanli
445efe9e21 Add support for seeed_xiao_nrf52840_kit (#6231)
* add support for seeed_xiao_nrf52840_kit

* Update platformio.ini remove board level define
2025-03-05 16:22:25 -06:00
Austin
b96b027926 Consume device-ui as a pio library (#6193) 2025-03-05 16:19:59 -06:00
github-actions[bot]
239e5412b3 [create-pull-request] automated change (#6235)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-05 14:53:51 -06:00
Michael Gjelsø
ede3f7b702 Changes for 2.6 device_install (#6206)
* Changes for 2.6 device_install

For #6186
Added 2 new arguments --tft and -tft-16mb
Some checks are added.
Before it would try to write all files to the device, if there was more than ONE littlefs-* or littlefswebui-* in the directory.

Added OTA Offsets for 8 and 16mb (fix)
Thanks to @caveman99 for spotting it.

* The missing SET

Added a missing SET.

Thanks to @ThatKalle

* Fix and more checks.

Added Checks to make sure, that --tft and --tft-16mb can't be used with a non tft bin file.
Added error messages on files not found.
Removed a "ECHO" that shouldn't be there.

* Fixes to device-install.sh

Replace /bin/sh with /bin/bash for better string handling.
Removed a SET that doesn't belong in the .sh file.
Better checking for TFT and non TFT build, based on filename.
Corrected a mix of TAB & SPACE indent.

* Update device-install.bat

Corrected a mix of TAB & SPACE indent.

* Update device-install.bat

Double ELSE block at the end of file, one removed.

* Update device-install.bat

Added more reliable method to display the scripts own name in help menu.
Fixed case sensitive options -p and -P
Added some VAR cleanup.
Changed the detect method on BLEOTA.
Changed some wording.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-05 13:07:26 -06:00
Mictronics
f0f2cd0e0e RAK11310 Fix build with latest Arduino framework (#6227) 2025-03-04 21:39:10 +01:00
Matt Andreko
fdbadc992c Enable GPS functionality for RAK4631_eth_gw variant (#6229) 2025-03-04 21:27:57 +01:00
Tom Fifield
2391982c1d Only call GPS Probe commands once per family (#6114)
In the GPS probe code we write commands on the serial line and
 determine which GPS we have based on the result.

GPS units in the same family sometimes use the same command,
 but return different results (eg AG3335 and AG3332 both use $PAIR021*39).
Currently we run the command once per GPS. Instead we should run each
command only once per family, record the result, and select the GNSS MODEL
 based on the result, which is what this patch does.

Before the change, we put 12 commands on the serial bus.
Now we only put 6.

This should markedly improve the speed and reliability of GPS detection.

Fixes https://github.com/meshtastic/firmware/issues/5193

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-04 09:47:06 -06:00
dependabot[bot]
41875d245e Bump lib/device-ui from 5c6156d to 22f9ac0 (#6215)
Bumps [lib/device-ui](https://github.com/meshtastic/device-ui) from `5c6156d` to `22f9ac0`.
- [Commits](5c6156d2aa...22f9ac01ea)

---
updated-dependencies:
- dependency-name: lib/device-ui
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-03-04 09:45:29 -06:00
github-actions[bot]
95bcd7ab0b Upgrade trunk (#6223)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-04 09:45:02 -06:00
github-actions[bot]
050f0016c4 [create-pull-request] automated change (#6221) 2025-03-04 01:56:35 +01:00
Thomas Göttgens
6715662281 don't build the niche* stuff for non-inkHUD builds. (#6217) 2025-03-03 09:10:47 -06:00
Mictronics
b6562e175f RAK11310 support for RAK12002 RTC added. (#6210) 2025-03-03 11:08:02 +01:00
Thomas Göttgens
f89f916f96 Revert "Trunk: Add clang-tidy (#6171)" (#6203)
This reverts commit 12fde696c1.
2025-03-02 13:58:37 +01:00
Mictronics
43a6e711da RAK11310: Update to last building platform package and possibly fix for #5361 (#6202) 2025-03-02 13:15:30 +01:00
Mark Trevor Birss
63b20e358f Create lora-raxda-rock2f-starter-edition-hat.yaml (#6192)
* Create lora-raxda-rock2f-starter-edition-hat.yaml

* Update lora-raxda-rock2f-starter-edition-hat.yaml
2025-03-02 06:14:07 -06:00
Austin
12fde696c1 Trunk: Add clang-tidy (#6171) 2025-03-02 11:27:53 +01:00
Ben Meadors
5c8f1fb46b Enable external (UART) GPS support on WM1110 tracker dev board (#6189) 2025-03-01 08:27:43 -06:00
Mark Trevor Birss
ce38ac10d1 Create lora-starter-edition-sx1262-i2c.yaml and lora-ws-raspberry-pi-pico-to-rpi-adapter.yaml (#6162)
* Create lora-ws-raspberry-pi-pico-to-rpi-adapter.yaml

* Create lora-starter-edition-sx1262-i2c.yaml

* Update lora-ws-raspberry-pi-pico-to-rpi-adapter.yaml

* Update lora-ws-raspberry-pi-pico-to-rpi-adapter.yaml

* Update lora-starter-edition-sx1262-i2c.yaml
2025-03-01 07:14:04 -06:00
github-actions[bot]
d5ec205572 Upgrade trunk (#6188)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-03-01 06:58:39 -06:00
GUVWAF
9893d24c62 Only request all NodeInfo/Position on fresh install (#6184)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-03-01 06:57:44 -06:00
github-actions[bot]
ab61cd65d1 Upgrade trunk (#6178)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-03-01 06:57:12 -06:00
Austin
baef8dce79 Switch pio_deps to native-tft for flatpak (#6187)
Consumed in flatpak for "offline" builds.
2025-03-01 06:56:49 -06:00
Ben Meadors
99d3e5eb70 2.6 changes (#5806)
* 2.6 protos

* [create-pull-request] automated change (#5789)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Hello world support for UDP broadcasts over the LAN on ESP32 (#5779)

* UDP local area network meshing on ESP32

* Logs

* Comment

* Update UdpMulticastThread.h

* Changes

* Only use router->send

* Make NodeDatabase (and file) independent of DeviceState (#5813)

* Make NodeDatabase (and file) independent of DeviceState

* 70

* Remove logging statement no longer needed

* Explicitly set CAD symbols, improve slot time calculation and adjust CW size accordingly (#5772)

* File system persistence fixes

* [create-pull-request] automated change (#6000)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Update ref

* Back to 80

* [create-pull-request] automated change (#6002)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* 2.6 <- Next hop router (#6005)

* Initial version of NextHopRouter

* Set original hop limit in header flags

* Short-circuit to FloodingRouter for broadcasts

* If packet traveled 1 hop, set `relay_node` as `next_hop` for the original transmitter

* Set last byte to 0xFF if it ended at 0x00
As per an idea of @S5NC

* Also update next-hop based on received DM for us

* temp

* Add 1 retransmission for intermediate hops when using NextHopRouter

* Add next_hop and relayed_by in PacketHistory for setting next-hop and handle flooding fallback

* Update protos, store multiple relayers

* Remove next-hop update logic from NeighborInfoModule

* Fix retransmissions

* Improve ACKs for repeated packets and responses

* Stop retransmission even if there's not relay node

* Revert perhapsRebroadcast()

* Remove relayer if we cancel a transmission

* Better checking for fallback to flooding

* Fix newlines in traceroute print logs

* Stop retransmission for original packet

* Use relayID

* Also when want_ack is set, we should try to retransmit

* Fix cppcheck error

* Fix 'router' not in scope error

* Fix another cppcheck error

* Check for hop_limit and also update next hop when `hop_start == hop_limit` on ACK
Also check for broadcast in `getNextHop()`

* Formatting and correct NUM_RETRANSMISSIONS

* Update protos

* Start retransmissions in NextHopRouter if ReliableRouter didn't do it

* Handle repeated/fallback to flooding packets properly
First check if it's not still in the TxQueue

* Guard against clients setting `next_hop`/`relay_node`

* Don't cancel relay if we were the assigned next-hop

* Replies (e.g. tapback emoji) are also a valid confirmation of receipt

---------

Co-authored-by: GUVWAF <thijs@havinga.eu>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>

* fix "native" compiler errors/warnings NodeDB.h

* fancy T-Deck / SenseCAP Indicator / unPhone / PICOmputer-S3 TFT screen (#3259)

* lib update: light theme

* fix merge issue

* lib update: home buttons + button try-fix

* lib update: icon color fix

* lib update: fix instability/crash on notification

* update lib: timezone

* timezone label

* lib update: fix set owner

* fix spiLock in RadioLibInterface

* add picomputer tft build

* picomputer build

* fix compiler error std::find()

* fix merge

* lib update: theme runtime config

* lib update: packet logger + T-Deck Plus

* lib update: mesh detector

* lib update: fix brightness & trackball crash

* try-fix less paranoia

* sensecap indicator updates

* lib update: indicator fix

* lib update: statistic & some fixes

* lib-update: other T-Deck touch driver

* use custom touch driver for Indicator

* lower tft task prio

* prepare LVGL ST7789 driver

* lib update: try-fix audio

* Drop received packets from self

* Additional decoded packet ignores

* Honor flip & color for Heltec T114 and T190 (#4786)

* Honor TFT_MESH color if defined for Heltec T114 or T190

* Temporary: point lib_deps at fork of Heltec's ST7789 library
For demo only, until ST7789 is merged

* Update lib_deps; tidy preprocessor logic

* Download debian files after firmware zip

* set title for protobufs bump PR (#4792)

* set title for version bump PR (#4791)

* Enable Dependabot

* chore: trunk fmt

* fix dependabot syntax (#4795)

* fix dependabot syntax

* Update dependabot.yml

* Update dependabot.yml

* Bump peter-evans/create-pull-request from 6 to 7 in /.github/workflows (#4797)

* Bump docker/build-push-action from 5 to 6 in /.github/workflows (#4800)

* Actions: Semgrep Images have moved from returntocorp to semgrep (#4774)

https://hub.docker.com/r/returntocorp/semgrep notes: "We've moved!
 Official Docker images for Semgrep now available at semgrep/semgrep."

Patch updates our CI workflow for these images.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Bump meshtestic from `31ee3d9` to `37245b3` (#4799)

Bumps [meshtestic](https://github.com/meshtastic/meshTestic) from `31ee3d9` to `37245b3`.
- [Commits](31ee3d90c8...37245b3d61)

---
updated-dependencies:
- dependency-name: meshtestic
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* [create-pull-request] automated change (#4789)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Bump pnpm/action-setup from 2 to 4 in /.github/workflows (#4798)

Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 2 to 4.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v2...v4)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>

* Raspberry Pico2 - needs protos

* Re-order doDeepSleep (#4802)

Make sure PMU sleep takes place before I2C ends

* [create-pull-request] automated change

* heltec-wireless-bridge
requires Proto PR first

* feat: trigger class update when protobufs are changed

* meshtastic/ is a test suite; protobufs/ contains protobufs;

* Update platform-native to pick up portduino crash fix (#4807)

* Hopefully extract and commit to meshtastic.github.io

* CI fixes

* [Board] DIY "t-energy-s3_e22" (#4782)

* New variant "t-energy-s3_e22"

- Lilygo T-Energy-S3
- NanoVHF "Mesh-v1.06-TTGO-T18" board
- Ebyte E22 Series

* add board_level = extra

* Update variant.h

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>

* Consolidate variant build steps (#4806)

* poc: consolidate variant build steps

* use build-variant action

* only checkout once and clean up after run

* Revert "Consolidate variant build steps (#4806)" (#4816)

This reverts commit 9f8d86cb25.

* Make Ublox code more readable (#4727)

* Simplify Ublox code

Ublox comes in a myriad of versions and settings. Presently our
configuration code does a lot of branching based on versions being
or not being present.

This patch adds version detection earlier in the piece and branches
on the set gnssModel instead to create separate setup methods for Ublox 6,
Ublox 7/8/9, and Ublox10.

Additionally, adds a macro to make the code much shorter and more
readable.

* Make trunk happy

* Make trunk happy

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Consider the LoRa header when checking packet length

* Minor fix (#4666)

* Minor fixes

It turns out setting a map value with the index notation causes
an lookup that can be avoided with emplace. Apply this to one line in
the StoreForward module.

Fix also Cppcheck-determined highly minor performance increase by
passing gpiochipname as a const reference :)

The amount of cycles used on this laptop while learning about these
callouts from cppcheck is unlikely to ever be more than the cycles
saved by the fixes ;)

* Update PortduinoGlue.cpp

* Revert "Update classes on protobufs update" (#4824)

* Revert "Update classes on protobufs update"

* remove quotes to fix trunk.

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>

* Implement optional second I2C bus for NRF52840
Enabled at compile-time if WIRE_INFERFACES_COUNT defined as 2

* Add I2C bus to Heltec T114 header pins
SDA: P0.13
SCL: P0.16

Uses bus 1, leaving bus 0 routed to the unpopulated footprint for the RTC (general future-proofing)

* Tidier macros

* Swap SDA and SCL
SDA=P0.16, SCL=P0.13

* Refactor and consolidate time window logic (#4826)

* Refactor and consolidate windowing logic

* Trunk

* Fixes

* More

* Fix braces and remove unused now variables.

There was a brace in src/mesh/RadioLibInterface.cpp that was breaking
compile on some architectures.

Additionally, there were some brace errors in
src/modules/Telemetry/AirQualityTelemetry.cpp
src/modules/Telemetry/EnvironmentTelemetry.cpp
src/mesh/wifi/WiFiAPClient.cpp

Move throttle include in WifiAPClient.cpp to top.

Add Default.h to sleep.cpp

rest of files just remove unused now variables.

* Remove a couple more meows

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>

* Rename message length headers and set payload max to 255 (#4827)

* Rename message length headers and set payload max to 255

* Add MESHTASTIC_PKC_OVERHEAD

* compare to MESHTASTIC_HEADER_LENGTH

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>

* Check for null before printing debug (#4835)

* fix merge

* try-fix crash

* lib update: fix neighbors

* fix GPIO0 mode after I2S audio

* lib update: audio fix

* lib update: fixes and improvements

* extra

* added ILI9342 (from master)

* device-ui persistency

* review update

* fix request, add handled

* fix merge issue

* fix merge issue

* remove newline

* remove newlines from debug log

* playing with locks; but needs more testing

* diy mesh-tab initial files

* board definition for mesh-tab (not yet used)

* use DISPLAY_SET_RESOLUTION to avoid hw dependency in code

* no telemetry for Indicator

* 16MB partition for Indicator

* 8MB partition for Indicator

* stability: add SPI lock before saving via littleFS

* dummy for config transfer (#5154)

* update indicator (due to compile and linker errors)

* remove faulty partition line

* fix missing include

* update indicator board

* update mesh-tab ILI9143 TFT

* fix naming

* mesh-tab targets

* try: disable duplicate locks

* fix nodeDB erase loop when free mem returns invalid value (0, -1).

* upgrade toolchain for nrf52 to gcc 9.3.1

* try-fix (workaround) T-Deck audio crash

* update mesh-tab tft configs

* set T-Deck audio to unused 48 (mem mclk)

* swap mclk to gpio 21

* update meshtab voltage divider

* update mesh-tab ini

* Fixed the issue that indicator device uploads via rp2040 serial port in some cases.

* Fixed the issue that the touch I2C address definition was not effective.

* Fixed the issue that the wifi configuration saved to RAM did not take effect.

* rotation fix; added ST7789 3.2" display

* dreamcatcher: assign GPIO44 to audio mclk

* mesh-tab touch updates

* add mesh-tab powersave as default

* fix DIO1 wakeup

* mesh-tab: enable alert message menu

* Streamline board definitions for first tech preview. (#5390)

* Streamline board definitions for first tech preview. TBD: Indicator Support

* add point-of-checkin

* use board/unphone.json

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>

* fix native targets

* add RadioLib debugging options for (T-Deck)

* fix T-Deck build

* fix native tft targets for rpi

* remove wrong debug defines

* t-deck-tft button is handled in device-ui

* disable default lightsleep for indicator

* Windows Support - Trunk and Platformio (#5397)

* Add support for GPG

* Add usb device support

* Add trunk.io to devcontainer

* Trunk things

* trunk fmt

* formatting

* fix trivy/DS002, checkov/CKV_DOCKER_3

* hide docker extension popup

* fix trivy/DS026, checkov/CKV_DOCKER_2

* fix radioLib warnings for T-Deck target

* wake screen with button only

* use custom touch driver

* define wake button for unphone

* use board definition for mesh-tab

* mesh-tab rotation upside-down

* update platform native

* use MESH_TAB hardware model definition

* radioLib update (fix crash/assert)

* reference seeed indicator fix commit arduino-esp32

* Remove unneeded file change :)

* disable serial module and tcp socket api for standalone devices (#5591)

* disable serial module and tcp socket api for standalone devices
* just disable webserver, leave wifi available
* disable socket api

* mesh-tab: lower I2C touch frequency

* log error when packet queue is full

* add more locking for shared SPI devices (#5595)

* add more locking for shared SPI devices
* call initSPI before the lock is used
* remove old one
* don't double lock
* Add missing unlock
* More missing unlocks
* Add locks to SafeFile, remove from `readcb`, introduce some LockGuards
* fix lock in setupSDCard()
* pull radiolib trunk with SPI-CS fixes
* change ContentHandler to Constructor type locks, where applicable

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: GUVWAF <thijs@havinga.eu>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>

* T-Deck: revert back to lovyanGFX touch driver

* T-Deck: increase allocated PSRAM by 50%

* mesh-tab: streamline target definitions

* update RadioLib 7.1.2

* mesh-tab: fix touch rotation 4.0 inch display

* Mesh-Tab platformio: 4.0inch: increase SPI frequency to max

* mesh-tab: fix rotation for 3.5 IPS capacitive display

* mesh-tab: fix rotation for 3.2 IPS capacitive display

* restructure device-ui library into sub-directories

* preparations for generic DisplayDriverFactory

* T-Deck: increase LVGL memory size

* update lib

* trunk fmt

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Jason Murray <15822260+scruplelesswizard@users.noreply.github.com>
Co-authored-by: Jason Murray <jason@chaosaffe.io>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: virgil <virgil.wang.cj@gmail.com>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: Kalle Lilja <15094562+ThatKalle@users.noreply.github.com>
Co-authored-by: GUVWAF <thijs@havinga.eu>

* Version this

* Update platformio.ini (#6006)

* tested higher speed and it works

* Un-extra

* Add -tft environments to the ci matrix

* Exclude unphone tft for now. Something is wonky

* fixed Indicator touch issue (causing IO expander issues), added more RAM

* update lib

* fixed Indicator touch issue (causing IO expander issues), added more RAM (#6013)

* increase T-Deck PSRAM to avoid too early out-of-memory when messages fill up the storage

* update device-ui lib

* Fix T-Deck SD card detection (#6023)

* increase T-Deck PSRAM to avoid too early out-of-memory when messages fill up the storage

* fix SDCard for T-Deck; allow SPI frequency config

* meshtasticd: Add X11 480x480 preset (#6020)

* Littlefs per device

* 2.6 update

* [create-pull-request] automated change (#6037)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* InkHUD UI for E-Ink (#6034)

* Decouple ButtonThread from sleep.cpp
Reorganize sleep observables. Don't call ButtonThread methods inside doLightSleep. Instead, handle in class with new lightsleep Observables.

* InkHUD: initial commit (WIP)
Publicly discloses the current work in progress. Not ready for use.

* feat: battery icon

* chore: implement meshtastic/firmware #5454
Clean up some inline functions

* feat: menu & settings for "jump to applet"

* Remove the beforeRender pattern
It hugely complicates things. If we can achieve acceptable performance without it, so much the better.

* Remove previous Map Applet
Needs re-implementation to work without the beforeRender pattern

* refactor: reimplement map applet
Doesn't require own position
Doesn't require the beforeRender pattern to precalculate; now all-at-once in render
Lays groundwork for fixed-size map with custom background image

* feat: autoshow
Allow user to select which applets (if any) should be automatically brought to foreground when they have new data to display

* refactor: tidy-up applet constructors
misc. jobs including:
- consistent naming
- move initializer-list-only constructors to header
- give derived applets unique identifiers for MeshModule and OSThread logging

* hotfix: autoshow always uses FAST update
In future, it *will* often use FAST, but this will be controlled by a WindowManager component which has not yet been written.
Hotfixed, in case anybody is attempting to use this development version on their deployed devices.

* refactor: bringToForeground no longer requests FAST update
In situations where an applet has moved to foreground because of user input, requestUpdate can be manually called, to upgrade to FAST refresh.
More permanent solution for #23e1dfc

* refactor: extract string storage from ThreadedMessageApplet
Separates the code responsible for storing the limited message history, which was previously part of the ThreadedMessageApplet.
We're now also using this code to store the "most recent message". Previously, this was stored in the `InkHUD::settings` struct, which was much less space-efficient.
We're also now storing the latest DM, laying the foundation for an applet to display only DMs, which will complement the threaded message applet.

* fix: text wrapping
Attempts to fix a disparity between `Applet::printWrapped` and `Applet::getWrappedTextHeight`, which would occasionally cause a ThreadedMessageApplet message to render "too short", overlapping other text.

* fix: purge old constructor
This one slipped through the last commit..

* feat: DM Applet
Useful in combination with the ThreadedMessageApplets, which don't show DMs

* fix: applets shouldn't handle events while deactivated
Only one or two applets were actually doing this, but I'm making a habit of having all applets return early from their event handling methods (as good practice), even if those methods are disabled elsewhere (e.g. not observing observable, return false from wantPacket)

* refactor: allow requesting update without requesting autoshow
Some applets may want to redraw, if they are displayed, but not feel the information is worth being brought to foreground for. Example: ActiveNodesApplet, when purging old nodes from list.

* feat: custom "Recently Active" duration
Allows users to tailor how long nodes will appear in the "Recents" applets, to suit the activity level of their mesh.

* refactor: rename some applets

* fix: autoshow

* fix: getWrappedTextHeight
Remove the "simulate" option from printWrapped; too hard to keep inline with genuine printing (because of AdafruitGFX Fonts' xAdvance, mabye?). Instead of simulating, we printWrapped as normal, and discard pixel output by setting crop. Both methods are similarly inefficient, apparently.

* fix: text wrapping in ThreadedMessageApplet
Wrong arguments were passed to Applet::printWrapped

* feat: notifications for text messages
Only shown if current applet does not already display the same info. Autoshow takes priority over notifications, if both would be used to display the same info.

* feat: optimize FAST vs FULL updates
New UpdateMediator class counts the number of each update type, and suggets which one to use, if the code doesn't already have an explicit prefence. Also performs "maintenance refreshes" unprovoked if display is not given an opportunity to before a FULL refresh through organic use.

* chore: update todo list

* fix: rare lock-up of buttons

* refactor: backlight
Replaces the initial proof-of-concept frontlight code for T-Echo
Presses less than 5 seconds momentarily illuminate the display
Presses longer than 5 seconds latch the light, requiring another tap to disable
If user has previously removed the T-Echo's capacitive touch button (some DIY projects), the light is controlled by the on-screen menu. This fallback is used by all T-Echo devices, until a press of the capacitive touch button is detected.

* feat: change tile with aux button
Applied to VM-E290.
Working as is, but a refactor of WindowManager::render is expected shortly, which will also tidy code from this push.

* fix: specify out-of-the-box tile assignments
Prevents placeholder applet showing on initial boot, for devices which use a mult-tile layout by default (VM-E290)

* fix: verify settings version when loading

* fix: wrong settings version

* refactor: remove unimplemented argument from requestUpdate
Specified whether or not to update "async", however the implementation was slightly broken, Applet::requestUpdate is only handled next time WindowManager::runOnce is called. This didn't allow code to actually await an update, which was misleading.

* refactor: renaming
Applet::render becomes Applet::onRender.
Tile::displayedApplet becomes Tile::assignedApplet.
New onRender method name allows us to move some of the pre and post render code from WindowManager into new Applet::render method, which will call onRender for us.

* refactor: rendering
Bit of a tidy-up. No intended change in behavior.

* fix: optimize refresh times
Shorter wait between retrying update if display was previously busy.
Set anticipated update durations closer to observed values. No signifacant performance increase, but does decrease the amount of polling required.

* feat: blocking update for E-Ink
Option to wait for display update to complete before proceeding. Important when shutting down the device.

* refactor: allow system applets to lock rendering
Temporarily prevents other applets from rendering.

* feat: boot and shutdown screens

* feat: BluetoothStatus
Adds a meshtastic::Status object which exposes the state of the Bluetooth connection. Intends to allow decoupling of UI code.

* feat: Bluetooth pairing screen

* fix: InkHUD defaults not honored

* fix: random Bluetooth pin for NicheGraphics UIs

* chore: button interrupts tested

* fix: emoji reactions show as blank messages

* fix: autoshow and notification triggered by outgoing message

* feat: save InkHUD data before reboot
Implemented with a new Observable. Previously, config and a few recent messages were saved on shutdown. These were lost if the device rebooted, for example when firmware settings were changed by a client. Now, the InkHUD config and recent messages saved on reboot, the same as during an intentional shutdown.

* feat: imperial distances
Controlled by the config.display.units setting

* fix: hide features which are not yet implemented

* refactor: faster rendering
Previously, only tiles which requested update were re-rendered. Affected tiles had their region blanked before render, pixel by pixel. Benchmarking revealed that it is significantly faster to memset the framebuffer and redraw all tiles.

* refactor: tile ownership
Tiles and Applets now maintain a reciprocal link, which is enforced by asserts. Less confusing than the old situation, where an applet and a tile may disagree on their relationship. Empty tiles are now identified by a nullptr *Applet, instead of by having the placeholderApplet assigned.

* fix: notifications and battery when menu open
Do render notifications in front of menu; don't render battery icon in front of menu.

* fix: simpler defaults
Don't expose new users to multiplexed applets straight away: make them enable the feature for themselves.

* fix: Inputs::TwoButton interrupts, when only one button in use

* fix: ensure display update is complete when ESP32 enters light sleep
Many panels power down automatically, but some require active intervention from us. If light sleep (ESP32) occurs during a display update, these panels could potentially remain powered on, applying voltage the pixels for an extended period of time, and potentially damaging the display.

* fix: honor per-variant user tile limit
Set as the default value for InkHUD::settings.userTiles.maxCount in nicheGraphics.h

* feat: initial InkHUD support for Wireless Paper v1.1 and VM-E213

* refactor: Heard and Recents Applets
Tidier code, significant speed boost. Possibly no noticable change in responsiveness, but rendering now spends much less time blocking execution, which is important for correction functioning of the other firmware components.

* refactor: use a common pio base config
Easier to make any future PlatformIO config changes

* feat: tips
Show information that we think the user might find helpful. Some info shown first boot only. Other info shown when / if relevant.

* fix: text wrapping for '\n'
Previously, the newline was honored, but the adojining word was not printed.

* Decouple ButtonThread from sleep.cpp
Reorganize sleep observables. Don't call ButtonThread methods inside doLightSleep. Instead, handle in class with new lightsleep Observables.

* feat: BluetoothStatus
Adds a meshtastic::Status object which exposes the state of the Bluetooth connection. Intends to allow decoupling of UI code.

* feat: observable for reboot

* refactor: Heltec VM-E290 installDefaultConfig

* fix: random Bluetooth pin for NicheGraphics UIs

* update device-ui: fix touch/crash issue while light sleep

* Collect inkhud

* fix: InkHUD shouldn't nag about timezone (#6040)

* Guard eink drivers w/ MESHTASTIC_INCLUDE_NICHE_GRAPHICS

* Case sensitive perhaps?

* More case-sensitivity instances

* Moar

* RTC

* Yet another case issue!

* Sigh...

* MUI: BT programming mode (#6046)

* allow BT connection with disabled MUI

* Update device-ui

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* MUI: fix nag timeout, disable BT programming mode for native (#6052)

* allow BT connection with disabled MUI

* Update device-ui

* MUI: fix nag timeout default and remove programming mode for native

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* remove debuglog leftover

* Wireless Paper: remove stray board_level = extra (#6060)

Makes sure the InkHUD version gets build into the release zip

* Fixed persistence stragglers from NodeDB / Device State divorce (#6059)

* Increase `MAX_THREADS` for InkHUD variants with WiFi (#6064)

* Licensed usage compliance (#6047)

* Prevent psk and legacy admin channel on licensed mode

* Move it

* Consolidate warning strings

* More holes

* Device UI submodule bump

* Prevent licensed users from rebroadcasting unlicensed traffic (#6068)

* Prevent licensed users from rebroadcasting unlicensed traffic

* Added method and enum to make user license status more clear

* MUI: move UI initialization out of main.cpp and adding lightsleep observer + mutex (#6078)

* added device-ui to lightSleep observers for handling graceful sleep; refactoring main.cpp

* bump lib version

* Update device-ui

* unPhone TFT: include into build, enable SD card, increase PSRAM (#6082)

* unPhone-tft: include into build, enable SD card, increase assigned PSRAM

* lib update

* Backup / migrate pub private keys when upgrading to new files in 2.6 (#6096)

* Save a backup of pub/private keys before factory reset

* Fix licensed mode warning

* Unlock spi on else file doesn't exist

* Update device-ui

* Update protos and device-ui

* [create-pull-request] automated change (#6129)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Proto

* [create-pull-request] automated change (#6131)

* Proto update for backup

* [create-pull-request] automated change (#6133)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Update protobufs

* Space

* [create-pull-request] automated change (#6144)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Protos

* [create-pull-request] automated change (#6152)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Updeet

* device-ui lib update

* fix channel OK button

* device-lib update: fix settings panel -> no scrolling

* device-ui lib: last minute update

* defined(SENSECAP_INDICATOR)

* MUI hot-fix pub/priv keys

* MUI hot-fix username dialog

* MUI: BT programming mode button

* Update protobufs

---------

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: GUVWAF <thijs@havinga.eu>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Jason Murray <15822260+scruplelesswizard@users.noreply.github.com>
Co-authored-by: Jason Murray <jason@chaosaffe.io>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: virgil <virgil.wang.cj@gmail.com>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: Kalle Lilja <15094562+ThatKalle@users.noreply.github.com>
Co-authored-by: rcarteraz <robert.l.carter2@gmail.com>
2025-03-01 06:18:33 -06:00
github-actions[bot]
088fce7d11 [create-pull-request] automated change (#6181)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-03-01 05:09:59 -06:00
github-actions[bot]
b46bf16385 Upgrade trunk (#6160)
Co-authored-by: vidplace7 <1779290+vidplace7@users.noreply.github.com>
2025-02-27 13:49:59 +08:00
Rick Mark
1c827f5512 DevContainers: Include meshtasticd dependencies (#5699)
* Include meshtasticd dependencies

* Remove device-ui checkin

* Add trunk rules matching other Dockerfiles

---------

Co-authored-by: vidplace7 <vidplace7@gmail.com>
2025-02-27 13:01:34 +08:00
Austin
b437f0fb54 More trunk junk / remove old workflows (#6153) 2025-02-27 09:43:01 +08:00
Karch
ffe4e7b6be Add some minor additional options to userPrefs.jsonc (#6137)
* added some additional userPrefs options

* linted

* some further changes

* fixed some option ordering
2025-02-27 08:57:43 +08:00
Mictronics
598cfcc081 Cast user pref strings. (#6123) 2025-02-27 08:21:03 +08:00
github-actions[bot]
f2e49aa4ee Upgrade trunk (#6151)
Co-authored-by: sachaw <11172820+sachaw@users.noreply.github.com>
2025-02-25 16:27:45 -05:00
dependabot[bot]
3a0ad9bb58 Bump python from 3.12-alpine3.21 to 3.13-alpine3.21 (#6142)
Bumps python from 3.12-alpine3.21 to 3.13-alpine3.21.

---
updated-dependencies:
- dependency-name: python
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-25 20:53:33 +08:00
Austin
4e575872da junk in the Trunk (#6149) 2025-02-25 16:41:45 +08:00
Ben Meadors
bf958ed01d Update version.properties 2025-02-24 10:23:24 -06:00
Austin
c93728eb75 Debian: Ensure deps exist for changelog bump (#6145) 2025-02-24 09:16:18 -06:00
dependabot[bot]
01c717a41d Bump actions/stale from 9.0.0 to 9.1.0 in /.github/workflows (#6143)
Bumps [actions/stale](https://github.com/actions/stale) from 9.0.0 to 9.1.0.
- [Release notes](https://github.com/actions/stale/releases)
- [Changelog](https://github.com/actions/stale/blob/main/CHANGELOG.md)
- [Commits](https://github.com/actions/stale/compare/v9.0.0...v9.1.0)

---
updated-dependencies:
- dependency-name: actions/stale
  dependency-type: direct:production
  update-type: version-update:semver-minor
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2025-02-24 22:35:14 +08:00
github-actions[bot]
7061fd1f16 Upgrade trunk (#6139) 2025-02-24 11:12:18 +01:00
Tom Fifield
7d8e0ede6c Reduce some log levels. (#6127)
This patch takes a few LOG_INFO messages and turns them into
LOG_DEBUG. The logs appear to be mostly useful to developers, rather
than end users and as such placing them at INFO level is too high a
priority.
2025-02-23 06:14:37 -06:00
github-actions[bot]
efca2b5849 [create-pull-request] automated change (#6122)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-02-22 11:19:07 -06:00
GUVWAF
cfcd9cc210 Revert "Rak4631 remove spi1 (#6042)" (#6121)
This reverts commit 9b46cb4ef0.
2025-02-22 08:03:05 -06:00
Tom Fifield
fe1ced7480 GPS Factory Reset no longer needed. (#6116)
In 2020 there was a bad batch of tbeams whose ubloxen went a little
loopy. We factory reset them to bring them sane again.

It's now 2025, the problem with tbeam is long fixed, and this is not
necessary for any other devices we're aware of. Removing the function to
make our code more maintainable.

There is an associated protobuf entry did_gps_reset that we might be able
to re-purpose for something else, or remove in 3.0.
2025-02-21 16:53:46 -06:00
Austin
3787cf7803 meshtasticd deb: Build armv6-compatible binary (#6104) 2025-02-21 09:55:38 +08:00
Ben Meadors
1be28520a7 Perhaps fix TXCO reports on pro-micro (#6110)
* Perhaps fix TXCO reports on pro-micro

* Missed one
2025-02-21 08:30:09 +08:00
GUVWAF
4942c7b71f Fix PowerTelemetry initialization (#6106) 2025-02-20 15:28:01 -06:00
GUVWAF
4709d21df8 Ignore and disallow multi-hop traceroutes destined to broadcast address (#6109)
* Ignore traceroutes destined to broadcast address

* Disallow multi-hop traceroute request to broadcast address

* Allow zero-hop broadcast requests
2025-02-20 14:34:09 -06:00
Tom Fifield
ec0eafedab Move variant-specific lines back to variant (#6044)
Last release a change introduced different branching functions in
gps.cpp based on the model of a device. This makes the code less
readable and introduces the potential for bugs.

This patch creates a new variable, GPS_PROBETRIES that can be set
in variant.h of devices that will control how many times we will
probe for GPS presence. It sets up the T1000-E to use this variable
and cleans the code in gps.c
2025-02-20 07:48:37 -06:00
rostekus
994e22aba9 feat: added BMP-390 support to the BMP-3xx sensors (#6103) 2025-02-20 21:36:49 +08:00
Mictronics
9930bba3f5 Add Pico2W variant including Wifi support. (#6062) 2025-02-20 10:56:34 +01:00
Austin
f1dc1b309a PIO: Cleanup dependency naming (#6090) 2025-02-19 18:14:54 -06:00
Austin
337265a07f Trunk: Another annotation attempt (#6100) 2025-02-20 07:43:23 +08:00
Sebastian Muszynski
bb73555209 Expose INA219 measurement as battery voltage for Seeed Xiao ESP32S3 (#6070)
* Expose INA219 measurement as battery voltage for Seeed Xiao ESP32S3

* Define BATTERY_PIN and don't block a random GPIO
2025-02-19 06:36:59 -06:00
Tom Fifield
93c64cb442 Dependencies: minor version updates (#6045)
platformio/espressif32@6.9.0 --> 6.10.0
lewisxhe/XPowersLib@^0.2.6 --> 0.2.7
platformio/framework-arduinoststm32@~Oct 2024 --> 4.20900.0
zinggjm/GxEPD2@^1.4.9 --> 1.6.2
tool-esptoolpy@^1.40500.0 --> 1.40801.0

Used platformio tool to check, kept to minor version updates,
checked release notes for any breaking changes.
2025-02-19 06:32:38 -06:00
Austin
5da5803c4c Trunk: Annotate PRs and Auto-Upgrade (#6091) 2025-02-19 06:14:46 -06:00
Ikko Eltociear Ashimine
79b3a1e60e chore: update unishox2.h (#6092)
occuring -> occurring
2025-02-19 12:58:41 +01:00
rcarteraz
191ca8ce12 update readme add logo image (#6088) 2025-02-18 15:56:13 -06:00
noahhaon
c67aa25d19 Add missing traceroute fields to serialized JSON output (#6087) 2025-02-18 13:25:55 -06:00
Eric Severance
3b0232de1b Validate MQTT config by testing a connection (#6076) 2025-02-17 15:03:44 -06:00
A_Ponzano
7eb77276cd Add support for new NRF52 board, MeshLink (#5736)
* Add support for MeshLink

* Updated, enabled watchdog and added button definition

* added eink variant and removed some compile errors

* Small board json file edit

* Finally got trunk working (somehow?), this is just cleanup with trunk fmt

* Various improvements and cleanup. Removed the use of PIN_3V3_En and defined a specific WD_EN pin instead for better clarity. Will do a bit more testing asap to make sure everything still works as intended :)

* Enable on-board QSPI Flash

* run trunk fmt with clang-format

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Austin <vidplace7@gmail.com>
2025-02-16 19:49:17 -06:00
Eric Severance
7648391f91 Reject invalid configuration for the default MQTT server (#6066)
* Sanity check configuration for the default MQTT server

* Skip for MESHTASTIC_EXCLUDE_MQTT

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-02-16 07:15:30 -06:00
porkcube
4407d9e040 assigning SDA/SCL so it actually works 8| (#6065) 2025-02-16 06:39:48 -06:00
GUVWAF
27fea5fc07 Fix STM32WL TCXO setting; enable logs and modules (#6063)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-02-15 09:06:10 -06:00
Michael Gjelsø
2f6cd02111 Typo for Bandit button LEDs (#6053)
Changed Button 2 LED index define from BUTTON1_COLOR_INDEX to correct BUTTON2_COLOR_INDEX
2025-02-15 08:06:41 -06:00
GUVWAF
8c9947b05c Allow NeighborInfo on non-default frequency slot (#6061) 2025-02-15 07:55:51 -06:00
Eric Severance
50b7d6a0f7 Establish MQTT connection only from MQTT::runOnce (#6057)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-02-14 20:32:41 -06:00
Eric Severance
c83ffd4911 Consider the MQTT TLS remote IP when enabled. (#6058) 2025-02-14 19:19:50 -06:00
Woutvstk
9b46cb4ef0 Rak4631 remove spi1 (#6042)
* Removed non-existant SPI1 interface on rak4631

* trunk fmt
2025-02-14 12:53:22 -06:00
porkcube
01935ea35e Add XIAO nRF52840 + Wio SX1262 DIY Variant (#5976)
* added xiao nRF52840 + xiao wio sx1262 DIY variant

* fix path / make buildy buildy

* pcf cruft from personal hw

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-02-14 06:50:28 -06:00
Austin
495f69cf90 Trunk: Trailing commas begone! (#6038) 2025-02-12 08:57:23 +08:00
Manuel
eb650a6adb set TCXO to 2.4V (#6036) 2025-02-11 10:34:37 -06:00
nwilde1590
7fdd262d55 Added custom OCV array values for T1000-E (#6031) 2025-02-11 14:02:21 +08:00
Austin
d1fa27d353 small fix: don't junk the zip for pio-deps (#6029) 2025-02-10 20:35:06 -06:00
Austin
8427072d79 meshtasticd: include .hidden (.git) dirs in pio-deps (#6028) 2025-02-10 18:58:02 -05:00
github-actions[bot]
4e2b47cc67 [create-pull-request] automated change (#6027)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-02-10 15:02:42 -06:00
Jason P
da1d78c882 Add support for 12- and 24-hour clock, Minor Settings Frame Adjustment (#5988)
* 12- or 24-hour clock work in progress

* 12- and 24-hour added to Settings Frame. Also some adjustments to screen layout.

* Updated Uptime wording to be "Up" to fit within screen real estate

* Removed label from uptime to conserve additional space

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-02-10 14:30:43 -06:00
Austin
7c4bf38647 meshtasticd flatpak: Include pio deps with release (#6025) 2025-02-10 14:29:16 -06:00
Mark Trevor Birss
96262b106c Revert "Create display-x11.yaml (#6021)" (#6022)
This reverts commit 39e45d90e1.
2025-02-10 11:53:58 +02:00
Mark Trevor Birss
39e45d90e1 Create display-x11.yaml (#6021) 2025-02-10 09:59:13 +02:00
ChangYanChu
d70a9392af improve UTF-8 string handling in JSONValue (#6011)
```text
feat(json): improve UTF-8 string handling in JSONValue

- Add proper UTF-8 multi-byte character sequence handling
- Add boundary checks for UTF-8 sequences
- Keep original code structure and flow
- Add detailed comments for UTF-8 processing logic

This change improves the robustness of JSON string handling
while maintaining compatibility with existing code.
2025-02-08 20:03:44 +08:00
dylanli
4e8c4f0d55 T1000-E hardware updates and GPS positioning accuracy optimisation (#6003)
* T1000-E button setting update

* T1000-E GNSS lock error fix

* T1000-E GNSS improve detection success

---------

Co-authored-by: WayenWeng <jinyuan.weng@seeed.cc>
2025-02-07 10:02:56 +02:00
lizthedeveloper
4a6a0efcfd log the nonce value at DEBUG instead of INFO (#6001)
you're leaking the nonce to stdout, if your logs are routed to a folder, this logs the nonce every time, leading to replay attack surface area being higher. Changed to debug.
2025-02-07 08:29:48 +08:00
github-actions[bot]
cb0519dd9c [create-pull-request] automated change (#5989)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-02-06 14:11:32 -06:00
Manuel
9db51a72a4 Fix T-Deck/T-Watch no BT (#5998)
fixes #5997
2025-02-06 14:11:17 -06:00
Tom
64def246ee Corrected some misinformation (#5995)
Change the module text too soon , before it had chance to reach a final conclusion.

Co-authored-by: Tom <116762865+Nestpebble@users.noreply.github.com>
2025-02-06 11:36:04 +08:00
Austin
1c8eb7ece3 meshtasticd: Fix web download location (#5993) 2025-02-05 15:19:22 -06:00
Austin
447533aae5 meshtasticd-debian: Remove existing deb builds (#5792)
Replaced with OpenSUSE Build Service
https://build.opensuse.org/project/show/network:Meshtastic
2025-02-04 07:38:54 -05:00
github-actions[bot]
1b457bcfbb [create-pull-request] automated change (#5985)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-02-03 20:47:51 -06:00
Thomas Göttgens
ed07cc067a Merge branch 'master' of https://github.com/meshtastic/firmware 2025-02-03 16:48:23 +01:00
Thomas Göttgens
a3a295488c add firmware build script for use with docker 2025-02-03 16:48:10 +01:00
Thomas Göttgens
5c17afb2ac Clean up some legacy macro definitions (#5983) 2025-02-03 09:36:05 -06:00
Tom Fifield
8cacdb65d6 Fix INA226 Sensor Voltage Readings (#5972)
They were off by a factor of 1000 due to the difference between
Volts and MilliVolts, as reported by @morcant .

Fixes https://github.com/meshtastic/firmware/issues/5969
2025-02-03 08:39:42 -06:00
Tom
3a34f8beaf E80 promicro update (#5967)
* add readme and update rfswitch

* Updated readme to include all data from Ebyte

* Added results from switch testing & notes thereon

* fixed picture

* Whoops!

Forgot to uncomment some settings from test.

* Update readme.md

* Delete variants/diy/nrf52_promicro_diy_tcxo/E80_RSSI_per_case.png

* Add webp image to appease trunk

* Update readme.md

* Trunky trunk trunk

* Clang and the trunk is done
2025-02-03 20:16:35 +08:00
GUVWAF
d740934278 Don't rate-limit position requests for Lost and Found role (#5981) 2025-02-03 19:24:47 +08:00
Woutvstk
b370717dcd Add bearing to other node on device screen in text (#5968)
* Merge branch 'store-and-forward' of https://github.com/Woutvstk/meshtastic_firmware into store-and-forward

* also show bearing to a waypoint in text on screen
2025-02-03 13:43:32 +08:00
Chloe Bethel
d9534cfc9d Remove unused usages of #include <iostream> to save Flash (#5978)
Saves ~100KB on wio-e5, which was previously at 99% Flash usage
2025-02-03 11:31:54 +08:00
Austin
4c0e0b8471 Portduino: Set Web SSL Cert / Key paths from yaml (#5961) 2025-02-01 16:58:58 +08:00
Ben Meadors
b5cad2b65e Fix negative decimal value detection in userPrefs (#5963) 2025-01-29 20:52:24 -06:00
Jason P
cd8592ef4a Fixes #5766 Updated MQTT privateCidrRanges to add Tailscale (#5957) 2025-01-29 06:14:43 -06:00
Austin
78da8f6fc4 Portduino: Allow limiting TX Power from yaml (#5954) 2025-01-29 12:51:26 +01:00
Tom Fifield
6a12760c3d Fix off-by-one error with log writes (#5959)
As reported by @jstockdale, when writing coloured logs we were
writing the full string, including a null terminator. This caused
issues for programs consuming our logs. The fix as identified is
not to write the null.

Fixes https://github.com/meshtastic/firmware/issues/5945
2025-01-28 19:57:52 -06:00
Thomas Göttgens
30a31a3a13 Oem logo (#5939)
* reinstate oemlogo, add to userPrefs.jsonc

* disable from default build
2025-01-28 08:38:22 -06:00
Manuel
2d42e1b2bc fix: TCXO_OPTIONAL featuring SenseCAP Indicator (V1/V2) (#5948)
* fix TCXO_OPTIONAL

* fix LOG_WARN

* fix lora.begin() returns -707

* trunk fmt
2025-01-27 14:00:12 -06:00
GUVWAF
4747e73f37 Space out periodic broadcasts of modules automatically (#5931)
* Space out periodic broadcasts of modules automatically

* Add warning for function usage

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-26 13:59:59 -06:00
Aleksey Vasilenko
10d553087c Add missing build_unflags (#5941)
Fixes 'undefined reference to app_main' build error for
my_esp32s3_diy_eink and my_esp32s3_diy_oled variants.
2025-01-26 16:54:26 +08:00
Ben Meadors
7649e70585 Revert "No focus on new messages if auto-carousel is off (#5881)" (#5936)
This reverts commit 0f981153eb.
2025-01-25 12:01:25 -06:00
GUVWAF
a14346bc4f Rate limit position replies to three minutes (#5932) 2025-01-25 09:24:24 -06:00
github-actions[bot]
fd56995764 [create-pull-request] automated change (#5928)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-25 07:53:24 -06:00
github-actions[bot]
4c97351187 [create-pull-request] automated change (#5926)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-24 18:52:17 -06:00
Tom Fifield
3298df953a Fixed the issue that the wifi configuration saved to RAM did not take effect. (#5925)
Co-authored-by: virgil <virgil.wang.cj@gmail.com>
2025-01-24 07:30:18 -06:00
Ben Meadors
d1f7739bbe Peg NRF52 arduino to meshtastic fork with LFE bluetooth fix (#5924) 2025-01-23 19:56:59 -06:00
Ben Meadors
0d860882a8 NRF52 - Remove file totally before opening write (#5916)
* Remove prefs first

* Remove file first

* Remove truncate

* No longer needed

* Missed a param

* That wasn't supposed to be there

* Remove vestigal lfs assert

* Durr
2025-01-23 19:12:20 -06:00
Austin
3b40fe9805 Docker: Switch tags to newline-seperated (#5919) 2025-01-24 09:03:03 +11:00
Austin
8e8b22edb0 Debian: Switch OBS repo to network:Meshtastic (#5912) 2025-01-22 11:09:29 -06:00
Austin
01892cbd1e Docker: tag intermediate containers (#5910) 2025-01-22 08:55:57 -06:00
Thomas Göttgens
7fb22cf678 ignore platformio core files when building in place 2025-01-22 14:11:58 +01:00
Eric Severance
fdc87d492c Add quotes around ${platformio.build_dir} (#5906)
Fixes #5898 (hopefully)
2025-01-22 19:45:34 +11:00
Austin
0fdbf70452 Small fix: Correctly pass secrets in Docker builds (#5905) 2025-01-22 14:26:10 +11:00
Austin
71591fb06a Build docker images with other linux (#5837) 2025-01-21 18:53:32 -06:00
Austin
9041af365d Move OpenWRT configs to subdir (#5902) 2025-01-21 16:18:40 -06:00
GUVWAF
f87c370123 Fix possible memory leak for ROUTER_LATE (#5901) 2025-01-21 18:11:37 +01:00
Eric Severance
c4fcbad372 Reboot before formatting LittleFS (#5900)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-20 11:43:35 -06:00
isseysandei
0f981153eb No focus on new messages if auto-carousel is off (#5881)
* no focus on messages if screen carousel is disabled

* trunk + comment

* compacted the nested if using ternary operator

* trunk
2025-01-20 10:47:47 -06:00
Mark Trevor Birss
c1beb44678 Create BananaPi-BPI-R4-sx1262.yaml (#5897) 2025-01-20 13:20:59 +02:00
Thomas Göttgens
973b453d43 Update RAK2560 code (#5844)
* * Update RAK9154 sensor to tx remote power telemetry
* remove uf2 script, pio run does that inline
* move sensor module to correct position
* disable LED and Accelerometer code on rak2560
* trunk fmt
* mention epaper variant
* attention, revert, revert
* Enable Environment Telemetry of these values
* fix float values
2025-01-20 09:34:54 +01:00
Ben Meadors
950341d1f9 Alert app messages should be treated as text (#5878) 2025-01-18 08:15:06 -06:00
Thomas Göttgens
b353bcc04a fix detection of lark weather station and add rain sensor (#5874)
* fix detection of lark weather station
* fix unit tests and add support for Dfrobot rain gauge
* fix name display on bootup
* fix gauge init logic
* trunk fmt
2025-01-18 14:10:13 +01:00
github-actions[bot]
c4051c1a7b [create-pull-request] automated change (#5877)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2025-01-18 13:32:09 +01:00
Austin
2262d77be4 Small fix: Reference COPR group correctly (@) (#5872) 2025-01-17 12:27:49 +08:00
Austin
9566d6ffd4 COPR: Switch to forked GitHub Action (#5871) 2025-01-16 20:21:52 -06:00
Patrick Siegl
e466bf2475 Slight rework of CH341 HAL (#5848)
* Rework of CH341 HAL

* Applied trunk fmt

* revert serial reading

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-01-16 19:38:58 -06:00
Eric Severance
b0fe5ef8ba Initial commit of a fuzzer for Meshtastic (#5790)
* Initial commit of a fuzzer for Meshtastic.

* Use a max of 5 for the phone queues

* Only write files to the temp dir

* Limitless queue + fuzzer = lots of ram :)

* Use $PIO_ENV for path to program

* spelling: s/is/to/

* Use loopCanSleep instead of a lock in Router

* realHardware allows full use of a CPU core

* Ignore checkov CKV_DOCKER_2 & CKV_DOCKER_3

* Add Atak seed

* Fix lint issues in build.sh

* Use exception to exit from portduino_main

* Separate build & source files into $WORK & $SRC

* Use an ephemeral port for the API server

* Include CXXFLAGS in the link step

* Read all shared libraries

* Use a separate work directory for each sanitizer

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-16 18:42:21 -06:00
Vít Holásek
f132158c3e Fixed localization on bigger screens (#5695)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-16 18:39:39 -06:00
SignalMedic
8179e61fdc changed GPS buad rate to 9600 (#5786)
Co-authored-by: Huston Hedinger <1875033+hdngr@users.noreply.github.com>
2025-01-16 17:26:02 -06:00
danwelch3
a085614aaa Initiate magnetometer based compass calibration from button presses (#5553)
* Initiate magenetometer based compass calibration from button presses

- only active for BMX160 accelerometers on RAK_4631
- replace automatic calibration on power on with button triggered
  calibration
- set 5 presses to trigger 30s calibration
- set 6 presses to trigger 60s calibration (useful if unit is not
  handheld, ie vehicle mounted)
- show calibration time remaining on calibration alert screen

* Fix non RAK 4631 builds

- exclude changes from non RAK 4631 builds
- remove calls to screen when not present

* Fix build on RAK4631_eth_gw

- exclude all compass heading updates on variant without screen

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-16 17:22:27 -06:00
Ben Meadors
7acd72ede1 Cleanup unique id 2025-01-16 16:00:23 -06:00
Austin
7ba593432e COPR: Switch from hook to copr_cli (#5864) 2025-01-16 15:51:18 -06:00
todd-herbert
a48df91737 Canned messages: allow GPIO0 with "scan and select" input (#5838)
* Allow GPIO0; check for conflict with user button

* Guard for no BUTTON_PIN; handle portduino

* Portduino settings: attempt two
We don't really need to #include radio code here just to check if the pin is RADIOLIB_NC. We're only interested if scanAndSelect pin matches user button pin, but they won't match if user button is RADIOLIB_NC.

* Portduino attempt 3: glue
2025-01-16 06:38:22 -06:00
github-actions[bot]
262f1d25a2 [create-pull-request] automated change (#5860)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-16 06:15:17 -06:00
todd-herbert
4cd2ba5479 More lines of environmental telemetry on-screen (#5853) 2025-01-16 23:23:57 +13:00
todd-herbert
f9876cfe9c Wait for disconnection (#5859) 2025-01-15 07:19:51 -06:00
Ben Meadors
85de193845 Fix NRF52 default append write mode of files (#5858)
* Fix NRF52 default append write mode of files

* Inside the lock
2025-01-15 06:46:12 -06:00
Ben Meadors
fb2c008c89 Update version.properties 2025-01-14 18:55:02 -06:00
Austin
dd9ab7f0e1 Small Fix: Release_Channels permissions (#5852) 2025-01-14 15:17:54 +08:00
github-actions[bot]
729c39fb86 [create-pull-request] automated change (#5849)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-13 19:18:34 -06:00
isseysandei
038430db23 Environmental sensors page scrolling (#5847)
* env scrolling first iteration

* ran trunk
2025-01-14 09:00:00 +08:00
Ben Meadors
d5cd6f87a0 Kablammo 2025-01-13 12:15:27 -06:00
Austin
de42d96adf Actions: Fix issues with new Release process (#5845) 2025-01-13 10:46:07 -06:00
Ben Meadors
e2dd845051 Fix devicestate protobuf / filesize allocation (#5835) 2025-01-13 08:30:20 -06:00
github-actions[bot]
6366633cd4 [create-pull-request] automated change (#5841)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-13 07:05:59 -06:00
Ben Meadors
1c0f43c8e2 NRF52 SafeFile should not remove / rename files (#5840) 2025-01-13 06:28:18 -06:00
isseysandei
89a9e0b99d Added illuminance sensors to the node's environmental sensor page (#5832)
* illuminance sensors added

* added white_lux to debug
2025-01-13 16:39:01 +08:00
Austin
4dc8d6e400 Fix daily packaging perms (#5836) 2025-01-13 13:20:22 +08:00
Austin
e0f97c9306 rpkg Fedora packaging (#5735) 2025-01-13 12:24:05 +08:00
Jonathan Bennett
6b1c01ce02 Trunk n stuff (#5833)
* Trunk

* Allow new gpio syntax with defaults

* Exit on pin init failure
2025-01-12 15:10:50 -06:00
Patrick Siegl
70296b47bc Multi gpiochip support for native environment (#5743)
* For each GPIO PIN, allow to specify gpiochip and line

* Added support for LLCC68 in native env.

* Removed one if by employing &&

* Fix for log, as std::string and not const char*

* Remove CH341 flag, enabling it for all LoRa chips

* Provide a default example

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2025-01-12 13:40:25 -06:00
Erayd
0cf4a2951a Bugfix for low-priority packet replacement when TX queue is full (#5827)
* Correct function comment

* Enqueue the intended packet, not the pointer to what we just dropped!

* Add some log output when we drop packets due to a full queue

* Make it clear when a non-late packet is dropped

* Remove from queue before release, not after

* Erase dropped packet from queue

* Declared type

* Log TX queue length after every send

* Fix operand order

* Add worst-case cap on TX delay vs current time
2025-01-12 12:05:51 -06:00
Eric Severance
124936b6cf Avoid a potential NULL pointer reference in nrf52/BluetoothPhoneAPI (#5830) 2025-01-12 12:05:04 -06:00
Tom Fifield
fd60c9b3be Upgrade to LovyanGFX 1.2 (#5677)
* [WIP] Attempt upgrade to LovyanGFX 1.1.16

This is the version most used by the TFT branch.

I wonder if this will work with our existing code? :)

* Update Portduino to LovyanGFX 1.20.0

Manuel says it's good to go.

* Update unPhone platformio.ini

---------

Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
2025-01-12 15:16:26 +08:00
And137
a0a4c5bc79 Support for Polish fonts on E-Ink devices, Polish fonts retouch, fixed Czech/Slovak OLED/E-Ink double space bug (#5821)
* Added support for Polish fonts for E-Ink devices

* Added support for Polish fonts for E-Ink devices FIX

* Polilsh E-Ink/OLED font retouch, fixed Czech/Slovak font double space bug

* Fixed platformio.ini uncommented flag
2025-01-12 14:30:58 +08:00
Eric Severance
0fe8d4ccc7 Run the AddressSanitizer during tests (#5815)
* Run the AddressSanitizer during tests

* Show details for test failures
2025-01-12 13:51:43 +08:00
DarkZeros
00fdf2c9aa Heltec Wireless Stick Lite V1/V2 support (#5808)
* I only have the V2.1 version, not sure if
  the HW is same with V1, or V2. Given the few
  resources I could find I think it is.
* ADC / Battery measure and TX/RX are working
2025-01-12 13:17:40 +08:00
Eric Severance
253ab458ef Add lsb-release on the github runner (#5825) 2025-01-11 22:29:24 -06:00
Eric Severance
b4a4d2db4e Cache Python & PlatformIO dependencies (#5822) 2025-01-11 19:40:39 -06:00
GUVWAF
6b8cf164e9 Save some flash usage on STM32WL (#5819) 2025-01-11 07:20:32 -06:00
GUVWAF
812aa35f09 Enable Tx interrupt immediately after startTransmit() (#5820) 2025-01-11 07:19:17 -06:00
Eric Severance
e7802d960f Manage when destructor is called for native HttpAPI (#5807) 2025-01-11 06:15:50 -06:00
Tom Fifield
077ee02426 Cherry-pick: Meshtab streamline and rotation fixes (#5812)
* mesh-tab: streamline target definitions

* mesh-tab: fix touch rotation 4.0 inch display

* Mesh-Tab platformio: 4.0inch: increase SPI frequency to max

* mesh-tab: fix rotation for 3.5 IPS capacitive display

* mesh-tab: fix rotation for 3.2 IPS capacitive display

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2025-01-11 05:52:28 -06:00
Tom Fifield
46ea39af45 Quote filename in device-install.sh (#5814)
Without these quotes, a filename with spaces would be interpreted as
different arguments.

Thanks to @Hnikar-az for the report.

fixes https://github.com/meshtastic/firmware/issues/5795
2025-01-11 10:10:04 +01:00
Thomas Göttgens
25a5f178e1 remove ethernet code from this variant, remove unused radio chip code (#5810)
* remove ethernet code from this variant, remove unused radio chip code

* remove ethernet lib too, pin onewire library to release hash
2025-01-11 10:43:48 +08:00
Austin
c144ee77a7 GitHub Actions: Fix meshtastic display issue in logs (#5811) 2025-01-10 19:46:12 -06:00
Austin
b62bdbc46a meshtasticd-debian: Auto-Publish to OBS (#5791) 2025-01-11 09:03:29 +08:00
Ben Meadors
f18a92e8c5 Don't check for node channels on broadcast address (#5804) 2025-01-10 18:46:26 +08:00
Bernd Giesecke
2e44de262e Add GPS capability to RAK2560 (RAKwireless WisMesh Hub) (#5797)
* Add GPS to RAK2560

* Add GPS to RAK2560
2025-01-09 19:20:38 -06:00
Eric Severance
1d756ae574 Fix potential memory leak in AtakPluginModule (#5803) 2025-01-10 08:25:25 +08:00
Austin
8aac9f2e8e GH Actions: Update Release action, clarify versioning (#5794) 2025-01-08 20:43:24 -06:00
Ben Meadors
33e5a04508 Don't update to the latest ref on non-master branches 2025-01-07 20:02:47 -06:00
Austin
6cf3485d07 meshtasticd-debian: Fix versioning compliance, add OBS (#5785) 2025-01-07 17:16:56 -06:00
Mictronics
9421eba027 Fix build for Pico2 RP2350 platform. (#5783)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

* Remove static declaration for admin keys from userPrefs.h. Load hard coded admin keys in case config file has empty slots.

* Removed newlines from log.

* Fix issue #5665.

* Fix build for Pico2 RP2350 platform.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2025-01-07 09:57:42 -06:00
Eric Severance
27fbfd03d6 Add unit tests for MQTT (#5724)
* Add unit tests for MQTT

* Test received fields
2025-01-07 07:10:42 -06:00
Marco Veneziano
353740623f Increase esp32c3 stability over wifi (#5774)
* Increase esp32c3 stability over wifi

* only apply the fix on esp32c3 based nodes
2025-01-07 07:09:51 -06:00
Austin
cdcbf4c615 Small fix: debian, curl follow redirs (#5780) 2025-01-07 10:51:50 +08:00
Jonathan Bennett
395469d20a As Per XKCD #1168 2025-01-06 19:59:02 -06:00
Austin
86170171a7 meshtasticd-debian: Include web components (#5778) 2025-01-06 19:25:05 -06:00
Austin
57766d47a8 GitHub Actions: Trigger PPA stable builds upon release (#5777) 2025-01-06 18:45:59 -06:00
Austin
e5dbcf5bce meshtasticd-debian: parameterize target PPA (#5776) 2025-01-06 16:20:05 -06:00
Jonathan Bennett
4c3a3ca47d Specify the *correct* scons version 2025-01-06 13:02:53 -06:00
Jonathan Bennett
78371dfdb7 Add PPA to nightly 2025-01-06 12:26:17 -06:00
Jonathan Bennett
ca32889893 Specify scons version 2025-01-06 12:23:08 -06:00
Thomas Göttgens
35cd600c54 update to 7.1.2 and remove the obsolete default_envs. (#5771) 2025-01-06 17:08:12 +01:00
isseysandei
70076a4b27 Improved Power Telemetry page readability even more (#5770)
* increased buffer size to 1024

* better readability

* better readability 2

---------

Co-authored-by: BuildTools <unconfigured@null.spigotmc.org>
2025-01-06 09:14:52 -06:00
Jonathan Bennett
f1a8900288 Don't push to PPA for every commit 2025-01-05 23:50:32 -06:00
Jonathan Bennett
16bc89ea57 Explicitly install tools-scons 2025-01-05 22:23:34 -06:00
Jonathan Bennett
6edf74e8f1 Tab not spaces 2025-01-05 19:58:34 -06:00
Jonathan Bennett
7f280dd556 Hide pio folder in a tarball to preserve .git folders 2025-01-05 19:38:08 -06:00
Jonathan Bennett
2396aa77ca don't run the clean step 2025-01-05 19:03:44 -06:00
Jonathan Bennett
d3cbbfd345 Try adding tar-ignore to preserve .git directories 2025-01-05 18:59:14 -06:00
isseysandei
c003ab0eee Improved readability of Power Telemetry page (#5746)
* increased buffer size to 1024

* better readability
2025-01-05 18:58:10 -06:00
Ben Meadors
4fcf7fe027 Revert "Explicitly set CAD symbols, improve slot time calculation and adjust …" (#5765)
This reverts commit 9cc79b1d1e.
2025-01-05 18:55:55 -06:00
GUVWAF
9cc79b1d1e Explicitly set CAD symbols, improve slot time calculation and adjust CW size accordingly (#5749)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2025-01-05 18:55:20 -06:00
Austin
403fa15a3f meshtasticd-debian: Include run in version (#5762) 2025-01-05 15:55:04 -06:00
Austin
b0087fd328 meshtasticd-debian: Include core_dir in sdeb (#5761) 2025-01-05 15:26:31 -06:00
Austin
fb74e1d182 meshtasticd-debian: set PLATFORMIO_CORE_DIR (#5760) 2025-01-05 15:00:01 -06:00
Austin
29a7866fc1 Use jbennett for gpg email (#5759) 2025-01-05 14:26:56 -06:00
Austin
2f552d15e5 meshtasticd-debian: Cleanup debian versioning (#5758) 2025-01-05 14:14:47 -06:00
Austin
892e0922ff meshtastic-debian: --create requires missing changelog (#5757) 2025-01-05 13:37:15 -06:00
Austin
d21d6c1301 meshtasticd-debian: Build multiple series (#5756) 2025-01-05 13:24:05 -06:00
github-actions[bot]
031aecac66 [create-pull-request] automated change (#5755)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2025-01-05 13:14:56 -06:00
Austin
7c10caa78b meshtastic-debian: publish with dput (#5753) 2025-01-05 12:31:01 -06:00
Austin
5196ee39cb meshtasticd: debian checkout to subdir (#5752) 2025-01-05 11:44:05 -06:00
Austin
02a5a91da0 meshtasticd debian: secrets perms (#5751) 2025-01-05 11:30:43 -06:00
Austin
b2a89b8136 meshtasticd: gpg tomfoolery (#5750) 2025-01-05 11:06:00 -06:00
Austin
15019e8663 meshtasticd: deps for debian_build_src (#5748) 2025-01-05 10:37:38 -06:00
Austin
35814fd4bc meshtasticd debian: split libs for PPA (#5745) 2025-01-05 10:22:11 -06:00
Jonathan Bennett
6aabbedc00 Last Ditch effort for PPA build 2025-01-04 15:41:49 -06:00
Jonathan Bennett
eb72ee0fc1 don't use "source" for deb builds 2025-01-04 14:51:36 -06:00
Jonathan Bennett
7480378aed Update debian build rules 2025-01-04 14:37:13 -06:00
Jonathan Bennett
7c21d7761c Move the RFM9x to config.available (#5742) 2025-01-04 14:12:54 -06:00
Austin
2c654454cf meshtasticd debian source package (#5741) 2025-01-04 13:39:37 -06:00
Alex Markley
9afadde2f4 Add support for LS20031 GPS module. (#5718)
Hardware documentation referenced:
- https://cdn.sparkfun.com/datasheets/GPS/LS20030~3_datasheet_v1.3.pdf
- https://cdn-shop.adafruit.com/datasheets/PMTK%20command%20packet-Complete-C39-A01.pdf
2025-01-04 07:00:39 +08:00
isseysandei
66a961cb75 increased buffer size to 1024 (#5733) 2025-01-03 11:35:34 -06:00
Tom Fifield
e1aaafb77a Cherrypick "add more locking for shared SPI devices (#5595) " (#5728)
* add more locking for shared SPI devices (#5595)

* add more locking for shared SPI devices
* call initSPI before the lock is used
* remove old one
* don't double lock
* Add missing unlock
* More missing unlocks
* Add locks to SafeFile, remove from `readcb`, introduce some LockGuards
* fix lock in setupSDCard()
* pull radiolib trunk with SPI-CS fixes
* change ContentHandler to Constructor type locks, where applicable

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: GUVWAF <thijs@havinga.eu>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>

* mesh-tab: lower I2C touch frequency

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: GUVWAF <thijs@havinga.eu>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
2025-01-03 10:05:26 +08:00
Tom Fifield
9d710041c4 Add MESHTASTIC_EXCLUDE_SOCKETAPI (#5729)
MESHTASTIC_EXCLUDE_SOCKETAPI disables the API Server when set.

Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: GUVWAF <thijs@havinga.eu>
2025-01-03 09:01:10 +08:00
Eric Severance
b41efc17ba Disable BUILD_EPOCH for unit tests (#5723) 2025-01-02 10:32:38 -06:00
Thomas Göttgens
9bda080e3d evaluate GPS_THREAD_INTERVAL after variant file (#5722) 2025-01-02 16:05:12 +01:00
Eric Severance
9f7cbf1b4f MQTT unit test can inject WiFiClient (#5716) 2025-01-02 19:32:39 +08:00
Eric Severance
93e2bc7058 Use relative paths in coverage info files (#5721) 2025-01-02 14:53:07 +08:00
Eric Severance
7a1c32b89a test_native.yaml checks out code for the PR. (#5720) 2025-01-02 12:41:13 +08:00
Eric Severance
88d8ab53c8 Disable coverage generation (#5719)
* Disable coverage generation

* Comment a bit more of the report generation
2025-01-02 11:37:11 +08:00
Eric Severance
183f68ba00 Run tests as part of the main CI (#5712)
* Create an shared action to install native dependecies

* Create a workflow for running native tests

* Artifact names contain version

* Add test-native to main_matrix.yml

* No permission are required for test_native.yml

* Add permissions for dorny/test-reporter

* No permissions when running tests

* s/Generate Reports/Generate Test Reports/
2025-01-01 19:26:12 -06:00
Eric Severance
9f32995d7f Implement MeshModule destructor (#5714) 2025-01-01 19:25:01 -06:00
Eric Severance
c2c06ed0ad Move DecodedServiceEnvelope into its own file (#5715) 2025-01-02 08:40:14 +08:00
Jonathan Bennett
9abd07bb05 Set ch341 MAD Address via sprintf formatting (#5713) 2025-01-01 09:06:38 +11:00
Tom Fifield
fdcc0e12aa Minor TFT branch synch (#5706) 2024-12-31 10:15:01 -06:00
Thomas Göttgens
8b34c4ff05 fix misc cppcheck things and compile time warnings (#5710) 2024-12-31 15:58:59 +01:00
Bernd Giesecke
9af8c58c40 Add Ethernet RAK13800 support to RAK11310 (#5707) 2024-12-31 13:36:49 +01:00
Jonathan Bennett
58ebd5bcdb Actually use the MAC address from a ch341 (#5704)
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-12-31 17:46:03 +11:00
Tom Fifield
d1e5be515a cherry-pick: disable BT when TFT in use (#5705)
* disable BT when TFT in use

* add comment BT disable

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-30 20:00:37 -06:00
Tom Fifield
f9e71c3fb9 Remove an \n (#5703) 2024-12-30 19:01:21 -06:00
Tom Fifield
bfcfca2e46 add spi_host + missing rotation (#5691)
Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-30 18:18:29 -06:00
Thomas Göttgens
a2a6b236b7 support indicator sensors through Rp2040 serial (#5696)
* support indicator sensors through Rp2040 serial

* disable excessive debug printing
2024-12-30 21:28:31 +01:00
Tom Fifield
3c7053c66a reference seeed indicator fix commit arduino-esp32 (#5692)
Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-29 15:23:46 +11:00
Tom Fifield
e45c0e4d40 Minor cppcheck fixes (#5689)
* In graphics/Screen.cpp, a copy/paste error to do with hearts
* In mesh/http/ContentHandler.cpp, an unused variable
* in mqtt/MQTT.cpp, remove unneded logic " '!A || (A && B)' is equivalent to '!A || B'"
2024-12-28 18:56:05 -06:00
Jonathan Bennett
57a9a5ca21 Another Valgrind fix (#5690) 2024-12-28 18:48:54 -06:00
github-actions[bot]
6749367a73 [create-pull-request] automated change (#5686)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-28 18:23:56 -06:00
Jonathan Bennett
a8e2446f00 Initialize array to 0s (#5688) 2024-12-29 11:05:25 +11:00
Tom Fifield
89ebafc8b8 Minor TFT branch cherry-picks (#5682)
* update indicator board

* Fixed the issue that indicator device uploads via rp2040 serial port in some cases.

* esp debug logs

* USB mode=1 messed up the debug log

* dummy for config transfer (#5154)

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: virgil <virgil.wang.cj@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-12-28 08:32:24 -06:00
Tom Fifield
43d6b31603 TFT branch grab-bag (#5683)
Selection of minor edits from the TFT branch that are too
challenging to cherry-pick cleanly, including:
* introducing the HAS_TFT flag
* fixing pins in unphone
* Adding pinterdevice to portduino settings
2024-12-28 08:31:54 -06:00
Ben Meadors
31a5b9c122 Cleanup and exclude external sensor macro to make T1000-E binaries much smaller 2024-12-28 08:30:53 -06:00
Tom Fifield
ad726ad684 More meshtab cherry-pick (#5681)
* board definition for mesh-tab (not yet used)

* use board definition for mesh-tab

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-28 08:29:58 -06:00
Erayd
b2808063d0 Add new ROUTER_LATE role (#5528)
Will always rebroadcast packets, but will do so after all other modes.
Intended for router nodes that are there to provide additional coverage
in areas not already covered by other routers, or to bridge around
problematic terrain, but should not be given priority over other routers
in order to avoid unnecessaraily consuming hops.

By default, this role will rebroadcast during the normal client window.
However, if another node is overheard rebroadcasting the packet, then it
will be moved to a second window *after* the normal client one, with the
same timing behaviour.
2024-12-28 09:52:18 +11:00
Ben Meadors
2b33be2fea Exclude health telemetry by macro (#5679) 2024-12-28 08:49:24 +11:00
Mictronics
5133117936 Fix issue #5665. (#5678)
* Fix issue #5665.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-12-27 16:12:26 +01:00
aussieklutz
e5accf4e1d Enable the autoconf settings for MPR121 based keyboards, to make it more flexible for varying implementations. (#5680)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-27 07:16:08 -06:00
Tom Fifield
26a4d6c87a Cherry-pick: Mesh-tab (#5674)
* mesh-tab targets

* update meshtab voltage divider

* fix DIO1 wakeup

* update mesh-tab tft configs

* update mesh-tab ini

* rotation fix; added ST7789 3.2" display

* mesh-tab touch updates

* mesh-tab: enable alert message menu

* mesh-tab rotation upside-down

* use MESH_TAB hardware model definition

* use board definition for mesh-tab

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-27 05:13:45 -06:00
Tom Fifield
ae93f3fa3f TFT branch - minor cherry picks (#5676)
* fix missing include

* fix request, add handled

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-27 05:12:33 -06:00
Tom Fifield
ed39d14c85 Remove remaining \n from log lines. (#5675) 2024-12-27 18:01:02 +11:00
Jonathan Bennett
8f8e304216 Add packet length to printPacket() (#5672) 2024-12-26 18:58:26 -06:00
Tom Fifield
cd198fcf3f cherry-pick: device-ui persistency (#5570)
* device-ui persistency

* review update

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-26 17:46:21 -06:00
Tavis
b1d25ac7b7 fix for nrf52 lfs assert boot loop (#5670)
* fix for nrf52 lfs assert boot loop

* guard format in ifdef FSCom block

* add ifndef portduino for format call
2024-12-27 10:08:31 +11:00
Austin
b12ac6d564 meshtasticd-docker: Alpine container (#5659) 2024-12-26 13:00:50 -06:00
Austin
33d2f78d21 meshtasticd-docker: simplify, add USB compose (#5662) 2024-12-26 12:59:26 -06:00
GUVWAF
b12aa3f360 Unset received SNR/RSSI values upon receiving packet via MQTT (#5668) 2024-12-26 20:49:06 +11:00
Vít Holásek
d87b7e49e4 Add czech oled localization (#5661)
* Added support for Czech and Slovak glyphs localization

* Remove accidental commit

* Fix typo

* Fixed formatting
2024-12-26 20:08:23 +11:00
Eric Severance
cc357df489 Include log messages in unit tests (#5666)
* Include log messages in unit tests

* Provide an initial time value

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-26 13:42:15 +11:00
Eric Severance
1281da627e Generate a coverage report for End to end tests (#5667)
* Generate coverage report after running tests

* Wait for integration program to stop/start
2024-12-25 19:47:03 -06:00
github-actions[bot]
835344074c [create-pull-request] automated change (#5660)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-25 19:31:46 -06:00
Jonathan Bennett
13960874ae Bump libch341 userspace to dev branch 2024-12-25 16:47:00 -06:00
Eric Severance
a7d9e8107a More accurately determine if MQTT uses the default server (#5663)
* More accurately determine if MQTT uses the default server

* Channels::anyMqttEnabled() uses same logic

* Remove previous static bool
2024-12-25 08:33:53 -06:00
Eric Severance
fbdd6e7223 Synchronize test workflow packages with native (#5664) 2024-12-25 16:31:35 +11:00
github-actions[bot]
175ff218f1 [create-pull-request] automated change (#5658)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-24 05:54:20 -06:00
Thomas Göttgens
57af51cc18 fix typo in nugget radio def 2024-12-24 09:04:57 +01:00
Tom Fifield
b4b2fd6122 LIS3DH (WisMesh Pocket) - Honor Wake On Tap Or Motion (#5625)
As reported by @Mason10198, the WisMesh Pocket was always waking
on accelerometer motion.

This change gates the LIS3DH sensor's call to wakeScreen based on
config.display.wake_on_tap_or_motion .

fixes https://github.com/meshtastic/firmware/issues/5579
2024-12-24 10:47:27 +11:00
Eric Severance
143e1d1a0d Check if MQTT remote IP is private (#5647)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-23 09:48:07 -06:00
Jonathan Bennett
32719f69c9 Add NXP_SE050 detection (#5651)
* Add NXP_SE050 detection

* Put the flag in the right place

* Include libi2c0 dependency in .deb packages
2024-12-23 15:53:54 +11:00
Jonathan Bennett
6a2a4ffa2a Add libi2c-dev to native builds 2024-12-22 21:25:48 -06:00
nebman
80fc0f2bda Detect charging status by measuring current flow with configured INA battery sensor (#5271)
* INA219 charging detection

minimal implementation: if there is a configured INA219 sensor for battery monitoring we can take the current flow across the shunt resistor to know if we are charging the battery - negative milliamps indicate charging

* Update Power.cpp

added comments and 2 extra defines to disable and swap detection direction

* Update Power.cpp

fix disabled case

* move getCurrentMa() to new CurrentSensor class

* INA219 charging detection

minimal implementation: if there is a configured INA219 sensor for battery monitoring we can take the current flow across the shunt resistor to know if we are charging the battery - negative milliamps indicate charging

* Update Power.cpp

added comments and 2 extra defines to disable and swap detection direction

* Update Power.cpp

fix disabled case

* move getCurrentMa() to new CurrentSensor class

* add INA3221 charging detection

* RP2040: Update core; add mDNS support (#5355)

* Update arduino-pico core

* RP2040: Add mDNS support

* SimpleMDNS `begin` now returns a bool

* Add `-g` option to `debug_build_flags` to link files for gdb

* RAK11310 needs old platform as well

* Change defines to specific architecture

* Core version 4.2.1 is out

* Add sudo to apt-get commands for Raspbian Build (#5364)

Without sudo, inadequate permissions to runs the commands meant
the build was failing.

* Typo fix in build_raspbian.yml (#5365)

s/sudp/sudo :(:(:(

* Rework some things

* Trunk

* Separate littlefs bundle

* version tags

* Diag

* Add littlefswebui

* Bug fixed in ExternalNotificationModule (#5375)

While `nagging` setExternalState wasn't written to Buzzer & Vibra so output was never toggled.

Possible fix for #5348

* Cleanup static files from bad Web UI bundle on 2.5.13 release (#5376)

* Cleanup static files from bad Web UI bundle on 2.5.13 release

* Check existence first

* Esp32 is the only one we care about

* Move some actions to after `startTransmit()` (#5383)

To minimize the time between channel scan and actual transmit

* [create-pull-request] automated change (#5380)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Allows all 3 PKI keys to be added to userPrefs.h (#4969) and a tool. (#5368)

* more userPrefs.h

Added PKI Admin keys to userPrefs.h

* Update userPrefs.h

Allows all 3 PKI keys to be added to userPrefs.h (#4969)

* Update NodeDB.cpp

Trunk

* Update userPrefs.h

Changed wording

* Create base64_to_hex.py

A little tool for converting base64 PKI Keys to decoded byte that userPrefs.h can understand.

* more userPrefs.h

Added PKI Admin keys to userPrefs.h

* Update userPrefs.h

Allows all 3 PKI keys to be added to userPrefs.h (#4969)

* Update NodeDB.cpp

Trunk

* Update userPrefs.h

Changed wording

* Create base64_to_hex.py

A little tool for converting base64 PKI Keys to decoded byte that userPrefs.h can understand.

* [create-pull-request] automated change (#5388)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* add smiley emoji (#5391)

* add smiley emoji

* clang-formatted

* Anable trace route function on wismeshtap platform (#5389)

* fix 'symbal' typo (#5395)

* [create-pull-request] automated change (#5399)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* /api/v1/fromradio: add OPTIONS handler for CORS. (#5386)

This avoids hitting the 404 Not Found handler, which breaks connection
keep-alive, so this change fixes a big performance regression for Web Client in
Chrome: https://github.com/meshtastic/firmware/issues/5385

Tested on Heltec V3.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Make heart emoji usable (#5403)

* Create a specific hw_model for WisMesh Tap (#5400)

* Create a specific hw_model for WisMesh Tap

* Trunk

* HAS_ETHERNET

* Remove it altogether

* Don't need these either

* Fix RTC time injection and consolidate position logic (#5396)

* Fix RTC time injection and consolidate position logic

* Comment out unused var warning

* Backerds

* Update arduino-pico core to fix sporadic hangs (#5406)

* Update platform-raspberrypi also (#5407)

* Update arduino-pico core to fix sporadic hangs

* Update platform-raspberrypi also

* --web added to device-install(.sh/.bat) (#5405)

* Add --web

* Update device-install.bat

Forgot a "-" a few places.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* add GPS in indicator board (#5411)

* Fixed NMEA sentence issue in CalTopo as well as bug with no printing all of the nodes (#5412)

* --web littlefswebui-* typo fix (#5416)

* Add --web

* Update device-install.bat

Forgot a "-" a few places.

* Typo fix.

* Typo fix

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>

* Temporarily disable MDNS when MQTT is enabled (#5418)

Leads to a panic

* Check for OkToMqtt flag presence before uplinking to MQTT (#5413)

* Check for oktomqtt flag presence before uplinking to MQTT

* Move to mqtt->onSend

* Temetry can respond to want-response for LocalStats variant (#5414)

* Seems like the last DIY board that's not "extra" (#5420)

* Cherry pick tdeck fixes (#5422)

* Try-fix (workaround) T-Deck audio crash

* set T-Deck audio to unused 48 (mem mclk)

* swap mclk to gpio 21

* dreamcatcher: assign GPIO44 to audio mclk

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>

* add canned message and keyboard in indicator board (#5410)

* add canned message and keyboard in indicator board

* Added virtual keyboard macro and enabled for Indicator

* Cleanup macros by applying USE_VIRTUAL_KEYBOARD and DISPLAY_CLOCK_FRAME

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Update build-native.sh (#5415)

* Update build-native.sh

Device-install.sh and device-update.sh are not used on native platform, skip copying to release directory after build and copy native-install.sh and native-run.sh instead.

* Update build-native.sh

Skip native-run.sh copy

* Cleans up visibility in GPS.h (#5426)

Signed-off-by: Christopher Hoover <ch@murgatroid.com>

* Fix admin key loading from userPrefs.h (#5417)

* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

* Remove static declaration for admin keys from userPrefs.h. Load hard coded admin keys in case config file has empty slots.

* Removed newlines from log.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>

* try to detect dfrobot station to tell it apart from an ublox gps. (#5393)

* Remove BMA-423 and STK8X by default (#5429)

* Remove BMA-423 by default

* STK

* Wrong macro

* Helps if you include the file

* [create-pull-request] automated change (#5431)

Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>

* Support for the ClimateGuard RadSens Geiger-Muller tube (#5425)

* fixes https://github.com/meshtastic/firmware/issues/5434 (#5435)

* update libpax
* fix interval init

* Fix memory leaks by adding missing `free()` calls before early returns in `MQTT::onReceive` (#5439)

This fix addresses memory leaks in the `MQTT::onReceive` function by ensuring that dynamically allocated resources (`e.channel_id`, `e.gateway_id` and `e.packet`) are properly freed before each early return. Previously, these resources were only freed at the end of the function, leaving them unhandled in certain exit paths. Adding the missing `free()` calls prevents memory leaks and ensures proper resource cleanup in all scenarios.

* Removing 1.0 legacy boards from releases and completely removing Heltec wireless capsule from support (#5436)

Co-authored-by: Tom Fifield <tom@tomfifield.net>

* A second round of cleanup on GPS.h. (#5433)

* Move yet more stuff out of GPS.h and into file scope.

* Protect code macros from eating semicolons.

* Remove unused (and unimplemented) getDOPString.

* clang-format with project style file on affected files.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>

* enable MQTT with TLS on RPi picow (#5442)

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Don't powersave on Wifi (#5443)

* Don't go into light sleep with wifi enabled

* Move

* Trunk

* Revert "Seems like the last DIY board that's not "extra" (#5420)" (#5446)

This reverts commit e6fb6b115a.

* Actually gunzip all the files when building a .deb (#5449)

* [create-pull-request] automated change (#5457)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Cleanup i2c scan logs and macro to save some bytes and remain consistent (#5455)

* Cleanup i2c scan logs and macro to save some bytes and remain consistent

* Functions are better than macros

* Exclude i2c scan for STM32

* Useless log

* Clean up some inline functions (#5454)

* Use isWithinTimespanMs to avoid refererence to NodeDb instance inside of NodeDb (#5453)

* fix cors for meshtasticd to allow use of cross origin clients (#5463)

* Remove ATECC crypto chip placeholder code (#5461)

* GPS.h cleanups round 3. (#5447)

* GPS.h cleanups round 3.

No effective behavior change.

Protected members can be private so make it so.  (Supporting
subclasses needs a lot more work.)

Moves uBloxGnssModelInfo into file scope.

Moves uBloxProtocolVersion into uBloxGnssModelInfo.

Moves baud rate arrays into file scope.

Removes unused/ unimplemented powerStateToString.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>

* Trunk Format.

---------

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>

* Fix ukrainian fonts (#5468)

* FIX:  rollback to !4624

* UPDATE: new 16 and 24 UA Fonts and fixes

* fix: Solve the lightsleep crash problem via disable  lightsleep for indicator. (#5470)

* Trunk

* Warnings and log cleanup (#5472)

* Don't log if keyboard not found

* Signed comparison issue

* [create-pull-request] automated change (#5475)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Adds libusb dev package to Raspbian build steps (#5480)

* [create-pull-request] automated change (#5478)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Portduino fixes (#5479)

* Set config.yaml defaults even if General is missing

* Unsigned values should get %u in logging

* Update arduino-pico core and remove MDNS restriction (#5483)

* Update xiao_esp32 fully support L67K (#5488)

L67K module hardware changed

* Convert userprefs to a json file instead of header file which has to be included everywhere (#5471)

* WIP

* Got string quoting and macro expansion working

* Need the placeholder

* Cleanup

* Missed a user prefs reference

* Update jsonc

* SimRadio: clean-up and emulate collisions (#5487)

* Clean up SimRadio and don't let it use PKC

* Add collision emulation for SimRadio

* Add stats from SimRadio to LocalStats

* Make emulating collisions optional

* add nodeId to nodeinfo update log lines and removed redundant nodeinfo update log line (#5493)

* Refact the macro definition of GPS initialization of GPSDEFAULTD_NOT_PRESENT and added  seeeed Indicator to this sequence (#5494)

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Extend Length of Source and Destination Node IDs Logged (#5492)

* show 8 chars for logging source and destination ids

* extend legnth of source and destination nodes in log

* Added femtofox configs (#5477)

* added femtofox configs

* Rename bin/config.d/femtofox_Waveshare-SX126X-XXXM_AI-Thinker-RA-01SH.yaml to bin/config.d/femtofox/femtofox_Waveshare-SX126X-XXXM_AI-Thinker-RA-01SH.yaml

* moved femtofox configs to subdir

* [Add] LR1110, LR1120 and LR1121 to linux native Portduino (#5496)

* Update main.cpp

* Update PortduinoGlue.h

* Update PortduinoGlue.cpp

* Update PortduinoGlue.cpp

* Update PortduinoGlue.cpp

* Update main.cpp

* [create-pull-request] automated change (#5500)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Fix minor typos in package workflows (#5505)

* Don't use channel index for encrypted packet (#5509)

* Don't use channel index for encrypted packet

* Remove assert in `getKey`, set invalid key length
So encrypting will fail without reboot

* Reset channel to 0 when unable to encrypt
Such that the NAK doesn't use the failing channel hash

* Always Announce MDNS meshtastic service (#5503)

* refactor server api port into define

* always announce MDNS meshtastic service

* fix nodeDB erase loop when free mem returns invalid value (0, -1). (#5519)

Co-authored-by: mverch67 <manuel.verch@gmx.de>

* Add heltec capsule back

* Revert "Add heltec capsule back"

This reverts commit fc16d93421.

* Lets try this again minus device ui

* Add popular nrf52 pro micro to the builds (#5523)

* Add MACAddress to config.yaml (#5506)

* Add MACAddress to config.yaml

* Better error handling on native, including failing to launch with blank MAC Address and real hardware.

* Re-arrange Mac Address handling and add MACAddressSource

* Bump portduino to remove macaddr function there

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Configure Seeed Xiao S3 RX enable pin (#5517)

* Create OpenWRT_One_mikroBUS_sx1262.yaml (#5529)

* tlora_v2_1_16: Unset BUTTON_PIN and BUTTON_NEED_PULLUP (#5535)

Unset BUTTON_PIN and BUTTON_NEED_PULLUP as the board ships without a user button.

Devices and users expecting a button on GPIO12 have to set [GPIO for user button](https://meshtastic.org/docs/configuration/radio/device/#gpio-for-user-button) to 12 (or any GPIO pin the momentary switch was connected to) to restore functionality.

Signed-off-by: Andrew Yong <me@ndoo.sg>

* [create-pull-request] automated change (#5530)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Fix detection for some RadSens hardware versions (#5542)

Co-authored-by: Jake-B <jake-b@users.noreply.github.com>

* Initialize dmac array to nulls (#5538)

* Initialize dmac array to nulls

* Use std::cout for print before console is init.

* Update OpenWRT_One_mikroBUS_sx1262.yaml (#5544)

* Add portduino-buildroot variant (#5540)

* Add portduino-buildroot variant

* Update platform-native for platform-buildroot

* portduino-buildroot: Define c standard (#5547)

* Portduino: Move meshtasticd/web out of /usr/share/doc/ (#5548)

* Portduino: fix transitional symlinks (#5550)

* Windows Support - Trunk and Platformio (#5397) (#5518)

* Add support for GPG
* Add usb device support
* Add trunk.io to devcontainer
* Trunk things
* trunk fmt
* formatting
* fix trivy/DS002, checkov/CKV_DOCKER_3
* hide docker extension popup
* fix trivy/DS026, checkov/CKV_DOCKER_2

Co-authored-by: Kalle Lilja <15094562+ThatKalle@users.noreply.github.com>

* Synch minor changes from TFT branch (#5520)

* Synch minor changes from TFT branch

Includes:
* New nordicnrf52 minor version (10.5.0 --> 10.6.0)
* Optimisations for T_DECK
* preparation for MESH_TAB
* add ext notification module to portduino

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>

* DIO3_TCXO_VOLTAGE in config.yaml can now take an exact voltage (#5558)

* Support TLORA_V3.0 (#5563)

- Support TLORA_V3.0. Update of the legendary 2.1_1.6.1 with solar charger, TCXO and IPEX connector.
- 'extra' some short-lived EOL intermediate boards in that range. If possible use T3S3 instead of all of these!
- update trunk to latest version

* Create OpenWRT-One-mikroBUS-LR-IOT-CLICK.yaml (#5564)

* Portduino: fix setting hwId via argument (#5565)

* INA219 charging detection

minimal implementation: if there is a configured INA219 sensor for battery monitoring we can take the current flow across the shunt resistor to know if we are charging the battery - negative milliamps indicate charging

* Update Power.cpp

added comments and 2 extra defines to disable and swap detection direction

* Trunk Fixes

* Add INA226 support

---------

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
Signed-off-by: Andrew Yong <me@ndoo.sg>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
Co-authored-by: Michael Gjelsø <36234524+gjelsoe@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: jcyrio <50239349+jcyrio@users.noreply.github.com>
Co-authored-by: Daniel.Cao <144674500+DanielCao0@users.noreply.github.com>
Co-authored-by: Catalin Patulea <cronos586@gmail.com>
Co-authored-by: dylanli <dylan3000dylan@gmail.com>
Co-authored-by: mverch67 <manuel.verch@gmx.de>
Co-authored-by: madeofstown <33820964+madeofstown@users.noreply.github.com>
Co-authored-by: Christopher Hoover <ch@murgatroid.com>
Co-authored-by: Mictronics <github@mictronics.de>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
Co-authored-by: jake-b <1012393+jake-b@users.noreply.github.com>
Co-authored-by: César de Tassis Filho <CTassisF@users.noreply.github.com>
Co-authored-by: Tomas Dubec <tomas.dubec@gmail.com>
Co-authored-by: Liam Cottle <liam@liamcottle.com>
Co-authored-by: panaceya <panaceya@users.noreply.github.com>
Co-authored-by: virgil <virgil.wang.cj@gmail.com>
Co-authored-by: Robert <r@rbrt.io>
Co-authored-by: noon92 <40807970+noon92@users.noreply.github.com>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: broglep <20624281+broglep@users.noreply.github.com>
Co-authored-by: Matthias Granberry <matthias.granberry@gmail.com>
Co-authored-by: Andrew Yong <me@ndoo.sg>
Co-authored-by: Jake-B <jake-b@users.noreply.github.com>
Co-authored-by: Austin <vidplace7@gmail.com>
Co-authored-by: Kalle Lilja <15094562+ThatKalle@users.noreply.github.com>
2024-12-22 15:02:50 +11:00
noon92
fa1a1fd869 Update Femtofox configs (#5646)
* Delete bin/config.d/femtofox/femtofox_EByte-E22-900M30S_Ebyte-E22-900M22S.yaml

* Delete bin/config.d/femtofox/femtofox_EByte-E22-900MM22S.yaml

* Delete bin/config.d/femtofox/femtofox_Heltec-HT-RA62_Seeed-WIO-SX1262.yaml

* Delete bin/config.d/femtofox/femtofox_Waveshare-SX126X-XXXM_AI-Thinker-RA-01SH.yaml

* Add files via upload

* Update and rename bin/config.d/femtofox_SX1262_XTAL.yaml to bin/config.d/femtofox/femtofox_SX1262_XTAL.yaml

* Update and rename bin/config.d/femtofox_LR1121_TCXO.yaml to bin/config.d/femtofox/femtofox_LR1121_TCXO.yaml

* Update and rename bin/config.d/femtofox_SX1262_TCXO.yaml to bin/config.d/femtofox/femtofox_SX1262_TCXO.yaml
2024-12-22 10:04:18 +11:00
Eric Severance
2fd5a4848a Separate host:port before checking for private IP (x2) (#5643) 2024-12-21 14:07:20 -06:00
GUVWAF
f4cff33450 Portduino: specify C++ version and add link pthread (#5642) 2024-12-21 11:13:03 -06:00
Ben Meadors
1c8b165408 Add libusb to dockerfile for ch341 (#5641) 2024-12-21 11:03:17 -06:00
Thomas Göttgens
8e6ef4ea04 add nugget and nibble boards for 38c3 (#5609)
* add nugget and nibble boards for 38c3

* mark those boards extra for now
2024-12-21 14:57:01 +01:00
Ben Meadors
fb7866fca7 Revert "Check if MQTT remote IP is private (#5627)" (#5636)
This reverts commit 9a10907a2d.
2024-12-21 07:49:25 -06:00
Ben Meadors
d9b287880f Revert "Separate host/port before checking for private IP (#5630)" (#5635)
This reverts commit 398d29064e.
2024-12-21 07:48:47 -06:00
Ben Meadors
f39a9c5083 Clean up some straggler NRF52 json (#5628) 2024-12-21 14:42:54 +11:00
Eric Severance
398d29064e Separate host/port before checking for private IP (#5630) 2024-12-21 14:06:01 +11:00
Tom Fifield
df63423cdc Let RangeTest Module use Phone position if there's no GPS (#5623)
As reported by @Fastomat, if a user had enabled "Share Phone
Position" in the app, RangeTest did not use this position and
recorded a 0,0 lat/lon.

This change preferences GPS where avaialble, but otherwise
uses the position stored for the node in NodeDB.

fixes https://github.com/meshtastic/firmware/issues/5620
2024-12-20 19:26:23 -06:00
Eric Severance
9a10907a2d Check if MQTT remote IP is private (#5627) 2024-12-20 19:25:31 -06:00
Tom Fifield
5fed679d33 Add detection code for INA226 (#5605)
INA226 is a high accuracy current and voltage sensor.
2024-12-20 19:24:29 -06:00
Eric Severance
58d80b8557 Use IPAddress.fromString for parsing private IPs (#5621) 2024-12-21 11:21:27 +11:00
Jonathan Bennett
960626e498 Ch341 (#5474)
* Very hacky first attempt at usermod ech341

* Fixes and debug printfs

* Move to library version of libpinedio-usb

* Add spidev: ch341 option in meshtasticd config.yaml

* Only check settingsStrings on native

* Use new CH341 code

* Bump ch341 lib

* Cleanup USBHal

* Add ch341 config.d files

* Remove ch341quirk

* Bump to most recent spi-userspace driver

* Add handling for ch341 serial, pid, and vid

* Minor fixes from pio check

* Trunk

* Add include for musl compliance

* Point to upstream libch341
2024-12-20 17:34:02 -06:00
Eric Severance
658459aaf3 Use encoded ServiceEnvelope in mqttQueue (#5619) 2024-12-20 14:59:23 -06:00
Eric Severance
e1de439a7f Remove unnecessary memcpy for PKI crypto (#5608)
* Remove unnecessary memcpy for PKI crypto

* Update comment s/packet_id/id/

* Create a copy of bytes for each channel decrypt

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-12-19 19:14:27 -06:00
Ben Meadors
827553f4c7 Only execute on workflow_dispatch 2024-12-19 08:42:49 -06:00
Ben Meadors
445c641004 Version 2024-12-19 07:52:17 -06:00
Ben Meadors
7075a05bcd Fix docker secret permission 2024-12-19 06:27:19 -06:00
Lewis He
63091b7838 [T-Deck] Fixed the issue that some devices may experience low voltage reset due to excessive startup current (#5607)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-19 06:21:54 -06:00
Eric Severance
8c6eec52f2 Refactor MQTT::onReceive to reduce if/else nesting (#5592)
* Refactor MQTT::onReceive to reduce if/else nesting

* Fix missing #include <functional>

* const DecodedServiceEnvelope e

* Combine validDecode if statement.

* Only call pb_release when validDecode.

* s/ptr/channelName/

* Use reference type for deleter

* Use lambda instead of bind

* Document deleter

* Reorder 'if's to avoid object creation

* Remove unnecessary comment

* Remove 'else'; simpifies #5516

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-19 05:47:46 -06:00
Ben Meadors
68413486e3 Switch back docker/login-action 2024-12-18 07:15:48 -06:00
📡 WatskeBart 🤖
af79970ad7 Added product url (#5594) 2024-12-18 15:46:18 +11:00
Tom
4edeca5f84 Added support for the LR1121 radio to the NRF52 Pro-Micro (#5515)
* Added support for the LR1121 radio

Added support for the LR1121 radio, tested as functional with an E80-900M2213S from CDEbyte.

* Swap PNG for PDF

* remove PNG

* put TCXO voltage to 1.8, as in example file

It worked at 1.6v, but ¯\_(ツ)_/¯

* Hopefully this will appease Trunk

* Update rf switch pins and Schematic

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-17 10:25:37 -06:00
Ben Meadors
b0e3039732 Bump platform 2024-12-17 06:52:26 -06:00
github-actions[bot]
92511ab10b [create-pull-request] automated change (#5597)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-17 06:33:17 -06:00
Ben Meadors
b0a4087a0c Bump nano-pb 2024-12-17 06:12:23 -06:00
Ben Meadors
1b2fc00b99 Update main_matrix.yml 2024-12-17 05:45:31 -06:00
GUVWAF
69d01a8088 StoreForward: (tapback) reply support (#5585) 2024-12-15 13:11:13 -06:00
Ben Meadors
09c082fd00 Fix omission of AQ metrics (#5584) 2024-12-15 16:59:14 +01:00
Tom Fifield
020e9102a8 Define BUTTON_PIN as -1 for RP2040-lora (#5574)
The previous approach of undef'ing meant that it was impossible
for users to change the button pin in the apps.

Fixes https://github.com/meshtastic/firmware/issues/5566
2024-12-15 07:14:48 -06:00
Ben Meadors
2d45afafe5 Try docker authentication with command-line instead 2024-12-15 06:52:45 -06:00
Tom Fifield
56002155c6 Based default Node Names on NodeNum, rather than MAC address (#5576)
Presently we base the default long name (Meshtastic XXXX) and short
names (XXXX) on a node's MAC address. This works fine, unless you
have a node with no bluetooth, like Portduino.

Our logic for node numbers is also based on MAC address. However,
it has the added feature that it will create a random node number
if the Mac address is no good. The name is always "Meshtastic 0001".

This change switches node names (long and short) to instead rely
on the node number for defaults. For nodes with mac addresses,
there should be no user-visible change. For nodes without, they'll
now have a name other than "Meshtastic 0001".

Fixes https://github.com/meshtastic/firmware/issues/5370

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-15 06:23:27 -06:00
github-actions[bot]
547a57256d [create-pull-request] automated change (#5577)
Co-authored-by: fifieldt <1287116+fifieldt@users.noreply.github.com>
2024-12-15 05:23:15 -06:00
Ben Meadors
ea72abff22 Posthumous tronk 2024-12-14 20:21:19 -06:00
Aaron.Lee
4024bfdeeb Add screen detection function (#5533) 2024-12-14 20:20:29 -06:00
Austin
6d8be13266 Portduino-buildroot: Remove pkg-config optional libs (#5573) 2024-12-14 19:19:19 -06:00
André Perdigão Gonçalves
4a1239f811 Add new endpoint to retrieve node info (#5557) 2024-12-15 11:43:41 +11:00
GUVWAF
44cf6d388e Portduino: fix setting hwId via argument (#5565) 2024-12-14 11:55:32 +01:00
Mark Trevor Birss
c3f89a6db8 Create OpenWRT-One-mikroBUS-LR-IOT-CLICK.yaml (#5564) 2024-12-14 11:46:35 +01:00
Thomas Göttgens
332dbaf573 Support TLORA_V3.0 (#5563)
- Support TLORA_V3.0. Update of the legendary 2.1_1.6.1 with solar charger, TCXO and IPEX connector.
- 'extra' some short-lived EOL intermediate boards in that range. If possible use T3S3 instead of all of these!
- update trunk to latest version
2024-12-14 10:59:15 +01:00
Jonathan Bennett
92225eb6c3 DIO3_TCXO_VOLTAGE in config.yaml can now take an exact voltage (#5558) 2024-12-13 11:48:27 -06:00
Tom Fifield
03770b799f Synch minor changes from TFT branch (#5520)
* Synch minor changes from TFT branch

Includes:
* New nordicnrf52 minor version (10.5.0 --> 10.6.0)
* Optimisations for T_DECK
* preparation for MESH_TAB
* add ext notification module to portduino

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-12 17:42:41 +01:00
Tom Fifield
1790407078 Windows Support - Trunk and Platformio (#5397) (#5518)
* Add support for GPG
* Add usb device support
* Add trunk.io to devcontainer
* Trunk things
* trunk fmt
* formatting
* fix trivy/DS002, checkov/CKV_DOCKER_3
* hide docker extension popup
* fix trivy/DS026, checkov/CKV_DOCKER_2

Co-authored-by: Kalle Lilja <15094562+ThatKalle@users.noreply.github.com>
2024-12-12 16:58:19 +01:00
Austin
7dd3629501 Portduino: fix transitional symlinks (#5550) 2024-12-10 15:02:38 -06:00
Austin
cabeb40c30 Portduino: Move meshtasticd/web out of /usr/share/doc/ (#5548) 2024-12-11 06:58:16 +11:00
Austin
761a99d241 portduino-buildroot: Define c standard (#5547) 2024-12-10 18:09:54 +02:00
Austin
cf46e675ca Add portduino-buildroot variant (#5540)
* Add portduino-buildroot variant

* Update platform-native for platform-buildroot
2024-12-10 17:14:52 +02:00
Mark Trevor Birss
438f627e9b Update OpenWRT_One_mikroBUS_sx1262.yaml (#5544) 2024-12-10 09:46:50 +02:00
Jonathan Bennett
0e3dae4fec Initialize dmac array to nulls (#5538)
* Initialize dmac array to nulls

* Use std::cout for print before console is init.
2024-12-09 21:51:55 -06:00
jake-b
d0e3427ec7 Fix detection for some RadSens hardware versions (#5542)
Co-authored-by: Jake-B <jake-b@users.noreply.github.com>
2024-12-09 19:46:13 -06:00
github-actions[bot]
f3850ee73b [create-pull-request] automated change (#5530)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-09 06:50:30 -06:00
Andrew Yong
3ae85e2c82 tlora_v2_1_16: Unset BUTTON_PIN and BUTTON_NEED_PULLUP (#5535)
Unset BUTTON_PIN and BUTTON_NEED_PULLUP as the board ships without a user button.

Devices and users expecting a button on GPIO12 have to set [GPIO for user button](https://meshtastic.org/docs/configuration/radio/device/#gpio-for-user-button) to 12 (or any GPIO pin the momentary switch was connected to) to restore functionality.

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-12-09 05:38:51 -06:00
Mark Trevor Birss
f81d3b045d Create OpenWRT_One_mikroBUS_sx1262.yaml (#5529) 2024-12-08 12:06:45 +02:00
Matthias Granberry
59ed5c9049 Configure Seeed Xiao S3 RX enable pin (#5517) 2024-12-08 07:32:49 +11:00
Jonathan Bennett
4a34bf648f Add MACAddress to config.yaml (#5506)
* Add MACAddress to config.yaml

* Better error handling on native, including failing to launch with blank MAC Address and real hardware.

* Re-arrange Mac Address handling and add MACAddressSource

* Bump portduino to remove macaddr function there

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-07 10:29:49 -06:00
Ben Meadors
b99e57a6fa Add popular nrf52 pro micro to the builds (#5523) 2024-12-07 07:03:58 -06:00
Ben Meadors
46eab20a90 Lets try this again minus device ui 2024-12-07 05:30:59 -06:00
Ben Meadors
39b5fb041e Revert "Add heltec capsule back"
This reverts commit fc16d93421.
2024-12-07 05:29:13 -06:00
Ben Meadors
fc16d93421 Add heltec capsule back 2024-12-06 20:01:47 -06:00
Tom Fifield
bac9fec17f fix nodeDB erase loop when free mem returns invalid value (0, -1). (#5519)
Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-12-06 18:39:30 -06:00
broglep
de774188c9 Always Announce MDNS meshtastic service (#5503)
* refactor server api port into define

* always announce MDNS meshtastic service
2024-12-05 06:02:10 -06:00
GUVWAF
c3d60342f4 Don't use channel index for encrypted packet (#5509)
* Don't use channel index for encrypted packet

* Remove assert in `getKey`, set invalid key length
So encrypting will fail without reboot

* Reset channel to 0 when unable to encrypt
Such that the NAK doesn't use the failing channel hash
2024-12-05 10:00:19 +08:00
Jonathan Bennett
d3e3985e39 Fix minor typos in package workflows (#5505) 2024-12-04 12:15:17 -06:00
github-actions[bot]
8eca6a2df8 [create-pull-request] automated change (#5500)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-12-04 08:15:50 -06:00
Mark Trevor Birss
e4f53677fc [Add] LR1110, LR1120 and LR1121 to linux native Portduino (#5496)
* Update main.cpp

* Update PortduinoGlue.h

* Update PortduinoGlue.cpp

* Update PortduinoGlue.cpp

* Update PortduinoGlue.cpp

* Update main.cpp
2024-12-04 05:39:02 -06:00
noon92
10e10450cf Added femtofox configs (#5477)
* added femtofox configs

* Rename bin/config.d/femtofox_Waveshare-SX126X-XXXM_AI-Thinker-RA-01SH.yaml to bin/config.d/femtofox/femtofox_Waveshare-SX126X-XXXM_AI-Thinker-RA-01SH.yaml

* moved femtofox configs to subdir
2024-12-03 06:33:27 -06:00
Robert
f846503cbf Extend Length of Source and Destination Node IDs Logged (#5492)
* show 8 chars for logging source and destination ids

* extend legnth of source and destination nodes in log
2024-12-03 06:30:19 -06:00
dylanli
85b2bad275 Refact the macro definition of GPS initialization of GPSDEFAULTD_NOT_PRESENT and added seeeed Indicator to this sequence (#5494)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-12-03 06:29:33 -06:00
Robert
7ad137b56a add nodeId to nodeinfo update log lines and removed redundant nodeinfo update log line (#5493) 2024-12-03 06:28:46 -06:00
GUVWAF
57ea6a265e SimRadio: clean-up and emulate collisions (#5487)
* Clean up SimRadio and don't let it use PKC

* Add collision emulation for SimRadio

* Add stats from SimRadio to LocalStats

* Make emulating collisions optional
2024-12-03 06:21:24 -06:00
Ben Meadors
d00e0f6911 Convert userprefs to a json file instead of header file which has to be included everywhere (#5471)
* WIP

* Got string quoting and macro expansion working

* Need the placeholder

* Cleanup

* Missed a user prefs reference

* Update jsonc
2024-12-03 06:17:25 -06:00
dylanli
594af0cacd Update xiao_esp32 fully support L67K (#5488)
L67K module hardware changed
2024-12-02 10:59:34 +02:00
GUVWAF
9f4c8a2804 Update arduino-pico core and remove MDNS restriction (#5483) 2024-11-30 13:16:02 -06:00
Jonathan Bennett
43b8972171 Portduino fixes (#5479)
* Set config.yaml defaults even if General is missing

* Unsigned values should get %u in logging
2024-11-30 11:29:45 +08:00
github-actions[bot]
fe8e0713cc [create-pull-request] automated change (#5478)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-29 19:40:44 -06:00
Jonathan Bennett
ac6b6c8d83 Adds libusb dev package to Raspbian build steps (#5480) 2024-11-30 07:05:28 +08:00
github-actions[bot]
79da2365f0 [create-pull-request] automated change (#5475)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-29 08:03:46 -06:00
Ben Meadors
b5777beb7d Warnings and log cleanup (#5472)
* Don't log if keyboard not found

* Signed comparison issue
2024-11-28 11:20:06 -06:00
Ben Meadors
5ad30a55ea Trunk 2024-11-28 06:26:51 -06:00
virgil
060a3bde4d fix: Solve the lightsleep crash problem via disable lightsleep for indicator. (#5470) 2024-11-28 06:19:18 -06:00
panaceya
8df7a035e2 Fix ukrainian fonts (#5468)
* FIX:  rollback to !4624

* UPDATE: new 16 and 24 UA Fonts and fixes
2024-11-28 05:34:09 -06:00
Christopher Hoover
b00c05012d GPS.h cleanups round 3. (#5447)
* GPS.h cleanups round 3.

No effective behavior change.

Protected members can be private so make it so.  (Supporting
subclasses needs a lot more work.)

Moves uBloxGnssModelInfo into file scope.

Moves uBloxProtocolVersion into uBloxGnssModelInfo.

Moves baud rate arrays into file scope.

Removes unused/ unimplemented powerStateToString.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>

* Trunk Format.

---------

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-11-27 18:56:25 +08:00
Ben Meadors
0832388482 Remove ATECC crypto chip placeholder code (#5461) 2024-11-27 09:45:54 +01:00
Liam Cottle
601d912c6f fix cors for meshtasticd to allow use of cross origin clients (#5463) 2024-11-27 09:45:31 +01:00
Ben Meadors
502a83bb8a Use isWithinTimespanMs to avoid refererence to NodeDb instance inside of NodeDb (#5453) 2024-11-26 16:39:16 -06:00
Ben Meadors
474f9b5bfb Clean up some inline functions (#5454) 2024-11-26 14:00:10 -06:00
Ben Meadors
fe86c40145 Cleanup i2c scan logs and macro to save some bytes and remain consistent (#5455)
* Cleanup i2c scan logs and macro to save some bytes and remain consistent

* Functions are better than macros

* Exclude i2c scan for STM32

* Useless log
2024-11-26 13:59:50 -06:00
github-actions[bot]
09286a3beb [create-pull-request] automated change (#5457)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-26 08:32:02 -06:00
Jonathan Bennett
ae4f54224e Actually gunzip all the files when building a .deb (#5449) 2024-11-26 12:49:13 +08:00
Ben Meadors
d5af8f0a97 Revert "Seems like the last DIY board that's not "extra" (#5420)" (#5446)
This reverts commit e6fb6b115a.
2024-11-26 11:09:55 +08:00
Ben Meadors
58c957f2c7 Don't powersave on Wifi (#5443)
* Don't go into light sleep with wifi enabled

* Move

* Trunk
2024-11-25 06:53:05 -06:00
Tomas Dubec
7c2b6778cb enable MQTT with TLS on RPi picow (#5442)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-25 06:12:19 -06:00
Christopher Hoover
0048e3cdcb A second round of cleanup on GPS.h. (#5433)
* Move yet more stuff out of GPS.h and into file scope.

* Protect code macros from eating semicolons.

* Remove unused (and unimplemented) getDOPString.

* clang-format with project style file on affected files.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
2024-11-25 05:32:04 -06:00
Ben Meadors
6018c0a830 Removing 1.0 legacy boards from releases and completely removing Heltec wireless capsule from support (#5436)
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-11-25 05:14:48 -06:00
César de Tassis Filho
37da78919a Fix memory leaks by adding missing free() calls before early returns in MQTT::onReceive (#5439)
This fix addresses memory leaks in the `MQTT::onReceive` function by ensuring that dynamically allocated resources (`e.channel_id`, `e.gateway_id` and `e.packet`) are properly freed before each early return. Previously, these resources were only freed at the end of the function, leaving them unhandled in certain exit paths. Adding the missing `free()` calls prevents memory leaks and ensures proper resource cleanup in all scenarios.
2024-11-25 12:05:06 +08:00
Thomas Göttgens
ad9d7a4972 fixes https://github.com/meshtastic/firmware/issues/5434 (#5435)
* update libpax
* fix interval init
2024-11-24 14:28:36 +01:00
jake-b
932966b896 Support for the ClimateGuard RadSens Geiger-Muller tube (#5425) 2024-11-24 13:53:52 +01:00
github-actions[bot]
4d69159e75 [create-pull-request] automated change (#5431)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2024-11-24 12:29:17 +01:00
Ben Meadors
f2ee0df015 Remove BMA-423 and STK8X by default (#5429)
* Remove BMA-423 by default

* STK

* Wrong macro

* Helps if you include the file
2024-11-23 17:18:22 -06:00
Thomas Göttgens
fcfb197571 try to detect dfrobot station to tell it apart from an ublox gps. (#5393) 2024-11-23 16:56:40 +01:00
Mictronics
dd7140b7a1 Fix admin key loading from userPrefs.h (#5417)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

* Remove static declaration for admin keys from userPrefs.h. Load hard coded admin keys in case config file has empty slots.

* Removed newlines from log.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-11-23 09:08:18 -06:00
Christopher Hoover
fadcbd597f Cleans up visibility in GPS.h (#5426)
Signed-off-by: Christopher Hoover <ch@murgatroid.com>
2024-11-23 06:10:09 -06:00
madeofstown
14b9a1a929 Update build-native.sh (#5415)
* Update build-native.sh

Device-install.sh and device-update.sh are not used on native platform, skip copying to release directory after build and copy native-install.sh and native-run.sh instead.

* Update build-native.sh

Skip native-run.sh copy
2024-11-23 18:06:31 +08:00
dylanli
c51a7b98bd add canned message and keyboard in indicator board (#5410)
* add canned message and keyboard in indicator board

* Added virtual keyboard macro and enabled for Indicator

* Cleanup macros by applying USE_VIRTUAL_KEYBOARD and DISPLAY_CLOCK_FRAME

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-22 18:54:06 -06:00
Ben Meadors
fdec95f9c1 Cherry pick tdeck fixes (#5422)
* Try-fix (workaround) T-Deck audio crash

* set T-Deck audio to unused 48 (mem mclk)

* swap mclk to gpio 21

* dreamcatcher: assign GPIO44 to audio mclk

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-11-22 14:25:09 -06:00
Jonathan Bennett
e6fb6b115a Seems like the last DIY board that's not "extra" (#5420) 2024-11-22 05:32:35 -06:00
Ben Meadors
d5bb32ff93 Temetry can respond to want-response for LocalStats variant (#5414) 2024-11-21 15:11:19 -06:00
Ben Meadors
f5058a9cbb Check for OkToMqtt flag presence before uplinking to MQTT (#5413)
* Check for oktomqtt flag presence before uplinking to MQTT

* Move to mqtt->onSend
2024-11-21 14:52:54 -06:00
GUVWAF
dbc5ec27f7 Temporarily disable MDNS when MQTT is enabled (#5418)
Leads to a panic
2024-11-21 14:11:50 -06:00
Michael Gjelsø
1089469f82 --web littlefswebui-* typo fix (#5416)
* Add --web

* Update device-install.bat

Forgot a "-" a few places.

* Typo fix.

* Typo fix

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-11-21 13:27:26 -06:00
Ben Meadors
fd98e9f553 Fixed NMEA sentence issue in CalTopo as well as bug with no printing all of the nodes (#5412) 2024-11-21 20:13:30 +08:00
dylanli
ccfc9e5dd9 add GPS in indicator board (#5411) 2024-11-21 19:14:35 +08:00
Michael Gjelsø
1752caaf19 --web added to device-install(.sh/.bat) (#5405)
* Add --web

* Update device-install.bat

Forgot a "-" a few places.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-21 07:21:06 +08:00
GUVWAF
364dead3aa Update platform-raspberrypi also (#5407)
* Update arduino-pico core to fix sporadic hangs

* Update platform-raspberrypi also
2024-11-20 14:53:36 -06:00
GUVWAF
154864dfbf Update arduino-pico core to fix sporadic hangs (#5406) 2024-11-20 13:18:27 -06:00
Ben Meadors
2ca3cdf837 Fix RTC time injection and consolidate position logic (#5396)
* Fix RTC time injection and consolidate position logic

* Comment out unused var warning

* Backerds
2024-11-20 07:52:39 -06:00
Ben Meadors
485c371de4 Create a specific hw_model for WisMesh Tap (#5400)
* Create a specific hw_model for WisMesh Tap

* Trunk

* HAS_ETHERNET

* Remove it altogether

* Don't need these either
2024-11-20 12:57:46 +08:00
jcyrio
a255da3cf5 Make heart emoji usable (#5403) 2024-11-20 11:31:46 +08:00
Catalin Patulea
d65dc497f2 /api/v1/fromradio: add OPTIONS handler for CORS. (#5386)
This avoids hitting the 404 Not Found handler, which breaks connection
keep-alive, so this change fixes a big performance regression for Web Client in
Chrome: https://github.com/meshtastic/firmware/issues/5385

Tested on Heltec V3.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-19 14:33:44 -06:00
github-actions[bot]
c641bfd53c [create-pull-request] automated change (#5399)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-19 12:53:54 -06:00
jcyrio
b947b123fc fix 'symbal' typo (#5395) 2024-11-19 06:52:20 -06:00
Daniel.Cao
df1f66a6b9 Anable trace route function on wismeshtap platform (#5389) 2024-11-19 05:42:29 -06:00
jcyrio
70336f7f4f add smiley emoji (#5391)
* add smiley emoji

* clang-formatted
2024-11-19 13:25:11 +08:00
github-actions[bot]
de76caca32 [create-pull-request] automated change (#5388)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-17 19:29:43 -06:00
Michael Gjelsø
89469fcb88 Allows all 3 PKI keys to be added to userPrefs.h (#4969) and a tool. (#5368)
* more userPrefs.h

Added PKI Admin keys to userPrefs.h

* Update userPrefs.h

Allows all 3 PKI keys to be added to userPrefs.h (#4969)

* Update NodeDB.cpp

Trunk

* Update userPrefs.h

Changed wording

* Create base64_to_hex.py

A little tool for converting base64 PKI Keys to decoded byte that userPrefs.h can understand.

* more userPrefs.h

Added PKI Admin keys to userPrefs.h

* Update userPrefs.h

Allows all 3 PKI keys to be added to userPrefs.h (#4969)

* Update NodeDB.cpp

Trunk

* Update userPrefs.h

Changed wording

* Create base64_to_hex.py

A little tool for converting base64 PKI Keys to decoded byte that userPrefs.h can understand.
2024-11-17 12:36:41 -06:00
github-actions[bot]
a8357ebd52 [create-pull-request] automated change (#5380)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-17 10:51:11 -06:00
GUVWAF
0d1f9e915f Move some actions to after startTransmit() (#5383)
To minimize the time between channel scan and actual transmit
2024-11-17 10:51:01 -06:00
Ben Meadors
1a06f88dfb Cleanup static files from bad Web UI bundle on 2.5.13 release (#5376)
* Cleanup static files from bad Web UI bundle on 2.5.13 release

* Check existence first

* Esp32 is the only one we care about
2024-11-17 07:57:59 -06:00
Michael Gjelsø
a174ec7cf9 Bug fixed in ExternalNotificationModule (#5375)
While `nagging` setExternalState wasn't written to Buzzer & Vibra so output was never toggled.

Possible fix for #5348
2024-11-17 07:36:06 -06:00
Ben Meadors
37b29f6899 Add littlefswebui 2024-11-16 19:36:55 -06:00
Ben Meadors
74d0c58576 Diag 2024-11-16 06:24:10 -06:00
Ben Meadors
ca3d8da128 version tags 2024-11-16 06:22:08 -06:00
Ben Meadors
be6348388e Separate littlefs bundle 2024-11-16 06:12:45 -06:00
Ben Meadors
fdc473e5fa Trunk 2024-11-16 06:01:07 -06:00
Ben Meadors
add70b5229 Rework some things 2024-11-16 05:58:07 -06:00
Tom Fifield
1b99543a15 Typo fix in build_raspbian.yml (#5365)
s/sudp/sudo :(:(:(
2024-11-16 12:48:15 +08:00
Tom Fifield
90a3050c1f Add sudo to apt-get commands for Raspbian Build (#5364)
Without sudo, inadequate permissions to runs the commands meant
the build was failing.
2024-11-16 12:01:41 +08:00
GUVWAF
9545a10361 RP2040: Update core; add mDNS support (#5355)
* Update arduino-pico core

* RP2040: Add mDNS support

* SimpleMDNS `begin` now returns a bool

* Add `-g` option to `debug_build_flags` to link files for gdb

* RAK11310 needs old platform as well

* Change defines to specific architecture

* Core version 4.2.1 is out
2024-11-16 08:20:20 +08:00
Michael Gjelsø
d4d89447bd Adds fixed GPS, BUTTON_PIN and BLE code to userPrefs.h (#5341)
* userPrefs.h

Added FixedGPS
Added Fixed Bluetooth PIN

* Update NodeDB.cpp

Removed some un-used LOG_INFO

* Added BUTTON_PIN

* Trunk

* Variable re-naming.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-14 06:56:22 -06:00
github-actions[bot]
81172574a4 [create-pull-request] automated change (#5347)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-14 04:54:56 -06:00
Ben Meadors
295278bb12 Update version.properties 2024-11-13 18:47:46 -06:00
Ben Meadors
ec6949fdc0 Migrate NRF52 devices max nodes down to 80 for now to prevent brownouts (#5346) 2024-11-13 18:44:35 -06:00
github-actions[bot]
f4908fadd6 [create-pull-request] automated change (#5344)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-13 13:18:57 -06:00
Mictronics
528e177c62 Remove log spam when reading INA sensor. (#5345)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

* Remove log spam when reading INA voltage sensor.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-13 13:18:38 -06:00
Ben Meadors
73430cb582 Update version.properties (#5343) 2024-11-13 11:00:23 -06:00
Ben Meadors
3a66c738bd Revert "Decrease max nodes for NRF52 to 80 as workaround to prevent FS blowou…" (#5340)
This reverts commit ea150c32f3.
2024-11-13 10:21:55 -06:00
Ben Meadors
ea150c32f3 Decrease max nodes for NRF52 to 80 as workaround to prevent FS blowouts (#5338)
* Decrease max nodes for NRF52 to 80 as workaround to prevent FS blowouts

* Don't redefine

* Newline
2024-11-13 07:43:05 -06:00
Ben Meadors
ac804818de Only allow 30 seconds minimum for power.on_battery_shutdown_after_secs (#5337) 2024-11-13 05:39:15 -06:00
Blake-Latchford
8fcfe7f28b Read voltage during init fixes #5276 (#5332)
Power::readPowerStatus is called on startup,
but AnalogBatteryLevel::getBattVoltage
skips the read because 5 seconds have not
elapsed since last_read_time_ms, which
is initialized to zero.

`batMv=3100` is reported because
AnalogBatteryLevel::last_read_value is
initialized as:
```
float last_read_value = (OCV[NUM_OCV_POINTS - 1] * NUM_CELLS);
```
2024-11-13 04:13:55 -06:00
GUVWAF
e866734a25 Handle repeated packet after potentially canceling previous Tx (#5330)
* Revert "Fix sending duplicate packets to PhoneAPI/MQTT (#5315)"

This reverts commit 40bc04b521.

* Handle repeated packet after potentially canceling previous Tx
2024-11-12 15:23:32 -06:00
Matthijs De Smedt
2ec3958cd8 Add support for ignoring nodes with is_ignored field in NodeInfo (#5319)
* Add support for is_ignored bool in NodeInfo

* is_ignored is not a boring node either

* Clean out metrics and position

* Clear the key too

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-12 13:27:44 -06:00
GUVWAF
f4b0e19a65 Fix another heap leak (#5328) 2024-11-12 10:59:29 -06:00
Ben Meadors
a49f080bd2 Revert "Portduino packaging: Move meshtastic/web out of /usr/share/doc (#5323)" (#5325)
This reverts commit 762ccdc1b9.
2024-11-12 06:40:46 -06:00
Ben Meadors
e65a754430 Remove board level extra from wismesh tap 2024-11-12 06:20:42 -06:00
Ben Meadors
a84324c4fa Don't attempt to save NodeDB on low-batt shutdown to prevent FS corruption (#5312) 2024-11-12 06:17:26 -06:00
Daniel.Cao
ff33a27789 Reduce the flash usage of wismeshtap platform (#5322)
* Reduce the flash usage of wismeshtap platform

* fix STOREFORWARD twice

* Reduce the flash usage of wismeshtap platform

* fix STOREFORWARD twice

* add range test

* Update platformio.ini

remove
-DMESHTASTIC_EXCLUDE_PAXCOUNTER=1
-DMESHTASTIC_EXCLUDE_AUDIO=1

* Update platformio.ini

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-12 06:16:40 -06:00
Ben Meadors
51ea7ac627 Trunk toolchain versions 2024-11-12 06:12:09 -06:00
Ben Meadors
606c2e8eb0 Exclude paxcounter 2024-11-12 05:50:30 -06:00
Austin
762ccdc1b9 Portduino packaging: Move meshtastic/web out of /usr/share/doc (#5323)
* Portduino: Move meshtastic/web out of `doc`

* Remove /usr/share/doc/meshtasticd before linking
2024-11-12 16:14:12 +08:00
Michael Gjelsø
0acccdfe2d Don't send to public channel (#5310)
* Don't send to public channel

`p->to` wasn't set and had the same value as broadcast, it's now set to our own NodeNum.

* Trunk

* Update DetectionSensorModule.cpp

Take 3

* Revert NodeNum()
2024-11-11 19:11:54 -06:00
github-actions[bot]
0e4f7003c7 [create-pull-request] automated change (#5320)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-11 18:55:02 -06:00
GUVWAF
40bc04b521 Fix sending duplicate packets to PhoneAPI/MQTT (#5315)
* Fix potential duplicate packets to PhoneAPI/MQTT

* Fix include error for STM32

* Fix cppcheck error
2024-11-12 07:54:05 +08:00
Thomas Göttgens
eb8d38a7e9 radiolib update (#5246)
* update radiolib to 7.1.0
* stay at 7.0.2 for STM32, also remove unused board from ESP32 arch
---------
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-11 16:05:48 +01:00
Ben Meadors
3d5eb34c5c Add back some details to the PhoneAPI logs (#5313) 2024-11-11 07:01:29 -06:00
Ben Meadors
3a9a4bbb92 Coerce minimum neighborinfo interval on startup (#5314) 2024-11-11 07:00:56 -06:00
Daniel.Cao
6eba2789d0 rak10701 (rak wismeshtap) optimization (#5280)
* Improve the processing speed of virtual keyboards
* Remove the disable GPS feature, as it would interfere with the normal use of TFT
* Changed the default screen sleep time to 30s
* Rename platform rak10701 -> rak wismeshtap
* Fixed rak wismeshtap turned off gps caused the screen not to display
* Reduce the size of the flash, otherwise uf2 will not work

Co-authored-by: Daniel Cao <daniel.cao@rakwireless.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-11-11 13:37:43 +01:00
GUVWAF
9b4c260a92 Fix memory leak in MQTT (#5311) 2024-11-11 13:22:22 +01:00
Ben Meadors
667b4ef0f2 Exclude some niche modules by default and populate exclude_modules (#5300)
* Exclude some niche modules by default

* Start of intelligently excluding modules

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-11-10 13:36:49 -06:00
Tom Fifield
db76561930 Package file move - include dotfiles (#5303)
Adds shopt -s dotglob nullglob to ensure we get 'hidden' files in
our move command.
2024-11-10 20:56:44 +08:00
Tom Fifield
7bad070891 Fix syntax error with package builds (#5302)
test (]) and its parameters need a space between them.
2024-11-10 06:13:58 -06:00
Tom Fifield
6365fcfdc6 Update dependency versions (#5299)
Using platformio pkg outdated, discover that some versions are not
up-to-date. Update all apart from RadioLib (existing pull) and
SensorLib (doesn't compile).

Also, trunk formatted platformio.ini

Package                   Current    Wanted     Latest     Type     Environments
------------------------  ---------  ---------  ---------  -------  --------------------------
Adafruit BME280 Library   2.2.2      2.2.2      2.2.4      Library  tracker-t1000-e
Adafruit INA260 Library   1.5.0      1.5.0      1.5.2      Library  tracker-t1000-e
Adafruit LPS2X            2.0.4      2.0.4      2.0.6      Library  tracker-t1000-e
Adafruit LSM6DS           4.7.2      4.7.2      4.7.3      Library  tracker-t1000-e
Adafruit MCP9808 Library  2.0.0      2.0.0      2.0.2      Library  tracker-t1000-e
Adafruit MPU6050          2.2.4      2.2.4      2.2.6      Library  tracker-t1000-e
Adafruit SHT4x Library    1.0.4      1.0.4      1.0.5      Library  tracker-t1000-e
Adafruit Unified Sensor   1.1.11     1.1.11     1.1.14     Library  tracker-t1000-e
BME68x Sensor library     1.1.40407  1.1.40407  1.2.40408  Library  tracker-t1000-e
QMC5883LCompass           1.2.0      1.2.0      1.2.3      Library  tracker-t1000-e
RadioLib                  7.0.2      7.0.2      7.1.0      Library  wio-sdk-wm1110
SensorLib                 0.2.0      0.2.0      0.2.2      Library  tbeam
2024-11-10 06:13:31 -06:00
Tom Fifield
ab2cbada75 Web now(?) comes in a /build subdirector in the tar (#5301)
* Web now(?) comes in a /build subdirector in the tar

So let's move everything to where it's expected and cleanup before
trying to unzip.

* Add checks to avoid running unneeded commands

stops this failing in the event the build subdir goes away.
2024-11-10 19:58:06 +08:00
Jonathan Bennett
875b8641d3 Pin library versions in platform.io (#5293)
* Pin library versions in platform.io

This has been a constant source of headache. This moves to only updating libraries manually. Will eliminate the random build failures, and make rebuilding specific release versions possible.

* Bump ina219 to latest library version

* More lib version bumps
2024-11-09 16:06:17 -06:00
Jonathan Bennett
67c2c516a0 Use sudo for building armv7 2024-11-09 12:44:06 -06:00
Tom Fifield
623203ca3b Remove scary warning about full NodeDB (#5292)
NodeDB becoming full at 100 entries and cycling out old entries is normal behaviour. The user doesn't need to take any action and shouldn't be concerned when this happens.

Remove the warning from the screen and reduce loglevel to info.
2024-11-09 07:30:04 -06:00
github-actions[bot]
f28f0a9d90 [create-pull-request] automated change (#5290)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-09 05:31:09 -06:00
GUVWAF
893efe4f11 Always set the channel corresponding to a node (#5287) 2024-11-09 11:30:12 +08:00
GUVWAF
2c2213ef9b Add setting to transmit NeighborInfo over LoRa (#5286)
* Add setting to transmit NeighborInfo over LoRa
Only if not using the default channel

* Bump minimum broadcast interval for NeighborInfo to 4 hours
2024-11-09 09:38:48 +08:00
github-actions[bot]
439c1dec08 [create-pull-request] automated change (#5284)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-08 07:53:55 -06:00
Tavis
aa184e6d8b copy the has_relative_humidity value to telem packet from AHTX0 packet (#5277)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-08 07:59:36 +08:00
Marco Veneziano
2eea412f1c Fixed compile error when using GPS_DEBUG (#5275) 2024-11-07 16:19:31 -06:00
Thomas Göttgens
b0a5a26f58 fix wio-tracker-dev sensor scan (#5274) 2024-11-07 18:01:58 +01:00
Thomas Göttgens
a815a770b4 Sync up ESP32 build variants 2024-11-07 15:03:05 +01:00
Austin
286f3c6458 uClibc compatibility (#5270)
* uclibc compatibility

Adds compatibility with uclibc, the officially supported toolchain of the luckfox pico

* Explicitly link stdc++fs for std::filesystem

Bringing this over from buildroot-meshtastic
2024-11-07 14:23:08 +01:00
github-actions[bot]
b506f6dcb0 [create-pull-request] automated change (#5272)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-07 07:17:23 -06:00
Jeremiah K
bd3755bb33 Fix device flashing scripts so they work with esptool when it's installed via pipx (#5269)
* Try esptool.py in device flashing scripts for pipx compatibility

* esptool detection fixes in device flashing .bat's
2024-11-07 09:43:34 +08:00
Ben Meadors
73e2e25eb1 Smarter traffic scaling (#5264) 2024-11-06 15:00:53 -06:00
GUVWAF
3bd3911913 Only PKC encrypt when packet originates from us (#5267) 2024-11-06 22:00:26 +01:00
Ben Meadors
982190936d More log reductions. I'll probably stop now ;-) (#5263) 2024-11-06 21:03:25 +08:00
Ben Meadors
8498b175e7 Add exception for RTC to not strip time from position (#5262)
* Add exception for RTC to not strip time from position

* t
2024-11-06 10:06:43 +08:00
github-actions[bot]
255713d23d [create-pull-request] automated change (#5258)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-05 19:33:20 -06:00
Timo
8e2a3e5728 fix display of umlauts (UTF-8 left byte C3) (#5252) 2024-11-05 04:36:37 -06:00
Ben Meadors
f769c50fa5 More reduction (#5256)
* Now with even fewer ings

* Ye

* Mo

* QMA6100PSensor
2024-11-04 19:15:59 -06:00
GUVWAF
7ba6d97e99 Release no-LoRa packet after sending to phone (#5254) 2024-11-04 14:13:54 -06:00
GUVWAF
f3b698905d Disable automatic NodeInfo request when NodeDB is full (#5255) 2024-11-04 14:06:12 -06:00
Ben Meadors
50dac38a1b Pass#2: Lots more savings in logs and string reduction surgery (#5251)
* Pass#2: Lots more savings in logs and string reduction surgery

* Don't need Thread suffix either

* Warn
2024-11-04 12:16:25 -06:00
Jonathan Bennett
bf944e78d8 More configs (#5253)
* Add config.available for the MeshAdv 900M30S

* Move configs out of config.yaml
2024-11-04 11:17:32 -06:00
Tom Fifield
e71be778dd Fix cppcheck HIGH error (#5250)
https://github.com/meshtastic/firmware/pull/5247 introduced new
protobufs, particularly the excluded_modules feature.

Immediately afterward, cppcheck started sounding klaxons about
an unitialized variable. This patch simply sets excluded_modules
to none as a temporary measure while the feature from protobuf
is integrated into code.
2024-11-04 07:03:50 -06:00
Tom Fifield
276067065e Log cleanups (#5135)
* Log cleanups

change log levels, shorten log messages, delete commented out logs

* Address comments from review

* Remove full stops

* EDEBUG --> DEBUG
2024-11-04 06:09:23 -06:00
github-actions[bot]
a628c93125 [create-pull-request] automated change (#5247)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-04 05:40:55 -06:00
Ben Meadors
03aaaafa13 Exclude preferred routing roles from nodeinfo interrogation behavior (#5242)
* Exclude prefered routing roles from nodeinfo interrogation behavior

* Exclude prefered routing roles from nodeinfo interrogation behavior

* Update MeshService.cpp

* Rework logic to prevent spammy router logs
2024-11-04 19:05:03 +08:00
Thomas Göttgens
0a82fd28b3 PIO_ENV (#5239)
* add hw_env to packet

needs https://github.com/meshtastic/protobufs/pull/616

* rename to pio_env

* Move to mynodeinfo

* Includy doody

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-03 20:02:13 -06:00
github-actions[bot]
89c186e662 [create-pull-request] automated change (#5243)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-03 19:48:50 -06:00
github-actions[bot]
8c99f913c1 [create-pull-request] automated change (#5241)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-03 16:18:38 -06:00
Thomas Göttgens
d00acc5d7b Update stale_bot.yml 2024-11-03 20:10:17 +01:00
Austin
9415254dda musl compatibility (#5219)
* musl compat

* trunk fmt

* Update platform-native, including musl fix

https://github.com/meshtastic/platform-native/pull/5

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-03 14:24:04 +01:00
Tom Fifield
448c754882 LR1110 - remove old comment referring to non-existent function. (#5233)
It seems like there was no setrxgain function in RadioLib. Since
we're unlikely to uncomment and enable this non-existent feature,
remove this code.
2024-11-03 14:14:06 +01:00
GUVWAF
da7424a604 Improve ACK logic for responses and repeated packets (#5232)
* Don't send ACKs to responses over multiple hops

* Move repeated sending logic to `wasSeenRecently()`

* Add exception for simulator for duplicate packets from PhoneAPI

* Add short debug message
2024-11-03 06:21:45 -06:00
Tom Fifield
1bec23b6bb Fix displays showing "GPS Not Present" until first lock (#5229)
https://github.com/meshtastic/firmware/pull/5160 introduced a change
which made first publication of GPS information take up to 15mins.
For that initial period, displays would show "No GPS Present", even
if one was detected.

This change fixes that bug, triggering publication immediately after
a GPS module is detected.
2024-11-03 06:19:15 -06:00
Technologyman00
bee474ee54 Spell check all Code (#5228)
* Spelling Fixes

* More Spelling Errors

* More Spelling Checks

* fixed wording

* Undo mesh\generated changes

* Missed one file on readd

* missed second file
2024-11-03 09:25:05 +08:00
github-actions[bot]
93bc61c855 [create-pull-request] automated change (#5227)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-02 16:30:43 +01:00
Ben Meadors
0fc5c9b0d7 Create CODE_OF_CONDUCT.md (#5225) 2024-11-02 07:57:33 -05:00
Tom Fifield
b0c924f185 Optimise GPS Baud Rate cycle (#5102)
* Optimise GPS Baud Rate cycle

Previously, our baud rate cycled through one list twice.

There were some rarer baudrates in there, so this code
separates out those into a dedicated list that is only
run through if detection fails for common bauds. We also
only run through each baud rate once.

* Fix first time around bug

Would have always reset GPS baudrate every time.

* Add support for fixing GPS_BAUDRATE

If GPS_BAUDRATE is set in variant.h, the deployer knows something we
don't about the GPS. Used especially when the GPS is soldered to a board
in a commercial product :) If we see that, we don't try other baud rates
at all.

* Don't print blank lines in GPS_DEBUG.

* Try GPS_BAUDRATE first, not only.

* Fix spelling mistakes in comments

* Only use GPS_BAUDRATE if specified in variant.h

* Modify RareSerial Speeds based on FIXED or not.
2024-11-02 07:51:12 -05:00
github-actions[bot]
8801bc5ce9 [create-pull-request] automated change (#5223)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-11-02 05:58:06 -05:00
Jonathan Bennett
cf476eb87c Remove assert in mesh-pb-constants.cpp (#5207)
* Remove assert in mesh-pb-constants.cpp

* Add raw packet output to portduino trace logging.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-02 05:38:44 -05:00
todd-herbert
ba2f25293b Fix flipped logic after move to Throttle::isWithinTimespanMs (#5221) 2024-11-02 05:36:40 -05:00
GUVWAF
2d4d36c605 Drop oldest packet from radio when queue is full (#5212)
And still notify Router

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-11-01 15:48:55 -05:00
Ben Meadors
cbe74009a9 Comment out unused var to get rid of warning 2024-11-01 15:46:11 -05:00
Ben Meadors
701421b50a Trunk fmt 2024-11-01 15:17:25 -05:00
Aaron.Lee
336cdc0efe Add Heltec V3 battery read pin detect function (#5196) 2024-11-01 15:12:41 -05:00
Ben Meadors
a1ac358b0a Don't try to count non-lora transmissions into airtime (or attempt to decode) (#5215)
* Don't try to count non-lora transmissions into airtime (or attempt to decode)

* Don't need to check utilization anymore
2024-11-01 13:20:11 -05:00
dependabot[bot]
8462d65f76 Bump actions/github-script from 5 to 7 in /.github/workflows (#5214)
Bumps [actions/github-script](https://github.com/actions/github-script) from 5 to 7.
- [Release notes](https://github.com/actions/github-script/releases)
- [Commits](https://github.com/actions/github-script/compare/v5...v7)

---
updated-dependencies:
- dependency-name: actions/github-script
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-11-01 07:50:40 -05:00
Ben Meadors
10dd8af614 Eh? 2024-11-01 06:10:42 -05:00
Ben Meadors
9c06c492d9 Use one from the other PR 2024-11-01 06:04:14 -05:00
Ben Meadors
7e3c369e87 Trunk fmt on comment 2024-11-01 05:58:48 -05:00
Ben Meadors
732cf4832a Bump version since I killed the PR 2024-11-01 05:20:00 -05:00
Jonathan Bennett
545ebf9b17 Don't skip GPS serial speeds, and always land on GPS_BAUDRATE (#5195)
* Don't skip GPS serial speeds, and always land on GPS_BAUDRATE

* Update log message to match.

* print the value instead
2024-11-01 08:44:02 +08:00
Ben Meadors
7912c214c7 Increase NimBLE stack size (#5202) 2024-10-31 15:09:27 -05:00
Alexander Begoon
600208ab0b Refactor getMacAddr function to retrieve MAC address as MAC-48 for IEEE 802.15.4 compatibility (#5208) 2024-10-31 15:07:59 -05:00
GUVWAF
462a0718cf Fix SerialModule getting packet from ourselves (#5206) 2024-10-31 11:46:00 -05:00
Thomas Göttgens
aae346aef7 Update stale_bot.yml 2024-10-30 23:02:59 +01:00
Andre K
28b469dbf0 fix: don't broadcast public keys if the user is licensed (#5190)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-10-30 12:05:09 -05:00
Ben Meadors
5f6e19d971 As a Router 2024-10-30 06:02:59 -05:00
Thomas Göttgens
0726eaa678 Update stale_bot.yml 2024-10-30 10:43:08 +01:00
Thomas Göttgens
50fb575caa Update stale_bot.yml 2024-10-30 10:16:40 +01:00
Thomas Göttgens
cc59a50cba Test: mark issues as stale 2024-10-30 10:14:59 +01:00
Jonathan Bennett
b3ba23b4e8 Don't generate or populate PKC keys in licensed mode 2024-10-29 14:17:14 -05:00
Ben Meadors
936260fca3 Default rebroadcast mode for Router and Repeater to ignore problematic portnums (#5178)
* Default rebroadcast mode for Router and Repeater to ignore problematic portnums

* Verbiage

* IS_ONE_OF
2024-10-29 05:44:32 -05:00
Tom Fifield
2945b9cfbe De-duplicate Ambient LED management code (#5156)
We currently have 4 different places where we have the logic for
modifying LED state of the various types of Ambient LEDs,
ExternalNotificationModule::SetExternalOff
ExternalNotificationModule::SetExternalOn
AmbientLightingThread::setLighting
AmbientLightingThread::setLightingOff

This patch de-duplicates the methods in ExternalNotification to
a single method, using a boolean to toggle whether we're turning
things on or off.
2024-10-29 05:41:21 -05:00
Megaceryle-alcyon
ed03d28a83 Added PA1616S GPS module (#5157)
* Added GPS chip PA1616S

GPS chip PA1616S is used in some recent Adafruit GPS breakout boards.

* Update GPS.cpp

---------

Co-authored-by: picusviridis <mesh.culprit381@passmail.net>
2024-10-29 09:34:01 +01:00
Jonathan Bennett
850f61d2d0 Native config.d (#5165)
* Add support for loading yaml from a config directory

* Add waveshare hats to the new config.d approach

* Move to available.d for module inactive module configs
2024-10-28 21:48:10 -05:00
Ben Meadors
e12fd27b49 Trunkdor the burninator 2024-10-28 06:40:48 -05:00
Spiffysec
77dfc92f1e Update GPSUpdateScheduling.cpp (#5160)
* Update GPSUpdateScheduling.cpp

Default value is too short, resulting in unstable GPS locks on T1000-E (possibly others). Fix has been tested an confirmed working with no adverse effects, by multiple users. Also discussed at length on Discord

* Coerce minimum instead of hardcode

* config

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-28 06:18:03 -05:00
github-actions[bot]
c4eb9a6d7f [create-pull-request] automated change (#5176)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-28 06:16:06 -05:00
Tom Fifield
195f109ef7 Cherrry pick bin/config-dist.yml from TFT-GUI-Work (#5168)
* support SHCHV 3.5 RPi TFT+Touchscreen

* add TZT 2.0inch ST7789 config

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-10-28 09:31:21 +01:00
Tom Fifield
3c8ca39eff cherry-pick: fix nrf builds (#5172)
* fix nrf builds

* fix rp2040 + monteops build

* Bump lovyan version

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-10-28 09:30:39 +01:00
Tom Fifield
c071eed6a3 cherry-pick: unphone support (#5174)
* unphone part 1

* Unphone support

* update HWid unphone

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-10-28 09:25:25 +01:00
Tom Fifield
d14d42ba2c diy mesh-tab initial files (#5169)
Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-10-28 09:23:49 +01:00
Jonathan Bennett
82145e0661 Cherry picks (#5166)
* fix compiler error std::find()

* fix wifi/bt connection status

* try-fix crash

* added 1200baud reset

---------

Co-authored-by: mverch67 <manuel.verch@gmx.de>
2024-10-28 10:21:57 +10:00
Ben Meadors
1334d07c6a Trunk updates 2024-10-27 06:57:11 -05:00
Muhammad Shah
bf760a44ba Icarus - Fix platform dependency version and add selection button (#5161)
* Update variant.h

* Update platformio.ini
2024-10-27 05:51:51 -05:00
mverch67
94ff67e927 fix spiLock in RadioLibInterface 2024-10-27 10:55:23 +01:00
Muhammad Shah
e37369a25f Icarus - Custom PCB (#5155)
* added Icarus

* added Icarus

* Update platformio.ini

* Fixed I2C ports

* Update variant.h
2024-10-26 19:24:30 -05:00
mverch67
a8bd1ee0da stability: add SPI lock before saving via littleFS 2024-10-26 16:01:46 +02:00
github-actions[bot]
2568d4fcd8 [create-pull-request] automated change (#5153)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2024-10-26 15:51:28 +02:00
Thomas Göttgens
adf1bc4b0e fix tracker build (#5151)
fix tracker 1000 build
2024-10-26 14:40:10 +02:00
github-actions[bot]
ea63f035d1 [create-pull-request] automated change (#5137)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-26 12:07:07 +02:00
Tom Fifield
e394bc6f8f De-duplicate log-level determination (#5148)
RedirectablePrint had a method, getLogLevel, which did exactly
what code in SerialConsole did. Let's use that method rather than
duplicating the code.
2024-10-26 12:06:50 +02:00
Tom Fifield
a0e468b16e Remove unused AXP debug code (#5149)
This was shuffled around a couple years ago, but hasn't been used
since, and we had two copies in the code. Delete it.
2024-10-26 12:04:46 +02:00
Thomas Göttgens
93318b4f56 T1000-E Peripherals (#5141)
* T1000-E Peripherals
- enable intelligent charge controller signals
- enable Accelerometer
- enable internal I2C bus
- provide Power to Accelerometer

* POC Accelerometer Code (wakeScreen is moot for that device, just test if the driver works)
* fix building without the sensor
2024-10-26 12:03:28 +02:00
Mark Trevor Birss
0c0da3909f Update variant.h (#5140) 2024-10-25 08:07:01 +10:00
Manuel
701293c2d3 fix missing includes (#5138) 2024-10-24 21:58:24 +02:00
github-actions[bot]
6485f037ec [create-pull-request] automated change (#5133)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-23 21:21:49 -05:00
Ben Meadors
ca5f71f774 Add device unique id (#5092)
* Add device unique id

* Trunk

* WIP

* Esp32 implementation

* Trunk

* Check for ESP_EFUSE_OPTIONAL_UNIQUE_ID

* Comment print

* Trunk
2024-10-23 21:18:37 -05:00
panaceya
57667f1028 ADD: Configurable UPLINK_ENABLED and DOWNLINK_ENABLED in userPrefs.h (#5120) 2024-10-23 05:26:44 -05:00
Craig Bailey
3f1c86f953 Update meshtasticd.service (#5118)
Adding restart on service failure with 3 seconds between restart to stop fasst restart loops. Adding StartLimitBurst to limit it to 5 restarts in 200 seconds.
2024-10-22 16:22:10 -05:00
github-actions[bot]
4416ac57cf [create-pull-request] automated change (#5124)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-21 16:06:56 -05:00
Robert
a4705d2c19 add RFC 3927 IP address space to private IP checks (#5115)
Add the RFC 3927 IP address block (169.254.0.0/16), also referred to as IPIPA, to the private address checks for MQTT functionality.
2024-10-21 19:25:27 +11:00
aussieklutz
5ff8c904c8 MPR121 Touch IC Based Keypad Input Module (#5103)
Implements an input driver utilising the MPR121 Touch IC and is compatible with common MPR121 keypad PCB's.

- Implements a "candybar" phone style 12-key keypad
  - multiple taps to rotate through the character set
  - longpress for navigation keys
  - keymap to allow arbitrary routing of MPR121 pin to button configuration
  - extendable to other key functions
- Integrates with the existing kbI2cBase implementation
- Works with CannedMessageModule Freetext mode
- Can be used with common MPR121 boards, such as https://www.amazon.com/MPR121-Capacitive-Keyboard-Buttons-Sensitive/dp/B083R89CHB/ref=sr_1_6
- Of use for PCB based radios, where some form of low surface area low component freetext input is required, but also without consuming too many IO pins.
- Tested on a T3S3 connected to Wire1 (Second) interface.
  - Demonstration of functionality: https://youtu.be/UI6QP6nGvhY
2024-10-21 17:53:36 +11:00
GUVWAF
09c8642aa6 Fix rebroadcasting encrypted packets when KNOWN_ONLY or LOCAL_ONLY is used (#5109) 2024-10-20 17:04:45 -05:00
Thomas Göttgens
82bcd503a3 Merge pull request #5112 from meshtastic/preamble-length
Wide_Lora uses 12 symbols to be compatible with SX1280
2024-10-20 22:06:06 +02:00
Thomas Göttgens
18ca5b4449 Wide_Lora uses 12 symbols to be compatible with SX1280 2024-10-20 21:54:07 +02:00
Tom Fifield
2ba72c154a Fix GPS_DEBUG output (#5100)
After the recent change to move logging line breaks to a central
location, GPS_DEBUG is now emitting one character per line,
making the logs unusable.

Patch uses local strings and appends to collate and then print
in the right places.

Fixes https://github.com/meshtastic/firmware/issues/5099

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-20 04:46:25 -05:00
Ben Meadors
7e3931b05d Move 115200 baud GNSS probe earlier (#5101)
* Move 115200 baud GNSS probe earlier

* Even more optimized!
2024-10-19 20:05:52 -05:00
Ben Meadors
4575352d8c Initial NODENUM_BROADCAST_NO_LORA implementation with NeighborInfo module (#5087)
* Initial NODENUM_BROADCAST_NO_LORA implementation with NeighborInfo module

* isBroadcast

* Trunkt
2024-10-19 12:48:00 -05:00
Thomas Göttgens
b1b6bce6b7 Merge pull request #5095 from meshtastic/revert-5036-caveman99-patch-1
Revert "Permanently engage !CTRL"
2024-10-19 19:06:33 +02:00
Thomas Göttgens
304f26b909 Revert "Permanently engage !CTRL" 2024-10-19 19:01:58 +02:00
madeofstown
a27f9fcdbd Add -p flag (#5093)
Add the `-p` to the `mkdir` so it doesn't fail when the folder already exists

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-18 20:19:24 -05:00
Jonathan Bennett
dfeb33d46e Add DIO2_AS_RF_SWITCH to pinedio prefilled config. 2024-10-18 12:30:46 -05:00
github-actions[bot]
b8b6894d58 [create-pull-request] automated change (#5091)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-18 06:00:55 -05:00
Technologyman00
934be69663 Add buzzer feedback on GPS toggle (#5090)
Triple Press on buttons toggles GPS enable/disable.

This enhancement plays a triple-beep so that users of devices with buzzers can get audible feedback about whether they have turned the GPS off or on. This is especially valuable for screenless devices such as the T1000E where it may not be immediately obvious the GPS has been disabled.
2024-10-18 14:40:18 +11:00
Ben Meadors
ec9e562a77 Coerce minimum telemetry interval of 30 minutes on defaults and make new default interval one hour (#5086)
* Coerce minimum telemetry interval of 30 minutes on defaults and make new default interval one hour

* Smaller log messages
2024-10-17 13:33:52 -05:00
Johnathon Mohr
fbb6778415 Account for port specification with IP address for MQTT server. Some additional format validation. (#5084) 2024-10-17 05:05:35 -05:00
github-actions[bot]
2ea2b47690 [create-pull-request] automated change (#5085)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-16 19:51:11 -05:00
Ben Meadors
f77c87dca8 Extra extra 2024-10-16 09:18:44 -05:00
Ben Meadors
198b62f3fc I thought these were already board level extra 2024-10-16 07:34:24 -05:00
Johnathon Mohr
3e5f129fce Ensure the MQTT address is an IPv4 before determining it's private (#5081)
* Ensure the mqtt address is an IPv4 (or at least not a domain) before determining it's private.

* check address length
2024-10-16 05:19:00 -05:00
Johnathon Mohr
ad214ea42a Add MQTT exception for private IP address server (#5072)
Determines if the given IP address is a private address, i.e. not routable on the public internet.
These are the ranges: 127.0.0.1, 10.0.0.0-10.255.255.255, 172.16.0.0-172.31.255.255, 192.168.0.0-192.168.255.255.

If so, allow MQTT publication the same as existing localhost support.
2024-10-16 11:08:49 +11:00
Jeff Epler
25b557cf46 Fix incorrect va_start calls (#5076) 2024-10-15 17:15:10 -05:00
github-actions[bot]
7fd1c334d3 [create-pull-request] automated change (#5074)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-15 09:15:15 -05:00
Tavis
696bcc60af Ws85 updates : set want_ack, high_priority, add temperature. (#5052)
* ws85 updates

add temperature
add wantack
add high_priority

set lull to 0 if never set.

add the has_FIELD_NAME lines to ws85

* pbufs sync

* high insteaed of max reliability

* only set want_ack and high reliable if sensor_role set

* protobufs

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-10-15 05:09:18 -05:00
Andre K
af0db8a29f retain fixed_position during reset-nodedb (#5067) 2024-10-14 19:32:25 -05:00
Thomas Göttgens
ea20bb1836 Merge pull request #5061 from meshtastic/oem-proto
drop oem.proto support in favor of userprefs
2024-10-14 21:49:14 +02:00
Ben Meadors
420ab89f8d Merge branch 'master' into oem-proto 2024-10-14 14:10:31 -05:00
github-actions[bot]
1212969ff7 [create-pull-request] automated change (#5062)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-14 14:10:19 -05:00
Thomas Göttgens
e49e584ae1 drop oem.proto support in favor of userprefs 2024-10-14 19:39:07 +02:00
Tom
89c1e041e1 Add in RF95 support to Pro-micro DIY (#5055)
* Add in RF95 support

Added in lines to enable RF95 modules. Tested on SX1262 by NomDeTom/ @Nestpebble . Tested with RA02 by Ludovic / @lboue

* Trunk
2024-10-14 07:59:38 -05:00
github-actions[bot]
655e58f424 [create-pull-request] automated change (#5058)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-14 07:49:58 -05:00
Ludovic BOUÉ
0ec1684718 [Board]: Support for M5Stack CoreS3 (Part 1: radio) (#5049) 2024-10-14 19:13:22 +11:00
Thomas Göttgens
05e4a639a1 remove newline from logging statements. (#5022)
remove newline from logging statements in code. The LOG_* functions will now magically add it at the end.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-14 15:11:43 +11:00
Ben Meadors
fb9f361052 Implement rebroadcast mode NONE (#5040)
* Implement rebroadcast mode none

* Correct debug message
2024-10-12 06:17:44 -05:00
github-actions[bot]
37448205b5 [create-pull-request] automated change (#5041)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-12 06:16:53 -05:00
Thomas Göttgens
015f7335b0 enable native build stage 2024-10-12 10:34:22 +02:00
Thomas Göttgens
48d8b85a3b Merge pull request #5036 from meshtastic/caveman99-patch-1
Permanently engage !CTRL
2024-10-12 10:26:23 +02:00
mverch67
363fd8ab98 fix GPIO0 mode after I2S audio 2024-10-12 10:24:41 +02:00
Thomas Göttgens
323e7503ea trunk fmt 2024-10-12 07:09:21 +08:00
Thomas Göttgens
4e4431560e Permanently engage !CTRL
switching RXEN is not fast enough and not in sync with DIO2. This pin needs to be permanently encabled, like on RAK4631.
2024-10-12 07:09:21 +08:00
Jonathan Bennett
a8c216f4f8 Update main_matrix.yml -- re-enable x86_64 .deb builds 2024-10-11 16:41:41 -05:00
github-actions[bot]
9d0729c83f [create-pull-request] automated change (#5034)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-11 06:29:30 -05:00
Thomas Göttgens
3c89716074 Merge pull request #5033 from markbirss/master
Fix SH1107 - Set Geometry 128x128
2024-10-11 13:05:53 +02:00
Mark Trevor Birss
ec96256bcd Update main.cpp 2024-10-11 11:39:37 +02:00
Ben Meadors
1f2d972e18 Remove waypoint and text message frames on NodeDB reset as well (#5029) 2024-10-10 19:24:37 -05:00
github-actions[bot]
cc87002a8a [create-pull-request] automated change (#5028)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-10 18:31:20 -05:00
github-actions[bot]
8ab772221d [create-pull-request] automated change (#5027)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-10 18:29:29 -05:00
GUVWAF
d55c08d5cd Uplink DMs not to us if MQTT encryption enabled (#5025)
* Uplink DMs not to us if MQTT encryption enabled

* Only really need to try uplinking encrypted packet if MQTT encryption is enabled

* Add log about publishing nothing when packet is not decrypted and encryption_enabled is false

* Improve comment
2024-10-10 15:11:58 -05:00
Ben Meadors
e8f287a36f Fixes critical error rendering before screen thread is running (#5024)
* Fixes critical error rendering before screen thread is running

* Fix GPS thread crashing on probe code attempting to %s print an enum

* 10
2024-10-10 14:58:42 -05:00
Ben Meadors
b769799410 Update version.properties 2024-10-10 14:58:30 -05:00
Ben Meadors
f5f9fd54a1 Revert "[create-pull-request] automated change (#5019)" (#5026)
This reverts commit 3b21856a76.
2024-10-10 14:58:06 -05:00
Jonathan Bennett
f82585d9b0 Add localhost exception for dontMqttMeBro (#5023) 2024-10-10 14:06:47 -05:00
Tom Fifield
1b04d41b9a Fix U-Blox detection code. (#5014)
Recently there have been reports of intermittent difficulties
detecting U-Blox chips. This patch proposes a new approach that should
be more reliable.

Previously we were fighting with NMEA messages to try and send binary
commands. We unusually also tried changing the Baud rate of U-Blox
chips, something we don't do with any other GPS.

It turns out U-Blox has another method to disable NMEA
messages. PUBX,40 is a text-based command, supported on all the
U-Blox versions we care about that can set the rate of NMEA messages
to zero.

This is what we attempt to do with all other GPS and it works quite
well.

So this patch alters the probe code to:
1. Remove UBX binary code to stop NMEA messages
2. Remove code that tries to reset UBX chips to 9600 baud
3. Add UBX proprietary text commands messages to stop the NMEA flood
4. Improve log strings sent to the user.

Tested on Ublox 6, Ublox 9, and Ublox 10 on multiple devices.

Also tested on several devices with
non-Ublox GPS to ensure it does not interfere with their detection
(heltec-wireless-tracker, wio-tracker-wm11110)
2024-10-10 06:45:40 -05:00
github-actions[bot]
3b21856a76 [create-pull-request] automated change (#5019)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-10 06:45:22 -05:00
Thomas Göttgens
519ca9c0aa Merge pull request #5018 from fifieldt/UC6580-QZSS
Enable QZSS on UC6580
2024-10-10 12:19:04 +02:00
Thomas Göttgens
23a52ee625 Merge pull request #5016 from meshtastic/fifieldt-patch-1
Fix bug sending wrong sleep command to U-Blox chips
2024-10-10 12:18:27 +02:00
Jonathan Bennett
7ff4bafe22 Disentangle NodeDB from the CryptoEngine (#5013) 2024-10-10 18:14:11 +08:00
Tom Fifield
149620f071 Enable QZSS on UC6580
@allanmac noted we were not enabling QZSS on the UC6580.
QZSS is an augmentation service that runs on the same frequency
as GPS, so turning it on should not have any impact on usage other
than improving performance for users in the Asia Pacific.

Fixes https://github.com/meshtastic/firmware/issues/5009
2024-10-10 17:56:32 +08:00
todd-herbert
0cbade989e Check whether NimBLE is instantiated before using (#5015) 2024-10-10 17:37:25 +08:00
Tom Fifield
411834afba Fix bug sending wrong sleep command to U-Blox chips
The "U-Blox readable" patch introduced a bug where sleep commands for the 10 and other versions were reversed.
2024-10-10 17:19:52 +08:00
Thomas Göttgens
1096973828 Merge pull request #5011 from meshtastic/create-pull-request/patch
Bump version.properties
2024-10-10 10:13:48 +02:00
thebentern
dc9aa6aff7 [create-pull-request] automated change 2024-10-09 23:48:31 +00:00
Jonathan Bennett
ad8747d914 Possibly forward PKC DMs over MQTT (#5012) 2024-10-09 17:56:08 -05:00
GUVWAF
ddd4a45bc3 Ignore packets coming from the broadcast address (#4998) 2024-10-09 11:59:00 +08:00
Thomas Göttgens
4f8f96ab29 preliminary Othernet Dreamcatcher Support (#4933)
* preliminary Othernet Dreamcatcher 2206 Support
Need to adapt to 2301 final version

* second target for latest revision

* preliminary Othernet Dreamcatcher 2206 Support
Need to adapt to 2301 final version

* second target for latest revision

* preliminary Othernet Dreamcatcher 2206 Support
Need to adapt to 2301 final version

* second target for latest revision

* address comments

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-10-08 07:05:13 -05:00
Thomas Göttgens
ee5091fee5 Merge pull request #4661 from beegee-tokyo/master
Add RAK4631 Ethernet Gateway with working JSON output to MQTT
2024-10-08 13:26:31 +02:00
Ben Meadors
876993f095 No idea why trunk wants to disturb these PNGs but... 2024-10-08 05:34:41 -05:00
Ben Meadors
a05b009379 Posthumous tronkination 2024-10-08 05:33:38 -05:00
Thomas Göttgens
5db4918413 Merge branch 'master' into master 2024-10-08 12:33:34 +02:00
TheMalkavien
a0dd7b43d5 First version of a DeepSleep state for the RP2040 (#4976)
* Adding pico-extra utils

* RP2040 can now go to deepsleep

* First RP2040 DeepSleep code - TODO : do better and restore

* FIX RAK11310 compilation (revert SDK + missing defines)

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-08 05:24:37 -05:00
Thomas Göttgens
b1f045cab8 Merge branch 'master' into master 2024-10-08 12:17:13 +02:00
Ben Meadors
2e5399dbe4 De-conflict MLX90614_ADDR macro 2024-10-08 05:03:43 -05:00
Thomas Göttgens
d005b1e49c Merge branch 'beegee-tokyo-master' 2024-10-08 11:42:49 +02:00
Thomas Göttgens
9d9258a59b conflict resolution 2024-10-08 11:41:54 +02:00
jhps
37f294d0a6 In shutdown, on button press, wake back to application rather than into the loader. (#4997)
Suggested by lyusupov and implemented by todd-herbert.
https://github.com/meshtastic/firmware/issues/4651
2024-10-07 20:39:59 -05:00
Ben Meadors
411aedaf5d Add health telemetry module (#4927)
* Add stub health telemetry module

* Add detection for MAX30102 Health Sensor

It lives on I2C bus at 0x57, which conflicts with an existing
sensor. Add code to check the PARTID register for its response 0x15
per spec.

* Add detection for MLX90614

An IR Temperature sensor suitable for livestock monitoring.

* Add libraries for MLX90614 and MAX30102 sensors

* Fix Trunk

* Add support for MLX90614 IR Temperature Sensor

* Add support for MAX30102 (Temperature)

* Make it build - our first HealthTelemetry on the mesh.

If a MAX30102 is connected, its temperature will be sent to the
mesh as HealthTelemetry.

* Add spo2 and heart rate calculations to MAX30102

* Switch MLX90614 to Adafruit library

Sparkfun was having fun with SDA/SCL variables which we can avoid
by switching to this highly similar library.

* Enable HealthTelemetry if MLX90614 detected

* Change MLX90614 emissivity for human skin.

* Add health screen!

* Remove autogenerated file from branch

* Preparing for review

* Fix MeshService master sync from before.

* Prepare for review

* For the americans

* Fix native build

* Fix for devices with no screen

* Remove extra log causing issues

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-10-07 19:50:44 -05:00
HarukiToreda
1c54388bb8 Toggle Bluetooth with Fn+b shortcut (#4977)
* Toggle Blutooth with Fn+b shortcut

Problem:
As many are aware, ESP32 devices are known for their high power consumption. For instance, the Heltec ESP32 V3 draws around 110mA when powered on with the screen active and connected to a phone via Bluetooth. The Bluetooth radio alone is responsible for approximately 50mA of that consumption. For keyboard-based standalone devices, which rarely need Bluetooth other than for changing settings, users were forced to keep Bluetooth on regardless of necessity. There was no way to toggle Bluetooth on or off without physically connecting the device to a computer via serial or using the admin channel, which required another node for access.

Solution:
I implemented a new feature that allows users to turn off Bluetooth on keyboard devices by pressing Fn+b and turn it back on when needed. This enhancement significantly improves power efficiency for these devices.

Result:
With Bluetooth off, the device now consumes only 55mA. When combined with Power Save mode, the consumption can drop as low as 11mA, a substantial reduction from the previous 110mA. Users can still easily reconnect to a phone using the shortcut when necessary, offering greater flexibility and extended battery life.

* Remove 1 reboot at least.

I was able to prevent a reboot using the disableBluetooth(); command, current tested at 47-55mA, it doesn't require a reboot to turn off, but it does need reboot to turn back on.

* Update CannedMessageModule.cpp
2024-10-07 15:16:10 -05:00
Mictronics
94ecbad904 Fix storage of admin key when installing default config. (#4995)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

* Admin key count needs to be set otherwise the key will be zero loaded after reset.

* Don't reset the admin key size when loading defaults. Preserve an existing key in config if possible.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-07 12:44:21 -05:00
Ben Meadors
53f189fff4 Remove has_rx * on installDefaultDeviceState (#4982) 2024-10-07 19:43:55 +08:00
Jonathan Bennett
93d874b013 set tz config from string if unset (#4979) 2024-10-07 05:09:19 -05:00
Tom Fifield
234a56446b Add frequencies for Philippines (#4951)
There are three different frequencies available for Meshtastic
in the Philippines, each with pros and cons:
433 - 434.7 MHz <10 mW erp
868 - 869.4 MHz <25 mW erp
915 - 918 MHz <250 mW EIRP, no external antennna allowed

Philippines may also use LORA_24 unrestricted at up to 10mW, or up to
250mW if there is no external antennna.

Frequency rules in the Philippines are determined by aggregating the
information in laws, following the circulars referenced in the
[National Radio Frequency Allocation Table (NRFAT)](https://ntc.gov.ph/wp-content/uploads/2022/frequencyallocations/NRFAT_Rev_2020.pdf)
and then circulars that amend the circulars referenced in the NRFAT.
A full description of the regulatory basis can be found in the github issue:
https://github.com/meshtastic/firmware/issues/4948#issuecomment-2394926135

For 433MHz and 868MHz we refer to the Low Power Equipment rules for
"Non-specific Short Range Devices, Telemetry, Telecommand, Alarms,
Data In General and Other Similar Applications.".

For 915MHz and Wireless Data Network Services indoor device rules.

A device approved by the NTC is required for any use of Meshtastic
in the Philippines.

fixes https://github.com/meshtastic/firmware/issues/4948

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-06 09:31:13 -05:00
github-actions[bot]
830281803f [create-pull-request] automated change (#4974)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-06 08:14:03 -05:00
Tom Fifield
bb9f003c24 Switch EnvironmentTelemetry to use UnitConversions (#4972)
We already have a central class for unit conversions, switch
EnvironmentTelemetry to that in preparation for HealthTelemetry.
2024-10-06 07:55:21 -05:00
Ben Meadors
001a845ac3 Upgrade nanopb (#4973) 2024-10-06 07:55:02 -05:00
Tom Fifield
7febb41727 Trunk format Screen.cpp (#4970) 2024-10-06 07:37:20 -05:00
github-actions[bot]
ad031dd69f [create-pull-request] automated change (#4971)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-06 07:28:05 -05:00
Tom Fifield
ebc3a66d10 Which Module wants a UI Frame? (#4967)
Previously our debug message for screens blandly stated
"Module wants a UI Frame"

This patch replaces the word Module with the name of the Module
in need of a frame a frame, enhancing debugging ability.
2024-10-06 06:40:23 -05:00
Tom Fifield
553e572eb5 Coalesce duplicated method GetTimeSinceMeshPacket (#4968)
GetTimeSinceMeshPacket was duplicated in PowerTelemetry and
EnvironmentalTelemetry, albeit one had a cooler name than the other.

As we add HealthTelemetry, to avoid creating a third instance of
this method, let's move it somewhere that makese sense.

Adds a new method GetTimeSinceMeshPacket to MeshService and updates
EnvironmentTelemetry and PowerTelemetry to use it.
2024-10-06 06:40:06 -05:00
Ben Meadors
01df3ff477 Update generate-userprefs.yml 2024-10-06 05:26:04 -05:00
Ben Meadors
a3a97d3025 Start of generating json manifest of macros in userPrefs.h (#4946)
* Start of generating json manifest for userPrefs.h

* Just trunk this for now

* Add automatic generation of json manifest in GH action

* Trunk
2024-10-06 05:24:57 -05:00
medentem
0952d1b252 UserPrefs - Preconfigure up to 3 channels, GPS Mode (#4930)
* added up to 3 channels via userprefs

* added up to 3 channels via userprefs

* added up to 3 channels via userprefs

* trunk fmt

* Added USERPREFS for GPS MODE
2024-10-06 15:32:07 +08:00
Tom Fifield
8a370c5381 Revert "Revert "Remove unused Jlink monitoring files (#4953)" (#4959)" (#4966)
This reverts commit 783466f116.
2024-10-05 19:34:51 -05:00
Tom Fifield
a6f96cb9b4 Revert "Remove rak4631_epaper_onrxtx variant (#4958)" (#4963)
This reverts commit dac433ed2f.
2024-10-05 09:27:10 -05:00
github-actions[bot]
d650001caa [create-pull-request] automated change (#4960)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-05 08:05:44 -05:00
Tom Fifield
0c90a2274f Remove unused headers (#4954)
These files had existing since 2020 without being used/modified.
2024-10-05 05:39:13 -05:00
Tom Fifield
dac433ed2f Remove rak4631_epaper_onrxtx variant (#4958)
Appears to be a testing variant of rak4631_epaper. Due to little
information available, let's remove it for now.
2024-10-05 05:27:15 -05:00
Tom Fifield
8acc9ccf5f Remove support for pca10056-rc-clock (#4955)
In 2020, geeksville had a NRF52840-dk development board with a
busted oscilliator. Let's retire it from service :)

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-10-05 05:26:54 -05:00
Tom Fifield
243421b2a5 Retire lora-relay boards (#4957)
The lora-relay boards were important pathfinders for nrf52
support some years back. They are no longer commonly produced and
there are now many nrf52 options on the market. Retire these
boards and associated variant.
2024-10-05 05:25:28 -05:00
Tom Fifield
6d6ed55ed7 Retire PPR Boards (#4956)
The Othernet project appears to have failed. Retire these
boards/variants.
2024-10-05 05:25:14 -05:00
Ben Meadors
783466f116 Revert "Remove unused Jlink monitoring files (#4953)" (#4959)
This reverts commit 55049ed547.
2024-10-05 05:24:59 -05:00
Tom Fifield
55049ed547 Remove unused Jlink monitoring files (#4953)
The NRF52 JLINK_MONITOR are unmodified copies of code from Nordic
(https://github.com/NordicPlayground/j-link-monitoring-mode-debugging ),
which are not used by our firmware and have not been touched in ~4 years.
2024-10-05 05:24:12 -05:00
Tom Fifield
e182ae75c2 Remove ancient .gitignore lines (#4952)
The files referenced here have not existed for some time.
2024-10-05 05:15:20 -05:00
Jonathan Bennett
7e946d15ca Move ifndef to fix test (#4950) 2024-10-04 22:59:00 -05:00
Ben Meadors
c3b9d493b6 Leave the build epoch commented and uncomment when CI runs (#4943) 2024-10-04 15:07:10 -05:00
Jonathan Bennett
4db0c75c8e Don't use a static decleration in a header file (#4944)
* Don't use a static decleration in a header file

* Actually add the rest of the commit
2024-10-04 12:06:02 -05:00
Ludovic BOUÉ
e7cfadacd8 Add Panel_ILI9342 to TFTDisplay.cpp (#4822)
* Add Panel_ILI9342 to TFTDisplay.cpp

[Panel_ILI9342](https://github.com/lovyan03/LovyanGFX/blob/master/src/lgfx/v1/panel/Panel_ILI9342.hpp)

* Add ILI9342_DRIVER to TFTDisplay.cpp

* Add ILI9342_DRIVER to Screen.cpp

* Add ILI9342_DRIVER to ScreenFonts.h

* Add ILI9342_DRIVER to main.cpp

* Add ILI9342_DRIVER to images.h

* Add ILI9342_DRIVER to NodeDB.cpp

* Add ILI9342 to PortduinoGlue.cpp

* Add ili9342 to PortduinoGlue.h

* Fix formatting

* Update Screen.cpp to add ILI9342_DRIVER

* Update TFTDisplay.cpp

* Update TFTDisplay.cpp

* Update Screen.cpp

* Update Screen.cpp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-10-04 07:47:14 -05:00
GUVWAF
673fe294f3 Add rxDupe, txRelay and txRelayCanceled to LocalStats (#4936)
* Introduce `isFromUs()` and `isToUs()`

* Add rxDupe, txRelay and txRelayCanceled to LocalStats
2024-10-04 06:28:51 -05:00
gitbisector
236374491b cleanupNeighbors() time difference fix (#4941) 2024-10-04 06:17:23 -05:00
HarukiToreda
d6f26c682d Enabling Ve pin on T114 (#4940)
* Enabling Ve pin on T114

Problem:
The Ve pin was not enabled in the firmware, and it was supposed to control the power to the GPS via the GPS_EN pin. As a result, users were forced to rely on the 3.3V pin to power their additional peripherals, which caused a constant power draw from the battery, even when the node was in deep sleep mode.

Solution:
To resolve this, Todd_Hervert and I decided to remove the GPS power toggle after testing revealed that the GPS only consumes 1mA in soft sleep mode. This minimal power consumption allowed us to enable the Ve pin without causing significant battery drain. Additionally, we added a delay to the I2C initialization process, as the Ve pin requires a few milliseconds to stabilize, which could prevent some peripherals from booting up in time.

Result:

The GPS operates as usual, drawing only 1mA of power.
The keyboard and other peripherals attached to the Ve pin now power off correctly when the node is shut down.
The I2C check initiates without issues after the delay, allowing all peripherals to function smoothly.

* trunk format

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-10-04 06:15:59 -05:00
Jonathan Bennett
befc2ece6f Add a Userprefs Timezone String, to be replaced in the web flasher (#4938)
* Add a Userprefs Timezone String, to be replaced in the web flasher

* Use a volatile char buffer for slipstreamed strings.

* More refinement
2024-10-03 20:51:22 -05:00
github-actions[bot]
b2b60eccdb [create-pull-request] automated change (#4937)
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-10-03 14:54:18 -05:00
dependabot[bot]
07d4e6f5be Bump protobufs from 62c4b00 to b419706 (#4934)
Bumps [protobufs](https://github.com/meshtastic/protobufs) from `62c4b00` to `b419706`.
- [Release notes](https://github.com/meshtastic/protobufs/releases)
- [Commits](62c4b0081c...b419706693)

---
updated-dependencies:
- dependency-name: protobufs
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-10-03 07:57:34 -05:00
github-actions[bot]
0a93261c06 [create-pull-request] automated change (#4926)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-02 06:14:55 -05:00
Ben Meadors
00f15459ec Userprefs prefix macros for clarity and consistency (#4923)
* Convert userprefs macros to prefixed ones for clarity

* Fix key
2024-10-02 06:14:24 -05:00
todd-herbert
b8044c4983 Tweak dimensions for Canned Message Notifications (#4924) 2024-10-02 05:37:08 -05:00
Ben Meadors
18f12584ab Consolidate and shrink down the re-used strings in logs (#4907)
* Consolidate and shrink down the re-used strings in GPS

* Condense all the things

---------

Co-authored-by: GUVWAF <thijs@havinga.eu>
2024-10-01 15:38:36 -05:00
github-actions[bot]
e1e7bbc420 [create-pull-request] automated change (#4918)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-10-01 14:04:44 -05:00
Thomas Göttgens
5f974d2961 save a couple of bytes (#4922) 2024-10-01 14:04:23 -05:00
Thomas Göttgens
cae2e43dc6 revert .... revert .... 2024-10-01 16:36:44 +02:00
Thomas Göttgens
0d175a918c misc library updates and compiler warnings, trunk upgrade 2024-10-01 16:02:10 +02:00
Thomas Göttgens
3440c640c3 keep for 30 days only 2024-10-01 13:46:02 +02:00
Thomas Göttgens
b769d9f854 change workflow to build one zip per processor arch 2024-10-01 13:14:51 +02:00
Ben Meadors
8d288d5a3c Only on pull request 2024-09-30 19:26:35 -05:00
Ben Meadors
dc55d7dd98 Trunk it 2024-09-30 18:07:11 -05:00
TheMalkavien
553514e3b7 Fix #4911 : Partially rework some code to remove warnings about potential non-aligned memory accesses (#4912)
* * Adding the -Wcast-align compilation flag for
  the rp2040.

* * Some rework to use a struct to access radio data
* Buffer will not be accessed by arithmetic pointer anymore

* * Remplace arithmetic pointer to avoid Warning

* * Avoid 2 little artitmetic pointer

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-30 17:56:29 -05:00
github-actions[bot]
1dace9a508 [create-pull-request] automated change (#4917)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-30 17:35:35 -05:00
Jonathan Bennett
dd587419c7 Regenerate public key on boot, to avoid accidental mismatch. (#4916)
* Regenerate public key on boot, to avoid accidental mismatch.

* Fix ifdefs
2024-09-30 17:06:31 -05:00
Thomas Göttgens
bce7d73cc6 Merge pull request #4915 from meshtastic/radiolib-701
Radiolib 702
2024-09-30 21:55:14 +02:00
Thomas Göttgens
810a79668c 7.0.2 dropped 2024-09-30 21:54:00 +02:00
Thomas Göttgens
51ee6c11ea Merge branch 'radiolib-701' of github.com:meshtastic/firmware into radiolib-701 2024-09-30 21:53:31 +02:00
Thomas Göttgens
cb06ab10da Merge pull request #4913 from meshtastic/radiolib-701
Welp it's 7.0.2 now but the branch is still open :-)
2024-09-30 21:12:59 +02:00
Thomas Göttgens
199566a996 let's see if this works 2024-09-30 21:11:48 +02:00
Thomas Göttgens
5fcad1d8c5 Welp it's 7.0.2 now but the branch is still open :-) 2024-09-30 18:15:48 +02:00
Thomas Göttgens
a5bcf48240 Welp it's 7.0.2 now but the branch is still open :-) 2024-09-30 18:12:35 +02:00
Ben Meadors
8ad89ba724 Allow for better target level Radiolib exclude plumbing (#4906)
* WIP

* LR11x0

* Anothern

* =1
2024-09-30 05:14:22 -05:00
Thomas Göttgens
fd6e8613c6 Merge pull request #4908 from scruplelesswizard/fix-artifact-comments
Fix duplicate PR comments
2024-09-30 11:55:35 +02:00
Jason Murray
b529099f90 Update main_matrix.yml 2024-09-29 20:08:23 -07:00
Thomas Göttgens
3896009e55 Merge pull request #4905 from meshtastic/radiolib-701
Update radiolib to 7.0.1
2024-09-29 23:32:47 +02:00
KodinLanewave
6f506cead5 Update INA3221 to 1.0.1 (#4877)
Added new release with compiler error fixes for INA3221 library - updating dependencies so new release will be included

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-29 16:17:43 -05:00
GUVWAF
3492c9aa99 Construct StoreForwardModule for Portduino as well (#4903)
* Construct StoreForwardModule for Portduino as well

* Remove duplicate variables
2024-09-29 16:17:23 -05:00
Thomas Göttgens
19f45d282f Update radiolib to 7.0.1 2024-09-29 23:12:20 +02:00
Michael Gjelsø
d73cbf14d5 Get accelerometerThread running from AdminModule. (#4886) 2024-09-29 11:49:16 -05:00
dahanc
d41d4c930e When importing config, keep Bluetooth on and defer rebooting until co… (#4898)
* When importing config, keep Bluetooth on and defer rebooting until config is committed

* One more place that was prematurely disabling Bluetooth

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-29 07:30:10 -05:00
Ben Meadors
403e5c304e Fix: Not being able to stop Ext. Notification nagging for screenless devices (#4899)
* Move logic up to button thread for screen-less devices

* Comment doesn't apply

* Fiddy

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-09-29 07:29:53 -05:00
Ben Meadors
dcb2707d94 Return queue status on rate limit throttling (#4901) 2024-09-29 07:28:20 -05:00
Thomas Göttgens
2e935fd943 why is this different than github docs? 2024-09-29 14:03:22 +02:00
Thomas Göttgens
88af23319c Aha! 2024-09-29 14:00:36 +02:00
Thomas Göttgens
42a3301188 Update main_matrix.yml 2024-09-29 13:58:07 +02:00
Thomas Göttgens
57b8b55fc5 Merge pull request #4900 from meshtastic/caveman99-patch-1
runner debug
2024-09-29 13:55:00 +02:00
Thomas Göttgens
d0440f3cac don't interfere with the trunk check 2024-09-29 13:54:46 +02:00
Thomas Göttgens
ef2035a60c runner debug 2024-09-29 13:52:47 +02:00
Thomas Göttgens
fa29386eb7 Update main_matrix.yml 2024-09-29 12:40:17 +02:00
Jason Murray
7e0665a5cd comment on PR with artifact link (#4896) 2024-09-29 05:01:20 -05:00
github-actions[bot]
233962104c [create-pull-request] automated change (#4897)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-28 19:12:10 -05:00
Ben Meadors
a70d5ee9d8 Temporarily remove native AGAIN due to gather-artifacts failure 2024-09-28 15:49:37 -05:00
Thomas Göttgens
a542d41ac7 rats, missed one 2024-09-28 21:59:13 +02:00
Thomas Göttgens
9513c68544 Update main_matrix.yml 2024-09-28 20:37:38 +02:00
Thomas Göttgens
448afb8345 Add C6 Target 2024-09-28 20:37:07 +02:00
Thomas Göttgens
22ecbcb046 Create build_esp32_c6.yml 2024-09-28 20:35:48 +02:00
Thomas Göttgens
7963ca6171 Merge pull request #4869 from meshtastic/t3s3-1121
Support T3S3 LR1121 variant
2024-09-28 20:13:26 +02:00
Ben Meadors
6a355616c7 Another extra 2024-09-28 13:06:01 -05:00
Ben Meadors
ec23189407 Making some board levels extra for uncommon hardware 2024-09-28 13:04:50 -05:00
Thomas Göttgens
479b0856b4 use rfswitch definition and update radiolib 2024-09-28 19:07:11 +02:00
Thomas Göttgens
7289f36600 Merge branch 'master' into t3s3-1121 2024-09-28 17:51:21 +02:00
Thomas Göttgens
ef1f0cb074 Merge pull request #4895 from meshtastic/4884-unset-rx
Don't process RX when region unset
2024-09-28 17:50:29 +02:00
Thomas Göttgens
1e8d089c4e yolo! 2024-09-28 16:40:00 +02:00
Thomas Göttgens
06dab4fa13 Don't process RX when region unset 2024-09-28 16:27:38 +02:00
GUVWAF
12efedec42 Potential fix for bad Rx performance on T1000-E (#4885)
* Potential fix for bad Rx performance on T1000-E

* validate and refactor RF switching, eliminate godmode

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-09-28 09:24:13 -05:00
Thomas Göttgens
e530ceb566 Merge pull request #4692 from meshtastic/esp32-c6
First stab at ESP32-C6 support for TLora-C6
2024-09-28 14:05:42 +02:00
Thomas Göttgens
da346159f7 fix overzealous pin definitions 2024-09-28 14:01:42 +02:00
Thomas Göttgens
c650e7d273 finish TLora C6 Support, without bluetooth for now 2024-09-28 13:42:32 +02:00
Thomas Göttgens
f3213a5b2f Merge branch 'master' into esp32-c6 2024-09-28 13:39:55 +02:00
Thomas Göttgens
1dc0cc0d05 Merge pull request #4894 from meshtastic/create-pull-request/patch
Update protobufs and classes
2024-09-28 13:39:18 +02:00
caveman99
f28f5e07b7 [create-pull-request] automated change 2024-09-28 11:38:10 +00:00
Thomas Göttgens
62c306a14b Merge branch 'master' into esp32-c6 2024-09-28 12:33:50 +02:00
Thomas Göttgens
5a2c58197b Merge pull request #4891 from meshtastic/store-n-forward
First stab at enabling store and forward for Native
2024-09-28 12:09:53 +02:00
Thomas Göttgens
cc101f9cd2 run the full suite when run on master 2024-09-28 12:07:05 +02:00
Thomas Göttgens
016e1005df Merge branch 'master' into t3s3-1121 2024-09-28 11:37:42 +02:00
Jonathan Bennett
6e1aa52723 More store-n-forward on native 2024-09-28 11:37:27 +02:00
Jonathan Bennett
5ff265c196 First stab at enabling store and forward for Native 2024-09-28 11:37:27 +02:00
Thomas Göttgens
1f08401070 Merge pull request #4892 from dahanc/master
Only log "Setting DIO2 as RF switch" when doing so and fix battery level
2024-09-28 11:36:54 +02:00
Thomas Göttgens
d1d6bfe693 Merge pull request #4890 from meshtastic/guard-remotehardware
Remove remote hardware from firmware release
2024-09-28 11:36:27 +02:00
Thomas Göttgens
a39280e9df Merge pull request #4893 from meshtastic/softSleep
Only check hardsleep threshold if GPS softsleep is supported
2024-09-28 11:35:57 +02:00
GUVWAF
48fa9f2242 Only check threshold if GPS softsleep is supported 2024-09-28 09:34:37 +02:00
David Huang
7f59cb54ef Instead of having LipoBatteryLevel forward requests to AnalogBatteryLevel if there's no Lipo sensor, just have lipoInit return false. The forwarding didn't work because it never called analogInit. 2024-09-27 23:35:57 -05:00
David Huang
36a66df923 Don't log "Setting DIO2 as RF switch" unless we're actually going to do it. Also, if there's an error setting DIO2, log the error code. 2024-09-27 21:53:13 -05:00
Ben Meadors
8efc15f4d9 Ignore seen phoneapi packets (#4888)
* Ignore PhoneAPI packet if it's been seen

* ignoramus

* Also keep track of the last 20 packet IDs

* Fill

* Make this match the nimble one

* Add the log too

* Ignore zero ID packets

* Remove message entirely

* TRunkt
2024-09-27 20:09:53 -05:00
Ben Meadors
884e3f2e35 Remove remote hardware from release 2024-09-27 20:03:51 -05:00
Ken Piper
0e0811eccd Implement GPIO pin allowlist (#4882) 2024-09-27 19:31:05 -05:00
Jonathan Bennett
fd1b68513a Add sx126x_ant_sw for Native (#4887)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-27 19:29:44 -05:00
Thomas Göttgens
2798946176 Merge branch 'master' into t3s3-1121 2024-09-27 22:59:06 +02:00
Thomas Göttgens
4ee1ae429b Merge branch 'master' into esp32-c6 2024-09-27 22:58:46 +02:00
Thomas Göttgens
482361b252 Fix CAD IRQ setting
credited to @GUVWAF
2024-09-27 22:56:42 +02:00
Thomas Göttgens
cb1cf055b1 Merge branch 'master' into esp32-c6 2024-09-27 22:51:29 +02:00
Thomas Göttgens
6c2e60d415 Merge branch 'master' into t3s3-1121 2024-09-27 22:22:42 +02:00
Jonathan Bennett
ef223b1195 use delete[] to avoid leaking memory (#4883) 2024-09-27 14:55:55 -05:00
Thomas Göttgens
ae14ca7870 the name is somewhat misleading 2024-09-27 10:42:27 +02:00
Thomas Göttgens
747046d335 nope 2024-09-27 10:37:15 +02:00
Thomas Göttgens
e02a7d1c68 test if quick is working at all 2024-09-27 10:36:00 +02:00
Thomas Göttgens
bdb998c763 pick either setup or setup-quick as valid 2024-09-27 10:33:16 +02:00
Thomas Göttgens
c35d780236 only randominze for at least 3 elements 2024-09-27 10:27:57 +02:00
Thomas Göttgens
39febad630 only sample a few builds for CI runs 2024-09-27 10:25:37 +02:00
Thomas Göttgens
40932ea06c update ci builder to include a 'quick' command line option that only outputs 3 random devices or check targets 2024-09-27 10:21:34 +02:00
Thomas Göttgens
f37b88b55e Merge pull request #4880 from meshtastic/radiolib-crc
Update radiolib, fixes CRC bug on SX127x and improves LR11xx support
2024-09-27 10:19:06 +02:00
Thomas Göttgens
743fc2e812 Update radiolib, fixes CRC bug on SX127x and improves LR11xx support 2024-09-27 09:07:14 +02:00
Ben Meadors
30356dcd97 Retroactive trunkinate 2024-09-26 19:46:17 -05:00
Jonathan Bennett
5f6d9c3e27 Add pkc test (#4878)
* Add a second delay() to get the unit tests running on Rak4631

* Add test_PKC_Decrypt

* Remove cruft from test case
2024-09-26 19:33:08 -05:00
TheMalkavien
4794cdb120 Fix (some ?) memory alignment issues on the crypto part - resulting in crashes or strange behavior (#4867)
* Replace multiple potentially non aligned pointer dereference (#4855)
First step to fix some Crypto crashes or strange behaviors

* Makes the two Crypto byte buffers aligned (#4855)
Fix #4855, and probably multiple Crypto problems depending on hardware

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-09-26 17:44:11 -05:00
Thomas Göttgens
a32233bb92 fixa de typo too 2024-09-26 12:15:37 +02:00
Thomas Göttgens
fff2e435b5 Merge branch 'master' into t3s3-1121 2024-09-26 12:13:45 +02:00
Thomas Göttgens
8f84a96b69 refactor: typo fix in macro definition 2024-09-26 12:12:08 +02:00
Thomas Göttgens
11c17ec78c oh well 2024-09-26 11:39:35 +02:00
Thomas Göttgens
b4bdf604f5 tryfix 2024-09-26 11:08:49 +02:00
Thomas Göttgens
833d7f65bc fix toolchains between old and new ESP32 2024-09-26 10:18:45 +02:00
Ben Meadors
9bebad2dbe Trunkt 2024-09-25 19:54:14 -05:00
Szetya
14019f2afa Update WaypointModule.cpp (#4870)
In INVERTED display mode, the compass ring was not visible.
2024-09-25 19:09:27 -05:00
Thomas Göttgens
12481b568a fix a lot of nuisances reported by cppcheck (#4872)
* fix a lot of nuisances reported by cppcheck

* fix portduino
2024-09-25 19:09:06 -05:00
Thomas Göttgens
3072b2a444 Merge branch 'master' into esp32-c6 2024-09-26 00:20:00 +02:00
Thomas Göttgens
5c77e29d66 Merge branch 'master' into t3s3-1121 2024-09-26 00:17:41 +02:00
Thomas Göttgens
118809fbfc Account for size of Envelope when allocating buffer. (#4819)
* Account for size of Envelope when allocating buffer.

INFO  | 09:29:20 568 [mqtt] Subscribing to msh/2/e/LongFast/+
INFO  | 09:29:20 568 [mqtt] Subscribing to msh/2/json/LongFast/+
INFO  | 09:29:20 568 [mqtt] Subscribing to msh/2/e/PKI/+
DEBUG | 09:29:20 568 [mqtt] Publishing enqueued MQTT message
ERROR | 09:29:20 568 [mqtt] Panic: can't encode protobuf reason='bytes size exceeded'

assert failed: size_t pb_encode_to_bytes(uint8_t*, size_t, const pb_msgdesc_t*, const void*) mesh-pb-constants.cpp:18 (0)

* save some mem
2024-09-25 17:13:04 -05:00
Ben Meadors
baf9cf5a59 Encapsulate RadioLibInterface receive IRQ logic (#4866)
* Encapsulate RadioLibInterface receive IRQ logic

* More concise

* Trunk
2024-09-25 16:19:18 -05:00
Ben Meadors
51e4b364b0 Trunk things 2024-09-25 16:18:45 -05:00
Thomas Göttgens
581686c7b7 Merge pull request #4780 from augustozanellato/detsensor_broadcast_changes
DetectionSensor: more flexible triggering
2024-09-25 22:48:57 +02:00
Ben Meadors
3a2fa118a2 Merge branch 'master' into detsensor_broadcast_changes 2024-09-25 13:57:49 -05:00
Ben Meadors
ac5edf867c Create SECURITY.md (#4868) 2024-09-25 13:55:04 -05:00
Thomas Göttgens
d4e8452c60 Tbeams have no ADC (#4871) 2024-09-25 13:51:11 -05:00
Ben Meadors
4128d75ad4 IS_ONE_OF macro to make long chains of conditions more concise and easy to follow (#4860)
* Is one of macro

* Moar

* Whoops

* Trunk

* isOneOf function backed macro
2024-09-25 13:50:00 -05:00
Augusto Zanellato
ed4527cfa5 address review comments 2024-09-25 20:02:22 +02:00
Thomas Göttgens
26112ba001 Support T3S3 LR1121 variant 2024-09-25 18:56:17 +02:00
Ben Meadors
9dd769586f Version 2024-09-25 08:40:33 -05:00
Ben Meadors
6e1616375e Trunk update 2024-09-25 07:25:45 -05:00
Ben Meadors
a7c379961a New detection sensor trigger type value 2024-09-25 07:01:15 -05:00
Ben Meadors
02d9d8b76c Merge branch 'master' into detsensor_broadcast_changes 2024-09-25 06:30:09 -05:00
todd-herbert
d1138d51e5 Wrangle module frames with I2C keyboard (#4817)
* Only suppress UI nav if module using keyboard input

* CardKB combo to dismiss text message and waypoint
Currently assigned to Fn + Delete
2024-09-25 06:27:04 -05:00
Ben Meadors
31e952c72e Merge branch 'master' into detsensor_broadcast_changes 2024-09-25 06:26:14 -05:00
github-actions[bot]
9d7938f570 [create-pull-request] automated change (#4865)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-25 06:25:56 -05:00
David
9456c42fc0 Refactor AccelerometerThread.h (#4831)
* Initial upload

* Tidy up

* Update ICM20948Sensor.cpp

* Update AccelerometerThread.h

* Initial upload

* Tidy up

* Update ICM20948Sensor.cpp

* Update AccelerometerThread.h

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-25 06:25:31 -05:00
David
40b3dbaa70 Add MAX17048 lipo fuel gauge (#4851)
* Initial commit

* Update MAX17048Sensor.cpp

* Update EnvironmentTelemetry.cpp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-25 05:34:53 -05:00
Jonathan Bennett
1129c92974 Add a second delay() to get the unit tests running on Rak4631 (#4862) 2024-09-25 05:31:29 -05:00
dylanli
1293c5cdd4 Support for Seeed XIAO S3 Board (#4850)
* feat: add seeed-xiao-s3 board defination and pins defination

* chore:  add SEEED XIAO S3 into mesh pb

* fix: fix trunk fmt check failed

* Trunk fmt variant.h

* Restore automatically generated file

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-09-25 18:27:14 +08:00
Thomas Göttgens
bebd2bb9e0 Merge pull request #4863 from meshtastic/create-pull-request/patch
Update protobufs and classes
2024-09-25 10:29:27 +02:00
caveman99
f73aa8aa82 [create-pull-request] automated change 2024-09-25 08:28:33 +00:00
Tom Fifield
e6e05dda1e Merge branch 'master' into master 2024-09-25 15:10:48 +08:00
Ben Meadors
c50df710ba Also put this back 2024-09-24 20:12:42 -05:00
Thomas Göttgens
65104d5d8c fix #4844 (#4859) 2024-09-24 16:51:07 -05:00
Augusto Zanellato
881f133021 Merge branch 'master' into detsensor_broadcast_changes 2024-09-24 23:00:35 +02:00
Ben Meadors
10c51d8a05 Put this back 2024-09-24 15:44:16 -05:00
Ben Meadors
453b3a59b2 python3 ref 2024-09-24 15:24:08 -05:00
Ben Meadors
67fd4b64af Actual ref 2024-09-24 15:20:05 -05:00
Ben Meadors
1d0013918b master ref 2024-09-24 15:15:55 -05:00
Ben Meadors
cac640ea97 Meshtestic submodule update 2024-09-24 14:57:20 -05:00
Ben Meadors
e7569838c7 Bin path 2024-09-24 14:32:20 -05:00
Ben Meadors
64b2bf5f93 Checkout should handle this but oh well 2024-09-24 14:18:19 -05:00
Ben Meadors
d6a008500a Who chose that ridiculous name anyway?! 2024-09-24 14:05:12 -05:00
Ben Meadors
a9d636c025 Consolidate commands 2024-09-24 14:02:12 -05:00
Ben Meadors
292027f40f Setup node 2024-09-24 13:57:53 -05:00
Ben Meadors
3c126212d5 PIO script 2024-09-24 13:45:02 -05:00
Ben Meadors
9710ac79d3 Pipargs 2024-09-24 13:37:40 -05:00
Ben Meadors
f2801a660b Update tests.yml 2024-09-24 13:33:51 -05:00
Ben Meadors
4d269501dd No args 2024-09-24 13:30:26 -05:00
Ben Meadors
752192b09a pipx 2024-09-24 13:27:13 -05:00
Ben Meadors
f8f9329529 pip3 2024-09-24 13:16:24 -05:00
github-actions[bot]
c3e53d916d [create-pull-request] automated change (#4858)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-24 13:04:52 -05:00
Ben Meadors
c679932248 Setup python 2024-09-24 12:58:41 -05:00
Ben Meadors
5488c8f579 Got the runner labels backwards 2024-09-24 12:54:04 -05:00
Ben Meadors
6c488fe816 Ony run on test runner label 2024-09-24 12:43:39 -05:00
Ben Meadors
771cb52616 Remove amd64 2024-09-24 10:52:46 -05:00
Ben Meadors
10869ea10a Don't wait for after-checks 2024-09-24 09:10:29 -05:00
Ben Meadors
e4d0e38f37 Remove native and add v4 back 2024-09-24 08:25:25 -05:00
Ben Meadors
d7badcc9cb Don't run checks on workflow_dispatch 2024-09-24 07:17:38 -05:00
Ben Meadors
4fbf666cd9 Try v3 2024-09-24 07:12:43 -05:00
Tom Fifield
adb094ebc9 Remove old comments from main (#4849)
These comments were circa 4 years old. Remove them.
2024-09-24 06:08:32 -05:00
Tom Fifield
b709d47832 Fix Ublox M10 Setup (#4842)
There is no EXTINT pin available on the Tdeck, which uses
the Ublox M10 GPS. Therefore our previous hack to use that pin
makes the GPS not work. That workaround was implemented to
fix sleep issues which have now since been fixed with the
state machine.

This patch restores the state prior to the hack, which is
known-working.

Additionaly, it was discovered that M10s hate it when you
try and save to non-extistent eeprom/SPI flash.

This patch creates a new SAVE command for the M10 that fixes
this issue.

Many thanks to @MisterC925 whose report and testing was
essential for this fix.

fixes https://github.com/meshtastic/firmware/issues/4625

Co-authored-by: Ken McGuire <kenm@paonia.com>
2024-09-24 05:50:03 -05:00
Augusto Zanellato
01d42d4728 Merge branch 'master' into detsensor_broadcast_changes 2024-09-24 11:53:41 +02:00
Augusto Zanellato
ce480ae626 fix comment style 2024-09-24 11:16:04 +02:00
Augusto Zanellato
139686d639 bump protobufs 2024-09-24 11:11:16 +02:00
Jason Murray
4fde1ca2a8 chomp trailing newline (#4848) 2024-09-24 16:27:46 +08:00
Jason Murray
c72612d826 sed doesn't like newlines (#4847)
* sed doesn't like newlines

* fold remove-debug-flags block

* PATH is a system env var

* Runners don't like rm -f ${workspace path}
2024-09-24 15:41:40 +08:00
Tom Fifield
682133501a Syntax fix for github action (#4846)
https://docs.github.com/en/actions/sharing-automations/creating-actions/metadata-syntax-for-github-actions#runs-for-composite-actions
2024-09-24 14:49:01 +08:00
Jason Murray
b4c09ace23 Consolidate variant build steps (#4820)
* poc: consolidate variant build steps

* use build-variant action

* only checkout once and clean up after run

* checkout before local action
2024-09-24 13:47:31 +08:00
Jonathan Bennett
c39d270f40 Build message in printBytes, to not spam BLE log (#4843) 2024-09-24 12:41:28 +08:00
Tom Fifield
428a567078 Wire 1 is PIN_WIRE1_SDA (#4840)
Based on #4745, PIN_WIRE1_SDA is the 'second' wire interface.

This pach amends the check to determine whether a device has two
wire interfaces should use PIN_WIRE1_SDA, rather than PIN_WIRE_SDA.
2024-09-23 19:16:44 -05:00
Ben Meadors
0ad1f776ae Manually regen protos for now 2024-09-23 18:53:01 -05:00
Ben Meadors
e78c706999 Fix RAK4631 accelerometer (#4837) 2024-09-23 18:40:54 -05:00
Ben Meadors
c442cd7267 Remove some straggler now 2024-09-23 15:53:42 -05:00
Ben Meadors
9cbabb0468 Teardown bluetooth phoneAPI better and fix client notification issue (#4834)
* Teardown bluetooth phoneAPI better and fix client notification issue

* Fix client notification draining
2024-09-23 15:51:05 -05:00
Jonathan Bennett
9a7a4d3814 Check for null before printing debug (#4835) 2024-09-23 13:56:26 -05:00
Jonathan Bennett
fa1cc59841 Rename message length headers and set payload max to 255 (#4827)
* Rename message length headers and set payload max to 255

* Add MESHTASTIC_PKC_OVERHEAD

* compare to MESHTASTIC_HEADER_LENGTH

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-09-23 09:20:32 -05:00
Augusto Zanellato
d4dc4dec76 Merge branch 'master' into detsensor_broadcast_changes 2024-09-23 16:20:20 +02:00
Augusto Zanellato
be01c18c74 DetectionSensor: more flexible triggering 2024-09-23 16:15:44 +02:00
Ben Meadors
e8829b8f52 Refactor and consolidate time window logic (#4826)
* Refactor and consolidate windowing logic

* Trunk

* Fixes

* More

* Fix braces and remove unused now variables.

There was a brace in src/mesh/RadioLibInterface.cpp that was breaking
compile on some architectures.

Additionally, there were some brace errors in
src/modules/Telemetry/AirQualityTelemetry.cpp
src/modules/Telemetry/EnvironmentTelemetry.cpp
src/mesh/wifi/WiFiAPClient.cpp

Move throttle include in WifiAPClient.cpp to top.

Add Default.h to sleep.cpp

rest of files just remove unused now variables.

* Remove a couple more meows

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-09-23 08:58:14 -05:00
Thomas Göttgens
1afd61698b Merge pull request #4745 from todd-herbert/t114-i2c
I2C for Heltec Mesh Node T114
2024-09-23 15:45:35 +02:00
Jason Murray
3ff9398b92 Revert "Update classes on protobufs update" (#4824)
* Revert "Update classes on protobufs update"

* remove quotes to fix trunk.

---------

Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-09-23 20:34:19 +08:00
Todd Herbert
76900555e8 Swap SDA and SCL
SDA=P0.16, SCL=P0.13
2024-09-24 00:25:43 +12:00
Todd Herbert
1487ca2a30 Tidier macros 2024-09-24 00:25:43 +12:00
Todd Herbert
f960164c0e Add I2C bus to Heltec T114 header pins
SDA: P0.13
SCL: P0.16

Uses bus 1, leaving bus 0 routed to the unpopulated footprint for the RTC (general future-proofing)
2024-09-24 00:25:43 +12:00
Todd Herbert
11598beb16 Implement optional second I2C bus for NRF52840
Enabled at compile-time if WIRE_INFERFACES_COUNT defined as 2
2024-09-24 00:25:43 +12:00
Tom Fifield
1f8aa1efc7 Minor fix (#4666)
* Minor fixes

It turns out setting a map value with the index notation causes
an lookup that can be avoided with emplace. Apply this to one line in
the StoreForward module.

Fix also Cppcheck-determined highly minor performance increase by
passing gpiochipname as a const reference :)

The amount of cycles used on this laptop while learning about these
callouts from cppcheck is unlikely to ever be more than the cycles
saved by the fixes ;)

* Update PortduinoGlue.cpp
2024-09-23 18:22:06 +08:00
Jonathan Bennett
18aac0ba25 Consider the LoRa header when checking packet length 2024-09-22 16:09:46 -05:00
Tom Fifield
2e24d244be Make Ublox code more readable (#4727)
* Simplify Ublox code

Ublox comes in a myriad of versions and settings. Presently our
configuration code does a lot of branching based on versions being
or not being present.

This patch adds version detection earlier in the piece and branches
on the set gnssModel instead to create separate setup methods for Ublox 6,
Ublox 7/8/9, and Ublox10.

Additionally, adds a macro to make the code much shorter and more
readable.

* Make trunk happy

* Make trunk happy

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-22 10:00:32 -05:00
Tom Fifield
7db98ca1da Revert "Consolidate variant build steps (#4806)" (#4816)
This reverts commit 9f8d86cb25.
2024-09-22 19:39:35 +08:00
Jason Murray
9f8d86cb25 Consolidate variant build steps (#4806)
* poc: consolidate variant build steps

* use build-variant action

* only checkout once and clean up after run
2024-09-22 19:22:00 +08:00
Austin
2ff0af55b1 [Board] DIY "t-energy-s3_e22" (#4782)
* New variant "t-energy-s3_e22"

- Lilygo T-Energy-S3
- NanoVHF "Mesh-v1.06-TTGO-T18" board
- Ebyte E22 Series

* add board_level = extra

* Update variant.h

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Tom Fifield <tom@tomfifield.net>
2024-09-22 14:47:49 +08:00
Ben Meadors
51af747508 CI fixes 2024-09-21 20:53:23 -05:00
Ben Meadors
893bbe09d1 Hopefully extract and commit to meshtastic.github.io 2024-09-21 16:34:26 -05:00
Jonathan Bennett
d21087f639 Update platform-native to pick up portduino crash fix (#4807) 2024-09-21 16:17:30 -05:00
Thomas Göttgens
01203eb854 Merge pull request #4805 from scruplelesswizard/update-classes-on-protobuf-update
Update classes on protobufs update
2024-09-21 21:46:32 +02:00
Jason Murray
2072ebd196 meshtastic/ is a test suite; protobufs/ contains protobufs; 2024-09-21 09:58:28 -07:00
Jason Murray
202699239f feat: trigger class update when protobufs are changed 2024-09-21 07:51:09 -07:00
Thomas Göttgens
906b0233d2 Merge pull request #4801 from meshtastic/heltec-wireless-bridge
heltec-wireless-bridge
2024-09-21 16:15:28 +02:00
Thomas Göttgens
d584031d10 Merge pull request #4804 from meshtastic/create-pull-request/patch
Update protobufs and classes
2024-09-21 15:16:52 +02:00
thebentern
f324ab7de7 [create-pull-request] automated change 2024-09-21 15:16:31 +02:00
todd-herbert
54f56438da Re-order doDeepSleep (#4802)
Make sure PMU sleep takes place before I2C ends
2024-09-21 07:59:17 -05:00
Thomas Göttgens
e6c7c80b3f Raspberry Pico2 - needs protos 2024-09-21 14:50:19 +02:00
dependabot[bot]
c053c7d9ae Bump pnpm/action-setup from 2 to 4 in /.github/workflows (#4798)
Bumps [pnpm/action-setup](https://github.com/pnpm/action-setup) from 2 to 4.
- [Release notes](https://github.com/pnpm/action-setup/releases)
- [Commits](https://github.com/pnpm/action-setup/compare/v2...v4)

---
updated-dependencies:
- dependency-name: pnpm/action-setup
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-21 06:13:09 -05:00
github-actions[bot]
953beb56b1 [create-pull-request] automated change (#4789)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-21 06:12:05 -05:00
dependabot[bot]
acd044fdea Bump meshtestic from 31ee3d9 to 37245b3 (#4799)
Bumps [meshtestic](https://github.com/meshtastic/meshTestic) from `31ee3d9` to `37245b3`.
- [Commits](31ee3d90c8...37245b3d61)

---
updated-dependencies:
- dependency-name: meshtestic
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
2024-09-21 06:11:32 -05:00
Tom Fifield
de706523f5 Actions: Semgrep Images have moved from returntocorp to semgrep (#4774)
https://hub.docker.com/r/returntocorp/semgrep notes: "We've moved!
 Official Docker images for Semgrep now available at semgrep/semgrep."

Patch updates our CI workflow for these images.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-21 06:10:59 -05:00
Thomas Göttgens
52cef05c70 heltec-wireless-bridge
requires Proto PR first
2024-09-21 12:42:51 +02:00
dependabot[bot]
6490cadd35 Bump docker/build-push-action from 5 to 6 in /.github/workflows (#4800) 2024-09-21 09:30:36 +00:00
Thomas Göttgens
8e5928276b update pin definitions
update toolchain
enable telemetry
fix compilation
2024-09-21 11:27:14 +02:00
Thomas Göttgens
5dcaceccdd Merge branch 'esp32-c6' of github.com:meshtastic/firmware into esp32-c6 2024-09-21 11:24:58 +02:00
Thomas Göttgens
f1cf2bf413 First stab at ESP32-C6 support for TLora-C6 2024-09-21 11:24:52 +02:00
dependabot[bot]
3882841283 Bump peter-evans/create-pull-request from 6 to 7 in /.github/workflows (#4797) 2024-09-21 08:17:31 +00:00
Tom Fifield
74e6470439 fix dependabot syntax (#4795)
* fix dependabot syntax

* Update dependabot.yml

* Update dependabot.yml
2024-09-21 14:20:30 +08:00
Tom Fifield
dca711ac24 Merge pull request #4790 from scruplelesswizard/master
Enable Dependabot
2024-09-21 12:22:11 +08:00
Jason Murray
7368cb99dc chore: trunk fmt 2024-09-20 19:40:36 -07:00
Jason Murray
ec848bab52 Enable Dependabot 2024-09-21 09:40:56 +08:00
Jason Murray
ed13105aec set title for version bump PR (#4791) 2024-09-20 20:30:49 -05:00
Jason Murray
c2272ce5a1 set title for protobufs bump PR (#4792) 2024-09-20 20:30:32 -05:00
Ben Meadors
0664c09f9d Download debian files after firmware zip 2024-09-20 14:55:53 -05:00
todd-herbert
ba31a7c753 Honor flip & color for Heltec T114 and T190 (#4786)
* Honor TFT_MESH color if defined for Heltec T114 or T190

* Temporary: point lib_deps at fork of Heltec's ST7789 library
For demo only, until ST7789 is merged

* Update lib_deps; tidy preprocessor logic
2024-09-20 13:27:41 -05:00
Thomas Göttgens
1bca8de042 Merge branch 'esp32-c6' of github.com:meshtastic/firmware into esp32-c6 2024-09-20 19:37:51 +02:00
Thomas Göttgens
6ffdc9875b First stab at ESP32-C6 support for TLora-C6 2024-09-20 19:37:47 +02:00
Thomas Göttgens
b84cf55659 Merge branch 'esp32-c6' of github.com:meshtastic/firmware into esp32-c6 2024-09-20 19:37:24 +02:00
Ben Meadors
85d722232e Additional decoded packet ignores 2024-09-20 07:35:26 -05:00
Ben Meadors
921d92c649 Drop received packets from self 2024-09-20 06:55:16 -05:00
Jonathan Bennett
82f1be33aa Merge branch 'master' into master 2024-09-19 19:43:05 -05:00
Jonathan Bennett
0f3450ad44 Mark package workflows for gh hosted runners 2024-09-19 18:21:30 -05:00
Jonathan Bennett
114df8cb1b Pin sensorlib version 2024-09-19 13:29:17 -05:00
Jonathan Bennett
d3a293a0d8 Flag semgrep to not run on self-hosted
The semgrep action runs inside a docker container, and docker in podman just doesn't work.
2024-09-19 12:10:39 -05:00
Ben Meadors
91b4199f9d Revert "DetectionSensor: broadcast all state changes" (#4776) 2024-09-19 10:46:18 -05:00
Tom Fifield
6473cf0b69 Update RadioLib to 7.0.0 (#4771)
We were not too many commits behind, and the changes since then
were either for LoraWAN or useful minor bug fixes for SX1280.
2024-09-19 06:48:22 -05:00
Tom Fifield
84e197574b Merge pull request #4773 from markbirss/master
Update HW_VENDOR
2024-09-19 16:28:40 +08:00
Mark Trevor Birss
5c4c0965af Update nordic_pca10059.json 2024-09-19 15:41:59 +08:00
Mark Trevor Birss
7289b295e8 Update me25ls01-4y10td.json 2024-09-19 15:41:59 +08:00
Mark Trevor Birss
7c32ab3023 Update ms24sf1.json 2024-09-19 15:41:59 +08:00
Tom Fifield
2bc036f9eb Merge pull request #4772 from dahanc/master
Another missed define for the T114
2024-09-19 15:28:26 +08:00
David Huang
cc89e85e71 Another missed define for the T114 2024-09-19 00:53:33 -05:00
Tom Fifield
da45cb8557 Merge pull request #4767 from augustozanellato/detsensor_broadcast_changes
DetectionSensor: broadcast all state changes
2024-09-19 13:42:56 +08:00
Augusto Zanellato
2ebfcea94e DetectionSensor: broadcast all state changes
Closes #4753
2024-09-18 19:43:23 +02:00
github-actions[bot]
deada41cee [create-pull-request] automated change (#4765)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-18 10:49:12 -05:00
Ben Meadors
777bcf691a Initial PhoneAPI rate-limiting of messages on certain ports (#4756) 2024-09-18 10:13:07 -05:00
Tom Fifield
35e1c401e2 PMSA0031 sensors require ~3secs before coming up on I2C (#4743)
* PMSA0031 sensors require ~3secs before coming up on I2C

As reported by @MALAONE1 and debugged by @shodan8192 , PMSA0031s
on a RAK4631 take 3 seconds before they can become detectable on I2c.

Add a delay(4000) before I2C scan if the air quality sensor pin
is defined.

Fixes https://github.com/meshtastic/firmware/issues/3690

* Remove 4 second wait and rescan during air quality init for the sensor

* works without but this triggers my OCD

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-18 10:12:49 -05:00
Tom Fifield
19c57e8ec6 Fix Chatter 2 blank screen on boot (#4759)
As reported by @eureekasigns and @GPSFan, Chatter 2 had begun
to show a blank screen on boot after recent TFT display changes.

Setting TFT_BACKLIGHT_ON LOW resolves the issue.

Fixes https://github.com/meshtastic/firmware/issues/4751
2024-09-18 09:05:32 -05:00
GUVWAF
db4a793aa9 Merge branch 'master' into master 2024-09-18 11:38:40 +02:00
Jonathan Bennett
c6196b2260 Update build_esp32.yml -- less CI fun 2024-09-18 01:11:08 -05:00
Jonathan Bennett
3eebdcefa4 More CI fun 2024-09-18 00:28:54 -05:00
Jonathan Bennett
4289cb089b Update package_raspbian.yml to build on self-hosted (#4761)
* Update package_raspbian.yml to build on self-hosted

* Update package_raspbian_armv7l.yml to use self hosted
2024-09-18 00:17:48 -05:00
Jonathan Bennett
2d52803dbd Add new admin error types (#4750)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-17 21:09:24 -05:00
Jonathan Bennett
c78302a2ee Add hasPKC to deviceMetadata (#4755) 2024-09-17 19:34:05 -05:00
github-actions[bot]
923458bc18 [create-pull-request] automated change (#4754)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2024-09-17 17:55:16 -05:00
Ben Meadors
50fb4ab22a Implement optional hops_away on NodeInfo/Lite (#4747)
* Implement optional hops_away on NodeInfo/Lite

* Trunk
2024-09-17 12:08:04 -05:00
Thomas Göttgens
f5016763fd change evaluation order to silence warning about "found" (#4749) 2024-09-17 10:33:21 -05:00
Ben Meadors
2a6921292e Implement CoT detail support in TAKPacket (#4748)
* Implement CoT detail support in TAKPacket

* dest, src

* More coffee is needed

* SAVE
2024-09-17 10:05:55 -05:00
github-actions[bot]
a47570d65a [create-pull-request] automated change (#4746)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-17 06:52:42 -05:00
Andre K
db4dc88d6f feat: enable remote admin to set/clear fixed positions (#4713)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-17 06:50:49 -05:00
Tom Fifield
be306cc384 Increase GPS FIFO Buffer Size for RP2040 (#4741)
As discovered and tested by @Mictronics, default Serial FIFO size
on the Pico is 32bytes, which is not enough for GPS messages.

This patch increases the Serial GPS FIFO buffer size to 256
for the RP2040 Architecture

fixes https://github.com/meshtastic/firmware/issues/3989
2024-09-17 06:48:56 -05:00
Jonathan Bennett
a967dd52f3 More useful PKC logging (#4742) 2024-09-17 06:31:39 -05:00
Ben Meadors
11378325e0 Separate GPS and NTP RTCQuality logic and allow GPS time to always set us (#4721) 2024-09-17 06:29:18 -05:00
Thomas Göttgens
4b5bcf52d2 Merge pull request #4691 from S5NC/rak11200-pin-name-correction
Rak11200 pin name correction
2024-09-17 11:42:40 +02:00
Thomas Göttgens
5ba418b2cd Merge pull request #4744 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-09-17 09:27:42 +02:00
Thomas Göttgens
bc753e6903 trunk fmt 2024-09-17 15:24:11 +08:00
S5NC
34a543ec74 Update main.cpp 2024-09-17 15:24:11 +08:00
S5NC
06cd9abd81 Update SX126xInterface.cpp 2024-09-17 15:24:11 +08:00
S5NC
af30485611 Update main.cpp 2024-09-17 15:24:11 +08:00
S5NC
cd6bd1e9a3 Update main.cpp 2024-09-17 15:24:11 +08:00
S5NC
b025eeb13c Update variant.h 2024-09-17 15:24:11 +08:00
Thomas Göttgens
21eb54e58a Merge pull request #4740 from fifieldt/QMC5883L
Fix I2C address for QMC5883L.
2024-09-17 09:09:43 +02:00
Tom Fifield
6f1db6fc63 Fix I2C address for QMC5883L.
QMC5883L and HMC5883L are 3-axis compasses which are often confused.
As reported by @Africmod, we had the wrong I2C address for the QMC5883L.
This patch fixes the address and adds its HMC5883L so we keep info
about both.

Fixes https://github.com/meshtastic/firmware/issues/4144
2024-09-17 13:48:10 +08:00
Tom Fifield
a5118787b3 Merge pull request #4689 from Szetya/master
Improved compass arrow
2024-09-17 13:02:52 +08:00
jp-bennett
39c90dd581 [create-pull-request] automated change 2024-09-17 02:53:44 +00:00
Todd Herbert
33e6f7f6e0 Hollow triangle for E-Ink; trunk formatting 2024-09-17 08:27:00 +08:00
Szetya
97fd189f43 Compass update
https://github.com/meshtastic/firmware/issues/4494
New compass arrow and replacement of the north marker with a small circle.
2024-09-17 08:27:00 +08:00
jhps
1e665d5181 Update T114 LED definitions to include only one simple controllable LED and two NEOPIXELS. (#4710) 2024-09-16 19:11:55 -05:00
Thomas Göttgens
b3343303a9 write firmware version and hardware platform to Flash memory 2024-09-16 21:36:54 +02:00
github-actions[bot]
f37276d5fc [create-pull-request] automated change (#4736)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-16 10:32:21 -05:00
Tom Fifield
905194c604 Remove lora_isp4520 (#4735)
Per Ben: "We haven't supported any NRF5832 based board in quite some time.
It's relatively resource constrained compared to the NRF52840"
2024-09-16 09:06:13 -05:00
Thomas Göttgens
ea6f6c3668 First stab at ESP32-C6 support for TLora-C6 2024-09-16 14:25:17 +02:00
Thomas Göttgens
51b22630b4 Merge pull request #4728 from fifieldt/11111111111111111
Fix Heltec T114 vendor definition
2024-09-16 12:20:18 +02:00
Mark Trevor Birss
5d831ef461 Merge pull request #4729 from markbirss/master
[BUG-FIX] ME25LS01-4Y10TD_e-ink e-paper init fix
2024-09-16 11:14:16 +02:00
Mark Trevor Birss
4e8672cce4 Update variant.h 2024-09-16 10:40:52 +02:00
Tom Fifield
41a769aa06 Fix Heltec T114 vendor definition
@dahanc pointed out there was an extra one in there.
2024-09-16 13:55:27 +08:00
Ben Meadors
8d57b6164a Add Heltec T1114 hardware model to build (#4719) 2024-09-15 20:37:19 -05:00
Ben Meadors
dc3eba9100 Expand to MqttClientProxyMessage_size (#4726) 2024-09-15 18:57:02 -05:00
Jonathan Bennett
ff8baa1c85 Don't use PKC on a non-primary channel unless specifically requested (#4715)
* Don't use PKC on a non-primary channel unless specifically requested

* Don't change from channel 0 if we can send a PKC packet.
2024-09-15 09:26:43 -05:00
Jonathan Bennett
3a10a27851 Actually restrict remote hardware to gpio channel (#4717) 2024-09-15 06:27:59 -05:00
GUVWAF
8893529653 Make local stats number of Rx packets sum of good and bad (#4709) 2024-09-14 17:53:27 -05:00
Jonathan Bennett
1ab5bf4355 Use the time.age() value to correct stale GPS times (#4705)
* Use the time.age() value to correct stale GPS times

* Trunk

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-14 07:44:40 -05:00
Ben Meadors
ae791ca7e1 Add buildstamp epoch to initial debug output 2024-09-13 19:43:50 -05:00
Ben Meadors
35cfe4318a Stop past timestamps from setting our system time RTC (#4704)
* Ignore attempts to set times in the past (before our build epoch)

* TRONK
2024-09-13 19:42:31 -05:00
rcarteraz
b59bd6fee9 Update feature.yml (#4700) 2024-09-13 16:11:54 -05:00
rcarteraz
8b911f14cf Update Bug Report.yml (#4702) 2024-09-13 16:11:39 -05:00
Ben Meadors
d36c69396b Exclude meshtasticd binaries from firmware.zip (#4698)
* Exclude meshtasticd binaries from firmware.zip

* Incorrect
2024-09-13 10:42:40 -05:00
GUVWAF
b39aca8d11 Merge branch 'master' into master 2024-09-13 08:49:04 +02:00
Bernd Giesecke
6c327d960d Merge pull request #1 from GUVWAF/beegee-tokyo
Formatting for PR #4661
2024-09-13 09:26:00 +08:00
Thomas Göttgens
9527874815 First stab at ESP32-C6 support for TLora-C6 2024-09-12 22:42:10 +02:00
GUVWAF
cd480846e9 Remove accelerometer lib 2024-09-12 19:52:36 +02:00
Vertex
3d72fbb19e Define SX126X_ANT_SW for the RAK11200 to allow it to function correctly on the RAK19007 base (#4690) 2024-09-12 12:20:38 -05:00
GUVWAF
9f3a1c1214 Trunk fmt 2024-09-12 19:12:57 +02:00
Manuel
625254cf90 Support Seeed SenseCAP Indicator (#4279)
* preliminary target environment

* add debug tool

* add screen definitions

* screen definitions

* remove rtc, debug build

* correct rotation

* Add real hwmodel

* fix width

* use IO expander ports

* link to modified arduino-esp32

* added config_detail

* rotate screen

* remove touch INT

* add delay to display log

* color log and radiolib log

* LoRa init

* make trunk happy

* add lovyanGFX patch lib for io expander

* fix lib

* fix display&touch function

* touch driver I2C scan

* remove delay

* build for release

* minor code cleanup

* allow trunk to be happy

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-09-12 06:44:30 -05:00
beegee-tokyo
c4c85777d0 Another try to get the code format correct. 2024-09-12 13:20:09 +08:00
beegee-tokyo
ca8d2204ba Fix formatting 2024-09-12 11:06:13 +08:00
beegee-tokyo
a388e78842 Fix platformio.ini conflict 2024-09-12 10:00:46 +08:00
beegee-tokyo
35cdc81d45 Disable SCREEN and enable TZ 2024-09-12 09:53:13 +08:00
panaceya
910b6b7512 OLED_ can be configured via userPrefs.h (#4624) 2024-09-11 19:31:30 -05:00
Tom Fifield
371c3e05bf Beautify GPS_DEBUG getACK logging code (#4672)
This getACK is used to look for ASCII responses, so print ASCII
when GPS_DEBUG is enabled.

This markedly assisted with recent AG3335 debugging. It works great
with other chips too (tested eg ATGM336H). Even UBLOX prints
understandable "GPTXT,01,01,01,PDTI inv format*35." responses.

Credit to bluebrolly. on discord.
2024-09-11 19:30:29 -05:00
Michael Gjelsø
f37df4d6bf Radiomaster Bandit Accelerometer support (#4667)
* Added STK8xxxx Accelerometer chip

Added detection of STK8BA53 to I2C scanner.
Change the way and order MCP9808, lLISH3DH and STK8BA53 is detected since they all shares the same I2C address.

* Accelerometer support Radiomaster Bandit.

Enables tap to wake screen if enabled in config,

* Trunk

Trunk
2024-09-11 18:53:17 -05:00
github-actions[bot]
ba9a3cd719 [create-pull-request] automated change (#4685)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-11 18:51:52 -05:00
Ben Meadors
9ac0e26d42 Add option to preserve private key for factory reset (config) (#4679)
* Add option to preserve private key for factory reset (config)

* Typo fix

* Copy the key in the right direction, and set the size.

* Don't set the key size back to 0 right after setting it to 32.

* Set the key size before using it to do a memcpy.

* Use the right key_size for backing up private_key

* Don't factoryReset() for a missing nodeDB

* Disable Bluetooth in AdminModule when resetting device settings or nodeDB to avoid race

* Add checks for valid objects before deinit bluetooth

* Add disableBluetooth to handleSetConfig, handleSetModuleConfig, and commit settings

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-09-11 08:42:26 -05:00
Ben Meadors
1ba4f6e222 Revert "Temp: Grab pre-release tag"
This reverts commit e8e9826adc.
2024-09-10 20:07:06 -05:00
Ben Meadors
e8e9826adc Temp: Grab pre-release tag 2024-09-10 19:27:59 -05:00
zerolint
6724f1f7ea Print Unix epoch on time_t 64bit platforms (#4673)
Fixes (#4600) by using unsigned 32bit for epoch.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-10 15:51:28 -05:00
Ben Meadors
013021941e Remove scaling of smart position broadcast minimum interval specifically (#4677)
* Remove scaling of smart position broacast minimum interval specifically

* Trunk
2024-09-10 15:30:40 -05:00
Jonathan Bennett
4e850296b6 Fix repeatedly getting new NodeNum and add more debug (#4674)
* All the debug

* Change `memccpy()` to `memcpy()`

* Brint all the bytes of the MAC Address from the NodeDB

* Check for blank MAC Address in ourown NodeDB entry

* One more `memccpy()`

* Clean-up debug log

---------

Co-authored-by: GUVWAF <thijs@havinga.eu>
2024-09-10 13:24:57 -05:00
beegee-tokyo
0c42f79038 Merge branch 'master' of https://github.com/beegee-tokyo/firmware 2024-09-10 18:43:53 +08:00
beegee-tokyo
4fc3782ea3 Fix traceroute, neighborinfo and waypoint 2024-09-10 18:43:47 +08:00
Ben Meadors
9ac4a0114f Merge branch 'master' into master 2024-09-10 05:25:39 -05:00
beegee-tokyo
9188786581 Fix #ifndef and rename the variant 2024-09-10 11:58:25 +08:00
GUVWAF
f1602ee3f6 Merge pull request #4669 from GUVWAF/trFix 2024-09-09 23:13:39 +02:00
GUVWAF
5537f98dd6 Merge branch 'master' into trFix 2024-09-09 21:29:37 +02:00
GUVWAF
4ed12bf21d Try fix repeatedly getting a new NodeNum (#4670) 2024-09-09 14:22:32 -05:00
Ben Meadors
106dab23db Revert "Changes by create-pull-request action" (#4671) 2024-09-09 14:20:14 -05:00
GUVWAF
2f9dcee954 Fix size calculation of route/SNR array 2024-09-09 19:13:00 +02:00
Thomas Göttgens
68d6ff8c24 Merge pull request #4650 from fifieldt/AG3352
Add support for AG3352 and fix AG3335 support
2024-09-09 16:40:44 +02:00
Tom Fifield
dc8cc122a6 Add explicit to JSONValue constructors (#4665) 2024-09-09 09:20:21 -05:00
Tom Fifield
e9d55de3cb Fix out-of-bound array access in T1000X Sensor (#4663)
if u8i == 135, then u8i++ runs, the loop exits since u8i == 136,
then value for u8i is 136 after the for loop.

then in the next line, ntc_res2[u8i] will read past the end
 of the array
2024-09-09 07:54:11 -05:00
David
dacb452d47 Bugfix (#4660) 2024-09-09 07:16:58 -05:00
Thomas Göttgens
8ab2e91df6 Merge pull request #4659 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-09-09 12:21:56 +02:00
Thomas Göttgens
e985ee878f Merge pull request #4658 from fifieldt/zombiegps
If GPS sleepTime is Zero, don't sleep.
2024-09-09 12:12:53 +02:00
Thomas Göttgens
b2e2f1dba3 Merge branch 'master' into AG3352 2024-09-09 11:10:36 +02:00
beegee-tokyo
b2417f651a Merge branch 'master' of https://github.com/beegee-tokyo/firmware 2024-09-09 12:41:00 +08:00
beegee-tokyo
d02ba45109 Fix default build platform 2024-09-09 12:40:56 +08:00
Bernd Giesecke
c6bffd7d7f Update platformio.ini
Fix default build environment
2024-09-09 12:39:14 +08:00
beegee-tokyo
a5b79528b3 Add RAK4631 Ethernet Gateway with working JSON output to MQTT 2024-09-09 11:56:37 +08:00
thebentern
fabd6b0d6f [create-pull-request] automated change 2024-09-09 02:54:25 +00:00
Tom Fifield
ebe1b40bee If GPS sleepTime is Zero, don't sleep.
At the moment if the result of sleepTime calculations comes out
to zero, we put the GPS into HARDSLEEP (losing all its status) and
then immediately make it ACTIVE again.

This patch avoids that toga.

fixes https://github.com/meshtastic/firmware/issues/4657
2024-09-09 09:28:04 +08:00
Tom Fifield
6217e97c41 Add support for AG3352 and fix AG3335 support
AG33352 is a Mediatek/Airoha GPS/GLONASS/Galileo/BeiDou receiver.
Patch adds relevant detection and setup code.

Thanks to Bluebrolly and kongduino for providing the relevant
information and testing.

This patch also fixes support for the A3335, which is a related chip.
The setup and detection code now works as tested on a real life
T-1000E!

Thanks to @gpsfan for the guidance.
2024-09-09 09:06:05 +08:00
Tom Fifield
e470619e3d Remove undefined declaration (#4652)
The getNMEA method was introduced to the header but never defined
in code. As it's unused, remove it.
2024-09-08 12:33:56 -05:00
Jonathan Bennett
bf34329033 Adds the data bitfield and ok_to_mqtt bit (#4643)
* Don't filter PKI packets just for being encrypted.

* Add ok_to_mqtt config and bit

* Bitfield

* Adjust dontmqttmebro logic.

* Manipulate bitfield only in router.cpp

* Want_ack is not want_response

* Bitfield macros

* Use new Bitfield macro in MQTT.cpp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-07 18:21:59 -05:00
Thomas Göttgens
8e88b9e819 Merge pull request #4646 from gitbisector/batt_stat
Report PWD when no battery present.
2024-09-07 10:58:17 +02:00
Thomas Göttgens
56a2e40681 Merge pull request #4647 from fifieldt/gps-probe-macro
Simplify GNSS Probe code
2024-09-07 10:54:24 +02:00
Tom Fifield
ba28ffb65a Simplify GNSS Probe code
This patch takes inspiration from our I2CDetect code where we have
many sensors that can be detected rather simply. It creates a new
macro,
PROBE_SIMPLE(Chip name, Command to run, response, Driver, timeout)

and converts existing simple cases to use this macro.
2024-09-07 11:59:45 +08:00
gitbisector
9651b5a0ec Merge branch 'master' into batt_stat 2024-09-06 17:23:38 -07:00
git bisector
2f2ddae12a Report PWD when no battery present. 2024-09-06 17:19:53 -07:00
github-actions[bot]
c77b89d85c [create-pull-request] automated change (#4645) 2024-09-06 18:51:22 -05:00
Thomas Göttgens
5c2fe4a2c0 Merge pull request #4644 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-09-06 22:29:32 +02:00
caveman99
b8cee51e84 [create-pull-request] automated change 2024-09-06 20:27:28 +00:00
Thomas Göttgens
fd1ebdf363 Merge pull request #4507 from rcarteraz/add-contributing-file
Draft contributing.md file
2024-09-06 15:12:56 +02:00
Thomas Göttgens
35b47467c7 Merge pull request #4639 from zerolint/master
RAK13800 Ethernet improvements
2024-09-06 15:11:10 +02:00
Thomas Göttgens
8f35a42f4f tryfix #4384 (#4642)
* tryfix #4384 - don't assume we want that functionality if the Accelerometer was found. This is only for T-Watch

* Add  config.display.wake_on_tap_or_motion default to RAK

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-06 06:55:56 -05:00
Thomas Göttgens
35a565cd84 Merge pull request #4623 from robertfisk/tidyup_keyboard_defines
Gather canned message magic numbers into header defines.
2024-09-06 13:49:27 +02:00
Ben Meadors
ee68e727ed Merge branch 'master' into master 2024-09-06 06:25:07 -05:00
Robert Fisk
962d9ff220 Move defines to input broker 2024-09-06 11:54:31 +02:00
Robert Fisk
8e0a342f06 Gather canned message magic numbers into header defines. 2024-09-06 11:54:31 +02:00
Thomas Göttgens
55292f8a84 Merge pull request #4638 from fifieldt/CRLF
Add missing linefeeds to gps code
2024-09-06 11:46:57 +02:00
zerolint
d72a836e07 RAK13800 Ethernet improvements
Fixes (#3618) by allowing more time for slower requests.
Resolve Syslog not maintaining client causing issues on RAK13800.
Resolve Ethernet static IP setting subnet as gateway IP.
Reduce comment and log message ambiguity around API.
Remove duplicate #if !MESHTASTIC_EXCLUDE_WEBSERVER block.
2024-09-06 11:45:43 +02:00
Thomas Göttgens
26a3841a93 Merge pull request #4637 from todd-herbert/gps-icon
Update E-Ink GPS icon immediately when triple-pressing user button
2024-09-06 11:25:12 +02:00
Thomas Göttgens
8e519d09b4 Merge pull request #4641 from meshtastic/lr-version
Add LR11x0 firmware version to init.
2024-09-06 11:24:04 +02:00
Thomas Göttgens
ae41a7cc06 Merge pull request #4635 from RCGV1/patch-1
Update Pull Request Template
2024-09-06 10:05:11 +02:00
Thomas Göttgens
011e640e95 Add LR11x0 firmware version to init. 2024-09-06 09:47:43 +02:00
Tom Fifield
e4e1ea971f Add missing linefeeds to gps code
As reported by @caveman99, the required CRLFs were missing from the
AG3335 setup code.
2024-09-06 08:45:57 +08:00
Todd Herbert
bcdc36c07c Refresh E-Ink to show changes in GPS icon 2024-09-06 11:25:41 +12:00
Benjamin Faershtein
972a5d5779 Update Pull Request Template 2024-09-05 14:25:34 -07:00
Thomas Göttgens
7c6454f171 bring 2.4G back in line with preset bandwidth (#4634) 2024-09-05 15:49:08 -05:00
Tom Fifield
9e55e6befb Minor GPS fixes (#4630)
1. Remove unused line in GPS::probe
2. update new PositionModule::hasQualityTimeSource to handle
 MESHTASTIC_EXCLUDE_GPS
2024-09-05 06:16:06 -05:00
rcarteraz
1d3d44061b lol of course trunk fmt 2024-09-04 15:33:28 -07:00
rcarteraz
4d57c99ad1 add ticks 2024-09-04 15:28:17 -07:00
rcarteraz
22e23997c1 Merge branch 'master' into add-contributing-file 2024-09-04 15:27:11 -07:00
rcarteraz
8d29ce939d changes from feedback 2024-09-04 15:27:00 -07:00
gitbisector
bb9ddcf2b5 Same priority packets processed in enqueue order (#4608)
* Same priority packets processed in enqueue order

* Prefer same prio pkts on mesh over new ones.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-09-04 08:31:30 -05:00
Thomas Göttgens
ff40a3f120 fix RF switch for Tracker E (#4621)
* fix RF switch for Tracker E

* fix all flags for Radiolib

* hopefully fix LR1110

* update to latest radiolib master - thanks @GUVWAF
2024-09-03 14:21:40 -05:00
Thomas Göttgens
8b1d7825b9 Merge pull request #4612 from meshtastic/Tracker-1000E
several small changes for Tracker 1000E
2024-09-03 14:33:03 +02:00
Thomas Göttgens
6fc4a1754b Radiolib API Changes 2024-09-03 13:12:39 +02:00
Thomas Göttgens
d83f8edd54 include radiolib CRC fix 2024-09-03 12:09:53 +02:00
Thomas Göttgens
543e7f3342 add generic bootloaders by @markbirss 2024-09-03 12:03:06 +02:00
Thomas Göttgens
f9e513f4fd Merge branch 'Tracker-1000E' of github.com:meshtastic/firmware into Tracker-1000E
# Conflicts:
#	src/mesh/LR11x0Interface.cpp
2024-09-03 09:59:44 +02:00
Thomas Göttgens
7dad2286e2 trunk fmt 2024-09-03 09:58:27 +02:00
Thomas Göttgens
190c7ecdd4 Update Erase tool for legacy softdevices to V3 2024-09-03 09:26:41 +02:00
Thomas Göttgens
8598645931 - use setRfSwitchTable
- ditch Godmode
- fixes Signedness Error in Loop.
- add V3 factory erase for 7.3.0 softdevice
2024-09-03 09:26:41 +02:00
Thomas Göttgens
3bb1cb8f1d Update Erase tool for legacy softdevices to V3 2024-09-03 09:25:33 +02:00
Tom Fifield
cdea602181 Remove unused define (#4620)
Neither RF95_DIO2 nor LORA_DIO2 are found anywhere in the code.
2024-09-02 20:08:02 -05:00
Ben Meadors
b526a3ad53 Own node should be favorited and have zero hops away (#4618) 2024-09-02 17:51:02 -05:00
Thomas Göttgens
2f0c19ebea - use setRfSwitchTable
- ditch Godmode
- fixes Signedness Error in Loop.
- add V3 factory erase for 7.3.0 softdevice
2024-09-02 15:06:06 +02:00
Thomas Göttgens
06e27bb6c2 Merge pull request #4588 from S5NC/nukeunusedvariable
Nuke proxy variable
2024-09-02 10:28:33 +02:00
Thomas Göttgens
0588d69694 Merge pull request #4527 from geeksville/pr-fix4154
for #4154 Only enable Vext regulator when needed for either Screen or GPS
2024-09-02 10:24:39 +02:00
Thomas Göttgens
367d787d74 Merge branch 'master' into pr-fix4154 2024-09-02 10:24:31 +02:00
Thomas Göttgens
c8bf43de93 Merge pull request #4482 from dhskinner/BMP388
Add BMP388 as a new pressure and temp sensor
2024-09-02 10:23:57 +02:00
Thomas Göttgens
e543b61dd8 trunk fmt 2024-09-02 10:23:31 +02:00
Thomas Göttgens
1fc6cc2d6c Merge pull request #4610 from Coloradohusky/fix_chars
Fix display of certain Unicode symbols
2024-09-02 10:16:47 +02:00
Thomas Göttgens
719faf4f97 trunk fmt 2024-09-02 10:16:32 +02:00
Thomas Göttgens
3bf20dc3a6 Merge branch 'master' into pr-fix4154 2024-09-02 09:16:52 +02:00
David
d93425fde1 Merge branch 'master' into BMP388 2024-09-02 16:48:38 +10:00
Riley Nielsen
234e652a07 Fix switch 2024-09-01 20:43:56 -07:00
Riley Nielsen
cd16b7b00a fix display of degree symbol (+ other symbols) 2024-09-01 18:26:08 -07:00
Ben Meadors
24501c30c0 Update and rename test_simulator.yml to tests.yml 2024-09-01 11:33:41 -05:00
Ben Meadors
7d2f3a3425 Hello world for MeshTestic (#4607) 2024-09-01 11:29:34 -05:00
GUVWAF
56223710b5 More priorities for different types of MeshPackets (#4606) 2024-09-01 10:29:53 -05:00
github-actions[bot]
e45a358de0 [create-pull-request] automated change (#4594)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-09-01 09:20:10 -05:00
Jonathan Bennett
b71e12c5e5 Phone admin work (#4599)
* Don't throw an error on the sessionkey admin tag

* Throw an error on packet sent to 0
2024-08-31 15:04:35 -05:00
David
eb1f80f520 Fix build issue with mutex 2024-08-31 19:40:54 +10:00
David
6c0911038a Merge branch 'master' into BMP388 2024-08-31 18:18:26 +10:00
David
644e213b13 Added a singleton wrapper for bmp3xx 2024-08-31 18:15:33 +10:00
Ben Meadors
33eb073535 Ignore (from)Net time on positions with an unknown or fixed location source (#4593)
* Ignore (from)Net time on positions with an unknown or fixed location source

* Dunk a trunk
2024-08-30 19:02:48 -05:00
Ben Meadors
8729cdb699 Merge branch 'master' into pr-fix4154 2024-08-30 16:31:47 -05:00
Ben Meadors
7475cc301e GPS_POWER_TOGGLE on T114 2024-08-30 15:37:39 -05:00
GUVWAF
eb071ec80d Set high priority for text messages (#4592) 2024-08-30 14:54:44 -05:00
github-actions[bot]
8144dcbc25 [create-pull-request] automated change (#4591)
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-08-30 13:46:51 -05:00
Jonathan Bennett
2b0113ae82 Consider an admin timestamp to be higher quality than from net (#4589) 2024-08-30 06:02:48 -05:00
Manuel
6a24566efb Lilygo T3S3 E-Paper support (#4569)
* t3s3 e-paper support

* remove GPS autodetect (which leads to crashes during startup when no GPS present)

* update EINK defines

* keep definitions for external GPS connector but disable GPS auto scan by default
2024-08-30 05:53:06 -05:00
S5NC
dd933e6bab Add bluetooth capability marker to some ESP32S3 boards (#4587)
* Update ESP32-S3-WROOM-1-N4.json

* Update CDEBYTE_EoRa-S3.json

* Update tlora-t3s3-v1.json
2024-08-30 05:51:46 -05:00
S5NC
79925406d6 Update variant.h 2024-08-30 03:18:43 +01:00
Jonathan Bennett
5bc17a9911 Key regen and MQTT fix (#4585)
* Add public key regen

* Properly label and handle PKI MQTT packets

* Extra debug message to indicate PKI_UNKNOWN_PUBKEY

* Ternary!

* Don't call non-existant function on stm32

* Actually fix STM32 compilation
2024-08-29 16:28:03 -05:00
David
a1d0af6636 Merge branch 'master' into BMP388 2024-08-30 07:25:27 +10:00
Mark Trevor Birss
22454c95c7 [BOARD] Add Minewsemi MS24SF1 nRF52840 SX1262 Module (SoftDevice 7.3.0) (#4584)
* Update architecture.h

* Add files via upload

* Add files via upload

* Update variant.h

* Update variant.h

* Update variant.cpp

* Update variant.cpp

* Update variant.cpp
2024-08-29 16:17:44 -05:00
Thomas Göttgens
b99fd93247 Merge pull request #4572 from And137/polish-oled
Support for Polish OLED characters
2024-08-29 22:30:22 +02:00
Thomas Göttgens
50631f96fc trunk fmt 2024-08-29 21:51:06 +02:00
And137
a6cc7041d3 Merge branch 'master' into polish-oled 2024-08-29 20:04:03 +02:00
Ben Meadors
171512d2f6 Fixed buzzer 2024-08-29 11:42:27 -05:00
David
db870dc17d Update extensions.json 2024-08-29 16:40:17 +02:00
David
28d0cef427 Undo inadvertent changes to extensions.json 2024-08-29 16:40:17 +02:00
David
6d2011c172 Revert "Update nightly.yml"
This reverts commit 44b975386d042b1810d5f3e1f2796af3ba7c118a.
2024-08-29 16:40:17 +02:00
David
47e1580a62 Integration test 2024-08-29 16:40:17 +02:00
David
fc1e60ac58 Initial upload 2024-08-29 16:40:17 +02:00
David
c02bbad9f3 Update nightly.yml 2024-08-29 16:40:17 +02:00
And137
f1f66cf54a Merge branch 'master' into polish-oled 2024-08-29 12:54:06 +02:00
Jonathan Bennett
92eae39a1b Move Time set from system to main (#4583) 2024-08-29 05:39:30 -05:00
geeksville
9e20b0e9b9 Merge branch 'master' into pr-fix4154 2024-08-28 11:32:29 -07:00
Kevin Hester
dc9f6e1360 fix CI warnings (and change CI comment to be correct) 2024-08-28 11:25:54 -07:00
Ben Meadors
a1bf0d8519 Add button secondary and enable scan-select on T190 (#4577) 2024-08-28 11:25:54 -07:00
Ben Meadors
f5633bf0c5 Fix T1000-E default to turn on buzzer for Ext. Notification (#4575) 2024-08-28 11:25:54 -07:00
Thomas Göttgens
ad931799c9 trunk upgrade (#4574) 2024-08-28 11:25:54 -07:00
Ben Meadors
3ad0af5ce8 Fix super tiny T1114 tft font size and fork repo to fix compiler warnings (#4573) 2024-08-28 11:25:54 -07:00
Rafael Cortês
545d32fcec Fix devcontainer Dockerfile build 2024-08-28 11:25:54 -07:00
Thomas Göttgens
94c3bb4a56 fix #4390 (#4571) 2024-08-28 11:25:54 -07:00
Ben Meadors
72c82c1c08 Add RAK4631 hex to firmware release 2024-08-28 11:25:54 -07:00
Power Li
cc93df27a5 set current time to system time in portduino build (#4556)
* set current time to system time in portduino build

* fix includes order

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-08-28 11:25:54 -07:00
Jonathan Bennett
e3ce3a3a4f Don't compare nodeDB macaddr to owner.macaddr, because in rare cases that may be unset. (#4562)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-28 11:25:54 -07:00
Jonathan Bennett
3c4d964334 Mask out random bits when doing queue ordering (#4561)
* Mask out random bits when doing queue ordering

* Parenthesis
2024-08-28 11:25:54 -07:00
Jonathan Bennett
574124aee5 Deal with admin_key being repeated (#4558) 2024-08-28 11:25:54 -07:00
John Milton
1fe80e0f30 Add support for Adafruit Feather RP2040 with RFM95. (#4451)
* Add support for Adafruit Feather RP2040 with RFM95.

* Update mesh.pb.h

dropping this change from the file generated by the protobuf

* Update mesh.pb.h

remove these reverting changes

* Update mesh.pb.h

oops, missed a comma
2024-08-28 11:25:54 -07:00
Ben Meadors
927a35ef51 Protos 2024-08-28 11:25:54 -07:00
Ben Meadors
c11a66030f Userlite mem comparison (#4552) 2024-08-28 11:25:54 -07:00
github-actions[bot]
059d5582d1 [create-pull-request] automated change (#4544)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-28 11:25:54 -07:00
John Hollowell
17b2a83b44 Add devcontainer (#4491)
devcontainers can be used by IDEs/editors like VS Code to create a standardized development environment in a container
2024-08-28 11:25:54 -07:00
Nestpebble
eddb72705f add a .yml to setup a Gitpod instance quickly (#4551)
* Create .gitpod.yml

* Update .gitpod.yml
2024-08-28 11:25:54 -07:00
geeksville
9631a1be38 remove deprecated serial/bt logging options and unify in the new (#4516)
security option.  Per discussion in https://github.com/meshtastic/firmware/issues/4375
no need to preserve the old options when changing to this new simpler
single boolean because they were newish, rarely used and only for 'advanced'
developers.
2024-08-28 11:25:54 -07:00
Kevin Hester
8a9cc727a8 for #4154 use a binary gpio transformer to manage vext on heltec-tracker (saves power) 2024-08-28 11:25:54 -07:00
Kevin Hester
cdafa87cef add lateInitVariant() as a concept. see below for docs
(from src/extra_variants/README.md)

This directory tree is designed to solve two problems.

- The ESP32 arduino/platformio project doesn't support the nice "if initVariant() is found, call that after init" behavior of the nrf52 builds (they use initVariant() internally).
- Over the years a lot of 'board specific' init code has been added to init() in main.cpp. It would be great to have a general/clean mechanism to allow developers to specify board specific/unique code in a clean fashion without mucking in main.

So we are borrowing the initVariant() ideas here (by using weak gcc references). You can now define lateInitVariant() if your board needs it.

If you'd like a board specific variant to be run, add the variant.cpp file to an appropriately named
subdirectory and check for \_VARIANT_boardname in the cpp file (so that your code is only built for your board).
You'll need to define \_VARIANT_boardname in your corresponding variant.h file.
See existing boards for examples.

This approach has no added runtime cost.
2024-08-28 11:25:54 -07:00
Kevin Hester
5ce5b7b08b Older variant.h files (IMO sloppily) don't define VEXT_ON_VALUE
But in an attempt to avoid updating lots of files, make it default to LOW
2024-08-28 11:25:54 -07:00
Ben Meadors
b285aa5bd6 Dum dum zero comparision 2024-08-28 11:25:54 -07:00
Ben Meadors
9de0b7cfac Found more places to set explicit has_optional on position (#4542) 2024-08-28 11:25:54 -07:00
Ian McEwen
fe9a80a4e0 Use the '+' wildcard for MQTT rather than '#', to subscribe only to topics one nesting level deep (#4528) 2024-08-28 11:25:54 -07:00
Michael Gjelsø
de41a054b0 Initial support for RadioMaster Bandit. (#4523)
* Initial support for RadioMaster Bandit.

* Different lighting can be made for Button 1 & 2 on the Bandit.
Changes to AmbientLighting will turn off af shutdown().

* Trunk

* Trunk again.
2024-08-28 11:25:54 -07:00
Jonathan Bennett
9b2ef971c2 Fix copyPasta in NodeDB (#4538) 2024-08-28 11:25:54 -07:00
Jonathan Bennett
710fdbd4e5 Adds has_x bools to position packet. (#4540) 2024-08-28 11:25:54 -07:00
Ben Meadors
06175737cc Save nodedb after favoriting (or removing) (#4537) 2024-08-28 11:25:54 -07:00
And137
4a2a00a227 Merge branch 'meshtastic:master' into polish-oled 2024-08-28 14:58:27 +02:00
Ben Meadors
50f06840d7 Add button secondary and enable scan-select on T190 (#4577) 2024-08-28 07:54:50 -05:00
And137
6660aec79a Merge branch 'meshtastic:master' into polish-oled 2024-08-28 14:29:26 +02:00
Ben Meadors
a34170654c Fix T1000-E default to turn on buzzer for Ext. Notification (#4575) 2024-08-28 07:24:41 -05:00
And137
d611a38ce2 Merge branch 'meshtastic:master' into polish-oled 2024-08-28 13:59:30 +02:00
Thomas Göttgens
5b3579af52 trunk upgrade (#4574) 2024-08-28 06:51:44 -05:00
Ben Meadors
f27281d3fa Fix super tiny T1114 tft font size and fork repo to fix compiler warnings (#4573) 2024-08-28 06:43:30 -05:00
FW\AM5
59ecea507f Merge branch 'polish-oled' of https://github.com/And137/firmware into polish-oled 2024-08-28 13:25:33 +02:00
Thomas Göttgens
f7f21ecefd Merge pull request #4568 from mrfyda/fix/devcontainer-docker
Fix devcontainer Dockerfile build
2024-08-28 13:14:40 +02:00
Rafael Cortês
d1e64c74de Fix devcontainer Dockerfile build 2024-08-28 13:14:32 +02:00
FW\AM5
b8609ff130 Support for Polish OLED characters
Added support for Polish OLED characters.

- Custom FONT_SMALL ArialMT_Plain_10_PL

- Automatic selection between Polish and Ukrainian/Russian characters mapping depending on the -D OLED_{LANG_NAME} flage
2024-08-28 13:11:22 +02:00
FW\AM5
ef9ecec341 Support for Polish OLED characters
Added support for Polish OLED characters.

- Custom FONT_SMALL ArialMT_Plain_10_PL

- Automatic selection between Polish and Ukrainian/Russian characters mapping depending on the -D OLED_{LANG_NAME} flage
2024-08-28 13:10:19 +02:00
Thomas Göttgens
0ee9d375b3 fix #4390 (#4571) 2024-08-28 05:43:19 -05:00
Ben Meadors
50d778d281 Add RAK4631 hex to firmware release 2024-08-27 18:24:14 -05:00
Power Li
ab62590aa9 set current time to system time in portduino build (#4556)
* set current time to system time in portduino build

* fix includes order

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-08-27 16:26:02 -05:00
Jonathan Bennett
ada61ae178 Don't compare nodeDB macaddr to owner.macaddr, because in rare cases that may be unset. (#4562)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-27 14:49:58 -05:00
Jonathan Bennett
b9a8683a4b Mask out random bits when doing queue ordering (#4561)
* Mask out random bits when doing queue ordering

* Parenthesis
2024-08-26 15:48:47 -05:00
Jonathan Bennett
5824a8f4c1 Deal with admin_key being repeated (#4558) 2024-08-26 12:29:44 -05:00
John Milton
777ae2b99c Add support for Adafruit Feather RP2040 with RFM95. (#4451)
* Add support for Adafruit Feather RP2040 with RFM95.

* Update mesh.pb.h

dropping this change from the file generated by the protobuf

* Update mesh.pb.h

remove these reverting changes

* Update mesh.pb.h

oops, missed a comma
2024-08-26 10:28:08 -05:00
Ben Meadors
d0fd17134e Protos 2024-08-26 07:48:07 -05:00
Ben Meadors
d6dac1737a Userlite mem comparison (#4552) 2024-08-24 12:19:31 -05:00
github-actions[bot]
23844389ac [create-pull-request] automated change (#4544)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-23 20:44:14 -05:00
John Hollowell
8847945734 Add devcontainer (#4491)
devcontainers can be used by IDEs/editors like VS Code to create a standardized development environment in a container
2024-08-23 20:25:16 -05:00
Nestpebble
5514aab007 add a .yml to setup a Gitpod instance quickly (#4551)
* Create .gitpod.yml

* Update .gitpod.yml
2024-08-23 20:24:23 -05:00
geeksville
aa54335e21 remove deprecated serial/bt logging options and unify in the new (#4516)
security option.  Per discussion in https://github.com/meshtastic/firmware/issues/4375
no need to preserve the old options when changing to this new simpler
single boolean because they were newish, rarely used and only for 'advanced'
developers.
2024-08-23 20:18:36 -05:00
Ben Meadors
2a279c7f3d Dum dum zero comparision 2024-08-23 07:07:28 -05:00
Ben Meadors
7abc194ef5 Found more places to set explicit has_optional on position (#4542) 2024-08-23 07:04:34 -05:00
Ian McEwen
f99b81acf7 Use the '+' wildcard for MQTT rather than '#', to subscribe only to topics one nesting level deep (#4528) 2024-08-23 07:03:29 -05:00
Michael Gjelsø
0850ad6c8d Initial support for RadioMaster Bandit. (#4523)
* Initial support for RadioMaster Bandit.

* Different lighting can be made for Button 1 & 2 on the Bandit.
Changes to AmbientLighting will turn off af shutdown().

* Trunk

* Trunk again.
2024-08-23 06:28:23 -05:00
Jonathan Bennett
00ea9182a4 Fix copyPasta in NodeDB (#4538) 2024-08-23 06:26:19 -05:00
Jonathan Bennett
601ae29fe9 Adds has_x bools to position packet. (#4540) 2024-08-23 06:25:40 -05:00
Ben Meadors
ff500bc5a9 Save nodedb after favoriting (or removing) (#4537) 2024-08-22 20:57:03 -05:00
Kevin Hester
e6163a59cd Make specifying VEXT_ON_VALUE manatory if using VEXT_ENABLE 2024-08-22 11:26:15 -07:00
Kevin Hester
5c5cbb23cf wiphone isn't setting a valid backlight enable pin
Therefore don't just randomly be writing to a GPIO numbered -1
Instead just don't try to control the backlight
NOTE: I don't have a 'wiphone' to test with, but I saw this via inspection
while cleaning up some other stuff.
2024-08-22 10:52:17 -07:00
Kevin Hester
f77c5f6a5b Don't create backlight instances when the variant hasn't specified a pin 2024-08-22 10:50:44 -07:00
Kevin Hester
2a7cf9d387 Remove redundant defintions of ST7789_BACKLIGHT_EN 2024-08-22 10:40:12 -07:00
Kevin Hester
db6e591c07 For #4154 - change TFT driver to use virtual GPIO for backlight enable 2024-08-22 10:38:19 -07:00
Kevin Hester
02c34e6214 Merge remote-tracking branch 'root/master' into pr-fix4154 2024-08-22 10:19:18 -07:00
Kevin Hester
5570b6bbc6 change GPS to use virtual GPIOs (for #4154) 2024-08-22 10:15:23 -07:00
Kevin Hester
2dda640d27 Remove unneeded VGNSS_CTRL_V03 2024-08-22 09:33:43 -07:00
Kevin Hester
5ccb6df142 Remove all sorts of redundant VEXT_ENABLE ifdefs 2024-08-22 09:28:41 -07:00
Kevin Hester
3ae8aadaf0 Merge the three redundant backlight enables into the single TFT_BL flag 2024-08-22 09:15:59 -07:00
Kevin Hester
7fb9b094d5 Remove redundant ST7735_BL variant defs.
No need for _V05 and _V03 definitions - I think there was a slight misunderstanding
on how variant files are supposed to _decrease_ #ifdef code in the cpp files.
2024-08-22 08:59:46 -07:00
Mark Trevor Birss
734f36589d Update variant.h (#4534) 2024-08-22 10:44:49 -05:00
Mark Trevor Birss
1e655052fc Fixes for ME25LS01_4Y10TD and ESP32-PICO (#4522)
* Update platformio.ini

* Update variant.h

* Update architecture.h

* Update variant.h
2024-08-22 07:00:19 -05:00
Kevin Hester
d017fc7a5d for #4154 use internal pull-ups to power ADC_Ctrl
* Currently only on heltec tracker, but could use ADC_USE_PULLUP on other boards that could benefit
* Thanks @todd-herbert and @StevenCellist for the instructions ;-)
* Remove nasty Heltec_wireless #ifdefs that got somehow added to Power.cpp, instead use proper variant defs
* Cleanup adc enable/disable code a bit for less copy-paste cruft
2024-08-21 16:53:12 -07:00
Ben Meadors
6ddee795d6 Poetry 2024-08-21 17:24:56 -05:00
Mark Trevor Birss
d556ae762c Update ScanI2CTwoWire.cpp (#4520) 2024-08-21 06:04:03 -05:00
geeksville
48e0fd7ed0 fix #4448 (by seeing there is actually no problem) (#4517)
Print directory names when listing directories
2024-08-20 17:38:39 -05:00
rcarteraz
b19c1a52cb Merge branch 'master' into add-contributing-file 2024-08-20 13:12:02 -07:00
rcarteraz
ba771ae507 fix 2024-08-20 13:11:03 -07:00
rcarteraz
9014058935 add CLA admonition 2024-08-20 13:09:39 -07:00
Jonathan Bennett
ab7de7f6a0 Add handling for sessionkey config (#4513)
* Add handling for sessionkey config

* Protos

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-20 13:36:24 -05:00
Mictronics
6ee30043c3 Fix array out of bounds read. (#4514)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

* Fix array out of bounds read.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-20 13:36:10 -05:00
Ben Meadors
314009a10f Version 2.5 bump 2024-08-20 07:35:47 -05:00
Ben Meadors
2d9126f873 Try cwd 2024-08-20 07:17:39 -05:00
Ben Meadors
d404a49336 Trunk 2024-08-20 07:08:42 -05:00
Nestpebble
ee9e46ec92 Make it possible to define TCXO and XTAL radio modules within one variant (#4492)
* Update main.cpp

Add in TCXO_OPTIONAL variable for tcxoVoltage and a double-check for working in both modes.

* Update SX126xInterface.cpp

Make a change to the tcxoVoltage setting so that TCXO_OPTIONAL works if defined.

* Update variant.h

Added define for TCXO_OPTIONAL and the tcxoVoltage variable.

Added detail on the compatible boards.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-20 06:54:18 -05:00
Ben Meadors
929b3e4f88 Add platformio tests 2024-08-20 06:49:54 -05:00
Jorropo
2043ad3bd0 bin: remove unused imports from readprops.py (#3907)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-20 06:38:16 -05:00
Tom Fifield
2472c7cdc7 JP frequency - 20mW limit, change freqs to avoid duty cycle (#4446)
Thanks to user Goyath on Discord, we discovered that in Japan the
250mW radio level requires licensing, and 20mW is the practical
limit. We also discovered that a duty cycle of 10% is needed on
most frequencies.

    CH 24-38 920.5-923.5 20mW no airtime restrictions
    CH 39-61 923.5-928.1 20mW 10% airtime
2024-08-20 06:20:01 -05:00
todd-herbert
058e9769d6 Add heartbeat LED for HT-VME290 and HT-VME213 (#4511)
* Add heartbeat LED for HT-VME290 and HT-VME213
Not populated on original board, however revisions are now shipping which do have the LED

* Update outdated commenting

* Trunk strikes again
2024-08-20 06:19:29 -05:00
Tom Fifield
3b2c37c47f Remove heltec-specific gps code from main.cpp (#4508)
After the recent GPS power work we have an clear set of
definitions for turning GPS on and off. Rather than manipulating
specific heltec tracker-related pins in main setu, the relevant
power management code in the GPS module will turn things
on/off later as needed.
2024-08-20 06:19:02 -05:00
Mictronics
ef5279e85e Set RP2040 in dormant mode when deep sleep is triggered. (#4510)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

* Set RP2040 in dormant mode when deep sleep is triggered.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-20 06:04:39 -05:00
Ben Meadors
bd21a0455b & 2024-08-19 19:19:16 -05:00
Ben Meadors
9b4ad68f43 Add simulator back as a separate step 2024-08-19 18:39:26 -05:00
Jonathan Bennett
e20d57f3ad Merge pull request #4431 from meshtastic/2.5-changes
2.5 Changes
2024-08-19 18:18:51 -05:00
rcarteraz
33b12126e0 more verbiage 2024-08-19 10:10:32 -07:00
rcarteraz
9d323a3832 verbiage changes 2024-08-19 10:08:43 -07:00
rcarteraz
2a664e01b0 update code of conduct link 2024-08-19 10:06:33 -07:00
rcarteraz
c1569b0f70 add draft contributing.md file 2024-08-19 10:03:40 -07:00
Jonathan Bennett
48dc222b75 Merge branch 'master' into 2.5-changes 2024-08-19 11:28:20 -05:00
Jonathan Bennett
ab9268cba9 Admin session key debugging messages 2024-08-19 11:12:42 -05:00
Mictronics
6de3ca4301 Fix deprecated macros. (#4505)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

* Fix deprecated macros.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-19 07:09:09 -05:00
Talie5in
e65e79c6c9 We need Millseconds not... rapid fire NeighbourInfo! (#4504) 2024-08-19 07:05:28 -05:00
Ben Meadors
14146d6ff5 Ms! 2024-08-19 07:04:48 -05:00
Jonathan Bennett
273beef148 Re-set the extra-nonce value 2024-08-18 22:25:08 -05:00
Jonathan Bennett
94d5ee9fe6 Deal with adminModule session_time of 0 2024-08-18 22:22:21 -05:00
Jonathan Bennett
7b64c4a5bf Merge branch 'master' into 2.5-changes 2024-08-18 19:14:21 -05:00
Jonathan Bennett
ecb4fb72db Don't break EXCLUDE_PKI 2024-08-18 15:51:43 -05:00
Jonathan Bennett
f439081674 Don't segfault on PKI from unknown nodes 2024-08-18 14:11:39 -05:00
Jonathan Bennett
bfbc4bf93a Set the private_key in crypto when changed by admin 2024-08-18 14:11:17 -05:00
Jonathan Bennett
22e129e716 bluetooth != security; security = security 2024-08-18 13:00:52 -05:00
GUVWAF
a85df199a5 Only accept PKI messages for MQTT downlink if we know transmitter and receiver (#4498) 2024-08-18 12:15:50 -05:00
GUVWAF
7a65c8838d Fall back to default modem preset if requested bandwidth is too large (#4497) 2024-08-18 09:14:23 -05:00
Andre K
e3e36e23f9 add admin getter for SECURITY_CONFIG (#4499) 2024-08-18 09:13:53 -05:00
Rafael Cortês
7129cee944 feature: default to fuzzy GPS location on the Default Channel (#4467)
* feature: default to fuzzy GPS location on the Default Channel

* Default to 13

* 13 default

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-18 07:38:54 -05:00
Jonathan Bennett
23e3e6db92 Add 4 bytes of random nonce to PKI (#4493) 2024-08-18 07:23:56 -05:00
todd-herbert
a8999d7759 Don't manually clear runAsap flag (#4496) 2024-08-18 07:22:16 -05:00
Jonathan Bennett
c7c620ac69 Merge branch 'master' into 2.5-changes 2024-08-17 17:38:39 -05:00
Jonathan Bennett
1bbc273ba6 Don't reject network time updates unintentionally (#4489) 2024-08-17 17:35:05 -05:00
GUVWAF
33ced7e87a Add two-way traceroute result with SNR per hop (#4485)
* Add two-way traceroute result with SNR per hop

* Update protos
2024-08-17 17:34:32 -05:00
Jonathan Bennett
578ac6711b Merge branch 'master' into 2.5-changes 2024-08-17 15:39:41 -05:00
Mictronics
e37acae405 Fix RF switching logic on rp2040-lora board. (#4486)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

* Fix warning: extra tokens at end of #endif directive.

* Fix antenna switching logic. Complementary-pin control logic is required on the rp2040-lora board.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-17 15:09:13 -05:00
Jonathan Bennett
daddaf7146 Merge branch 'master' into 2.5-changes 2024-08-17 12:24:19 -05:00
Ben Meadors
5ff1078c8c Move NeighborInfo interval default to 6 hours (double NodeInfo) (#4483)
* Move NeighborInfo in line with NodeInfo

* Set default to 6 hours and cap minimum at 2 hours
2024-08-17 11:51:53 -05:00
Jonathan Bennett
0b010b4fd8 Get STM32 building again by disabling admin module 2024-08-17 11:06:00 -05:00
Jonathan Bennett
f86dde3c40 AdminModule session_passkey (#4478)
* Protobuf

* Adds session_passkey for remote admin changes
2024-08-17 08:41:12 -05:00
Ben Meadors
fdaaf71366 Merge branch 'master' into 2.5-changes 2024-08-17 08:01:15 -05:00
Matt Ranostaj
a577dd4142 define PERIPHERAL_WARMUP_MS for heltec_capsule_sensor_v3 (#4473)
* delay is at least needed for the GXHTC3 module to be detected
2024-08-17 06:37:05 -05:00
Ben Meadors
9dad62e3c4 Set time-only admin command (#4479) 2024-08-17 05:52:36 -05:00
todd-herbert
e0b4a8e31e Radio Master Joystick (#4476)
* Radio Master Bandit 5-Way Joystick: first draft
Untested on genuine hardware

* "Okay" moves to next frame, even when canned message disabled

* Refactor to allow easier customization

* Implement feedback from testing
* guard toggleGPS()
* show "Shutting down.." screen
* split adhoc ping alert onto two lines

* Don't block while waiting for shutdown
Was preventing the alert from showing
2024-08-17 05:51:53 -05:00
Jonathan Bennett
7cbae56e6c Merge branch 'master' into 2.5-changes 2024-08-16 19:39:10 -05:00
Jonathan Bennett
6eabbaf432 Add PKI logiv to KNOWN_ONLY and LOCAL_ONLY routing modes. 2024-08-16 19:37:28 -05:00
Jonathan Bennett
cec8233cd1 Don't attempt PKI decryption on broadcast packets 2024-08-16 19:33:06 -05:00
Mark Trevor Birss
0ebdc7ab0c Update architecture.h add Minewsemi ME25LS01 LR1110 breakout ME25LE01_V1.0 and fix buzzer (#4472)
* Update architecture.h

* Update variant.h

* Update variant.h

* Update architecture.h

* Update architecture.h

* Delete src/platform/nrf52/architecture.h

* Add files via upload

* Update architecture.h

* Update architecture.h

* Update architecture.h
2024-08-16 17:37:22 -05:00
Ben Meadors
e61bd84116 Send local stats telemetry to phone every 15 minutes (#4475)
* Send local stats telemetry to phone every 10 minutes

* Add debug log and bump to 15 minutes

* Tronk

* Explicit has_ optional
2024-08-16 17:15:51 -05:00
Jonathan Bennett
b0c1b7b7b5 MQTT PKI fixes 2024-08-16 10:10:08 -05:00
Ben Meadors
eefe9efa9f Adds ASCII log option needed by portudino (#4443) (#4474)
* Adds ASCII logs useful to portudino

Activates ASCII log option when stdout is not a terminal.  This is
generally the right thing to do; if not, the behavior can be
overridden in config.yaml using AsciiLogs under Logging.  The result
is reasonable system logs for portudino when running under systemd or
the like.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
Co-authored-by: Christopher Hoover <ch@murgatroid.com>
2024-08-16 07:42:19 -05:00
Ben Meadors
390de724ba Update 2.5 protos 2024-08-16 06:09:02 -05:00
Christopher Hoover
85176756ec Adds ASCII log option needed by portudino (#4443)
* Adds ASCII logs useful to portudino

Activates ASCII log option when stdout is not a terminal.  This is
generally the right thing to do; if not, the behavior can be
overridden in config.yaml using AsciiLogs under Logging.  The result
is reasonable system logs for portudino when running under systemd or
the like.

Signed-off-by: Christopher Hoover <ch@murgatroid.com>
2024-08-15 19:09:06 -05:00
Ben Meadors
6f1dae1b1b Re-compute correct timeslot on applyModemConfig (#4469)
* Re-compute correct timeslot on applyModemConfig

* Cap contention window max at 7
2024-08-15 15:05:38 -05:00
Jonathan Bennett
ef56fae976 Merge branch 'master' into 2.5-changes 2024-08-15 11:21:25 -05:00
Ben Meadors
d398419aef Router and sensor are impolite (#4468) 2024-08-15 08:47:49 -05:00
Ben Meadors
96cf78aadd Short turbo preset (#4465) 2024-08-14 21:16:21 -05:00
Jonathan Bennett
ced87596cb Add PKI channel for MQTT (#4464)
* Add PKI channel for MQTT
2024-08-14 19:32:45 -05:00
Jonathan Bennett
1be635a797 Merge remote-tracking branch 'origin/master' into 2.5-changes 2024-08-14 19:01:06 -05:00
Jonathan Bennett
36f1a62b0b Merge remote-tracking branch 'origin/2.5-changes' into 2.5-changes 2024-08-14 18:56:41 -05:00
Jonathan Bennett
8ef72a5c08 Shorter nodeinfo timeout redux (#4458)
* Add shorterTimeout bool to sendOurNodeInfo

* Respond to likely PKI decode errors with a quick nodeinfo

* Protbufs

* Move to PKI_UNKNOWN_PUBKEY for PKI decode error
2024-08-14 17:17:53 -05:00
Ben Meadors
efc27f2051 Initial telemetry with time and variant tags (#4463) 2024-08-14 16:24:28 -05:00
github-actions[bot]
837c4e9e7b [create-pull-request] automated change (#4461)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-14 09:33:57 -05:00
Christopher Hoover
181325103a Improves ignore messages in Router.cpp (#4442)
Signed-off-by: Christopher Hoover <ch@murgatroid.com>

.
2024-08-14 07:51:32 -05:00
Ben Meadors
207b9b49a5 Always attempt to set NTP or GPS time on a fresh position packet (#4460) 2024-08-14 07:42:30 -05:00
Jonathan Bennett
8ce1c07c4e Check for blank key coming from client 2024-08-13 22:34:21 -05:00
Jonathan Bennett
2661fc694f sync protobufs 2024-08-13 20:06:36 -05:00
Jonathan Bennett
b528290fde Failure returns PKI_FAILED message if client requested PKI 2024-08-13 18:45:40 -05:00
Jonathan Bennett
ff89dca5b3 Add PKI indicator to printPacket 2024-08-13 18:45:40 -05:00
Jonathan Bennett
80fd121d87 Add meshtastic_Routing_Error_NO_CHANNEL 2024-08-13 18:45:40 -05:00
Jonathan Bennett
f3fa8daedf Revert "Add Routing_Error_NONE"
This reverts commit e1985fa0f9.
2024-08-13 18:45:40 -05:00
Jonathan Bennett
bcd77c4523 Cleanup public_keys (#4450) 2024-08-13 18:45:40 -05:00
Jonathan Bennett
308c0a6bb8 Add Routing_Error_NONE 2024-08-13 18:45:40 -05:00
Jonathan Bennett
754db3f2bc Finish fixing config migrate 2024-08-13 18:45:40 -05:00
Jonathan Bennett
c16f20de21 Make "Alloc an error" a LOG_WARN 2024-08-13 18:45:40 -05:00
Jonathan Bennett
b4cbea1b3d Move security migrate to if has_security 2024-08-13 18:45:40 -05:00
Ben Meadors
0e7253d309 Protos 2024-08-13 18:45:38 -05:00
Jonathan Bennett
b91d66b436 Don't forget public_key.size in converting back 2024-08-13 18:44:27 -05:00
Jonathan Bennett
7537b55586 Ungoober oldestBoring 2024-08-13 18:44:27 -05:00
Jonathan Bennett
2d18130235 Don't goober public_key in Userlite conversion 2024-08-13 18:44:27 -05:00
Jonathan Bennett
67ddae2851 Add logic to nodeDB to prefer evicting boring nodes (#4441) 2024-08-13 18:44:27 -05:00
Ben Meadors
884bc529f0 protos 2024-08-13 18:44:25 -05:00
Ben Meadors
8f3614d66c User to UserLite in NodeDB (#4438)
* User to UserLite in the nodedb

* Tronkdor the burninator
2024-08-13 18:43:37 -05:00
Jonathan Bennett
e7dfabc20f Exclude position packets from PKI (at least for now) 2024-08-13 18:43:19 -05:00
Jonathan Bennett
185eb318ad Manual protobuf update 2024-08-13 18:43:19 -05:00
Jonathan Bennett
c86a3200f0 Add missed function rename. (Thanks VSCode) 2024-08-13 18:43:19 -05:00
Jonathan Bennett
c3aa56ef30 Refactor platform cryptography, add tests 2024-08-13 18:43:19 -05:00
Jonathan Bennett
192af05a25 Fix compile on STM32 2024-08-13 18:43:19 -05:00
Jonathan Bennett
26d0b2b477 Add DH25519 unit test 2024-08-13 18:43:19 -05:00
Jonathan Bennett
b726792efd Re-implement PKI from #1509 (#4379)
* Re-implement PKI from #1509
co-authored-by: edinnen <ethanjdinnen@protonmail.com>

* Set the key lengnth to actually make PKI work.

* Remove unused variable and initialize keys to null

* move printBytes() to meshUtils

* Don't reset PKI key son reboot unless needed.

* Remove double encryption for PKI messages

* Cleanup encrypt logic

* Add the MESHTASTIC_EXCLUDE_PKI option, and set it for minimal builds. Required for STM32 targets for now.

* Use SHA-256 for PKI key hashing, and add MESHTASTIC_EXCLUDE_PKI_KEYGEN for STM32

* Fix a crash when node is null

* Don't send PKI encrypted packets while licensed

* use chIndex 8 for PKI

* Don't be so clever, that you corrupt incoming packets

* Pass on channel 8 for now

* Typo

* Lock keys once non-zero

* We in fact need 2 scratch buffers, to store the encrypted bytes, unencrypted bytes, and decoded protobuf.

* Lighter approach to retaining known key

* Attach the public key to PKI decrypted packets in device memory

* Turn PKI back off for STM32 :(

* Don't just memcp over a protobuf

* Don't PKI encrypt nodeinfo packets

* Add a bit more memory logging around nodeDB

* Use the proper macro to refer to NODENUM_BROADCAST

* Typo fix

* Don't PKI encrypt ROUTING (naks and acks)

* Adds SecurityConfig protobuf

* Add admin messages over PKI

* Disable PKI for the WIO-e5

* Add MINIMUM_SAFE_FREE_HEAP macro and set to safe 1.5k

* Add missed "has_security"

* Add the admin_channel_enabled option

* STM32 again

* add missed configuration.h at the top of files

* Add EXCLUDE_TZ and RTC

* Enable PKI build on STM32 once again

* Attempt 1 at moving PKI to aes-ccm

* Fix buffers for encrypt/decrypt

* Eliminate unused aes variable

* Add debugging lines

* Set hash to 0 for PKI

* Fix debug lines so they don't print pointers.

* logic fix and more debug

* Rather important typo

* Check for short packets before attempting decrypt

* Don't forget to give cryptoEngine the keys!

* Use the right scratch buffer

* Cleanup

* moar cleanups

* Minor hardening

* Remove some in-progress stuff

* Turn PKI back off on STM32

* Return false

* 2.5 protos

* Sync up protos

* Add initial cryptography test vector tests

* re-add MINIMUM_SAFE_FREE_HEAP

* Housekeeping and comment fixes

* Add explanatory comment about weak dh25519 keys

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-13 18:43:19 -05:00
Ben Meadors
c451db3a3f Get in the trunk! 2024-08-13 18:43:19 -05:00
Ben Meadors
95682c9095 Add ClientNotification hello world 2024-08-13 18:43:19 -05:00
Ben Meadors
da53b8152d Protos 2024-08-13 18:43:17 -05:00
Ben Meadors
8d1a34a4bf Protobufs 2024-08-13 18:42:40 -05:00
Ben Meadors
464f270b12 More explicit guards for attempting to set RTC (#4452)
* Guard against timesources from the mesh if we have good time

* Trunk

* Consider phone time in the past 24 hours authoritative as well

* Rename

* GPS can be null

* Declaration

* Remove RemoteHardware

* Explicitly remove GPS

* Exclude GPS earlier for RAK2560
2024-08-13 06:56:20 -05:00
Ben Meadors
7740b4bccd Sweep up some missed trunk formatting 2024-08-13 06:52:03 -05:00
Ben Meadors
e85a2e827b Update protos 2024-08-13 06:49:32 -05:00
geeksville
62a0321c7d Fixes for #4395: nrf52 flash filesystem reliability (#4406)
* bug #4184: fix config file loss due to filesystem write errors
* Use SafeFile for atomic file writing (with xor checksum readback)
* Write db.proto last because it could be the largest file on the FS (and less critical)
* Don't keep a tmp file around while writing db.proto (because too big to fit two files in the filesystem)
* generate a new critial fault if we encounter errors writing to flash
either CriticalErrorCode_FLASH_CORRUPTION_RECOVERABLE or CriticalErrorCode_FLASH_CORRUPTION_UNRECOVERABLE
(depending on if the second write attempt worked)
* reformat the filesystem if we detect it is corrupted (then rewrite our config files) (only on nrf52 - not sure
yet if we should bother on ESP32)
* If we have to format the FS, make sure to preserve the oem.proto if it exists

* add logLegacy() so old C code in libs can log via our logging

* move filesList() to a better location (used only in developer builds)

* Reformat with "trunk fmt" to match our coding conventions

* for #4395: don't use .exists() to before attempting file open
If a LFS filesystem is corrupted, .exists() can fail when a mere .open()
attempt would have succeeded.  Therefore better to do the .open() in hopes that
we can read the file (in case we need to reformat to fix the FS).
(Seen and confirmed in stress testing)

* for #4395 more fixes, see below for details:
* check for LFS assertion failures during file operations (needs customized lfs_util.h to provide suitable hooks)
* Remove fsCheck() because checking filesystem by writing to it is very high risk, it makes likelyhood that we will
be able to read the config protobufs quite low.
* Update the LFS inside of adafruitnrf52 to 1.7.2 (from their old 1.6.1) to get the following fix:
97d8d5e96a

* use disable_adafruit_usb.py now that we are (temporarily?) using a forked adafruit lib
We need to reach inside the adafruit project and turn off USE_TINYUSB, just doing that
from platformio.ini is no longer sufficient.

Tested on a wio-sdk-wm1110 board (which is the only board that had this problem)

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-13 06:45:39 -05:00
Aaron.Lee
6e8300287b Heltec boards sensor and low power features update (#4418)
* Update sensor drive and low power features.

* Update ST7789 TFT control logic.

* Update Heltec nRF board low power features.

* Update the GPS UART port pointer
2024-08-13 06:30:35 -05:00
GUVWAF
f97ae52263 STM32WL improvements (#4449)
* STM32WL: Enable DeviceTelemetry

* Add long/short name user preference options

* Add new STM32WL-based hardware models
2024-08-12 20:31:45 -05:00
Jonathan Bennett
9bd293a941 Don't forget public_key.size in converting back 2024-08-12 16:20:07 -05:00
Jonathan Bennett
bc69621c3e Ungoober oldestBoring 2024-08-12 11:37:50 -05:00
Jonathan Bennett
2ee53d1500 Don't goober public_key in Userlite conversion 2024-08-12 11:27:05 -05:00
Jonathan Bennett
bee959150b Add logic to nodeDB to prefer evicting boring nodes (#4441) 2024-08-12 06:43:54 -05:00
Ben Loomis
c74bce9360 Detect UM600 as UC6580 (#4444) 2024-08-12 06:40:57 -05:00
Ben Meadors
48eee747da protos 2024-08-11 18:25:32 -05:00
Ben Meadors
a28f10e0c2 User to UserLite in NodeDB (#4438)
* User to UserLite in the nodedb

* Tronkdor the burninator
2024-08-11 17:22:11 -05:00
github-actions[bot]
6cd1882aaa [create-pull-request] automated change (#4439)
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
2024-08-11 17:22:01 -05:00
Jonathan Bennett
0bd17e6da6 Merge branch 'master' into 2.5-changes 2024-08-11 16:28:43 -05:00
Jonathan Bennett
9bc2224164 Exclude position packets from PKI (at least for now) 2024-08-11 14:18:33 -05:00
Jonathan Bennett
e1b4b226c9 Manual protobuf update 2024-08-11 14:12:20 -05:00
Tom Fifield
cf392a4c20 Address some FIXME comments (#4435)
* Address some FIXME comments

These comments have since been addressed by more modern code.
Remove them to reduce the clutter in the codebase.

* Remove 'dumb idea' from SimpleAllocator

4 year old code that was set never to run can probably be safely
deleted.
2024-08-11 07:06:38 -05:00
Jonathan Bennett
54a2e14e35 Add missed function rename. (Thanks VSCode) 2024-08-10 23:11:04 -05:00
Jonathan Bennett
1cfd5d12d2 Refactor platform cryptography, add tests 2024-08-10 22:38:05 -05:00
Jonathan Bennett
b573e0eacc Fix compile on STM32 2024-08-10 20:04:38 -05:00
Jonathan Bennett
8ca884bafd Add DH25519 unit test 2024-08-10 15:45:29 -05:00
Ben Meadors
864b793ce0 Merge branch 'master' into 2.5-changes 2024-08-10 13:45:52 -05:00
Jonathan Bennett
74afd13171 Re-implement PKI from #1509 (#4379)
* Re-implement PKI from #1509
co-authored-by: edinnen <ethanjdinnen@protonmail.com>

* Set the key lengnth to actually make PKI work.

* Remove unused variable and initialize keys to null

* move printBytes() to meshUtils

* Don't reset PKI key son reboot unless needed.

* Remove double encryption for PKI messages

* Cleanup encrypt logic

* Add the MESHTASTIC_EXCLUDE_PKI option, and set it for minimal builds. Required for STM32 targets for now.

* Use SHA-256 for PKI key hashing, and add MESHTASTIC_EXCLUDE_PKI_KEYGEN for STM32

* Fix a crash when node is null

* Don't send PKI encrypted packets while licensed

* use chIndex 8 for PKI

* Don't be so clever, that you corrupt incoming packets

* Pass on channel 8 for now

* Typo

* Lock keys once non-zero

* We in fact need 2 scratch buffers, to store the encrypted bytes, unencrypted bytes, and decoded protobuf.

* Lighter approach to retaining known key

* Attach the public key to PKI decrypted packets in device memory

* Turn PKI back off for STM32 :(

* Don't just memcp over a protobuf

* Don't PKI encrypt nodeinfo packets

* Add a bit more memory logging around nodeDB

* Use the proper macro to refer to NODENUM_BROADCAST

* Typo fix

* Don't PKI encrypt ROUTING (naks and acks)

* Adds SecurityConfig protobuf

* Add admin messages over PKI

* Disable PKI for the WIO-e5

* Add MINIMUM_SAFE_FREE_HEAP macro and set to safe 1.5k

* Add missed "has_security"

* Add the admin_channel_enabled option

* STM32 again

* add missed configuration.h at the top of files

* Add EXCLUDE_TZ and RTC

* Enable PKI build on STM32 once again

* Attempt 1 at moving PKI to aes-ccm

* Fix buffers for encrypt/decrypt

* Eliminate unused aes variable

* Add debugging lines

* Set hash to 0 for PKI

* Fix debug lines so they don't print pointers.

* logic fix and more debug

* Rather important typo

* Check for short packets before attempting decrypt

* Don't forget to give cryptoEngine the keys!

* Use the right scratch buffer

* Cleanup

* moar cleanups

* Minor hardening

* Remove some in-progress stuff

* Turn PKI back off on STM32

* Return false

* 2.5 protos

* Sync up protos

* Add initial cryptography test vector tests

* re-add MINIMUM_SAFE_FREE_HEAP

* Housekeeping and comment fixes

* Add explanatory comment about weak dh25519 keys

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-10 13:45:41 -05:00
Mictronics
8daebf80dd Fix warning: extra tokens at end of #endif directive. (#4432) 2024-08-10 12:32:52 -05:00
Ben Meadors
a767997cea Get in the trunk! 2024-08-10 08:57:37 -05:00
Ben Meadors
861f0b6769 Add ClientNotification hello world 2024-08-10 08:33:42 -05:00
Ben Meadors
2012a0ae1c Protos 2024-08-10 07:51:59 -05:00
Ben Meadors
3513d88794 Protobufs 2024-08-10 07:25:05 -05:00
GUVWAF
debf4b934f Fix for "has default channel" with empty channel name (#4430) 2024-08-09 15:26:22 -05:00
Ben Meadors
3878e025e4 Split factory reset into config and device variants (#4427)
* Split factory reset into config and device variants

* Trunk

* Default only in header
2024-08-09 08:38:29 -05:00
github-actions[bot]
3ab4bebdcb [create-pull-request] automated change (#4426)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-09 06:37:49 -05:00
Tom Fifield
e38aca3cba NimbleBluetooth.h is not required in MeshService. (#4419)
There are no calls to the functions defined in Nimble from this
class. See also older comment on line 8 about the dream to seperate
mesh and bluetooth :)
2024-08-09 06:35:42 -05:00
github-actions[bot]
d8bdb92efe [create-pull-request] automated change (#4409)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-09 06:35:26 -05:00
Jonathan Bennett
c6a9edf8c7 Move printBytes to meshUtils (#4424) 2024-08-09 01:43:13 -05:00
Jonathan Bennett
a7da3537e2 Adds MESHTASTIC_EXCLUDE_TZ option (#4423) 2024-08-09 00:52:31 -05:00
Ben Meadors
5b4530325f Short circuit while the probe code does not auto-detect 2024-08-08 20:53:26 -05:00
Tom Fifield
b498c0bfbf [WIP] Add support for Airoha AG3335 GPS (#4394)
* Add GPS detection code for Airoha AG3335

Airoha AG3335 is used in Seeed T-1000E Tracker

* Add support for Airoha AG3335

Airoha AG3335 is used in Seeed T-1000E Tracker. This adds
detection code, and code to configure its use.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-08 20:18:18 -05:00
Tom Fifield
02ae24b6fa Remove outdated comments (#4417)
These comments from four years ago no longer reflect how things
work.
2024-08-08 20:08:14 -05:00
Tilen Komel
5111bd703a Updted protobuf url (#4411) 2024-08-07 07:23:31 -05:00
Jonathan Bennett
789e8f02bf Add more exclude options to save program ram/flash (#4408)
* Add PowerFSM Exclude option

* Add TEXTMESSAGE module exclude option

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-06 18:48:55 -05:00
todd-herbert
92526fca23 "Scan and Select" input for Canned Messages (#4365)
* Add "Scan and Select" input method for canned messages

* Adapt canned message drawing if USE_EINK
* Indicate current selection with indent rather than inverse text
* Avoid large text on "sending" and delivery report pop-ups
* Fit SNR and RSSI details on screen

* Change hash function which detects changes in E-Ink images
The old function struggled to distingush between images on the canned-message frame, failing to update when scrolling between messages. No real justification for the new algorithm, other than "it works" and doesn't seem "too expensive". For context, this function runs once a second.

* Use canned messages (scan and select) by default with HT-VME213 and HT-VME290

* Guard for HAS_SCREEN
2024-08-06 17:16:56 -05:00
HarukiToreda
9ec7dbd695 Initial Support for Heltec VM-T190 (#4391)
Initial Support for Heltec VM-T190
2024-08-06 13:59:33 -05:00
geeksville
66c41e683d bug #4184: fix config file loss due to filesystem write errors (#4397)
* Use SafeFile for atomic file writing (with xor checksum readback)
* Write db.proto last because it could be the largest file on the FS (and less critical)
* Don't keep a tmp file around while writing db.proto (because too big to fit two files in the filesystem)
* generate a new critial fault if we encounter errors writing to flash
either CriticalErrorCode_FLASH_CORRUPTION_RECOVERABLE or CriticalErrorCode_FLASH_CORRUPTION_UNRECOVERABLE
(depending on if the second write attempt worked)
* reformat the filesystem if we detect it is corrupted (then rewrite our config files) (only on nrf52 - not sure
yet if we should bother on ESP32)
* If we have to format the FS, make sure to preserve the oem.proto if it exists

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-06 13:59:06 -05:00
geeksville
c1870f91fc Finish powermon/powerstress (#4230)
* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* powermon WIP (for https://github.com/meshtastic/firmware/issues/4136 )

* oops - mean't to mark the _dbg variant as an 'extra' board.

* powermon wip

* Make serial port on wio-sdk-wm1110 board work
By disabling the (inaccessible) adafruit USB

* Instrument (radiolib only for now) lora for powermon
per https://github.com/meshtastic/firmware/issues/4136

* powermon gps support
https://github.com/meshtastic/firmware/issues/4136

* Add CPU deep and light sleep powermon states
https://github.com/meshtastic/firmware/issues/4136

* Change the board/swversion bootstring so it is a new "structured" log msg.

* powermon wip

* add example script for getting esp S3 debugging working
Not yet used but I didn't want these nasty tricks to get lost yet.

* Add PowerMon reporting for screen and bluetooth pwr.

* make power.powermon_enables config setting work.

* update to latest protobufs

* fix bogus shellcheck warning

* make powermon optional (but default enabled because tiny and no runtime impact)

* tell vscode, if formatting, use whatever our trunk formatter wants
without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* add PowerStress module

* nrf52 arduino is built upon freertos, so let platformio debug it

* don't accidentally try to Segger ICE if we are using another ICE

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

* update to latest protobufs (needed for powermon goo)

* PowerStress WIP

* for #4154 and #4136 add concept of dependent gpios...
Which is currently only tested with the LED but eventually
will be used for shared GPIO/screen power rail enable
and LED forcing (which is a sanity check in the power stress
testing)

* fix linter warning

* Transformer is a better name for the LED input > operation > output classes

* PMW led changes to work on esp32-s3

* power stress improvements

* allow ble logrecords to be fetched either by NOTIFY or INDICATE ble types

This allows 'lossless' log reading.  If client has requested INDICATE
(rather than NOTIFY) each log record emitted via log() will have to fetched
by the client device before the meshtastic node can continue.

* Fix serious problem with nrf52 BLE logging.
When doing notifies of LogRecords it is important to use the
binary write routines - writing using the 'string' write won't work.
Because protobufs can contain \0 nuls inside of them which if being
parsed as a string will cause only a portion of the protobuf to be sent.
I noticed this because some log messages were not getting through.

* fix gpio transformer stuff to work correctly with LED_INVERTED

Thanks @todd-herbert for noticing this and the great stack trace.
The root cause was that I had accidentially shadowed outPin in a subclass
with an unneeded override.  It would break on any board that had inverted
LED power.

fixes
https://github.com/meshtastic/firmware/pull/4230#pullrequestreview-2217389099

* Support driving multiple output gpios from one input.

While investigating https://github.com/meshtastic/firmware/pull/4230#pullrequestreview-2217389099
I noticed in variant.h that there are now apparently newer TBEAMs than mine
that have _both_ a GPIO based power LED and the PMU based LED.  Add a splitter
so that we can drive two output GPIOs from one logical signal.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-06 12:35:54 -05:00
Tom Fifield
06eaf2ba5d Use sys.executable to refer to python. (#4402)
Thanks to @mrekin for testing the build on Windows.
The previous fix for this UF2 call did not work.
sys.executable should fix it.
2024-08-06 06:48:05 -05:00
github-actions[bot]
4a79a690db [create-pull-request] automated change (#4400)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-08-05 20:14:07 -05:00
Tom Fifield
1f458d6397 Make UF2 build command windows-friendly (#4399)
As reported by @mrekin, the previous changes to the platformio
custom build script may not work on windows. Change to use
python3 instead of a call to /usr/bin/env python3.
2024-08-05 19:25:47 -05:00
geeksville
02231fd487 fix minor type comparison warning that I saw in the build (#4398) 2024-08-05 17:07:43 -05:00
Tom Fifield
66a4632f34 Fix python call in UF2 generation. (#4392)
The call to generate UF2 files in the platformio custom script was
a bare call to python. In some environments, this command won't
exist in this way. Instead, use the standard env approach to find
the right python.

Additionally, add the shebang line on line 1 so this script can be
executed standalone if needed.
2024-08-05 10:00:52 -05:00
Tom Fifield
e509a91019 Fix UC6580 ifdefs (#4393)
meshtastic/firmware#4319 added autodetect code for UC6580, and
removed these ifdefs. However, they were inadvertantly re-added
by #4328 .
2024-08-05 10:00:32 -05:00
geeksville
d8f3c3324c Make lora radio reset reliable on wio-tracker-1100 and lower lr11x0 power consumption in sleep (#4383)
* Fix wio-tracker-1110 lora radio reset GPIO assignment
This fixes flaky lora radio init on this board.

* No need to keep lr11x0 radio config during sleep anymore, also stop TCXO

I think the problem (at least on the board I'm using for power testing
a wio tracker 1110) was that actually the RESET GPIO was not correct for
the radio.  This led to the radio not being properly reinited after exiting
sleep mode.

Now that the GPIO is fixed I can enter deep sleep (fully shutting down
radio) and then later when the CPU resets, it can successfully init the
radio and send packets.

After this seeming success, I also turned off the TCXO during sleep and that
worked as well.
2024-08-05 06:47:04 -05:00
Max
9ddfc6de4c Commented RF95(1276) as no needed right now (#4386) 2024-08-05 06:02:54 -05:00
geeksville
1a38c4e51d Remove LED_INVERTED, see below for why ;-) (#4382)
While working on #4378 I noticed a funny problem: the blinking system
LED was on during deep-sleep.  Initially I thought it was some weird
sleep hw config thing but it turns out it was easier but more pervasive.

We had two different preprocessor symbols which both meant approximately the same
thing LED_INVERTED and LED_STATE_ON (though their polarity was opposite).
Some variant files were setting one, others were setting the other, and others were
setting both. heh.

In the case of the board I was testing (seeed tracker wio 1100) it was only setting one
and the default behavior for the other (for all boards) was incorrect.  So I did a grep
and it seems like LED_STATE_ON was used more often, so I kept that one and removed
LED_INVERTED everywhere.
2024-08-05 06:02:32 -05:00
Mark Trevor Birss
40d6b99911 Add Minewsemi LR1110+nRF52840-ME25LS01 [both 4.2inch e-ink and non e-ink varaint] (#4387)
* Add files via upload

* Update EInkDisplay2.cpp

* Add files via upload

* Update platformio.ini

* Update platformio.ini

* Update platformio.ini

* Update platformio.ini
2024-08-05 05:59:57 -05:00
Jonathan Bennett
7d00e1cef9 Output more useful log message when the NodeDB is full (#4389) 2024-08-04 18:52:10 -05:00
Ken Piper
5bbafdfd31 Configure pin modes of selected pins before attempting to write to them (#4385) 2024-08-04 06:06:36 -05:00
Jonathan Bennett
5453c495e2 Actually set the rand() seed for Portduino (#4380) 2024-08-03 13:12:22 -05:00
geeksville
d1ff160256 Generalize SWD debugging stuff so it works on all nrf52 targets. (#4377)
* add bootloader install script for wio tracker 1110 board
Mostly for documentation purposes for future devs.

* Generalize nrf52 hw debugging support so it works on all nrf52 targets
2024-08-03 07:41:35 -05:00
geeksville
dd552a99e1 fix #4367 make USB power detection work correctly on seeed trackers (#4376)
for wio tracker 1110 and 1000-E and possibly other nrf52 boards.
The problem was that nrf52 power stuff wasn't generating regular
powerstatus notifications (because that code was guarded by a batteryLevel
check which was null for those boards).  So I've cleaned up the battery status stuff
a bit and we now have fewer special cases.
Tested on a 1000-E, tracker 1110 and a rak4631 board.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-02 20:20:44 -05:00
geeksville
09ea198205 Automatically generate .uf2 files anytime we generate a .hex file for nrf52 (#4370)
* Automatically generate .uf2 files (which are often used by nrf52 bootloaders for installing
app loads) anytime we generate a new hex file.  This tool takes very little time to run and it is handy
for development

* Remove an old custom target I had tried to add to autogen uf2 files (that never worked)

Build output now looks like:

$ pio run --environment tracker-t1000-e
Processing tracker-t1000-e (board: tracker-t1000-e; platform: platformio/nordicnrf52@^10.5.0; framework: arduino)
...
Generating UF2 file
Converting to uf2, output size: 1395200, start address: 0x27000
Wrote 1395200 bytes to /home/kevinh/development/meshtastic/firmware/.pio/build/tracker-t1000-e/firmware.uf2
Building .pio/build/tracker-t1000-e/firmware.zip
Zip created at .pio/build/tracker-t1000-e/firmware.zip
=================================================================================== [SUCCESS] Took 9.33 seconds ===================================================================================

Environment      Status    Duration
---------------  --------  ------------
tracker-t1000-e  SUCCESS   00:00:09.327
=================================================================================== 1 succeeded in 00:00:09.327 ===================================================================================

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-02 18:55:04 -05:00
geeksville
703da1d8c7 Fix build to not use incorrect OneButton version (#4374)
* Fix build to not use incorrect OneButton version
OneButton pushed out a new update today that has a different API
rather than just use whichever new version they push, stay on 2.5.x until
someone sees a need to update.  Fixes build for wm1100 tracker.

* Update stm32.ini

* 2.6.1

* Try github tag instead?

* Update stm32.ini

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-08-02 18:28:04 -05:00
Tom Fifield
48c0635188 Remove OSTimer (#4373)
This code is not included anywhere, and none of the functions are
called by code elsewhere in meshtastic.
2024-08-02 10:10:55 -05:00
Tom Fifield
8db6039264 Remove empty file, StatusHandler.h (#4372)
Was added 4 years ago, never used/modified.
2024-08-02 06:32:28 -05:00
todd-herbert
4b4c1669a9 Initial support for HT-VME290, sleep fixes for HT-VME213 (#4334)
* Fix I2C pindefs

* Initial driver testing for HT-VME290

* E-Ink full refresh after canned message pop up

* Tidy variant folders

* Clean ESP32 cpuDeepSleep method
Merge sections, and remove the random assortment of gpio holds left behind.

* Enable 32kHz in variant.h

* Orient E290 with LoRa antenna facing up

* Revert "Clean ESP32 cpuDeepSleep method"

This reverts commit cb8ee508ec2d6bc27a8e228021fd1efbd034c4a0.

* Reduce deep-sleep current for VME213 (non-intrusive)
Originally I made an attempt at tidying up the cpuDeepSleep method, but have reverted that. New commit makes only the changes needed to support VME213. Don't really want the headache of breaking sleep for other variants, especially when this PR is just about implementing new boards.

* Update lib_deps; remove board_level extra
2024-08-02 14:03:59 +12:00
Jonathan Bennett
d2ea430a3e Make SPI frequency and TOPHONE queue size configurable on Native (#4369)
* Make SPI frequency configurable on Native

* Make the tophone queue size configurable for Portduino

* The modified SPISettings must be configured in setup(), after config.yaml is processed

* make MeshService a pointer, so we can configure MAX_RX_TOPHONE at run time

* Got a little over excited with refactoring

* Silence a warning
2024-08-01 19:29:49 -05:00
Michael Gjelsø
4c1c5b070e Changed a RADIOMASTER_900_BANDIT_NANO to DISPLAY_FLIP_SCREEN (#4366)
* More compatible

Changed a RADIOMASTER_900_BANDIT_NANO to DISPLAY_FLIP_SCREEN that is responsible for flipping the OLED screen for better compatible with other devices.

* Update variant.h Radiomaster 

Remove a un-used SCREEN_ROTATE and added DISPLAY_FLIP_SCREEN
2024-08-01 11:53:38 -05:00
Ben Meadors
bcdda4de8a Missed some includes of userPrefs that would allow behavior we don't want 2024-07-31 08:53:59 -05:00
Ben Meadors
24ecfa1a45 Trunk fmt 2024-07-31 07:42:23 -05:00
Sylvain Migaud
106a50bce2 Adding support for Chatter keypad (#4022)
* Adding support for Chatter keypad

* Remove user button mapping since full keypad is now useable

* Adding TAB key and RIGHT to allow selecting a destination

* Fix shift bug (there's only three levels, not four)

* reformat file

* Fix bug with fast repeated keypresses

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-31 07:38:21 -05:00
Tom Fifield
103ab0c242 Cleanup - remove unused defines. (#4353)
* Cleanup - remove unused defines.

There were a number of defined variables that were carried over
from old code. - Removed.
Also a typo. - Fixed fix.
Also duplicate definitions of the number of seconds in a day.
-deduplicated.

* Cleanup - remove unused defines.

There were a number of defined variables that were carried over
from old code. - Removed.
Also a typo. - Fixed fix.
Also duplicate definitions of the number of seconds in a day.
-deduplicated.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-31 06:56:06 -05:00
Alexander Smyslov
848b9773b9 Add trackerd to build. (#4347)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-31 05:58:41 -05:00
Tom Fifield
ce1eb149ac Cleanup for Air530z GPS (#4344)
It turns out that the Air530z is a GNSS_MODEL_MTK. Our existing
code detects and configures it properly. This patch removes a
couple of AIROHA ifdefs since they are not required for a
working GPS.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-31 05:58:19 -05:00
Ben Meadors
29fe6e7448 Event mode: Block problematic portnums of traffic (#4362) 2024-07-31 05:52:17 -05:00
Oliver0804
a111f54b61 Add #define USE_SSD1306 to avoid automatic detection causing pixel shift. (#4356)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-30 17:15:50 -05:00
Tom Fifield
9f5f630dca Remove unused define in NRF52 architecture (#4350)
The NRF52 architecture defaulted to setting GPS_UBLOX.
However, GPS_UBLOX is not used anywhere in the code.

Remove these lines.
2024-07-30 15:57:31 -05:00
Tom Fifield
1f9dacf486 Add support for ATGM332D series (#4351)
Adds detection code for the ATGM332D series of chips (11, 21, 31,
51, 71), and sets meshtastic to use GNSS_MODEL_ATGM336H for them.
2024-07-30 15:57:13 -05:00
Ben Meadors
5dde738a31 Trunk 2024-07-30 15:08:38 -05:00
Michael Gjelsø
1951569b1a PA FAN Disable (#4355)
* PA FAN Disable

* PA FAN Disable

* Trunk

* Trunk

* Trunk

* Thunk .....
2024-07-30 15:05:51 -05:00
Ben Meadors
93ba19d1e1 Make LogRecord protobuf serial logging over Phone API opt-in instead (#4358)
* Make LogRecord protobuf serial logging over Phone API opt-in instead of enabled by default

* debug_log_enabled
2024-07-30 15:05:33 -05:00
github-actions[bot]
a1c998e7e0 [create-pull-request] automated change (#4361)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-30 14:57:24 -05:00
github-actions[bot]
302caa854a [create-pull-request] automated change (#4354)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-30 09:13:25 -05:00
Ben Meadors
59cc57fc29 Event mode: Enforce reliable hop limit and disallow default public MQTT (#4343)
* Event mode: Enforce reliable hop limit

* Event mode: Short circuit wantsLink on MQTT for default broker address

* Just enforce at channels level since everything uses this

* For events never forward packets with excessive hop_limit

* In EVENT_MODE, don't respond with hop_limit set more then the configured max.

* Correct hop_start when correcting hop_limit in event mode.

* Make EVENT_MODE work from userPrefs.h

* Event mode: Disallow Router or Repeater roles

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-07-29 20:16:47 -05:00
Ben Meadors
6813b8e4e9 Just literally trying stuff at this point 2024-07-29 06:52:14 -05:00
Ben Meadors
4aa6f60e95 Maybe remove pip cache 2024-07-29 06:41:26 -05:00
Ben Meadors
2ffc93324d After 2024-07-29 06:38:34 -05:00
Ben Meadors
c501cc501d Pip pip cheerios plz 2024-07-29 06:37:19 -05:00
Ben Meadors
8c0ff89972 Trunk 2024-07-29 06:14:32 -05:00
Ben Meadors
cf22b7ff04 Latest pip version of setuptools is broken. Install specific version 2024-07-29 06:11:08 -05:00
Ben Meadors
811a9ae261 Macro to trace log all MeshPackets as JSON (#4336)
* Macro to trace log all MeshPackets as JSON

* Comment

* Add trace logging to file for native target

* bytes to hex

* Add time_ms

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-07-28 19:49:10 -05:00
github-actions[bot]
8b0208d1c6 [create-pull-request] automated change (#4335)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-28 14:53:25 -05:00
Jonathan Bennett
1a1d545c38 Adds a userPrefs.h file, default blank, used for default settings for custom builds (#4325)
* add a userPrefs.h file, default blank, which can be used to easily set defaults on custom builds.

* Add Splash Screen to userPrefs

* Add channel 0 defaults to userPrefs.h

* CONFIG_LORA_IGNORE_MQTT_DEFAULT

* Unify naming for USERPREFS defines

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-28 14:12:30 -05:00
Ben Meadors
32bc2f1137 Add RAK3172 to the STM32WL canon 2024-07-27 09:38:28 -05:00
Ben Meadors
1b249c32bf Copy the actual bin 2024-07-27 07:28:11 -05:00
Ben Meadors
bca9fbe7e4 Missed a needs 2024-07-27 06:49:50 -05:00
Ben Meadors
e70435ebd7 All builds need to only pkg update for their target environment 2024-07-27 06:49:11 -05:00
Ben Meadors
f583837b4e Enable STM32 build (#4339)
* Enable stm32 builds and wio-e5 board

* Chmod
2024-07-27 06:39:16 -05:00
Max
6f235232f0 Added RF95 SX1268 support (#4338) 2024-07-27 05:58:55 -05:00
Nestpebble
8641777bac Add the UF2 conversion script to the p.io task menu (#4337)
* Add the UF2 conversion script to the p.io task menu

Update platformio-custom.py to include the UF2 conversion script as a project task. Saves you dropping into the command line every time.

Tested on Windows only...

* Forgot the build target...
2024-07-26 20:14:31 -05:00
Ben Meadors
4ee15d8128 Trunk 2024-07-26 06:38:54 -05:00
Ben Meadors
394e0e1b3e T1000_E hw model 2024-07-26 06:30:28 -05:00
github-actions[bot]
755952c261 [create-pull-request] automated change (#4333)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-26 06:29:05 -05:00
Ben Meadors
f645ae943d JSON serialization refactor (#4331) 2024-07-25 20:50:42 -05:00
Thomas Göttgens
4b0bbb8af1 Make STM compile again and update toolchain. (#2960)
* Make STM compile again and update toolchain. The binary is too big for the flash. WIP

* Making progress with OSFS, still WIP

* more progress, still too big. Adding RAK3172 to the equasion

* Make STM compile again and update toolchain. The binary is too big for the flash. WIP

* Making progress with OSFS, still WIP

* more progress, still too big. Adding RAK3172 to the equasion

* still too big

* minimize build

* trunk fmt

* fix a couple of symbol clashes

* trunk fmt

* down to 101% with a release vs. debug build and omitting the flash strings

* fix compilation

* fix compilation once more

* update protobufs linkage

* - Toolchain updated
- Fixed macro error

* silence compiler warning
note: do something about this assert...

* new toolkit and fix Power.cpp

* STM32WL make it fit (#4330)

* Add option to exclude I2C parts

The I2C hals and related code uses a significant amount of flash space and aren't required for a basic node.

* Add option to disable Admin and NodeInfo modules

Disabled by default in minimal build. This saves a significant amount of flash

* Disable unused hals

These use up significant flash

* Add float support for printf for debugging

Makes serial look nice for debugging

* This breaks my build for some reason

* These build flags can save a bit of flash

* Don't disable NodeInfo and Admin modules in minimal build

They fit in flash

* Don't include printf float support by default

Only useful for debugging

---------

Co-authored-by: Adam Lawson <dev@goshawk22.uk>

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Adam Lawson <dev@goshawk22.uk>
2024-07-25 20:16:21 -05:00
Ben Meadors
7ac64bd762 Trunk 2024-07-25 13:09:28 -05:00
Mark Trevor Birss
1481ce987e Fix T1000-E GPS - some changes went missing from #4303? (#4328)
* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp

* Update GPS.cpp
2024-07-25 13:05:03 -05:00
Ben Meadors
c5f2d2736d Whitespace trunk grousing 2024-07-24 21:14:58 -05:00
dylanli
a000a8d347 Support Seeed Tracker-T1000-E (#4303)
* feature-T1000-E: add Added the board definition for T1000-E

-  integrate a script for rapid dependency download that is compatible with both Linux and Windows platforms.
-  add the pin definitions for UART, SPI, GPIO, and other peripherals have been ensured to be correct.
-  add the env configuration for PlatformIO.

* refact-T1000-E: redefine T1000-E board

* feature-T1000-E: add basic sensors

* feature-T1000-E: add button init

* feat: add DRADIOLIB_GODMODE defination for use function setDioAsRfSwitch to DIO LORA RF

* feat : add gps(GNSS_Airoha) sleep mode

* feat: add behavier when rec or send message

* chore: hang IIC bus usage to avoid sensor address conflict

* feat: add sensor data acquisition

* feat : support Airoha GPS

- add disable it in FSM
- update  lookForTime and lookForLocation function

* fix: fix a bug

* version: change version to 0.9.0

* Update tracker-t1000-e.json

Remove a space

* Delete variants/tracker-t1000-e/run_once.sh

Delete not need as we will change platformio.ini

* Update platformio.ini

Update SoftDevice 7.3.0 usage in line with other lr1110 targets

Do we need to keep GODMODE ?

* fix: Button behavier incorrect bug

* fix:remove some invaild code of TextMessageModule

* fix: remove invaild comment

* version: change version to 0.9.1

- update mark's patch
- remove some invaild code and comments
- fix button behavier

* trunk format

* fix:  HELTEC_CAPSULE_SENSOR_V3 block got accidentally deleted

* fix: EnvironmentTelemetry upstream merge went awry.

* fix: Added macro definitions to ensure correct operation of LORA section

* fix :GNSS_AIROHA macro defination in line with others

* fix: upstream backmerge accidentally.

* fix: wrap macro PIN_3V3_EN BUZZER_EN_PIN GNSS_AIROHA in the TRACKER_T1000_E macro guard

---------

Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-07-24 21:10:38 -05:00
Ben Meadors
01e089fd07 Ignore invalid service envelopes (#4326) 2024-07-24 08:23:04 -05:00
Jonathan Bennett
300c3d32aa Just a bit of security hygiene. (#4313)
* Make sure to call randomSeed() on esp32

* Randomize the top 22 bits of the Message ID

* Make it clear that we are not calling randomSeed() on purpose

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-23 11:52:14 -05:00
Max
e27375d331 Set PIN_3V3_EN to HIGH (nrf52_promicro_diy variants) (#4321)
* Update variant.cpp

PIN 3v3 to HIGH

* Update variant.cpp

* Trunk fmt
2024-07-23 09:13:58 -05:00
Ben Meadors
1d3ac57943 Fix type (#4323) 2024-07-23 08:35:01 -05:00
Tom Fifield
316928deb0 Cleanup GPS, add UC6580 autodetect (#4319)
* Cleanup GPS, add UC6580 autodetect

Our GPS code autodetects devices by default. Previously UC6580 was
statically assigned, and had its own baudrate configuration inside
the GPS code.

This change adds autodetect functionality for the UC6580 and moves
any 'special' GPS baud rate requirements for a variant out into the
variant configuration. Thereby cleaning up core GPS code a little,
saving the whales, and curing global warming.

New Functionality:
* If GPS_BAUDRATE is defined in variant.h, GPS autodetection will
try that baudrate first.
* UC6580 GPS chips are now automatically detected

* Only run speedSelect skip the first time

* Cleanup GPS, add UC6580 autodetect

Our GPS code autodetects devices by default. Previously UC6580 was
statically assigned, and had its own baudrate configuration inside
the GPS code.

This change adds autodetect functionality for the UC6580 and moves
any 'special' GPS baud rate requirements for a variant out into the
variant configuration. Thereby cleaning up core GPS code a little,
saving the whales, and curing global warming.

New Functionality:
* If GPS_BAUDRATE is defined in variant.h, GPS autodetection will
try that baudrate first.
* UC6580 GPS chips are now automatically detected

* Cleanup GPS, add UC6580 autodetect

Our GPS code autodetects devices by default. Previously UC6580 was
statically assigned, and had its own baudrate configuration inside
the GPS code.

This change adds autodetect functionality for the UC6580 and moves
any 'special' GPS baud rate requirements for a variant out into the
variant configuration. Thereby cleaning up core GPS code a little,
saving the whales, and curing global warming.

New Functionality:
* If GPS_BAUDRATE is defined in variant.h, GPS autodetection will
try that baudrate first.
* UC6580 GPS chips are now automatically detected

* Remove Airoha baud rate code

It's no longer needed.
2024-07-23 06:18:27 -05:00
Ben Meadors
0d2a9b6282 Fix de/compression buffer overflows in TAK packets (#4317)
* Fix de/compression buffer overflows in TAK packets

* Log message
2024-07-23 06:16:53 -05:00
Thomas Göttgens
6e648b9b77 Merge pull request #4148 from meshtastic/wio-lr1110-refresh
Moar LR1110 Targets
2024-07-22 22:35:59 +02:00
Thomas Göttgens
d8fd3f615d meesa jinxed it 2024-07-22 22:35:39 +02:00
Thomas Göttgens
7568a35372 fix build and probably break GPS 2024-07-22 17:09:46 +02:00
Thomas Göttgens
50238fbaf5 Merge branch 'master' into wio-lr1110-refresh 2024-07-22 17:03:09 +02:00
github-actions[bot]
646f5ad262 [create-pull-request] automated change (#4316)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-22 09:34:19 -05:00
Thomas Göttgens
2248ac51be Merge branch 'wio-lr1110-refresh' of https://github.com/meshtastic/firmware into wio-lr1110-refresh 2024-07-22 15:46:31 +02:00
Thomas Göttgens
5781149f88 *sigh* 2024-07-22 15:46:15 +02:00
Thomas Göttgens
8bd74588ce bring back changes from #4248 2024-07-22 15:42:46 +02:00
Thomas Göttgens
94a10e011c Merge branch 'master' into wio-lr1110-refresh 2024-07-22 15:37:34 +02:00
Thomas Göttgens
bdd1c53072 Revert "Sync Wio lr1110 refresh with master (#4288)"
This reverts commit 5cc8ca59a3.

Revert "Sync Wio lr1110 refresh with master (#4251)"

This reverts commit d97e6b86b8.

Revert "update SD_FLASH_SIZE to 0x27000 (#4232)"

This reverts commit 2df8093fef.
2024-07-22 15:30:36 +02:00
Lennart Buhl
1123223058 Fix a typo in src/mesh/MeshService.h (#4314) 2024-07-22 06:58:24 -05:00
Tavis
fa6624548b Serial Mode for Ecowitt WS85 weather station. (#4296)
* protobufs

* initial mods, not tested

* manual telem packet creation, compiles.

* add gust and lull computation

* telem packet is getting fired off

* new pb ?

* pb and gust lull

* need to set the variant type for it to work.

* add gust and lull to mqtt json output.

* parse bat voltage and cap voltage and send the larger of the two in telem packet

also use the new ws85 serial mode (6).  must set it with cli. : meshtastic --set serial.mode 6

* set hard coded average/transmit interval to 5 minutes.

* proper direction averging with trig.

* Update protobufs

* sweep some crud

* read in 512 bytes at a time and break and clear serial input if we got wind data

* factor out sendTelemetry function

* Revert "factor out sendTelemetry function"

This reverts commit b61ba1a3c5.

* Reapply "factor out sendTelemetry function"

This reverts commit d0af9cfd7d.

* update protobufs

* put WS85 Serial2 is tcho and canaryone exclusion #ifdef

* include GeoCoord.h so dr-dev will compile.

* remove old TODO comment.

* breakout WS85 serial operation to it's own function called processWXSerial()

* canaryone and t-echo exclusion for Serial2

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-21 07:09:37 -05:00
Ben Meadors
dadf9234e5 Remove status topic (#4305) 2024-07-21 07:09:10 -05:00
Mictronics
f9d79964ef Remove duplicate code and fix error: #if with no expression (#4307)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

* Removed duplicate code.

* Fix error: #if with no expression

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-20 06:47:04 -05:00
todd-herbert
54df153e9e Wait for I2C power to stabilize on Heltec VME213; tidy variant folder (#4308)
* Tidy variant.h and pins_arduino.h (VME213)

* Wait for peripherals to stabilize after enabling I2C power
The 3.3V power for the I2C "quick link" connector is from Ve_3V3
2024-07-20 06:46:26 -05:00
github-actions[bot]
f25644e8cf [create-pull-request] automated change (#4287)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-18 06:13:03 -05:00
Ben Meadors
46d7b82ac1 Migrate to new defaults (#4294)
* Upgrade module config state version but don't blow everything away

* ModuleConfig version intervals roll forward

* Be specific about version migration criteria

* initModuleConfigIntervals fix

* Don't forget power!
2024-07-16 09:37:50 -05:00
Tom Fifield
9db3552e5a Remove softdevice folder from wio-sdk-wm1110 (#4295)
Recently, softdevice was moved to platform/nrf52. We missed
deleting this one.
2024-07-16 06:31:25 -05:00
Tom Fifield
0f5fdfbab7 Make mergehex executable. (#4290)
Previously, we used sudo and chmod to make mergehex executable in
our build script. This change attempts to set the executable bit
using git properties and remove the dependence on elevated
permissions.
2024-07-15 07:11:37 -05:00
Ben Meadors
a04de8c6b3 Add PaxCounter to the mix 2024-07-14 06:27:16 -05:00
Tom Fifield
5cc8ca59a3 Sync Wio lr1110 refresh with master (#4288)
* Fix protobuf structs handling (#4140)

* Fix protobuf structs handling

* Log instead of assert

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* BLE based logging (#4146)

* WIP log characteristic

* Bluetooth logging plumbing

* Characteristic

* Callback

* Check for nullptr

* Esp32 bluetooth impl

* Formatting

* Add thread name and log level

* Add settings guard

* Remove comments

* Field name

* Fixes esp32

* Open it up

* Whoops

* Move va_end past our logic

* Use `upload_protocol = esptool` as with the other heltec devices instead of `esp-builtin` (#4151)

* Standardize lat/lon position logs (#4156)

* Standardize lat/lon position logs

* Missed sone and condensed logs

* [create-pull-request] automated change (#4157)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Pause BLE logging during want_config flow (#4162)

* Update NimBLE to 1.4.2 (#4163)

* Implement replies for all telemetry types based on variant tag (#4164)

* Implement replies for all telemetry types based on variant tag

* Remove check for `ignoreRequest`: modules can set this, don't need to check

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Esptool is better

* Explicitly set characteristic

* fix INA3221 sensor (#4168)

- pass wire to begin()
- remove redundant setAddr() (already set in header)

* Show compass on waypoint frame; clear when waypoint deleted (#4116)

* Clear expired or deleted waypoint frame

* Return 0 to CallbackObserver

* Add a missing comment

* Draw compass for waypoint frame

* Display our own waypoints

* [create-pull-request] automated change (#4171)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Add semihosting support for nrf52 devices (#4137)

* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* fix my botched merge - keep board_level = extra flag for rak3631_dbg

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* [create-pull-request] automated change (#4174)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Display alerts (#4170)

* Move static functions into Screen.h, show compass during calibration

* Move to _fontHeight macro to avoid collision

* Move some alert functions to new alert handler

* Catch missed reboot code

* ESP32 fixes

* Bump esp8266-oled-ssd1306

* Fixes for when a device has no screen

* Use new startAlert(char*) helper class

* Add EINK bits back to alert handling

* Add noop class for no-display devices

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Send file system manifest up on want_config (#4176)

* Send file system manifest up on want_config

* Platform specific methods

* Helps to actually make the change

* Clear

* tell vscode, if formatting, use whatever our trunk formatter wants (#4186)

without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* fix the build - would loop forever if there were no files to send (#4188)

* Show owner.short_name on boot (and E-Ink sleep screen) (#4134)

* Show owner.short_name on boot and sleep screen (on e-ink)

* Update Screen.cpp - new line for short_name

Boot screen short_name now below the region setting.
Looks better on small screens.

* Draw short_name on right

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* nrf52 soft device will watchdog if you use ICE while BT on... (#4189)

so have debugger disable bluetooth.

* correct xiao_ble build preventing sx1262 init (#4191)

* Force a compile time failur if FromRadio or ToRadio get larger than (#4190)

a BLE packet size. We are actually very close to this threshold so
important to make sure we don't accidentally pass it.

* Clear vector after complete config state (#4194)

* Clear after complete config

* Don't collect . entries

* Log file name and size

* [create-pull-request] automated change (#4200)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Make the logs Colorful! (#4199)

* Squash needlessly static functions (#4183)

* Trim extra vprintf and filter for unprintable characters

* Deprecate Router Client role (and make it Client) (#4201)

* [create-pull-request] automated change (#4205)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Move waypoint (#4202)

* Move waypoint screen draw into the waypoint module

* Get the observer set up for the waypoint screen draw

* Static squashing: screen dimensions
Macros moved back to Screen.cpp, as a band-aid until we eventually move all those static functions into the Screen class.

* Move getCompassDiam into Screen class
(supress compiler warnings)
At this stage, the method is still static, because it's used by drawNodeInfo, which has no tidy reference to our screen instance.
This is probably just another band-aid until these static functions all move.

* Use new getCompassDiam function in AccelerometerThread

* Properly gate display code in WaypointModule

---------

Co-authored-by: Todd Herbert <herbert.todd@gmail.com>

* Fix flakey phone api transition from file manifest to complete (#4209)

* Try fix flakey phone api transition from file manifest to complete

* Skip

* enable colors in platformio serial monitor (#4217)

* When talking via serial, encapsulate log messages in protobufs if necessary (#4187)

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* [create-pull-request] automated change (#4218)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Fix SHT41 support (#4222)

* Add SHT41 Serial to I2c Detection Code

On the Seeed Wio-WM1110 Dev Kit board, the SHT41 chip was being
incorrectly detected as SHT31.

This patch adds the necessary serial number for the SHT41 chip to
be correctly detected.

fixes meshtastic/firmware#4221

* Add missing sensor read for SHT41

* Typo fix in logs - mhz - MHz (#4225)

As reported by karamo, a few different places in our logs had
incorrect capitalization of MHz.

fixes meshtastic/firmware#4126

* New new BLE logging characteristic with LogRecord protos  (#4220)

* New UUID

* New log radio characteristic with LogRecord protobuf

* LogRecord

* Merge derp

* How did you get there

* Trunk

* Fix length

* Remove assert

* minor cleanup proposal (#4169)

* MESHTASTIC_EXCLUDE_WIFI and HAS_WIFI cleanup...
Our code was checking HAS_WIFI and the new MESHTASTIC_EXCLUDE_WIFI
flags in various places (even though EXCLUDE_WIFI forces HAS_WIFI
to 0).  Instead just check HAS_WIFI, only use EXCLUDE_WIFI inside
configuration.h

* cleanup: use HAS_NETWORKING instead of HAS_WIFI || HAS_ETHERNET
We already had HAS_NETWORKING as flag in MQTT to mean 'we have
tcpip'.  Generallize that and move it into configuration.h so that
we can use it elsewhere.

* Use #pragma once, because supported by gcc and all modern compilers
instead of #ifdef DOTHFILE_H etc...

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>

* Add PowerMon support (#4155)

* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* powermon WIP (for https://github.com/meshtastic/firmware/issues/4136 )

* oops - mean't to mark the _dbg variant as an 'extra' board.

* powermon wip

* Make serial port on wio-sdk-wm1110 board work
By disabling the (inaccessible) adafruit USB

* Instrument (radiolib only for now) lora for powermon
per https://github.com/meshtastic/firmware/issues/4136

* powermon gps support
https://github.com/meshtastic/firmware/issues/4136

* Add CPU deep and light sleep powermon states
https://github.com/meshtastic/firmware/issues/4136

* Change the board/swversion bootstring so it is a new "structured" log msg.

* powermon wip

* add example script for getting esp S3 debugging working
Not yet used but I didn't want these nasty tricks to get lost yet.

* Add PowerMon reporting for screen and bluetooth pwr.

* make power.powermon_enables config setting work.

* update to latest protobufs

* fix bogus shellcheck warning

* make powermon optional (but default enabled because tiny and no runtime impact)

* tell vscode, if formatting, use whatever our trunk formatter wants
without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* add PowerStress module

* nrf52 arduino is built upon freertos, so let platformio debug it

* don't accidentally try to Segger ICE if we are using another ICE

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

* update to latest protobufs (needed for powermon goo)

* PowerStress WIP

* fix linter warning

* Cleanup buffer

* Merge hex for wm1110 target(s)

* Only sdk

* Sudo

* Fix exclude macros (#4233)

* fix MESHTASTIC_EXCLUDE_BLUETOOTH

* fix HAS_SCREEN=0

* fix MESHTASTIC_EXCLUDE_GPS

* fix typo in build-nrf52.sh (#4231)

chmod is the command, '+x' is the argument.

* Tidy Wireless Paper variant files (#4238)

* Quick tidy of pins_arduino.h
Matches requests made at https://github.com/meshtastic/firmware/pull/4226#discussion_r1664183480)

* Tidy variant.h

* Change deprecated ADC attenuation parameter
From 11dB to 12dB. Resolves compiler warning. Allegly, no impact on function: `This is deprecated, it behaves the same as `ADC_ATTEN_DB_12`

* Updated raspbian CI to update apt repository ahead of libbluetooth. (#4243)

* Fix BLE logging on nrf52 (#4244)

* allow ble logrecords to be fetched either by NOTIFY or INDICATE ble types

This allows 'lossless' log reading.  If client has requested INDICATE
(rather than NOTIFY) each log record emitted via log() will have to fetched
by the client device before the meshtastic node can continue.

* Fix serious problem with nrf52 BLE logging.
When doing notifies of LogRecords it is important to use the
binary write routines - writing using the 'string' write won't work.
Because protobufs can contain \0 nuls inside of them which if being
parsed as a string will cause only a portion of the protobuf to be sent.
I noticed this because some log messages were not getting through.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Fix build when HAS_NETWORKING is false on nrf52 (#4237)

(tested on a rak4631 by setting HAS_ETHERNET false when shrinking
image)

* If `toPhoneQueue` is full, still increment `fromNum` to avoid client never getting packets (#4246)

* Update to SoftDevice 7.3.0 for wio-sdk-wm1110 and wio-tracker-wm1110 (#4248)

* Update variant.h

* Update wio-tracker-wm1110.json

* Update wio-sdk-wm1110.json

* Update platformio.ini

* Update platformio.ini

* Add files via upload

* Add files via upload

* Update variant.h

* Cleanup NRF s140 Softdevice variants (#4252)

Note: This idea is originally from @caveman99 and should be
credited as such. Submitting as a separate PR so the work in
meshtastic/firmware#4148 can be a bit cleaner and Seeed boards
can build while that work is ongoing.

The nrf52 boards that depend on the v7 softdevice all use the same
code and linker files. Rather than duplicate the code, keep it
all together with the platform.

* Remove tracker variant specific soft device headers (#4255)

* [create-pull-request] automated change (#4247)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Add wio-sdk-wm1110 to build. (#4258)

The wio-sdk-wm1110 is distinct from the wio-tracker-wm1110, with
different platformio build options and pin config.

This change adds the wio-sdk-wm1110 to the CI matrix so firmware
is built as part of release.

* fix python warning in uf2conf (#4235)

the old regex worked but was technically incorrect.  fixes:
Generating NRF52 uf2 file
/home/kevinh/development/meshtastic/firmware/bin/uf2conv.py:195: SyntaxWarning: invalid escape sequence '\s'
  words = re.split('\s+', line)
Converting to uf2, output size: 1458688, start address: 0x26000

* Collect hex files and specifically wm1110 sdk

* Skip dfu file for sdk (for now)

* Helps if you remove the original clause

* Add Heltec new boards. (#4226)

* Add Heltec new boards

* Update variant.h

disable RTC by default

* Add Heltec New boards

* Add Heltec new boards

* Update Heltec Mesh Node definition.

* Update Heltec Vision Mater E290

* [create-pull-request] automated change (#4259)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Trunk fmt

* Fix macros

* Move e290 to board level extra while CI is broken

* Tell trunk to ignore bin folder

* Fix missing

* Update trunk.yaml, fix whitespace

* Update trunk.yaml

* Update build_raspbian_armv7l.yml --fix-missing

* [create-pull-request] automated change (#4263)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* GPS Power State tidy-up  (#4161)

* Refactor GPSPowerState enum
Identifies a case where the GPS hardware is awake, but an update is not yet desired

* Change terminology

* Clear old lock-time prediction on triple press

* Use exponential smoothing to predict lock time

* Rename averageLockTime to predictedLockTime

* Attempt: Send PMREQ with duration 0 on MCU deep-sleep

* Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep

* Revert "Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 8b697cd2a4.

* Revert "Attempt: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 9d29ec7603.

* Remove unused notifyGPSSleep Observable
Handled with notifyDeepSleep, and enable() / disable()

* WIP: simplify GPS power management
An initial attempt only.

* Honor #3e9e0fd

* No-op when moving between GPS_IDLE and GPS_ACTIVE

* Ensure U-blox GPS is awake to receive indefinite sleep command

* Longer pause when waking U-blox to send sleep command

* Actually implement soft and hard sleep..

* Dynamically estimate the threshold for GPS_HARDSLEEP

* Fallback to GPS_HARDSLEEP, if GPS_SOFTSLEEP unsupported

* Move "excessive search time" behavior to scheduler class

* Minor logging adjustments

* Promote log to warning

* Gratuitous buffer clearing on boot

* Fix inverted standby pin logic
Specifically the standby pin for L76B, L76K and clones
Discovered during T-Echo testing: totally broken function, probe method failing.

* Remove redundant pin init
Now handled by setPowerState

* Replace max() with if statements
Avoid those platform specific implementations..

* Trunk formatting
New round of settings.json changes keep catching me out, have to remember to re-enable my "clang-format" for windows workaround.

* Remove some asserts from setPowerState
Original aim was to prevent sending a 0 second PMREQ to U-blox hardware as part of a timed sleep (GPS_HARDSLEEP, GPS_SOFTSLEEP). I'm not sure this is super important, and it feels tidier to just allow the 0 second sleeptime here, rather than fudge the sleeptime further up.

* Fix an error determining whether GPS_SOFTSLEEP is supported

* Clarify a log entry

* Set PIN_STANDBY for MCU deep-sleep
Required to reach TTGO's advertised 0.25mA sleep current for T-Echo. Without this change: ~6mA.

* Optimize the shutdown current of RAK10701 to around 25uA (#4260)

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>

* INA3221 sensor: use for bus voltage & environment metrics (#4215)

* use INA3221 for bus voltage; fixes for telemetry variants

- add to sensors available for environment telemetry
  (to report voltage/current)
- add vars to define channels to use for battery voltage
  (for getBusVoltage) and environment metrics (default
  to CH1 for both)
- write to the correct fields on the measurement struct
  depending on the measurement variant, and DRY up the
  sensor measurement collection code a bit
- this might be suitable for a common implementation for
  the INA* sensors in a future PR...

* formatting

* derp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* WM1110 SDK kit enter serial DFU and add deployment packages (#4266)

* Switch default upload protocol to nrfutil so that pio generates zip deploy packages

* Enter serial DFU on SDK board

* Remove guard for DFU zip from SDK build

* NRF_USE_SERIAL_DFU macro instead

* Show specific frame when updating screen (#4264)

* Updated setFrames in Screen.cpp

Added code to attempt to revert back to the same frame that user was on prior to setFrame reload.

* Space added Screen.cpp

* Update Screen.cpp

Make screen to revert to Frame 0 if the originally displayed frame is no longer there.

* Update Screen.cpp

Inserted boolean holdPosition into setFrames to indicate the requirement to stay on the same frame ( if =true) or else it will switch to new frame .
Only Screen::handleStatusUpdate calls with setFrame(true). ( For Node Updates)
All other types of updates call as before setFrame(), so it will change focus as needed.

* Hold position, even if number of frames increases

* Hold position, if handling an outgoing text message

* Update Screen.cpp

* Reverted chnages related to devicestate.has_rx_text_message

* Reset to master

* CannedMessages only handles routing packets when waiting for ACK
Previously, this was calling Screen::setFrames at unexpected times

* Gather position info about screen frames while regenerating

* Make admin module observable
Notify only when relevant. Currently: only to handle remove_nodenum.

* Optionally specify which frame to focus when setFrames runs

* UIFrameEvent uses enum instead of multiple booleans

* Allow modules to request their own frame to be focussed
This is done internally by calling MeshModule::requestFocus()
Easier this way, insteady of passing the info in the UIFrameEvent:
* Modules don't always know whether they should be focussed until after the UIFrameEvent has been raised, in dramFrame
* Don't have to pass reference to module instance as parameter though several methods

* E-Ink screensaver uses FOCUS_PRESERVE
Previously, it had its own basic implementation of this.

* Spelling: regional variant

* trunk

* Fix HAS_SCREEN guarding

* More HAS_SCREEN guarding

---------

Co-authored-by: BIST <77391720+slash-bit@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: slash-bit <v-b2@live.com>

* Move up telemetry defaults to every 30 minutes (#4274)

* Don't send node info interrogation when ch. util is >25% (#4273)

* Moar LR1110 Targets

* update SD_FLASH_SIZE to 0x27000 (#4232)

The 7.3.0 softdevice needs the extra 1000 :)

* Fix spacing.

---------

Co-authored-by: Mike <mikhael.skvortsov@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Mike G <mkgin@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Warren Guy <5602790+warrenguy@users.noreply.github.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: geeksville <kevinh@geeksville.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Alexander <156134901+Dorn8010@users.noreply.github.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: quimnut <github@dopegoat.com>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
Co-authored-by: Agent Blu, 006 <blu006@ucr.edu>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
Co-authored-by: Aaron.Lee <32860565+Heltec-Aaron-Lee@users.noreply.github.com>
Co-authored-by: Daniel.Cao <144674500+DanielCao0@users.noreply.github.com>
Co-authored-by: BIST <77391720+slash-bit@users.noreply.github.com>
Co-authored-by: slash-bit <v-b2@live.com>
2024-07-13 20:38:19 -05:00
todd-herbert
3fa8b357e5 Initial work for Heltec Vision Master 213 (#4286)
* Fix for serial monitoring and I2C for Vision Master e213 (#4280)

* Fix for serial monitoring and I2C

The board did not allow serial monitoring while on boot mode, i was able to fix this by adding a board variant. I also corrected the i2c pins. I was able to test it with a cardkb

* oops

I delete some code by mistake, all back now

* Made some adjustments

* Minimize the diff

---------

Co-authored-by: Todd Herbert <herbert.todd@gmail.com>

* Don't redefine board identifier
Suppresses compiler warnings

* Detect Vision Master 213 with PIO serial monitor

* Use outermost button as user-button
Less chance of accidentally hitting reset

* Use 1200bps touch (213)
Allows upload without manually entering bootloader

---------

Co-authored-by: HarukiToreda <116696711+HarukiToreda@users.noreply.github.com>
2024-07-13 17:36:07 -05:00
GUVWAF
9e4ce86c2a Let StoreForward server send history to phoneAPI (#4282)
* Send StoreForward history of the server to a connected client
To extend the ToPhoneQueue

* Add delay after sending history info

* Don't allow history request over LoRa on default channel

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-13 12:36:44 -05:00
Tom Fifield
141ae296b7 Add Seeed Wio WM1110 to Github issue template (#4283) 2024-07-13 06:47:38 -05:00
Lennart Buhl
ca2b45a6e2 Fix that Dockerfile would not run with podman (#4262)
* Fix that Dockerfile would not run with podman

* Migrate away from non-OCI-compliant SHELL command in Dockerfile
2024-07-13 06:09:51 -05:00
Ben Meadors
4286f2c2dd Minor version bump 2024-07-13 06:07:20 -05:00
Ben Meadors
c5d747cd3e Scale default intervals based for *online* mesh size past 40 nodes (#4277)
* Add congestion scaling coefficient

* Added active mesh sized based interval scaling

* Moved back to bottom

* Format

* Add observers and use correct number of online nodes
2024-07-13 05:59:19 -05:00
Ben Meadors
0fa9974518 Don't send node info interrogation when ch. util is >25% (#4273) 2024-07-12 11:48:35 -05:00
Ben Meadors
699d37b04c Move up telemetry defaults to every 30 minutes (#4274) 2024-07-12 09:24:42 -05:00
todd-herbert
eabec5ae34 Show specific frame when updating screen (#4264)
* Updated setFrames in Screen.cpp

Added code to attempt to revert back to the same frame that user was on prior to setFrame reload.

* Space added Screen.cpp

* Update Screen.cpp

Make screen to revert to Frame 0 if the originally displayed frame is no longer there.

* Update Screen.cpp

Inserted boolean holdPosition into setFrames to indicate the requirement to stay on the same frame ( if =true) or else it will switch to new frame .
Only Screen::handleStatusUpdate calls with setFrame(true). ( For Node Updates)
All other types of updates call as before setFrame(), so it will change focus as needed.

* Hold position, even if number of frames increases

* Hold position, if handling an outgoing text message

* Update Screen.cpp

* Reverted chnages related to devicestate.has_rx_text_message

* Reset to master

* CannedMessages only handles routing packets when waiting for ACK
Previously, this was calling Screen::setFrames at unexpected times

* Gather position info about screen frames while regenerating

* Make admin module observable
Notify only when relevant. Currently: only to handle remove_nodenum.

* Optionally specify which frame to focus when setFrames runs

* UIFrameEvent uses enum instead of multiple booleans

* Allow modules to request their own frame to be focussed
This is done internally by calling MeshModule::requestFocus()
Easier this way, insteady of passing the info in the UIFrameEvent:
* Modules don't always know whether they should be focussed until after the UIFrameEvent has been raised, in dramFrame
* Don't have to pass reference to module instance as parameter though several methods

* E-Ink screensaver uses FOCUS_PRESERVE
Previously, it had its own basic implementation of this.

* Spelling: regional variant

* trunk

* Fix HAS_SCREEN guarding

* More HAS_SCREEN guarding

---------

Co-authored-by: BIST <77391720+slash-bit@users.noreply.github.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: slash-bit <v-b2@live.com>
2024-07-11 18:51:26 -05:00
Ben Meadors
df194ca0f0 WM1110 SDK kit enter serial DFU and add deployment packages (#4266)
* Switch default upload protocol to nrfutil so that pio generates zip deploy packages

* Enter serial DFU on SDK board

* Remove guard for DFU zip from SDK build

* NRF_USE_SERIAL_DFU macro instead
2024-07-11 14:08:31 -05:00
Warren Guy
974fc31856 INA3221 sensor: use for bus voltage & environment metrics (#4215)
* use INA3221 for bus voltage; fixes for telemetry variants

- add to sensors available for environment telemetry
  (to report voltage/current)
- add vars to define channels to use for battery voltage
  (for getBusVoltage) and environment metrics (default
  to CH1 for both)
- write to the correct fields on the measurement struct
  depending on the measurement variant, and DRY up the
  sensor measurement collection code a bit
- this might be suitable for a common implementation for
  the INA* sensors in a future PR...

* formatting

* derp

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-11 08:34:55 -05:00
Daniel.Cao
e79a7dce07 Optimize the shutdown current of RAK10701 to around 25uA (#4260)
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-07-11 08:34:33 -05:00
todd-herbert
33831cd41c GPS Power State tidy-up (#4161)
* Refactor GPSPowerState enum
Identifies a case where the GPS hardware is awake, but an update is not yet desired

* Change terminology

* Clear old lock-time prediction on triple press

* Use exponential smoothing to predict lock time

* Rename averageLockTime to predictedLockTime

* Attempt: Send PMREQ with duration 0 on MCU deep-sleep

* Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep

* Revert "Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 8b697cd2a4.

* Revert "Attempt: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 9d29ec7603.

* Remove unused notifyGPSSleep Observable
Handled with notifyDeepSleep, and enable() / disable()

* WIP: simplify GPS power management
An initial attempt only.

* Honor #3e9e0fd

* No-op when moving between GPS_IDLE and GPS_ACTIVE

* Ensure U-blox GPS is awake to receive indefinite sleep command

* Longer pause when waking U-blox to send sleep command

* Actually implement soft and hard sleep..

* Dynamically estimate the threshold for GPS_HARDSLEEP

* Fallback to GPS_HARDSLEEP, if GPS_SOFTSLEEP unsupported

* Move "excessive search time" behavior to scheduler class

* Minor logging adjustments

* Promote log to warning

* Gratuitous buffer clearing on boot

* Fix inverted standby pin logic
Specifically the standby pin for L76B, L76K and clones
Discovered during T-Echo testing: totally broken function, probe method failing.

* Remove redundant pin init
Now handled by setPowerState

* Replace max() with if statements
Avoid those platform specific implementations..

* Trunk formatting
New round of settings.json changes keep catching me out, have to remember to re-enable my "clang-format" for windows workaround.

* Remove some asserts from setPowerState
Original aim was to prevent sending a 0 second PMREQ to U-blox hardware as part of a timed sleep (GPS_HARDSLEEP, GPS_SOFTSLEEP). I'm not sure this is super important, and it feels tidier to just allow the 0 second sleeptime here, rather than fudge the sleeptime further up.

* Fix an error determining whether GPS_SOFTSLEEP is supported

* Clarify a log entry

* Set PIN_STANDBY for MCU deep-sleep
Required to reach TTGO's advertised 0.25mA sleep current for T-Echo. Without this change: ~6mA.
2024-07-11 15:26:43 +12:00
github-actions[bot]
11bca437fd [create-pull-request] automated change (#4263)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-10 15:15:57 -05:00
Jonathan Bennett
e59e50af0e Update build_raspbian_armv7l.yml --fix-missing 2024-07-10 14:42:29 -05:00
Jonathan Bennett
51d54a7d99 Update trunk.yaml 2024-07-10 14:39:41 -05:00
Jonathan Bennett
17c2d60b78 Update trunk.yaml, fix whitespace 2024-07-10 12:47:34 -05:00
Ben Meadors
c887675bb4 Fix missing 2024-07-10 09:35:18 -05:00
Ben Meadors
5c71187db1 Tell trunk to ignore bin folder 2024-07-10 07:34:41 -05:00
Ben Meadors
8048fab084 Move e290 to board level extra while CI is broken 2024-07-10 07:28:29 -05:00
Ben Meadors
e74d77dc44 Fix macros 2024-07-09 15:11:11 -05:00
Ben Meadors
ba8d17b9c1 Trunk fmt 2024-07-09 12:16:56 -05:00
github-actions[bot]
9ad0addbbf [create-pull-request] automated change (#4259)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-09 12:07:23 -05:00
Aaron.Lee
1626667400 Add Heltec new boards. (#4226)
* Add Heltec new boards

* Update variant.h

disable RTC by default

* Add Heltec New boards

* Add Heltec new boards

* Update Heltec Mesh Node definition.

* Update Heltec Vision Mater E290
2024-07-09 11:56:57 -05:00
Ben Meadors
a3777e8f29 Helps if you remove the original clause 2024-07-09 09:23:59 -05:00
Ben Meadors
8b388d1e27 Skip dfu file for sdk (for now) 2024-07-09 09:12:23 -05:00
Ben Meadors
9f089746da Collect hex files and specifically wm1110 sdk 2024-07-09 08:31:16 -05:00
geeksville
33c46d6eb1 fix python warning in uf2conf (#4235)
the old regex worked but was technically incorrect.  fixes:
Generating NRF52 uf2 file
/home/kevinh/development/meshtastic/firmware/bin/uf2conv.py:195: SyntaxWarning: invalid escape sequence '\s'
  words = re.split('\s+', line)
Converting to uf2, output size: 1458688, start address: 0x26000
2024-07-09 07:19:03 -05:00
Tom Fifield
308060b1fe Add wio-sdk-wm1110 to build. (#4258)
The wio-sdk-wm1110 is distinct from the wio-tracker-wm1110, with
different platformio build options and pin config.

This change adds the wio-sdk-wm1110 to the CI matrix so firmware
is built as part of release.
2024-07-08 20:59:27 -05:00
github-actions[bot]
a664d4597f [create-pull-request] automated change (#4247)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-08 14:26:19 -05:00
Ben Meadors
2b9848bf1b Remove tracker variant specific soft device headers (#4255) 2024-07-08 08:16:38 -05:00
Tom Fifield
d97e6b86b8 Sync Wio lr1110 refresh with master (#4251)
* Fix protobuf structs handling (#4140)

* Fix protobuf structs handling

* Log instead of assert

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* BLE based logging (#4146)

* WIP log characteristic

* Bluetooth logging plumbing

* Characteristic

* Callback

* Check for nullptr

* Esp32 bluetooth impl

* Formatting

* Add thread name and log level

* Add settings guard

* Remove comments

* Field name

* Fixes esp32

* Open it up

* Whoops

* Move va_end past our logic

* Use `upload_protocol = esptool` as with the other heltec devices instead of `esp-builtin` (#4151)

* Standardize lat/lon position logs (#4156)

* Standardize lat/lon position logs

* Missed sone and condensed logs

* [create-pull-request] automated change (#4157)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Pause BLE logging during want_config flow (#4162)

* Update NimBLE to 1.4.2 (#4163)

* Implement replies for all telemetry types based on variant tag (#4164)

* Implement replies for all telemetry types based on variant tag

* Remove check for `ignoreRequest`: modules can set this, don't need to check

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Esptool is better

* Explicitly set characteristic

* fix INA3221 sensor (#4168)

- pass wire to begin()
- remove redundant setAddr() (already set in header)

* Show compass on waypoint frame; clear when waypoint deleted (#4116)

* Clear expired or deleted waypoint frame

* Return 0 to CallbackObserver

* Add a missing comment

* Draw compass for waypoint frame

* Display our own waypoints

* [create-pull-request] automated change (#4171)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Add semihosting support for nrf52 devices (#4137)

* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* fix my botched merge - keep board_level = extra flag for rak3631_dbg

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* [create-pull-request] automated change (#4174)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Display alerts (#4170)

* Move static functions into Screen.h, show compass during calibration

* Move to _fontHeight macro to avoid collision

* Move some alert functions to new alert handler

* Catch missed reboot code

* ESP32 fixes

* Bump esp8266-oled-ssd1306

* Fixes for when a device has no screen

* Use new startAlert(char*) helper class

* Add EINK bits back to alert handling

* Add noop class for no-display devices

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Send file system manifest up on want_config (#4176)

* Send file system manifest up on want_config

* Platform specific methods

* Helps to actually make the change

* Clear

* tell vscode, if formatting, use whatever our trunk formatter wants (#4186)

without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* fix the build - would loop forever if there were no files to send (#4188)

* Show owner.short_name on boot (and E-Ink sleep screen) (#4134)

* Show owner.short_name on boot and sleep screen (on e-ink)

* Update Screen.cpp - new line for short_name

Boot screen short_name now below the region setting.
Looks better on small screens.

* Draw short_name on right

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* nrf52 soft device will watchdog if you use ICE while BT on... (#4189)

so have debugger disable bluetooth.

* correct xiao_ble build preventing sx1262 init (#4191)

* Force a compile time failur if FromRadio or ToRadio get larger than (#4190)

a BLE packet size. We are actually very close to this threshold so
important to make sure we don't accidentally pass it.

* Clear vector after complete config state (#4194)

* Clear after complete config

* Don't collect . entries

* Log file name and size

* [create-pull-request] automated change (#4200)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Make the logs Colorful! (#4199)

* Squash needlessly static functions (#4183)

* Trim extra vprintf and filter for unprintable characters

* Deprecate Router Client role (and make it Client) (#4201)

* [create-pull-request] automated change (#4205)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Move waypoint (#4202)

* Move waypoint screen draw into the waypoint module

* Get the observer set up for the waypoint screen draw

* Static squashing: screen dimensions
Macros moved back to Screen.cpp, as a band-aid until we eventually move all those static functions into the Screen class.

* Move getCompassDiam into Screen class
(supress compiler warnings)
At this stage, the method is still static, because it's used by drawNodeInfo, which has no tidy reference to our screen instance.
This is probably just another band-aid until these static functions all move.

* Use new getCompassDiam function in AccelerometerThread

* Properly gate display code in WaypointModule

---------

Co-authored-by: Todd Herbert <herbert.todd@gmail.com>

* Fix flakey phone api transition from file manifest to complete (#4209)

* Try fix flakey phone api transition from file manifest to complete

* Skip

* enable colors in platformio serial monitor (#4217)

* When talking via serial, encapsulate log messages in protobufs if necessary (#4187)

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* [create-pull-request] automated change (#4218)

Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>

* Fix SHT41 support (#4222)

* Add SHT41 Serial to I2c Detection Code

On the Seeed Wio-WM1110 Dev Kit board, the SHT41 chip was being
incorrectly detected as SHT31.

This patch adds the necessary serial number for the SHT41 chip to
be correctly detected.

fixes meshtastic/firmware#4221

* Add missing sensor read for SHT41

* Typo fix in logs - mhz - MHz (#4225)

As reported by karamo, a few different places in our logs had
incorrect capitalization of MHz.

fixes meshtastic/firmware#4126

* New new BLE logging characteristic with LogRecord protos  (#4220)

* New UUID

* New log radio characteristic with LogRecord protobuf

* LogRecord

* Merge derp

* How did you get there

* Trunk

* Fix length

* Remove assert

* minor cleanup proposal (#4169)

* MESHTASTIC_EXCLUDE_WIFI and HAS_WIFI cleanup...
Our code was checking HAS_WIFI and the new MESHTASTIC_EXCLUDE_WIFI
flags in various places (even though EXCLUDE_WIFI forces HAS_WIFI
to 0).  Instead just check HAS_WIFI, only use EXCLUDE_WIFI inside
configuration.h

* cleanup: use HAS_NETWORKING instead of HAS_WIFI || HAS_ETHERNET
We already had HAS_NETWORKING as flag in MQTT to mean 'we have
tcpip'.  Generallize that and move it into configuration.h so that
we can use it elsewhere.

* Use #pragma once, because supported by gcc and all modern compilers
instead of #ifdef DOTHFILE_H etc...

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>

* Add PowerMon support (#4155)

* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* powermon WIP (for https://github.com/meshtastic/firmware/issues/4136 )

* oops - mean't to mark the _dbg variant as an 'extra' board.

* powermon wip

* Make serial port on wio-sdk-wm1110 board work
By disabling the (inaccessible) adafruit USB

* Instrument (radiolib only for now) lora for powermon
per https://github.com/meshtastic/firmware/issues/4136

* powermon gps support
https://github.com/meshtastic/firmware/issues/4136

* Add CPU deep and light sleep powermon states
https://github.com/meshtastic/firmware/issues/4136

* Change the board/swversion bootstring so it is a new "structured" log msg.

* powermon wip

* add example script for getting esp S3 debugging working
Not yet used but I didn't want these nasty tricks to get lost yet.

* Add PowerMon reporting for screen and bluetooth pwr.

* make power.powermon_enables config setting work.

* update to latest protobufs

* fix bogus shellcheck warning

* make powermon optional (but default enabled because tiny and no runtime impact)

* tell vscode, if formatting, use whatever our trunk formatter wants
without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* add PowerStress module

* nrf52 arduino is built upon freertos, so let platformio debug it

* don't accidentally try to Segger ICE if we are using another ICE

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

* update to latest protobufs (needed for powermon goo)

* PowerStress WIP

* fix linter warning

* Cleanup buffer

* Merge hex for wm1110 target(s)

* Only sdk

* Sudo

* Fix exclude macros (#4233)

* fix MESHTASTIC_EXCLUDE_BLUETOOTH

* fix HAS_SCREEN=0

* fix MESHTASTIC_EXCLUDE_GPS

* fix typo in build-nrf52.sh (#4231)

chmod is the command, '+x' is the argument.

* Tidy Wireless Paper variant files (#4238)

* Quick tidy of pins_arduino.h
Matches requests made at https://github.com/meshtastic/firmware/pull/4226#discussion_r1664183480)

* Tidy variant.h

* Change deprecated ADC attenuation parameter
From 11dB to 12dB. Resolves compiler warning. Allegly, no impact on function: `This is deprecated, it behaves the same as `ADC_ATTEN_DB_12`

* Updated raspbian CI to update apt repository ahead of libbluetooth. (#4243)

* Fix BLE logging on nrf52 (#4244)

* allow ble logrecords to be fetched either by NOTIFY or INDICATE ble types

This allows 'lossless' log reading.  If client has requested INDICATE
(rather than NOTIFY) each log record emitted via log() will have to fetched
by the client device before the meshtastic node can continue.

* Fix serious problem with nrf52 BLE logging.
When doing notifies of LogRecords it is important to use the
binary write routines - writing using the 'string' write won't work.
Because protobufs can contain \0 nuls inside of them which if being
parsed as a string will cause only a portion of the protobuf to be sent.
I noticed this because some log messages were not getting through.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>

* Fix build when HAS_NETWORKING is false on nrf52 (#4237)

(tested on a rak4631 by setting HAS_ETHERNET false when shrinking
image)

* If `toPhoneQueue` is full, still increment `fromNum` to avoid client never getting packets (#4246)

* Update to SoftDevice 7.3.0 for wio-sdk-wm1110 and wio-tracker-wm1110 (#4248)

* Update variant.h

* Update wio-tracker-wm1110.json

* Update wio-sdk-wm1110.json

* Update platformio.ini

* Update platformio.ini

* Add files via upload

* Add files via upload

* Update variant.h

---------

Co-authored-by: Mike <mikhael.skvortsov@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Mike G <mkgin@users.noreply.github.com>
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
Co-authored-by: GUVWAF <78759985+GUVWAF@users.noreply.github.com>
Co-authored-by: Warren Guy <5602790+warrenguy@users.noreply.github.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: geeksville <kevinh@geeksville.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Alexander <156134901+Dorn8010@users.noreply.github.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: quimnut <github@dopegoat.com>
Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
Co-authored-by: Agent Blu, 006 <blu006@ucr.edu>
Co-authored-by: Mark Trevor Birss <markbirss@gmail.com>
2024-07-08 06:03:23 -05:00
Tom Fifield
deb7c274c4 Cleanup NRF s140 Softdevice variants (#4252)
Note: This idea is originally from @caveman99 and should be
credited as such. Submitting as a separate PR so the work in
meshtastic/firmware#4148 can be a bit cleaner and Seeed boards
can build while that work is ongoing.

The nrf52 boards that depend on the v7 softdevice all use the same
code and linker files. Rather than duplicate the code, keep it
all together with the platform.
2024-07-08 06:02:05 -05:00
Mark Trevor Birss
e1bf4c32f3 Update to SoftDevice 7.3.0 for wio-sdk-wm1110 and wio-tracker-wm1110 (#4248)
* Update variant.h

* Update wio-tracker-wm1110.json

* Update wio-sdk-wm1110.json

* Update platformio.ini

* Update platformio.ini

* Add files via upload

* Add files via upload

* Update variant.h
2024-07-07 12:14:18 -05:00
GUVWAF
86ca81b555 If toPhoneQueue is full, still increment fromNum to avoid client never getting packets (#4246) 2024-07-07 09:06:42 -05:00
geeksville
f59d98482f Fix build when HAS_NETWORKING is false on nrf52 (#4237)
(tested on a rak4631 by setting HAS_ETHERNET false when shrinking
image)
2024-07-07 07:08:49 -05:00
geeksville
27dfe10689 Fix BLE logging on nrf52 (#4244)
* allow ble logrecords to be fetched either by NOTIFY or INDICATE ble types

This allows 'lossless' log reading.  If client has requested INDICATE
(rather than NOTIFY) each log record emitted via log() will have to fetched
by the client device before the meshtastic node can continue.

* Fix serious problem with nrf52 BLE logging.
When doing notifies of LogRecords it is important to use the
binary write routines - writing using the 'string' write won't work.
Because protobufs can contain \0 nuls inside of them which if being
parsed as a string will cause only a portion of the protobuf to be sent.
I noticed this because some log messages were not getting through.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-07-07 06:50:47 -05:00
Agent Blu, 006
7b838d388d Updated raspbian CI to update apt repository ahead of libbluetooth. (#4243) 2024-07-06 19:45:58 -05:00
todd-herbert
c3d3dfa8c8 Tidy Wireless Paper variant files (#4238)
* Quick tidy of pins_arduino.h
Matches requests made at https://github.com/meshtastic/firmware/pull/4226#discussion_r1664183480)

* Tidy variant.h

* Change deprecated ADC attenuation parameter
From 11dB to 12dB. Resolves compiler warning. Allegly, no impact on function: `This is deprecated, it behaves the same as `ADC_ATTEN_DB_12`
2024-07-06 12:41:29 -05:00
Tom Fifield
8be378c227 fix typo in build-nrf52.sh (#4231)
chmod is the command, '+x' is the argument.
2024-07-05 09:03:45 -05:00
Tom Fifield
2df8093fef update SD_FLASH_SIZE to 0x27000 (#4232)
The 7.3.0 softdevice needs the extra 1000 :)
2024-07-05 09:02:55 -05:00
Manuel
ae420dcd21 Fix exclude macros (#4233)
* fix MESHTASTIC_EXCLUDE_BLUETOOTH

* fix HAS_SCREEN=0

* fix MESHTASTIC_EXCLUDE_GPS
2024-07-05 08:58:16 -05:00
Ben Meadors
c1df621711 Sudo 2024-07-04 08:32:59 -05:00
Ben Meadors
2ba88d305f Only sdk 2024-07-04 08:29:49 -05:00
Ben Meadors
fc63d956e7 Merge hex for wm1110 target(s) 2024-07-04 08:10:40 -05:00
Ben Meadors
4b82634d1a Cleanup buffer 2024-07-03 22:19:01 -05:00
geeksville
8bca3e168d Add PowerMon support (#4155)
* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* powermon WIP (for https://github.com/meshtastic/firmware/issues/4136 )

* oops - mean't to mark the _dbg variant as an 'extra' board.

* powermon wip

* Make serial port on wio-sdk-wm1110 board work
By disabling the (inaccessible) adafruit USB

* Instrument (radiolib only for now) lora for powermon
per https://github.com/meshtastic/firmware/issues/4136

* powermon gps support
https://github.com/meshtastic/firmware/issues/4136

* Add CPU deep and light sleep powermon states
https://github.com/meshtastic/firmware/issues/4136

* Change the board/swversion bootstring so it is a new "structured" log msg.

* powermon wip

* add example script for getting esp S3 debugging working
Not yet used but I didn't want these nasty tricks to get lost yet.

* Add PowerMon reporting for screen and bluetooth pwr.

* make power.powermon_enables config setting work.

* update to latest protobufs

* fix bogus shellcheck warning

* make powermon optional (but default enabled because tiny and no runtime impact)

* tell vscode, if formatting, use whatever our trunk formatter wants
without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).

* add PowerStress module

* nrf52 arduino is built upon freertos, so let platformio debug it

* don't accidentally try to Segger ICE if we are using another ICE

* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

* update to latest protobufs (needed for powermon goo)

* PowerStress WIP

* fix linter warning
2024-07-03 18:02:20 -05:00
geeksville
8785adf6e4 minor cleanup proposal (#4169)
* MESHTASTIC_EXCLUDE_WIFI and HAS_WIFI cleanup...
Our code was checking HAS_WIFI and the new MESHTASTIC_EXCLUDE_WIFI
flags in various places (even though EXCLUDE_WIFI forces HAS_WIFI
to 0).  Instead just check HAS_WIFI, only use EXCLUDE_WIFI inside
configuration.h

* cleanup: use HAS_NETWORKING instead of HAS_WIFI || HAS_ETHERNET
We already had HAS_NETWORKING as flag in MQTT to mean 'we have
tcpip'.  Generallize that and move it into configuration.h so that
we can use it elsewhere.

* Use #pragma once, because supported by gcc and all modern compilers
instead of #ifdef DOTHFILE_H etc...

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-07-03 17:39:09 -05:00
Ben Meadors
9c46bdad1a New new BLE logging characteristic with LogRecord protos (#4220)
* New UUID

* New log radio characteristic with LogRecord protobuf

* LogRecord

* Merge derp

* How did you get there

* Trunk

* Fix length

* Remove assert
2024-07-03 16:29:07 -05:00
Tom Fifield
10b157a38d Typo fix in logs - mhz - MHz (#4225)
As reported by karamo, a few different places in our logs had
incorrect capitalization of MHz.

fixes meshtastic/firmware#4126
2024-07-03 09:04:39 -05:00
Tom Fifield
e65c309af6 Fix SHT41 support (#4222)
* Add SHT41 Serial to I2c Detection Code

On the Seeed Wio-WM1110 Dev Kit board, the SHT41 chip was being
incorrectly detected as SHT31.

This patch adds the necessary serial number for the SHT41 chip to
be correctly detected.

fixes meshtastic/firmware#4221

* Add missing sensor read for SHT41
2024-07-02 07:03:51 -05:00
github-actions[bot]
9701f35a83 [create-pull-request] automated change (#4218)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-07-01 06:29:44 -05:00
geeksville
3219d65387 When talking via serial, encapsulate log messages in protobufs if necessary (#4187)
* clean up RedirectablePrint::log so it doesn't have three very different implementations inline.

* remove NoopPrint - it is no longer needed

* when talking to API clients via serial, don't turn off log msgs instead encapsuate them

* fix the build - would loop forever if there were no files to send

* don't use Segger code if not talking to a Segger debugger

* when encapsulating logs, make sure the strings always has nul terminators

* nrf52 soft device will watchdog if you use ICE while BT on...
so have debugger disable bluetooth.

* Important to not print debug messages while writing to the toPhone scratch buffer

* don't include newlines if encapsulating log records as protobufs

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-30 18:41:27 -05:00
Manuel
8177329eac enable colors in platformio serial monitor (#4217) 2024-06-30 16:01:28 -05:00
Ben Meadors
469ae0ff84 Fix flakey phone api transition from file manifest to complete (#4209)
* Try fix flakey phone api transition from file manifest to complete

* Skip
2024-06-30 08:22:24 -05:00
Jonathan Bennett
b5d7718319 Move waypoint (#4202)
* Move waypoint screen draw into the waypoint module

* Get the observer set up for the waypoint screen draw

* Static squashing: screen dimensions
Macros moved back to Screen.cpp, as a band-aid until we eventually move all those static functions into the Screen class.

* Move getCompassDiam into Screen class
(supress compiler warnings)
At this stage, the method is still static, because it's used by drawNodeInfo, which has no tidy reference to our screen instance.
This is probably just another band-aid until these static functions all move.

* Use new getCompassDiam function in AccelerometerThread

* Properly gate display code in WaypointModule

---------

Co-authored-by: Todd Herbert <herbert.todd@gmail.com>
2024-06-29 21:16:07 -05:00
github-actions[bot]
47a94d7a07 [create-pull-request] automated change (#4205)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-29 19:04:08 -05:00
Ben Meadors
20c1d71214 Deprecate Router Client role (and make it Client) (#4201) 2024-06-29 19:03:00 -05:00
Jonathan Bennett
6f3d7ca4d2 Trim extra vprintf and filter for unprintable characters 2024-06-28 23:30:39 -05:00
Jonathan Bennett
ca969e26a5 Squash needlessly static functions (#4183) 2024-06-28 21:28:18 -05:00
Jonathan Bennett
5263c738f3 Make the logs Colorful! (#4199) 2024-06-28 20:10:41 -05:00
github-actions[bot]
9c232da00f [create-pull-request] automated change (#4200)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-28 18:46:44 -05:00
Ben Meadors
0016e747e9 Clear vector after complete config state (#4194)
* Clear after complete config

* Don't collect . entries

* Log file name and size
2024-06-28 09:50:22 -05:00
geeksville
ce58a23f9b Force a compile time failur if FromRadio or ToRadio get larger than (#4190)
a BLE packet size. We are actually very close to this threshold so
important to make sure we don't accidentally pass it.
2024-06-28 06:51:04 -05:00
quimnut
c95b2c2d3c correct xiao_ble build preventing sx1262 init (#4191) 2024-06-28 06:49:38 -05:00
geeksville
f86a0e5228 nrf52 soft device will watchdog if you use ICE while BT on... (#4189)
so have debugger disable bluetooth.
2024-06-28 06:48:55 -05:00
Alexander
51f3ce5e60 Show owner.short_name on boot (and E-Ink sleep screen) (#4134)
* Show owner.short_name on boot and sleep screen (on e-ink)

* Update Screen.cpp - new line for short_name

Boot screen short_name now below the region setting.
Looks better on small screens.

* Draw short_name on right

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: todd-herbert <herbert.todd@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-28 18:55:54 +12:00
geeksville
41d633bfd8 fix the build - would loop forever if there were no files to send (#4188) 2024-06-27 20:43:08 -05:00
geeksville
2cb6e7bd37 tell vscode, if formatting, use whatever our trunk formatter wants (#4186)
without this flag if the user has set some other formatter (clang)
in their user level settings, it will be looking in the wrong directory
for the clang options (we want the options in .trunk/clang)

Note: formatOnSave is true in master, which means a bunch of our older
files are non compliant and if you edit them it will generate lots of
formatting related diffs.  I guess I'll start letting that happen with
my future commits ;-).
2024-06-27 13:14:16 -05:00
Ben Meadors
a966d84e3d Send file system manifest up on want_config (#4176)
* Send file system manifest up on want_config

* Platform specific methods

* Helps to actually make the change

* Clear
2024-06-27 07:07:27 -05:00
Jonathan Bennett
0425551341 Display alerts (#4170)
* Move static functions into Screen.h, show compass during calibration

* Move to _fontHeight macro to avoid collision

* Move some alert functions to new alert handler

* Catch missed reboot code

* ESP32 fixes

* Bump esp8266-oled-ssd1306

* Fixes for when a device has no screen

* Use new startAlert(char*) helper class

* Add EINK bits back to alert handling

* Add noop class for no-display devices

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-25 11:26:02 -05:00
github-actions[bot]
626aa762df [create-pull-request] automated change (#4174)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-24 20:27:00 -05:00
geeksville
aa12e28568 Add semihosting support for nrf52 devices (#4137)
* Turn off vscode cmake prompt - we don't use cmake on meshtastic

* Add rak4631_dap variant for debugging with NanoDAP debug probe device.

* The rak device can also run freertos (which is underneath nrf52 arduino)

* Add semihosting support for nrf52840 devices
Initial platformio.ini file only supports rak4630
Default to non TCP for the semihosting log output for now...
Fixes https://github.com/meshtastic/firmware/issues/4135

* fix my botched merge - keep board_level = extra flag for rak3631_dbg

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-24 10:27:37 -05:00
github-actions[bot]
58c00d0447 [create-pull-request] automated change (#4171)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-24 08:01:40 -05:00
todd-herbert
64531fa1ae Show compass on waypoint frame; clear when waypoint deleted (#4116)
* Clear expired or deleted waypoint frame

* Return 0 to CallbackObserver

* Add a missing comment

* Draw compass for waypoint frame

* Display our own waypoints
2024-06-24 02:04:46 -05:00
Warren Guy
23ac6b6514 fix INA3221 sensor (#4168)
- pass wire to begin()
- remove redundant setAddr() (already set in header)
2024-06-23 15:40:13 -05:00
Ben Meadors
f5098dc6d8 Explicitly set characteristic 2024-06-23 14:47:25 -05:00
Ben Meadors
2e0d96cece Esptool is better 2024-06-23 07:54:13 -05:00
GUVWAF
8078e03f5f Implement replies for all telemetry types based on variant tag (#4164)
* Implement replies for all telemetry types based on variant tag

* Remove check for `ignoreRequest`: modules can set this, don't need to check

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-23 07:13:59 -05:00
Ben Meadors
eb6bd3a06f Update NimBLE to 1.4.2 (#4163) 2024-06-22 08:49:55 -05:00
Ben Meadors
d32cdecc06 Pause BLE logging during want_config flow (#4162) 2024-06-22 07:00:48 -05:00
github-actions[bot]
f8db38cf99 [create-pull-request] automated change (#4157)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-21 19:02:16 -05:00
Ben Meadors
02d8715ca0 Standardize lat/lon position logs (#4156)
* Standardize lat/lon position logs

* Missed sone and condensed logs
2024-06-21 17:25:54 -05:00
Mike G
0dd363fa98 Use upload_protocol = esptool as with the other heltec devices instead of esp-builtin (#4151) 2024-06-20 20:01:36 -05:00
Ben Meadors
0bcc60d535 BLE based logging (#4146)
* WIP log characteristic

* Bluetooth logging plumbing

* Characteristic

* Callback

* Check for nullptr

* Esp32 bluetooth impl

* Formatting

* Add thread name and log level

* Add settings guard

* Remove comments

* Field name

* Fixes esp32

* Open it up

* Whoops

* Move va_end past our logic
2024-06-20 16:14:55 -05:00
Mike
2d39911f91 Fix protobuf structs handling (#4140)
* Fix protobuf structs handling

* Log instead of assert

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-20 16:14:34 -05:00
Thomas Göttgens
bd3e4e572b Merge branch 'master' into wio-lr1110-refresh 2024-06-20 23:04:01 +02:00
Thomas Göttgens
ddc406209b Merge pull request #4149 from geeksville/pr-fixserial
Make serial port on wio-sdk-wm1110 board work
2024-06-20 22:56:31 +02:00
Thomas Göttgens
f145b5f16f Merge pull request #3836 from ndoo/regulatory-gain
Add REGULATORY_GAIN configuration to remain within regulatory ERP limit
2024-06-20 22:53:18 +02:00
geeksville
e050888b26 Don't complain about wierd platformio python 2024-06-20 12:28:43 -07:00
geeksville
9266a53f4e Make serial port on wio-sdk-wm1110 board work
By disabling the (inaccessible) adafruit USB
2024-06-20 09:49:15 -07:00
Thomas Göttgens
9a80951d6f Merge pull request #4129 from ndoo/hru-3601
Add support for Heltec HRU-3601
2024-06-20 16:42:44 +02:00
Thomas Göttgens
ecf5519b56 Moar LR1110 Targets 2024-06-20 16:26:04 +02:00
Thomas Göttgens
f0a38a5cf0 Merge branch 'master' into regulatory-gain 2024-06-20 16:13:54 +02:00
Andrew Yong
1515c8e763 Add support for Heltec HRU-3601
Board is very similar to the Heltec HT-C62 based boards (Heltec HT62 variant) but due to wiring of SK6812 Neopixel LED to GPIO2 it becomes incompatible due to the regular HT-C62 dev board using a simple LED on the same GPIO. Depends on [protobufs#521](https://github.com/meshtastic/protobufs/pull/521).

Works:

* SK6812 Neopixel on GPIO2
* [GXCAS GXHTV3](https://www.lcsc.com/product-detail/Temperature-Sensors_GXCAS-GXHTV3C_C5441730.html) (SHTC3 compatible)

Won't fix:

* Battery reading - Board has no voltage divider on VBAT (board has a 1.25mm pitch "JST" style connector and a TP4054 charge IC)
* Main thread LED - Board has no LED on simple GPIO

Board schematic: [HRU3601.pdf](https://github.com/user-attachments/files/15874850/HRU3601.pdf)

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-20 12:30:02 +08:00
Andrew Yong
3e9e0fdd49 Remove TTGO_T_ECHO gating for PIN_POWER_EN
Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-20 12:30:02 +08:00
Thomas Göttgens
ca560d64ea Merge pull request #4143 from meshtastic/fix-portduino
mask the I2C rescan for portduino
2024-06-19 22:33:18 +02:00
github-actions[bot]
c59cb3c292 [create-pull-request] automated change (#4145)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-19 14:48:46 -05:00
Thomas Göttgens
f79039fe57 mask the rescan for portduino 2024-06-19 21:46:29 +02:00
Thomas Göttgens
e780b9a798 Merge pull request #4142 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-06-19 21:32:37 +02:00
caveman99
3c4fa2101f [create-pull-request] automated change 2024-06-19 19:31:05 +00:00
Thomas Göttgens
8fa0911ec8 speed up OLED Display by transferring bigger chunks (#4138) 2024-06-18 15:59:47 -05:00
Thomas Göttgens
5fceab7f0f Merge pull request #3933 from HarukiToreda/master
Boot issue fix of Cardkb on ESP32
2024-06-17 23:24:42 +02:00
Thomas Göttgens
5cebe4a0a7 trunk fmt 2024-06-17 23:24:27 +02:00
Thomas Göttgens
275e393115 Merge branch 'master' into master 2024-06-17 22:33:54 +02:00
Manuel
e7181988b6 Merge pull request #4130 from meshtastic/fix-module-defines
fix for MESHTASTIC_EXCLUDE_INPUTBROKER
2024-06-17 22:17:38 +02:00
mverch67
e822525ce5 more semi colons >_< 2024-06-17 21:23:07 +02:00
mverch67
5e92136ed0 semi colon 2024-06-17 21:19:36 +02:00
mverch67
cd60ee80bd fix wrong include file exclusion 2024-06-17 21:17:25 +02:00
mverch67
9d8a5221a9 fix for MESHTASTIC_EXCLUDE_INPUTBROKER 2024-06-17 20:17:56 +02:00
Thomas Göttgens
30b14c57e7 Merge branch 'master' into master 2024-06-17 17:06:37 +02:00
Thomas Göttgens
7a25e0b69a don't close the wire when we didn't find anything. We might rescan later. 2024-06-17 17:03:32 +02:00
Thomas Göttgens
b6066a78c1 WIP 2024-06-17 15:09:38 +02:00
github-actions[bot]
5d2f7d1962 [create-pull-request] automated change (#4127)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-17 07:17:36 -05:00
todd-herbert
83f5ba0161 Update OLED ref (#4125)
Upstream changes to the library temporarily reverted to restore debug info frame
2024-06-17 06:14:20 -05:00
Ben Meadors
12b8dc1918 Revert "[create-pull-request] automated change (#4121)" (#4124)
This reverts commit 7afa8107ae.
2024-06-17 06:09:50 -05:00
Thomas Göttgens
00162b4ccf Merge branch 'master' of https://github.com/HarukiToreda/ESP32-CardKB-Fix 2024-06-17 12:01:26 +02:00
Thomas Göttgens
ce3be5b4e8 Merge branch 'master' into master 2024-06-17 12:00:16 +02:00
Thomas Göttgens
cf2a824cc1 Merge branch 'master' of https://github.com/HarukiToreda/ESP32-CardKB-Fix 2024-06-17 11:52:47 +02:00
Thomas Göttgens
1f214211ba Merge pull request #4123 from geeksville/pr-nrf52-dap
Add rak4631_dap variant for debugging with NanoDAP debug probe device.
2024-06-17 11:51:38 +02:00
geeksville
96853aeeea Merge branch 'master' into pr-nrf52-dap 2024-06-16 22:25:58 -07:00
geeksville
af36ee3a05 Merge branch 'pr-nrf52-dap' of https://github.com/geeksville/Meshtastic-esp32 into pr-nrf52-dap 2024-06-16 22:24:57 -07:00
geeksville
c593e7ce56 Add rak4631_dap variant for debugging with NanoDAP debug probe device.
use board_level = extra
2024-06-16 22:21:54 -07:00
geeksville
15250a566a Turn off vscode cmake prompt - we don't use cmake on meshtastic (#4122) 2024-06-16 22:21:54 -07:00
github-actions[bot]
7afa8107ae [create-pull-request] automated change (#4121)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-16 19:22:51 -05:00
Ben Meadors
c2097d38fd Merge branch 'master' into pr-nrf52-dap 2024-06-16 19:17:30 -05:00
geeksville
163a732ddc Turn off vscode cmake prompt - we don't use cmake on meshtastic (#4122) 2024-06-16 19:17:19 -05:00
geeksville
ea69b999f9 Add rak4631_dap variant for debugging with NanoDAP debug probe device. 2024-06-16 15:19:29 -07:00
Thomas Göttgens
7aea056ac0 exclude debs from release zip 2024-06-16 22:43:16 +02:00
Thomas Göttgens
369d379720 CI is creating the uf2 file during build 2024-06-16 21:08:34 +02:00
Thomas Göttgens
02050a4775 Merge pull request #4117 from beegee-tokyo/master
Add RAKwireless WisMesh Hub (RAK2560/RAK9154)
2024-06-16 20:44:35 +02:00
Thomas Göttgens
aca0807acf more try more fix 2024-06-16 20:41:23 +02:00
Thomas Göttgens
4fe281cf7f tryfix linter error 2024-06-16 20:11:58 +02:00
Thomas Göttgens
11c3ca541f add proper RAK variant and change pathspec 2024-06-16 20:03:45 +02:00
Thomas Göttgens
ceb884cf18 trunk fmt 2024-06-16 16:29:45 +02:00
beegee-tokyo
e546220a80 Merge branch 'master' of https://github.com/beegee-tokyo/firmware 2024-06-16 21:06:43 +08:00
beegee-tokyo
f50073ed9f Separate RAK4631 and RAK2560 variants 2024-06-16 21:06:38 +08:00
Ben Meadors
0c45c99b15 Merge branch 'master' into master 2024-06-16 07:39:46 -05:00
Thomas Göttgens
abdb7f52bc Merge pull request #4118 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-06-16 14:37:33 +02:00
thebentern
471ee78a5e [create-pull-request] automated change 2024-06-16 12:25:52 +00:00
beegee-tokyo
85d621d9c6 Move RAK9154 to variants, fix json 2024-06-16 19:45:17 +08:00
Thomas Göttgens
a453d7f52c Iterate through uint array 2024-06-16 11:59:21 +02:00
Thomas Göttgens
ba14ffb8d3 change type to 8 bit uint 2024-06-16 11:59:21 +02:00
Thomas Göttgens
2eb3cfd5e0 change the main scan class so they scan only for wanted bits - UNTESTED 2024-06-16 11:59:21 +02:00
HarukiToreda
ce9e63a2cb Added fix for ESP32 2024-06-16 11:59:21 +02:00
Thomas Göttgens
dbb254ba7a change the main scan class so they scan only for wanted bits - UNTESTED 2024-06-16 11:59:21 +02:00
HarukiToreda
27bb3506d3 Added fix for ESP32 2024-06-16 11:59:21 +02:00
Thomas Göttgens
97e8b1fd18 Merge branch 'master' into regulatory-gain 2024-06-16 11:35:11 +02:00
beegee-tokyo
5e01b4251f Fix build error for none RAK2560 devices 2024-06-16 15:46:37 +08:00
beegee-tokyo
d7c52c33b9 Add RAK2560/RAK9154 2024-06-16 14:24:36 +08:00
Thomas Göttgens
a38a18da0d WIP: add NAU7802 based scale controller. (#4092)
* WIP: add NAU7802 based scale controller. Needs proto commit

* WIP: add NAU7802 based scale controller. Needs proto commit

* telemetry uses kg, scale internally g

* add sensor calibration setters
2024-06-15 19:59:22 -05:00
todd-herbert
96be051bff Screensaver validates short name (#4115) 2024-06-15 14:58:46 -05:00
Ben Meadors
b1cf5778b4 Update nrf52 platform to 10.5.0 (#4113) 2024-06-15 09:46:31 -05:00
Ben Meadors
32702e2750 Fix compiler warnings (#4112) 2024-06-15 09:46:15 -05:00
github-actions[bot]
21d47adb8d [create-pull-request] automated change (#4114)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-15 09:45:33 -05:00
Ben Meadors
3e4e1b2202 Trunk 2024-06-14 19:53:47 -05:00
Daniel.Cao
e55604b8e5 rak10701: support touchscreen (#4104)
* Add the touch screen driver RAK10701 platform, lib_deps https://github.com/RAKWireless/RAK14014-FT6336U

* Added RAK10701 touch screen virtual keyboard, supporting cannedMessageModule free text
2024-06-14 19:36:20 -05:00
Ben Meadors
8b8e056b7b Added (excluded) Dropzone Module for more comprehensive module example (#4098)
* DropzoneModule hello world

* Buttoning things up

* Exclude by default

* Upstream refs

* Cleanup

* Add modules folder to path

* Case and path matters

* Exclude from header

* Guard
2024-06-14 16:27:49 -05:00
Wolfgang Nagele
1a5227c826 Ensure data directory ownership is with mesh user (#4097) 2024-06-14 10:45:16 -05:00
todd-herbert
39c9f92c6e GPS: short update intervals, lock-time prediction (#4070)
* Refactor GPSPowerState enum
Identifies a case where the GPS hardware is awake, but an update is not yet desired

* Change terminology

* Clear old lock-time prediction on triple press

* Use exponential smoothing to predict lock time

* Rename averageLockTime to predictedLockTime

* Attempt: Send PMREQ with duration 0 on MCU deep-sleep

* Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep

* Revert "Attempt 2: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 8b697cd2a4.

* Revert "Attempt: Send PMREQ with duration 0 on MCU deep-sleep"

This reverts commit 9d29ec7603.
2024-06-14 08:28:01 -05:00
Ben Meadors
16b41b51af Update OLED ref 2024-06-13 12:05:14 -05:00
Ben Meadors
85bca8a32a Update lark to ref to clear C++ warning 2024-06-13 11:13:18 -05:00
Thomas Göttgens
96943fe4b5 Merge pull request #4094 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-06-13 16:50:47 +02:00
caveman99
75d5cd2c35 [create-pull-request] automated change 2024-06-13 14:50:21 +00:00
github-actions[bot]
26d4d06e2a [create-pull-request] automated change (#4093)
Co-authored-by: caveman99 <25002+caveman99@users.noreply.github.com>
2024-06-13 08:39:38 -05:00
GUVWAF
ce5f73bb00 Merge pull request #4088 from ab0oo/master
feature-mqtt: add hop_start to MQTT uplink
2024-06-13 12:43:30 +02:00
John Gorkos - AB0OO
f7433eb4ee trunk formatting 2024-06-12 14:36:38 -07:00
John Gorkos - AB0OO
b42185c722 included hop_start in conditional for hop_away 2024-06-12 13:02:01 -07:00
John Gorkos - AB0OO
d80bcd7d67 adding only hop_start, per @GUVWAF 2024-06-12 12:59:52 -07:00
John Gorkos - AB0OO
871f6854b5 feature-mqtt: add hop_start and hop_limit to MQTT uplink 2024-06-12 08:22:01 -07:00
Thomas Göttgens
78fd17c12e Merge pull request #4086 from HelTecAutomation/master
Add Heltec Capsule Sensor V3 to the Meshtastic source code
2024-06-12 15:50:06 +02:00
github-actions[bot]
c7769274dd [create-pull-request] automated change (#4085)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-12 07:23:54 -05:00
Heltec-Aaron-Lee
5b1d3ed173 Add Heltec Capsule Sensor V3 to source code 2024-06-12 20:21:26 +08:00
Ben Meadors
b09cee118c Trunk 2024-06-12 06:57:11 -05:00
Jan Veeh
992d1c42e6 changed CFG-PM config message to use external signal (#4062) 2024-06-12 06:43:50 -05:00
todd-herbert
d60d1d7447 Workaround to disable bluetooth on NRF52 (#4055)
* Workaround to allow bluetooth disable on NRF52

* Use miminum tx power for bluetooth

* Reorganize

* Instantiate nrf52Bluetooth correctly..

* Change log message
2024-06-12 06:34:00 -05:00
Thomas Göttgens
0c23e3109a Merge pull request #4080 from tavdog/wind_data_mqtt_json
add wind speed and direction to mqtt json output
2024-06-12 09:39:41 +02:00
Tavis
e63278cf43 add wind speed and direction to json 2024-06-11 15:13:17 -10:00
Jonathan Bennett
0852a170a3 Add support for BMX160/RAK12034 compass module (#4021) 2024-06-11 17:47:45 -05:00
github-actions[bot]
7f2647abb1 [create-pull-request] automated change (#4078)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2024-06-11 14:52:02 -05:00
Michael Gjelsø
8b1b6faf89 Added Radiomaster Bandit Nano and Radiomaster Bandit Micro to default_envs. (#4077)
Added Radiomaster Bandit Micro, it shares the same code and settings as Bandit Nano
2024-06-11 14:51:39 -05:00
Andrew Yong
53fc22178b Merge branch 'master' into regulatory-gain 2024-06-11 21:30:35 +08:00
Wolfgang Nagele
62b310ac5c Relax changes from #4001 to allow GPS and NTP as trusted sources (#4068) 2024-06-10 08:10:17 -05:00
github-actions[bot]
4f906ae3ae [create-pull-request] automated change (#4064)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-09 18:52:37 -05:00
GUVWAF
24458a73d6 Add missing hops in traceroute as "unkown" (#4056)
E.g. in case a node couldn't decrypt the packet
2024-06-09 16:03:53 -05:00
Michael Gjelsø
a2fb3d23a1 Radio Master 900 Bandit Nano Power output interpolation (#4057)
* DAC and DB values based on dBm using interpolation

* Moved getDACandDB funtion

Moved getDACandDB funtion up so it won't conflict with RF95_MAX_POWER

* Added DAC output to LOG_INFO

Added DAC output to LOG_INFO

* Make Trunk Happy
2024-06-09 16:03:39 -05:00
GUVWAF
237944aaf0 Avoid assert on receiving undecryptable packet (#4059)
* Send NAK on primary if original packet couldn't be decoded

* Add checks for `isDecoded` when accessing `decoded`

* Channel index should be of original packet, not of newly allocated NAK
2024-06-09 16:02:52 -05:00
Thomas Göttgens
1d98e48bab Update main_matrix.yml 2024-06-09 16:33:50 +02:00
Ben Meadors
01a214aa59 Add continues on failing docker steps 2024-06-09 08:32:31 -05:00
Ben Meadors
4da3f202e5 Roll-back to v2 2024-06-09 07:55:45 -05:00
Ben Meadors
2f99a8dbb8 Try latest version 2024-06-09 07:40:57 -05:00
Ben Meadors
f59cbc8ffb Add firmware repo level secret 2024-06-09 07:19:25 -05:00
Thomas Göttgens
095887de40 do the docker dance 2024-06-09 13:00:06 +02:00
Thomas Göttgens
46b8e2a850 fix binary location 2024-06-09 12:56:44 +02:00
Thomas Göttgens
27ad3da0ac reinstate after checks and hope the coffee kicks in 2024-06-09 12:37:23 +02:00
Thomas Göttgens
2335352fbe fix native build 2024-06-09 12:30:47 +02:00
Ben Meadors
2fa55b7b6f Remove bandit from extra 2024-06-08 09:44:13 -05:00
todd-herbert
da5bca31ed Triple-press not disabling GPS (#4041)
* Replace (bool) isAwake with an enum, to track standby states

* Tidy-up, extra logging

* Rename enum values

* Reorder GPSPowerState enum
Possibly more intuitive when reading logs

* Avoid lego comments
de22c57298 (r1627334779)
2024-06-07 09:41:46 -05:00
Thomas Göttgens
8a4e91e848 Merge pull request #4048 from Jorropo/improve-eu-868-docs
fix dead link in EU_868 documentation
2024-06-07 16:35:11 +02:00
Thomas Göttgens
d91fdc5ea7 Merge pull request #4053 from meshtastic/xiao-ble
Compile without toolchain patching
2024-06-07 16:34:41 +02:00
Thomas Göttgens
355c610824 Compile without toolchain patching 2024-06-07 15:36:48 +02:00
Thomas Göttgens
a52db85ebe fix base setup 2024-06-07 15:36:31 +02:00
todd-herbert
338244de32 Wake screen on first press (#4052) 2024-06-07 07:28:29 -05:00
Thomas Göttgens
90d45f24fd Merge pull request #4049 from Talie5in/minimized_build_fixes
Minimized build fixes
2024-06-06 20:13:32 +02:00
Talie5in
d09da96780 Fix indentation oopsie 2024-06-06 23:57:44 +09:30
Talie5in
a5c96a29d5 Fix missing IFNDEF and IFDEF in main-esp32.cpp when EXCLUDE_WIFI is defined.
Moved IFDEF HAS_NETWORK to beginning of MQTT:runOnce (to catch when EXCLUDE_WIFI is defined)
2024-06-06 22:52:11 +09:30
Talie5in
1f9f885aca If EXCUDE_MQTT Defined, skip reconnecting MQTT in WiFiAPClient and dont check status of is_mqtt_connected 2024-06-06 22:31:10 +09:30
Talie5in
646b252786 Include PositionModule if EXCLUDE_GPS defined (requied by AdminModule) 2024-06-06 22:19:40 +09:30
Andrew Yong
08e1c2f681 Rename REGULATORY_GAIN to REGULATORY_GAIN_LORA to allow for other RF gain controls
For example, Wi-Fi or BLE gain control (#3962)

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-06 14:42:30 +08:00
Andrew Yong
537814df58 xiao_ble: Add EBYTE E22-900M33S PA gain and limits
Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-06 14:42:30 +08:00
Andrew Yong
d1d49efc6e Implement REGULATORY_GAIN and SX126X_MAX_POWER in XIAO BLE EBYTE E22
Specify REGULATORY_GAIN and SX126X_MAX_POWER to prevent exceeding regulatory and hardware limits (i.e. overloading the PA input) respectively.

Also update the build flag to define EBYTE_E22_900M30S instead of just EBYTE_E22, since all the builds on the Discourse topic [New 1W DIY variant: Xiao nRF52840 + Ebyte E22-900M30S](https://meshtastic.discourse.group/t/new-1w-diy-variant-xiao-nrf52840-ebyte-e22-900m30s/7904) are using this module.

That should make it clearer as well that the variant header file should be tweaked if DIY builds are using stronger (E22-900M33S, not commonly available at this time) or weaker (E22-900M22S, not popular for DIY builds due to lack of differentiation from ordinary SX1262 modules).

Retain EBYTE_E22 flag alongside EBYTE_E22_900M30S build flag to prevent possible regressions in code paths generally intended for EBYTE E22 modules.

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-06 14:42:30 +08:00
Andrew Yong
3cda598673 Add REGULATORY_GAIN configuration to remain within regulatory ERP limit
REGULATORY_GAIN is the total system gain in dBm to subtract from the configured Tx power, to remain within regulatory ERP limit for non-licensed operators.

This value should be set in variant.h and is PA gain + antenna gain (if system ships with an antenna).

This is similar to antenna_gain/NL80211_ATTR_WIPHY_ANTENNA_GAIN/NL80211_ATTR_REG_RULE_POWER_MAX_ANT_GAIN setting in Linux Regulatory/OpenWrt/mac80211/nl80211/iw.

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-06 14:42:30 +08:00
Andrew Yong
5554cc46a7 Add REGULATORY_ prefix to LORA_REGIONCODE
Add REGULATORY_ prefix to LORA_REGIONCODE to prepare for more regulatory configuration options, and update comment block accordingly too.

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-06-06 14:42:30 +08:00
Jorropo
d82d9f5ef1 fix dead link in EU_868 documentation
See https://discord.com/channels/867578229534359593/871553168369148024/1248026118276255745.
2024-06-05 23:32:59 +02:00
Thomas Göttgens
96b286cd48 release x86_64 deb 2024-06-05 17:50:58 +02:00
Thomas Göttgens
7874ebc568 Update package_amd64.yml 2024-06-05 17:24:55 +02:00
Thomas Göttgens
fb3c141231 update package index 2024-06-05 17:04:22 +02:00
Thomas Göttgens
f1906c38f1 sudo make me a sandwich 2024-06-05 16:37:12 +02:00
Thomas Göttgens
14b7c5b6ef Create build_native.yml 2024-06-05 16:34:30 +02:00
Thomas Göttgens
d8775d94e3 try harder dude 2024-06-05 16:29:40 +02:00
Thomas Göttgens
2cc5598f89 Try building a deb for native 2024-06-05 16:27:46 +02:00
Thomas Göttgens
fbc8f6c03b package x86_64 meshtasticd 2024-06-05 15:08:23 +02:00
jcyrio
d0ca616c19 typo: 'our our' to 'of our' (#4037) 2024-06-04 16:02:43 -05:00
Thomas Göttgens
c37316e723 use correct hardware tag for tracker and sdk (#4036) 2024-06-04 08:44:48 -05:00
github-actions[bot]
67b67a481f [create-pull-request] automated change (#4035) 2024-06-04 08:34:38 -05:00
Thomas Göttgens
181f03cb95 tryfix random values (#4034) 2024-06-04 08:14:27 -05:00
Ben Meadors
9632e4c405 Add missing excludes to environmental sensors (#4033)
* DF Robot Lark weather station support

* Missed it

* I am a man of const char sorrow...

* Strang

* Use our fork

* Add excludes
2024-06-04 07:04:25 -05:00
Ben Meadors
a218c6fb4d DFRobot Lark weather station support (#4032)
* DF Robot Lark weather station support

* Missed it

* I am a man of const char sorrow...

* Strang

* Use our fork
2024-06-03 21:50:28 -05:00
Thomas Göttgens
b43c7c0f23 LR1110 support (#3013)
* DOES NOT WORK

* trunk

* DOES NOT WORK

* trunk

* DOES NOT WORK

* trunk

* WIP: LR11x0 non functional interface code. Please don't expect a working firmware out of this! I don't know what i am doing! :-)

* trunk fmt

* use canon toolchain

* update and fix radiolib dependency

* Switch Radiolib back to GIT checkout

* enable tcxo and fix startReceive

* progress

* Correct midjudgement on scope of build defines.

* - enable peripheral power rail during startup init
- fix portduino builds

* add tracker pinout variant

* update to radiolib 6.6.0 API (aka: godmode is not for mere mortals)

* tracker is not so 'extra' any more

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-06-03 16:04:40 -05:00
github-actions[bot]
7cbfe7aa54 [create-pull-request] automated change (#4029)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-03 15:59:39 -05:00
Thomas Göttgens
86f2000382 Merge pull request #4025 from meshtastic/bme-680
tryfix bme some more
2024-06-03 17:25:27 +02:00
Thomas Göttgens
79333c85a3 tryfix bme some more 2024-06-03 16:34:19 +02:00
Thomas Göttgens
4a93e4d85e Merge pull request #4023 from meshtastic/radiolib
update Radiolib to 6.6.0
2024-06-03 14:25:03 +02:00
Thomas Göttgens
b551c8b592 update Radiolib to 6.6.0 2024-06-03 14:00:58 +02:00
Ben Meadors
06c635eca0 MLX90632 IR temperature sensor support (#4019) 2024-06-02 09:38:28 -05:00
Ben Meadors
97a5abbc82 TI OPT3001 light sensor support (#4015)
* TI OPT3001 light sensor support

* Added register interrogation to deconflict with SHT sensors on same address
2024-06-02 07:39:08 -05:00
Manuel
2723ae6e9b fix crash during reset nodedb (#4017) 2024-06-02 07:38:20 -05:00
Ben Meadors
6ce2fdc1c8 Add TSL2591 sensor support (#4014) 2024-06-01 20:21:39 -05:00
github-actions[bot]
9a855c0b6f [create-pull-request] automated change (#4011)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-06-01 07:46:01 -05:00
Thomas Göttgens
2740a56944 tryfix: init change for BME680 (#3965) 2024-05-31 19:46:42 -05:00
fzellini
ffff2a03fc dragino trackerd (#4002)
* added AHTx0 sensor

* AHT10 definition in protobuf

* AHT10 definition in protobuf

* protobufs

* Management of AHT20+BMP280 module

* missing newline in log

* missing newline in log

* dragino trackerd support

* dragino trackerd support

* revert back .gitmodules

* reverted gitignore

* merged telemetry.pb.h

* merged telemetry.pb.h

* removed extra script, now bin version works

* reverted

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-31 13:05:40 -05:00
Ben Meadors
4fa2427b8c Trunk variants 2024-05-31 11:18:06 -05:00
fzellini
eddda3ca43 added AHTx0 sensor (#3977)
* added AHTx0 sensor

* AHT10 definition in protobuf

* AHT10 definition in protobuf

* protobufs

* Management of AHT20+BMP280 module

* missing newline in log

* missing newline in log

* reverted

* reverted .gitignore

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-31 11:17:53 -05:00
Ben Meadors
17142f8778 Add support for RadioMaster Bandit Nano (#4005)
* Add support for RadioMaster Bandit Nano

* Add fan to init and sleep
2024-05-31 10:56:04 -05:00
jonagnew
953aa4d091 Tracker v1.1 - fix pin 3 description in variant.h (#3990)
Schematic shows the following:
Pin 3 is Vext on v1.1 - HIGH enables LDO for Vext rail which goes to:
 GPS UC6580: GPS V_DET(8), VDD_IO(7), DCDC_IN(21), pulls up RESETN(17), D_SEL(33) and BOOT_MODE(34) through 10kR 
GPS LNA SW7125DE: VCC(4), pulls up SHDN(5) through 10kR
OLED: VDD, LEDA (through diode)

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-31 10:55:20 -05:00
Aaron.Lee
b9edc7563b Update the Heltec board battery level read accuracy. (#3955)
* Update variant.h

Update the Heltec board battery voltage read parameter.

* Update variant.h

Update the Heltec board battery voltage read parameter.

* Update variant.h

Update the Heltec board battery voltage read parameter.

* Update variant.h

Update the Heltec board battery voltage read parameter.
2024-05-31 10:55:05 -05:00
github-actions[bot]
c88278724c [create-pull-request] automated change (#4003)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-05-31 07:15:41 -05:00
Jonathan Bennett
54bccb898e Run tzset() and localtime() in getTZOffset() to ensure proper timezone offset (#3999)
* Run tzset() and localtime() in getTZOffset() to ensure proper timezone offset

* Try #2 to fix timezone/DST
2024-05-31 07:15:16 -05:00
Jonathan Bennett
8d90c496d0 Don't send potentially bogus timestamps with fixed location (#4001) 2024-05-31 07:14:33 -05:00
Ben Meadors
10e3040494 Add support for to_callsign on GeoChats for ATAK (#3996) 2024-05-30 18:49:08 -05:00
Mike
f138eaa970 Fix original esp32 boot init panic (#3985)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-30 10:59:10 -05:00
github-actions[bot]
cd8a7e44a8 [create-pull-request] automated change (#3992)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-05-30 09:08:32 -05:00
Ben Meadors
0b48663cbc Don't alloc NodeInfo replies when channel utilization is > 40% (#3991)
* Don't alloc NodeInfo replies when channel utilization is > 40%

* Commit

* Logs
2024-05-30 08:49:01 -05:00
Ben Meadors
af9d825266 Send own node-info earlier and move others to the end of want-config flow (#3949)
* Send own node-info earlier and move others to the end of want-config flow

* Special nonce skips other nodeinfos

* Missed it
2024-05-28 19:25:19 -05:00
Neil Hao
038413f46f User experience improvement - app battery icon (#3979)
* 'app_battery_icon'

* Undo VS automatic modifications to this file

* 'app_battery_icon_2'
2024-05-28 06:30:15 -05:00
andrew-moroz
77cf5c6200 Fix time updates from client device and potentially incorrect UI frame receiving 'toggle watch face' button tap (#3974) 2024-05-26 07:04:31 -05:00
Mike
aa33ad1d58 Fix memory leak when there's no display (#3972) 2024-05-26 06:42:44 -05:00
Jonathan Bennett
34553c9714 Bump portduino to pick up improvements to reboot() (#3975) 2024-05-26 06:42:23 -05:00
Thomas Göttgens
c46c3427f0 Iterate through uint array 2024-05-25 12:37:55 +02:00
Thomas Göttgens
dca8615eaa change type to 8 bit uint 2024-05-24 22:59:31 +02:00
Thomas Göttgens
79511aa61e Merge branch 'master' of https://github.com/HarukiToreda/ESP32-CardKB-Fix 2024-05-24 22:35:05 +02:00
Thomas Göttgens
80762518d5 Merge branch 'master' into master 2024-05-24 22:27:21 +02:00
capslockapocalypse
2233507667 Added "Hops away" on display (#3934)
* Added "Hops away" on display

Added in logic that displays "hops away" instead of signal strength when the node is more than 0 hops away.

* Added comment

* Update extensions.json to same as master

* attempt 2 at reverting extensions JSON

* Attempt 3 at getting extensions right

* Take 4. should be reverting to before my edits

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-24 08:08:21 -05:00
Thomas Göttgens
9a38a4b024 Merge pull request #3966 from andrew-moroz/t-watch-fix
t-watch-fix: Fully insulate T-Watch free text updates from other hardware platforms
2024-05-24 08:57:37 +02:00
Andrew Moroz
1d288414a5 t-watch-fix: Fully insulate T-Watch free text updates from other hardware platforms 2024-05-24 00:02:03 -04:00
andrew-moroz
2f9dc813d3 t-watch-updates: Add canned message free text via touch keyboard and watch face frames to T-Watch S3 (#3941)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-23 07:21:27 -05:00
github-actions[bot]
1a253dccc3 [create-pull-request] automated change (#3964)
Co-authored-by: thebentern <9000580+thebentern@users.noreply.github.com>
2024-05-23 07:20:13 -05:00
Ben Meadors
7d873eb06b Add exclude emoji macro 2024-05-22 20:40:26 -05:00
868meshbot
1631462db1 Oled screen emojis (#3940)
* Update images.h

Add some fun emojis

* Update Screen.cpp

Update Screen.cpp to display single emojis on the OLED of devices, if a single known emoji is detected

* Update images.h

add ? ! fog emojis

* Update Screen.cpp

add logic for new emojis

* Update Screen.cpp

correct formatting

* Update images.h

correct formatting

* Update Screen.cpp

change formatting via trunk application

* Update images.h

change formatting based on trunk application

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-22 19:28:30 -05:00
Jonathan Bennett
7bcb8f1fee Portduino: Catch the keyboard power button and initiate poweroff (#3953) 2024-05-22 07:54:06 -05:00
Mike
0c9da9aec7 Update platformio/espressif32 to the latest 6.7.0 (#3899)
* Bump platfomio/espressif32 version to latest 6.7.0

* Fix deprecated constants

* Remove pin defs already defined by the framework

* ESP_EXT1_WAKEUP_ALL_LOW is deprecated for any target except esp32

* Enable LTO and use newlib nano flavor

* Make trunk happy

* Respect build_unflags of base env

* Recover float printfing

* Disable BLE_SM_PAIR_AUTHREQ_SC

* Distribute BLE_SM_PAIR_KEY_DIST_ID too

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-21 21:02:09 -05:00
todd-herbert
a12b9922ed Screen changes from time deltas to timestamps after 15 minutes (#3935)
* E-Ink displays sometimes use timestamp instead of delta

* Allow users to disable E-Ink screensaver

* Clarify variable's purpose

* Operator order oopsie

* Picky print problem

* Implement for all display, not just E-Ink

* Align "unknown age" behavior with existing code

* One more use of timestamp, if screen is wide enough
2024-05-21 16:00:04 -05:00
todd-herbert
cdf86f4166 Change NRF_APM USB detection code (#3939) 2024-05-21 15:58:05 -05:00
github-actions[bot]
040b851615 [create-pull-request] automated change (#3950)
Co-authored-by: jp-bennett <5630967+jp-bennett@users.noreply.github.com>
2024-05-21 14:40:31 -05:00
Jonathan Bennett
d19607ba98 Look in the right place for .debs 2024-05-21 11:23:29 -05:00
Jonathan Bennett
b829ee795d re-add .deb download to build 2024-05-21 10:37:26 -05:00
Ben Meadors
2fdc2e2c3c Perhaps a wildcard shall I seek 2024-05-21 09:07:47 -05:00
Ben Meadors
b9a6d21dff Add EoRA-S3 2024-05-21 07:45:24 -05:00
Ben Meadors
8c5dee5881 Remove download 2024-05-21 07:04:18 -05:00
Ben Meadors
55d46bae92 Update build_raspbian_armv7l.yml 2024-05-21 06:56:16 -05:00
Jonathan Bennett
ed8abea11b Add final debug call for Portduino reboot (#3945) 2024-05-21 00:09:33 -05:00
Ben Meadors
5f107569f3 Put T-Beam supreme back to the future (#3944) 2024-05-20 19:48:10 -05:00
Ben Meadors
b68ef3d98a Revert "Fix TBeam Supreme woes (and upgrade platform)" (#3943) 2024-05-20 19:34:51 -05:00
Jonathan Bennett
34aec70998 No need to build Raspbian arm64 twice: Part 2 2024-05-19 23:44:12 -05:00
Jonathan Bennett
e8cdac8fa0 No need to build Raspbian arm64 twice 2024-05-19 23:31:33 -05:00
Jonathan Bennett
afae3a488e Move Raspbian Arm64 to new build scheme 2024-05-19 23:29:43 -05:00
Jonathan Bennett
85e238ca76 Better names for .deb artifacts 2024-05-19 21:12:47 -05:00
Jonathan Bennett
45b05c9896 Revert "Use the right arch name for armv7l builds"
This reverts commit 7d1a925892.
2024-05-19 20:39:11 -05:00
Jonathan Bennett
7d1a925892 Use the right arch name for armv7l builds 2024-05-19 20:16:33 -05:00
Jonathan Bennett
72fb8a30a1 No sudo on debian docker 2024-05-19 18:18:03 -05:00
Jonathan Bennett
1c67f491d4 Add deps install for armv7l builds 2024-05-19 18:13:12 -05:00
Jonathan Bennett
f7a4cd33b4 Add armv7 builds 2024-05-19 18:00:06 -05:00
HarukiToreda
d2390cb98a Merge branch 'master' of https://github.com/HarukiToreda/ESP32-CardKB-Fix 2024-05-19 16:11:26 -04:00
Thomas Göttgens
a37f309c03 change the main scan class so they scan only for wanted bits - UNTESTED 2024-05-19 19:33:19 +02:00
HarukiToreda
3a628047ef Added fix for ESP32 2024-05-19 19:33:19 +02:00
Thomas Göttgens
a5fdb663e2 change the main scan class so they scan only for wanted bits - UNTESTED 2024-05-19 19:32:08 +02:00
Jorropo
3719ddac03 automatically propose to setup virtualenv if platformio is having issues in native build (#3923) 2024-05-19 07:25:05 -05:00
Ben Meadors
4a05874dba Try-fix: Remove logging of actual payload strings (and compressed) for TAK packets (#3922)
* Remove logging of actual payload strings (and compressed) for TAK packets

* Don't assert / reboot. Log error and skip decode
2024-05-19 07:24:10 -05:00
HarukiToreda
1ec0e750a3 Added fix for ESP32 2024-05-18 22:14:22 -04:00
Jonathan Bennett
84d3117a7a Lock Portduino to MAGIC_USB_BATTERY_LEVEL for now (#3894) 2024-05-18 12:21:35 -05:00
Thomas Göttgens
300b26c6b5 Merge pull request #3925 from meshtastic/init-variant
PLEASE TEST move the power rail init earlier in the startup process on 4630
2024-05-18 15:33:06 +02:00
Thomas Göttgens
cf0424922a target does not use the powerrail 2024-05-18 10:48:57 +02:00
Thomas Göttgens
7ef9fec446 PLEASE TEST move the power rail init earlier in the startup process on 4630 2024-05-18 10:48:57 +02:00
Thomas Göttgens
2244b0efec Merge pull request #3930 from meshtastic/screen-pinning
remove screen pinning for pico targets
2024-05-18 10:43:45 +02:00
Thomas Göttgens
108dfdc2ec update trunk 2024-05-18 10:41:32 +02:00
Thomas Göttgens
b161649989 remove screen pinning for pico targets 2024-05-18 10:22:07 +02:00
Jonathan Bennett
a2284e3d52 DEBIAN is case sensitive 2024-05-17 03:32:11 -05:00
Thomas Göttgens
ce40f91613 Merge pull request #3924 from meshtastic/Stop-overwriting-my-config
debconf expects absolute paths.
2024-05-17 09:36:52 +02:00
Jonathan Bennett
314d2e2da1 debconf expects absolute paths. 2024-05-17 02:34:18 -05:00
Ben Meadors
b4a7e78d18 Don't reboot for certain config prefs and make accelerometer thread re-entrant (#3889)
* Don't reboot for certain config prefs and make accelerometer thread re-entrant

* WHOOPS

* Don't reboot for LED heartbeat and button press

* Remove TZ
2024-05-16 17:27:36 -05:00
todd-herbert
f3cf9a5e71 Adjust refresh for Heltec Wireless Paper V1.1 (#3913) 2024-05-16 15:37:09 -05:00
Thomas Göttgens
8e35e19fda Merge pull request #3915 from meshtastic/libpax-rssi
implements #3885
2024-05-16 21:20:33 +02:00
Thomas Göttgens
14839bd9ba Merge branch 'master' into libpax-rssi 2024-05-16 19:44:24 +02:00
Thomas Göttgens
f109bc25c9 Merge pull request #3918 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-16 19:44:03 +02:00
caveman99
0976705f25 [create-pull-request] automated change 2024-05-16 17:43:23 +00:00
Thomas Göttgens
14392c22fd Merge pull request #3912 from meshtastic/fix-tbeam-s3
Fix TBeam Supreme woes (and upgrade platform)
2024-05-16 17:38:13 +02:00
Thomas Göttgens
10010baacc Merge pull request #3917 from rcarteraz/patch-1
remove has screen = 0 from wsl variant
2024-05-16 17:37:37 +02:00
Thomas Göttgens
8c327cc573 Merge pull request #3904 from meshtastic/lib-update
update sensor libs
2024-05-16 17:37:07 +02:00
Thomas Göttgens
4087bd93a9 Axe trunk from check
We run that anyway as a separate job No need to run it in the matrix.
2024-05-16 17:35:14 +02:00
rcarteraz
57575f8e49 remove has screen = 0 2024-05-16 08:11:46 -07:00
Thomas Göttgens
d02e12a424 fix include path 2024-05-16 17:03:04 +02:00
Thomas Göttgens
fce281f54c update sensor libs 2024-05-16 17:03:04 +02:00
Thomas Göttgens
d95e3acab3 implements #3885 2024-05-16 15:52:22 +02:00
Ben Meadors
cc864291c2 Merge branch 'master' into fix-tbeam-s3 2024-05-16 07:49:09 -05:00
Thomas Göttgens
c04c589ae7 Merge pull request #3906 from Jorropo/remove-unused-imports/platformio-custom
bin: remove unused imports from platformio-custom.py
2024-05-16 14:47:29 +02:00
Ben Meadors
51d2795b26 Fix TBeam Supreme woes (and upgrade platform) 2024-05-16 07:46:47 -05:00
Jorropo
04837b3302 bin: remove unused imports from platformio-custom.py 2024-05-16 02:39:42 +02:00
Henrik Witt-Hansen
1d42a6c48f Fix static ip assignment on wifi for rp2040 (#3896)
by rearranging the arguments to match the expected input order.
The lwip library makes an internal reorder or the arguments
depending on the netmask to work with both ESP and Arduino
platforms.

The input order was incorrect when running on an rp2040 device.

Co-authored-by: Henrik Witt-Hansen <henrik@hardttoolkit.org>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-15 18:54:51 -05:00
Thomas Göttgens
4cd70f3cbd Merge pull request #3903 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-16 01:31:26 +02:00
caveman99
c18b4920ae [create-pull-request] automated change 2024-05-15 23:28:03 +00:00
Thomas Göttgens
eeb9a368f0 Merge pull request #3902 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-16 01:17:56 +02:00
Thomas Göttgens
306b8d3205 Merge branch 'master' into create-pull-request/patch 2024-05-16 01:17:37 +02:00
Thomas Göttgens
0c9eadc507 Resync 2024-05-16 01:16:05 +02:00
caveman99
fe2356ae87 [create-pull-request] automated change 2024-05-15 23:12:12 +00:00
Thomas Göttgens
c57d45ba52 Merge pull request #3893 from Dr-Gandalf/feature/veml7700
Implementation of the sensor VEML7700
2024-05-16 01:11:35 +02:00
Thomas Göttgens
fc03eee4d9 Merge branch 'master' into feature/veml7700 2024-05-16 01:09:38 +02:00
Thomas Göttgens
53dea44983 Revert "Merge pull request #3898 from meshtastic/create-pull-request/patch"
This reverts commit 938aba481a, reversing
changes made to 7810e59b0c.
2024-05-16 01:08:52 +02:00
Thomas Göttgens
3342395a0b fix generated files 2024-05-16 01:04:38 +02:00
Thomas Göttgens
6dbc858102 Revert "tryfix proto conflict"
This reverts commit 79628c73cd.
2024-05-16 00:26:01 +02:00
Thomas Göttgens
79628c73cd tryfix proto conflict 2024-05-16 00:23:51 +02:00
Thomas Göttgens
eaa7fcf3dc Revert "Updated protobufs submodule"
This reverts commit 022e1f472d.
2024-05-16 00:23:03 +02:00
Thomas Göttgens
861bec05f4 Merge pull request #3901 from Jorropo/remove-unused-import
bin: remove unused import in buildinfo.py
2024-05-15 23:56:46 +02:00
Jorge Castillo
ce25381f67 fix unrelated change 2024-05-15 17:13:28 -04:00
Jorge Castillo
e08c808c3f fix log line 2024-05-15 17:06:23 -04:00
Jorropo
9e8ca69a11 bin: remove unused import in buildinfo.py
This was originally added in b1c30f0650 and it now do nothing since 361556a6a7 because it now use readprops.
2024-05-15 23:00:12 +02:00
Ken McGuire
bd9156de24 GPS Chechsum failures (#3900)
* Portduino multiple logging levels

* Fixes based on GPSFan work

* Fix derped logic

* Correct size field for AID message

* Reformat to add comments, beginning of GPS rework

* Update PM2 message for Neo-6

* Correct ECO mode logic as ECO mode is only for Neo-6

* Cleanup ubx.h add a few more comments

* GPS rework, changes for M8 and stub for M10

* Add VALSET commands for u-blox M10 receivers

* Add VALSET commands for u-blox M10 receivers
tweak M8 commands
add comments for VALSET configuration commands

* Add commands to init M10 receivers,
tweak the M8 init sequence, this is a WIP as there are still some issues during init.
Add M10 version of PMREQ.

* Add wakeup source of uartrx to PMREQ_10
The M10 does not respond to commands when asleep,
may need to do this for the M8 as well

* Enable NMEA messages on USB port.
Normally, it is a good idea to disable messages on unused ports.
Native Linux needs to be able to use GNSS modules connected via
via either serial or USB.
In the future I2C connections may be required, but are not enabled for now.

* Save the config for all u-blox receiver types.
The M10 supports this command in addition to saving using
the VALSET commands for the RAM & BBR layers.

* Address Issue #3779 RAK12500 GPS Checksum failures
Remove NMEA sentences that are not processed by TinyGPS++ or Meshtastic.

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-15 12:12:46 -05:00
Thomas Göttgens
938aba481a Merge pull request #3898 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-15 14:48:12 +02:00
caveman99
419820f483 [create-pull-request] automated change 2024-05-15 12:47:31 +00:00
Thomas Göttgens
73087f667a Merge branch 'master' into feature/veml7700 2024-05-15 12:27:11 +02:00
Thomas Göttgens
7810e59b0c Merge pull request #3895 from meshtastic/fix-guards
fix native compilation for linux PCs
2024-05-15 12:25:21 +02:00
Thomas Göttgens
64dc6cc215 trunk fmt 2024-05-15 12:24:42 +02:00
mverch67
33812a2082 update portduino-framework 2024-05-15 11:18:39 +02:00
Thomas Göttgens
78a1b6a9a8 unrelated change, i just noticed this problem... 2024-05-15 09:59:46 +02:00
mverch67
49a9aa3e36 fix native compilation for linux PCs 2024-05-15 08:10:52 +02:00
Jorge Castillo
8d89e78bbf Merge branch 'master' into feature/veml7700 2024-05-14 19:00:32 -04:00
Jorge Castillo
0aa449bca9 Fix unnecessary code block removal in EnvironmentTelemetryModule 2024-05-14 18:47:20 -04:00
Jorge Castillo
a3e47b8d9b merge master in to veml7700 2024-05-14 17:40:34 -04:00
Jorge Castillo
022e1f472d Updated protobufs submodule 2024-05-14 17:00:33 -04:00
Jorge Castillo
77e76bc92b Fix VEML7700Sensor readings and update protobuf and MQTT JSON 2024-05-14 16:42:23 -04:00
Thomas Göttgens
5da798c625 Merge pull request #3891 from 2itea/master
Change SHT4X sensors library from Sensirion to Adafruit
2024-05-14 21:50:20 +02:00
pr000t
15178da566 Change SHT4X sensors library from Sensirion to Adafruit 2024-05-14 21:07:44 +02:00
Thomas Göttgens
c12b9b928b Merge pull request #3890 from GUVWAF/rp2040heap
RP2040: Add `getFreeHeap()` and `getHeapSize()` support
2024-05-14 19:38:06 +02:00
GUVWAF
1f9ff68f1d RP2040: Add getFreeHeap() and getHeapSize() support 2024-05-14 19:04:31 +02:00
Thomas Göttgens
3b5d4e92c5 add psram flag on RAK11200 board definition (#3887) 2024-05-14 13:48:26 +02:00
todd-herbert
2388eb91ae Fix immediate wake from deepsleep for some devices (#3884)
Affects ESP32 boards without an external pull-up on the defined user-button pin.
2024-05-14 06:46:03 -05:00
todd-herbert
a9a208de73 Implement "Flip screen" setting for E-Ink displays (#3871) 2024-05-13 06:42:41 -05:00
Thomas Göttgens
078f33ff78 Re-add missing files (#3873) 2024-05-13 11:45:22 +02:00
Thomas Göttgens
4d8c98c23d Update CI runner versions from Node 16 to 20. (#3872) 2024-05-13 10:47:40 +02:00
Thomas Göttgens
859fd7c251 Generate the build matrix from the variant files (#3870) 2024-05-12 22:43:47 +02:00
Thomas Göttgens
5de0c71a3e add bobricius tracksenger variants (#3866) 2024-05-11 19:50:54 -05:00
Thomas Göttgens
96b5bd2fd0 unphone has a display, don't default BLE PIN to 123456 (#3865)
fixes #3822
2024-05-11 08:20:11 -05:00
Thomas Göttgens
d8d831b27a Revert "exclude serial module for T-Echo, saves 3000 bytes"
This reverts commit 38347fa6db.
2024-05-11 14:19:53 +02:00
Thomas Göttgens
6ee995e262 Merge pull request #3818 from lewisxhe/master
Enhanced t-echo file system integrity check
2024-05-11 12:55:06 +02:00
Thomas Göttgens
c6f028a5f3 Merge branch 'master' into master 2024-05-11 11:58:43 +02:00
Thomas Göttgens
42cb9b854c Merge pull request #3859 from meshtastic/debug-mute
add optional define DEBUG_MUTE
2024-05-11 11:57:46 +02:00
Thomas Göttgens
e28f869d35 Merge pull request #3860 from meshtastic/exclude-serial
exclude serial module for T-Echo, saves 3000 bytes
2024-05-11 11:57:28 +02:00
Thomas Göttgens
ef1f2e47c3 Merge pull request #3858 from Jorropo/github/linux-native
.github: add Linux Native and other as platform to Feature Request
2024-05-11 10:05:20 +02:00
Thomas Göttgens
3b6ce29cca add the now common RP2040 2024-05-11 10:05:03 +02:00
Thomas Göttgens
38347fa6db exclude serial module for T-Echo, saves 3000 bytes 2024-05-11 10:03:13 +02:00
Thomas Göttgens
86b14793de add optional define DEBUG_MUTE
This shaves roughly 60k from firmware builds by not including the Logging Ressource strings. Define in variant.h or architecture.h

Stats from T-ECHO compiles:
Before:
Flash: [========  ]  81.5% (used 664700 bytes from 815104 bytes)
After:
Flash: [=======   ]  74.5% (used 606924 bytes from 815104 bytes)
2024-05-11 09:46:39 +02:00
Jorropo
58484d7fe5 .github: add Linux Native and other as platform to Feature Request 2024-05-11 02:10:23 +02:00
github-actions[bot]
69d765622f [create-pull-request] automated change (#3846)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-05-10 08:16:49 -05:00
Ben Meadors
f06c56a51b Removing release build type due to huge amount of flash utilization 2024-05-10 07:14:28 -05:00
Ben Meadors
ac22a503de Revert "Revert "Add Sensirion SHT4X sensors (#3792)" (#3845)" (#3850)
This reverts commit 5d9800b7c2.
2024-05-10 07:13:12 -05:00
Jonathan Bennett
676319a9ca Implement chunked SPI transfer for ch341 (#3847)
This seems to fix the ch341 quirk where large packets fail to send. As it can be problematic for other radios, we gate it behind "ch341_quirk" in the config.
2024-05-10 04:36:20 -05:00
Ben Meadors
5d9800b7c2 Revert "Add Sensirion SHT4X sensors (#3792)" (#3845)
This reverts commit 5371f134ba.
2024-05-09 21:25:36 -05:00
Jonathan Bennett
0c89aff0f6 Enable telemetry and power telemetry on the native target 2024-05-09 15:45:16 -05:00
todd-herbert
5e160b21c7 T-Echo screen and button performance (#3840)
* Make button timing configurable per variant

* Adjust button timing for T-Echo
Easier multi-clicks for features like "toggle backlight" (4x click)

* Fewer full-refreshes for T-Echo display
Disables ghost pixel tracking: T-Echo ghost pixels are fairly faint.
2024-05-09 08:14:58 -05:00
Jorge Castillo
39336847ad add veml7700 readings to protobuf and to the mqtt json + fix the readigns validator code in env telemetry 2024-05-08 22:14:55 -04:00
todd-herbert
75dc8cccec Button ISR runs thread asap (#3801) 2024-05-08 16:08:24 -05:00
Nicholas Baddorf
147de75a02 Added modifier key combination to allow keyboard shortcuts on t-deck (#3668)
* Updated kbI2cBase.cpp

Updated keyboard settings for t-deck to allow a modifier key to trigger 'tab', mute notifications, or quit. To trigger the modifier press the shift key and mic (0) button at the same time. Then press q (quit), m (mute), or t (tab).

* Update kbI2cBase.cpp

* fixed formatting issues in kbI2cBase.cpp

* Removed keyboard shortcut code that doesnt work

alt+t does not work on a t-deck so I removed it to avoid confusion.

* Updated kbI2cBase.cpp

Updated keyboard settings for t-deck to allow a modifier key to trigger 'tab', mute notifications, or quit. To trigger the modifier press the shift key and mic (0) button at the same time. Then press q (quit), m (mute), or t (tab).

* Update kbI2cBase.cpp

* fixed formatting issues in kbI2cBase.cpp

* Removed keyboard shortcut code that doesnt work

alt+t does not work on a t-deck so I removed it to avoid confusion.

* Changed modifier key to alt+c

* Added screen brightness functionality

Use modifier key with o(+) to increase brightness or i(-) to decrease.

Currently there are 4 levels of brightness, (L, ML, MH, H). I would like to add a popup message to tell you the brightness.

* Added checks to disable screen brightness changes on unsupported hardware

* Setting the brightness code to work on only applicable devices

* Added "function symbol" display to bottom right corner of screen. Now shows when mute is active or modifier key is pressed. Also fixed some other minor issues.

* commented out a log

* Reworked how modifier functions worked, added

I wasn’t  happy with my previous implementation, and I think it would have caused issues with other devices. This should work on all devices.

* Added back the function I moved causing issue with versions

* Fixed the version conflicts, everything seems to work fine now

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-05-08 07:37:50 -05:00
pr000t
5371f134ba Add Sensirion SHT4X sensors (#3792)
* add Sensirion SHT4X sensors

* Update platformio.ini

Fix lib version

* Delete src/mesh/generated/meshtastic/telemetry.pb.h

* Revert "Delete src/mesh/generated/meshtastic/telemetry.pb.h"

This reverts commit 8e5e6a9f6ff4e31ed32775741c03a855e663a5de.

* remove modification on generated file

* Update ScanI2CTwoWire.cpp

Fix copy/paste issue

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-05-08 07:02:53 -05:00
Max
8105c0440a New variants PROMICRO_DIY (#3788)
* New variants PROMICRO_DIY

* Renaming and cleanup

* Renaming - phase 2

* nrf52_promicro: Trunk formatting

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-05-08 06:53:13 -05:00
lewisxhe
6c75f2e627 Move LFS_NO_ASSERT to nrf52.ini 2024-05-08 08:51:24 +08:00
lewisxhe
5aef921962 Merge branch 'master' of https://github.com/lewisxhe/firmware 2024-05-08 08:49:23 +08:00
lewisxhe
8c3b9a6139 Move LFS_NO_ASSERT to nrf52.ini 2024-05-08 08:46:08 +08:00
lewisxhe
73ab43c67a Change to LOG_ERROR 2024-05-08 08:45:24 +08:00
Jorge Castillo
23466b5a5f regenerated files 2024-05-07 18:07:24 -04:00
Jorge Castillo
f19aa49eb2 add veml7700 2024-05-07 16:11:41 -04:00
lewisxhe
1d583341e4 trunk fmt 2024-05-07 16:20:43 +02:00
lewisxhe
8e7ede16ef Remove debug wait 2024-05-07 16:20:43 +02:00
lewisxhe
8886d2df55 Enhanced t-echo file system integrity check 2024-05-07 16:20:43 +02:00
Ben Meadors
cbf20e4cee Default to new vendor ntp pool (#3819) 2024-05-07 07:57:30 -05:00
lewisxhe
81ecd6d926 trunk fmt 2024-05-07 14:33:16 +08:00
lewisxhe
b63997b36f Remove debug wait 2024-05-07 13:42:00 +08:00
lewisxhe
76adcbb46b Enhanced t-echo file system integrity check 2024-05-07 11:57:49 +08:00
Jonathan Bennett
c009c0db1e Elimate non-text output for Portduino 2024-05-06 22:27:12 -05:00
Ben Meadors
2c99f11073 Revert "set USB_CDC_ON_BOOT, udate arduinoespressif32 to 2.0.15 (#3764)" (#3809)
This reverts commit 71400103b3.
2024-05-06 17:35:38 -05:00
Ben Meadors
0d57d29cbd Send fixed position to mesh after setting it (#3803) 2024-05-06 14:51:19 -05:00
Thomas Göttgens
353c7e07d1 Wiphone (#3793)
* add wiphone, still WIP

* (very preliminary) wiphone support

* undo config changes

* revert extensions.json

* eh?
2024-05-06 06:48:57 -05:00
HarukiToreda
77a66e1dce Fix for EnvironmentTelemetry Screen (#3785)
* Update EnvironmentTelemetry.cpp

* Update EnvironmentTelemetry.cpp

Corrected lines I deleted by mistake

* trunk fmt

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-05-06 06:47:34 -05:00
Thomas Göttgens
e98c3bf5d0 Merge pull request #3802 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-06 13:39:44 +02:00
caveman99
5e9d48d0d7 [create-pull-request] automated change 2024-05-06 11:37:03 +00:00
Thomas Göttgens
8e91f895a6 Merge pull request #3800 from oseiler2/fix/RCWL9620-MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR
Add MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR exclusion to RCWL9620
2024-05-06 12:06:17 +02:00
Oliver Seiler
b155a5b6dc rearrange includes 2024-05-06 12:15:49 +12:00
Oliver Seiler
2c30923e3e add MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR exclusion to RCWL9620 2024-05-06 11:25:18 +12:00
Thomas Göttgens
0afe2d459f Merge pull request #3790 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-05-05 17:34:07 +02:00
caveman99
0b239e618d [create-pull-request] automated change 2024-05-05 15:32:28 +00:00
Thomas Göttgens
e9ebdfeff2 Merge pull request #3787 from GUVWAF/ccToPhoneErr
Check if packet is not released before CC to phone
2024-05-05 16:47:11 +02:00
GUVWAF
6fb7d7f2d7 Check if packet is not released before CC to phone 2024-05-05 13:49:50 +02:00
tuxphone
70712d859c Enable compiling with gccnoneeabi 12.3.1 for nRF52 targets, additional small fixes (#3778)
* Fix type of nodeNum

Type of nodeNum is NodeNum, not uint

* typo

fixed typo "resumeAdverising()"

* fix missing #include "time.h"

Missing include breaks compilation with gccnoneeabi 12.3.1 for nrf52 targets on windows hosts.

* change type uint to unsigned int

uint is not a standard type. Using uint breaks compilation with gccnoneeabi 12.3.1 for nRF52 targets on windows hosts.

* fix type of channel_num

Type of channel_num should be uint32_t (as this is the type of hash() and numChannels).

Using uint non-standard type uint breaks compilation with gccnoneeabi 12.3.1 for nRF52 targets on windows hosts.

* Update nrf52.ini

Default build type should be "release" as this is the default of platformio.

* Update GPS.cpp

uint to unsigned int
2024-05-03 15:49:22 -05:00
Thomas Göttgens
4d9081b3b1 Merge pull request #3678 from meshtastic/RCWL-9620
Support radar sensor RCWL-9620 on i2c
2024-05-03 20:37:27 +02:00
Thomas Göttgens
7643a1acb1 Merge branch 'RCWL-9620' of github.com:meshtastic/firmware into RCWL-9620 2024-05-03 20:05:24 +02:00
Thomas Göttgens
61216e579e there 2024-05-03 19:25:37 +02:00
Thomas Göttgens
e31bb2d513 Merge branch 'master' into RCWL-9620 2024-05-03 16:00:08 +02:00
Thomas Göttgens
a8c38c4580 Merge pull request #3775 from lewisxhe/master
Fix the infinite restart caused by unformatted t-echo fs file system
2024-05-03 15:59:07 +02:00
Thomas Göttgens
85e0372d26 darn you, trunk. foiled my cunning plan. 2024-05-03 15:58:16 +02:00
Thomas Göttgens
53bd9de9b8 Merge branch 'master' into RCWL-9620 2024-05-03 15:12:51 +02:00
Thomas Göttgens
13ad524538 make clang-format happy again. Also fix assorted variable shrouding and logic bleeps 2024-05-03 15:10:57 +02:00
Thomas Göttgens
5f90f45ac4 trunk fmt 2024-05-03 15:04:11 +02:00
lewisxhe
dc0593c5a7 Fix the infinite restart caused by unformatted t-echo fs file system 2024-05-03 15:04:11 +02:00
Thomas Göttgens
df3cceb108 Merge pull request #3776 from oseiler2/fix/MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR
Fix #MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR
2024-05-03 15:02:47 +02:00
Thomas Göttgens
827dcfca4a trunk fmt 2024-05-03 14:26:57 +02:00
Thomas Göttgens
9fb6148aff Merge branch 'master' into RCWL-9620 2024-05-03 12:28:08 +02:00
Oliver Seiler
6c1377aa39 fix case statement 2024-05-03 18:59:33 +12:00
Oliver Seiler
077ca5919a MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR refinements 2024-05-03 14:15:13 +12:00
Oliver Seiler
668b716119 move QMC5883LCompass dependency to environmental_base 2024-05-03 14:15:13 +12:00
Oliver Seiler
eaa7e21bc7 exclude AccelerometerThread when MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR is set 2024-05-03 14:15:13 +12:00
Oliver Seiler
be0e882be1 exclude sensors when MESHTASTIC_EXCLUDE_ENVIRONMENTAL_SENSOR set 2024-05-03 14:15:13 +12:00
github-actions[bot]
09080d76ad [create-pull-request] automated change (#3773)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-05-02 20:46:22 -05:00
Ben Meadors
d490a332a7 Update version.properties 2024-05-02 19:11:35 -05:00
todd-herbert
5dfa4b837f Ensure LED is off when disabling heartbeat (#3772) 2024-05-02 19:11:13 -05:00
github-actions[bot]
9501f3bda9 [create-pull-request] automated change (#3771)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-05-02 16:17:41 -05:00
Jonathan Bennett
b69a1cada9 Portduino bump to pick up minor fix (#3770) 2024-05-02 13:54:50 -05:00
Jonathan Bennett
06e7d2b845 Track actual GPIO values, not just the enum values (#3768)
* Track actual GPIO values, not just the enum values

* trunk
2024-05-02 13:39:28 -05:00
Oliver Seiler
71400103b3 set USB_CDC_ON_BOOT, udate arduinoespressif32 to 2.0.15 (#3764) 2024-05-02 13:39:18 -05:00
Thomas Göttgens
40e361e6d0 Merge pull request #3763 from lewisxhe/master
Fix t-echo gps failure
2024-05-02 15:13:43 +02:00
lewisxhe
d1b6f11429 Fix t-echo gps failure 2024-05-02 14:39:58 +02:00
todd-herbert
0527fb10ce Init. battery voltage from ADC reading, instead of fixed value (#3761) 2024-05-02 07:14:44 -05:00
Andrew Yong
5f929a8024 Publish fixed position updates and consider changes in only altitude as an updated point (#3758)
* AdminModule: Publish fixed position updates

Enabled GPS thread when fixed position is updated, to let the GPS thread run once and publish the new fixed position.

Signed-off-by: Andrew Yong <me@ndoo.sg>

* GPS: Consider changes in only altitude as an updated point

Signed-off-by: Andrew Yong <me@ndoo.sg>

---------

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-05-02 07:13:36 -05:00
Thomas Göttgens
4f54862d63 Merge pull request #3765 from meshtastic/twc-mesh-buildfix
fix building new TWC_mesh_v4 board
2024-05-02 13:30:49 +02:00
Thomas Göttgens
0f4ac94559 fix building new TWC_mesh_v4 board 2024-05-02 12:48:50 +02:00
Jonathan Bennett
45c1b46bd0 Move native to spi_host to indicate spidev for LovyanGFX 2024-05-01 13:21:23 -05:00
Jonathan Bennett
5095efc55f Pick up support for more than 64 GPIO lines under Portduino 2024-05-01 13:21:23 -05:00
Ben Meadors
ec92f7a5a3 Remove phone nodenum warning and empty else clause (#3756) 2024-05-01 08:27:43 -05:00
Ben Meadors
57da37cfbc Position module should enforce precision for phone originated position packets (#3752) 2024-05-01 08:05:26 -05:00
github-actions[bot]
3619ac87b8 [create-pull-request] automated change (#3754)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-30 20:14:38 -05:00
GUVWAF
e51ee91c39 Optimization: stop relaying when reply is received (#3753) 2024-04-30 20:07:15 -05:00
todd-herbert
21311bbeda T-Echo touch button no longer requires "wake on tap or motion" (#3745) 2024-04-29 08:54:57 -05:00
Ben Meadors
472db5b237 Merge branch 'master' into RCWL-9620 2024-04-28 07:05:54 -05:00
Andrew Yong
18e69a0906 Update Heltec HT-C62 variant based on HT-DEV-ESP board (#3731)
* I2C is not defined in the reference schematic nor HT-DEV-ESP board, remove definition accordingly
* There is no screen in the the reference schematic nor HT-DEV-ESP board, change definition accordingly
* BUTTON_PIN has a 10 kOhm pullup resistor on HT-DEV-ESP, turning off redundant internal pullup should save some power
* LED is connected to GPIO2 on HT-DEV-ESP and is not inverted, update definition accordingly
* Remove redundant undef lines for LoRa pins

Above changes were built and flashed to my [HT-DEV-ESP_V2 board purchased from Heltec's Taobao store](https://item.taobao.com/item.htm?id=521590063077).

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-04-28 06:49:26 -05:00
David Ellefsen
93f77ea7d2 Update TinyGPSPlus version (#3727)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-27 19:50:15 -05:00
Mike
ee4c4ae6c9 Allow setting hopLimit for MQTT json sendtext and sendposition (#3735)
* Fix channel name extraction

* Allow setting hopLimit for mqtt sendtext and sendposition
2024-04-27 18:15:54 -05:00
Ben Meadors
6cc7dee95c Tradunkadunk 2024-04-27 11:12:52 -05:00
HarukiToreda
38c4d35a7b Add Notification on device screen following feature toggle (#3627)
* Update CannedMessageModule.h

* Update CannedMessageModule.cpp

* Update CannedMessageModule.cpp

hopefully this fixes the errors on Trunk

* Update CannedMessageModule.cpp

Changed "Ping Broadcasted" with "Telemetry Update Sent"

* tryfix: disable tempmessage again after 2 seconds

* fix 2s showtime

* Put spelling fix back

* Fix build

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-27 11:08:25 -05:00
Ben Meadors
e683d8f552 Rebrand "send network ping" to more honest "try send position" with better output (#3737) 2024-04-27 08:55:04 -05:00
jcyrio
e66aec8223 fix typo in comment (#3726) 2024-04-27 08:54:06 -05:00
Oliver Seiler
a06a01d25e fix #if HAS_TELEMETRY when set to 0 (#3733) 2024-04-27 06:35:44 -05:00
Andrew Yong
f8c3f43ea6 Fix xiao_ble variant build error due to undefined BATTERY_SENSE_RESOLUTION_BITS (#3732)
Define BATTERY_SENSE_RESOLUTION_BITS based on [amoroz's snippet on the Meshtastic forum](https://meshtastic.discourse.group/t/new-1w-diy-variant-xiao-nrf52840-ebyte-e22-900m30s/7904/10).

Fixes following build error:

```
src/Power.cpp: In member function 'virtual uint16_t AnalogBatteryLevel::getBattVoltage()':
src/Power.cpp:224:79: error: 'BATTERY_SENSE_RESOLUTION_BITS' was not declared in this scope
             scaled = operativeAdcMultiplier * ((1000 * AREF_VOLTAGE) / pow(2, BATTERY_SENSE_RESOLUTION_BITS)) * raw;
```

Signed-off-by: Andrew Yong <me@ndoo.sg>
2024-04-27 06:17:17 -05:00
todd-herbert
dfcabba0b2 Prevent overflow when calculating timezones (#3730) 2024-04-26 20:43:09 -05:00
Thomas Göttgens
827bacdfc8 Merge pull request #3723 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-04-25 23:46:43 +02:00
thebentern
5806a266d3 [create-pull-request] automated change 2024-04-25 20:19:54 +00:00
Jonathan Bennett
30fbcabf84 add conffiles to .deb packaging (#3722) 2024-04-25 14:23:38 -05:00
Arkadiusz Miśkiewicz
c14043f196 Split warning into two messages, so we know which one is the case. (#3710) 2024-04-25 06:47:39 -05:00
Jonathan Bennett
e3610a2eb1 Move to lovyangfx develop for Native 2024-04-24 13:17:43 -05:00
Oleksandr Podolchak
9baccc80d8 Add SX1268 modules support for linux-native (#3702)
* Add portduino Ebyte E22 XXXM30S/XXXM33S (sx1268) module support

* Add Ebyte E22 XXXM3XS module config

* Update comment for sx1268 module

* Address review comments

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-24 08:41:01 -05:00
Gareth Coleman
ac16ccf40c fix for unPhone hangs during boot without sd card present (#3709)
* work around sd card hang if not present

* comment out the define for HAS_SDCARD
2024-04-24 06:41:05 -05:00
Ben Meadors
1c0227f90c Merge branch 'master' into RCWL-9620 2024-04-23 14:19:08 -05:00
Jonathan Bennett
57d296e0db Add better support for the Adafruit PiTFT 2.8 for Native (#3704)
* Add better support for the Adafruit PiTFT 2.8 for Native

* native: Make touch i2c address configurable

* Bump portduino to pick up I2C features

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-23 14:18:51 -05:00
SCWhite
9c9d126f6b [BOARD] Add new variant: TWC_Mesh (#3705)
* add new variant: TWC_mesh_v4

* fix trunk format

* fix format under wsl

* change board to TWC_mesh_v4

* change platformio & variant.h properly

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-23 14:09:28 -05:00
github-actions[bot]
27f0e42d2f [create-pull-request] automated change (#3708)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-23 13:32:33 -05:00
todd-herbert
4599534616 Terminate an async-full-refresh when caught by determineMode() instead of onNotify() (#3706) 2024-04-23 12:00:48 -05:00
Tom Fifield
7acaec8ef5 Add power limit for TW region (#3701)
The TW region had now power limit set, so defaulted to 16dBm.

The relevant regulation is section 5.8.1 of the Low-power Radio-frequency Devices Technical Regulations, which notes the limits of  0.5W (27dBM) indoor or coastal, 1.0W (30dBM) outdoor.

This patch updates the power limit to 27dbM, using the the lower limit specified in the regulations to be conservative.

Regulation references:
https://www.ncc.gov.tw/english/files/23070/102_5190_230703_1_doc_C.PDF (latest English version)
https://gazette.nat.gov.tw/egFront/e_detail.do?metaid=147283 (latest Chinese version, February 2024)
2024-04-23 07:11:22 -05:00
Nicholas Baddorf
d0e81b9151 Fixed node and channel selection for t-deck (#3695)
This enables the node and channel selection to be accessed by pressing the tab shortcut and then swiping between nodes or pressing tab again to change channels.

(To access the tab function look at my other pull request https://github.com/meshtastic/firmware/pull/3668)

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-23 07:09:26 -05:00
Thomas Göttgens
c6e940af81 Merge branch 'master' into RCWL-9620 2024-04-23 14:04:22 +02:00
Thomas Göttgens
3302fbcc53 Merge pull request #3647 from garethhcoleman/RGBLED
Support for generic 4pin RGB LEDs (both CC and CA) and NeoPixels, also RGB LED and vibration notification support for unPhone
2024-04-23 13:57:23 +02:00
Gareth Coleman
ccbf635eef corrected a bit of overzealous tidying 2024-04-22 17:21:41 +01:00
Gareth Coleman
6669b22db3 tidied up, prob broke everything 2024-04-22 16:37:05 +01:00
Gareth Coleman
ec2b854ea2 oops missed the extern enabling little chap 2024-04-22 14:44:59 +01:00
Gareth Coleman
378a2d723e Merge branch 'RGBLED' of github.com:garethhcoleman/firmware into RGBLED 2024-04-22 14:43:07 +01:00
Gareth Coleman
5dd08e9533 added NeoPixel support using Adafruit library 2024-04-22 14:42:52 +01:00
Gareth Coleman
125add9792 Merge branch 'master' into RGBLED 2024-04-22 14:42:14 +01:00
Andrew Yong
250cf16bf8 Add ability to turn off heartbeat LED blinking (#3674)
* Add ability to turn off status LED blinking

Fixes #3635 and depends on [protobufs PR #485](https://github.com/meshtastic/protobufs/pull/485)

Signed-off-by: Andrew Yong <me@ndoo.sg>

* led_heartbeat_disabled

* trunk

---------

Signed-off-by: Andrew Yong <me@ndoo.sg>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-22 08:21:50 -05:00
Thomas Göttgens
8b5fad21b0 Merge pull request #3693 from titan098/updates_for_esp32s2_build
Updates for esp32s2 builds
2024-04-22 13:56:14 +02:00
David Ellefsen
30d4c3a945 Updates for esp32s2 build 2024-04-22 11:01:13 +02:00
Gareth Coleman
45fd5e25ac Merge branch 'master' into RGBLED 2024-04-22 09:15:44 +01:00
Thomas Göttgens
ac6a668362 Merge pull request #3697 from meshtastic/nrf52-signfix
fix signedness warnings of NRF52 toolchain
2024-04-22 10:13:38 +02:00
Thomas Göttgens
f47b40cf68 fix signedness warnings of NRF52 toolchain 2024-04-22 09:49:06 +02:00
quimnut
fd9461505f adjust adc for rak11310 devices (#3698) 2024-04-21 19:51:02 -05:00
Ben Meadors
84edaabfe9 Merge branch 'master' into RGBLED 2024-04-21 14:46:18 -05:00
Ben Meadors
048f0a1601 Merge branch 'master' into RCWL-9620 2024-04-21 14:41:49 -05:00
Nicholas Baddorf
4a48a3fb52 Fixed bug making t-deck reboot when muted (#3694) 2024-04-21 14:41:22 -05:00
Ben Meadors
39bbf0d352 Added more clear RTC handling and quality logging (#3691)
* Also refresh timestamp for "timeonly" fixed position nodes

* Added more clear RTC quality handling

* Fix clock drift from Phone GPS / NTP too
2024-04-21 14:40:47 -05:00
Ben Meadors
675d8fe089 Merge branch 'master' into RCWL-9620 2024-04-21 12:37:38 -05:00
Mictronics
0406be82d2 Use correct format specifier and fixed typo. (#3696)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

* Use correct format specifier and fixed typo.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-21 12:36:37 -05:00
Ric In New Mexico
679e068e19 Missing break in INA3221 i2c scan (#3692)
* INA3221 Mis-identification fix

* Missing break in INA3221 i2c scan
2024-04-21 12:35:42 -05:00
Thomas Göttgens
952393ca0f Merge branch 'master' into RCWL-9620 2024-04-21 18:34:40 +02:00
Thomas Göttgens
a231cd2ad0 derp... 2024-04-21 16:35:41 +02:00
Ben Meadors
ac87c0065f Also refresh timestamp for "timeonly" fixed position nodes (#3689) 2024-04-21 08:45:36 -05:00
S5NC
9822a85274 Add board and variant definitions for EBYTE_ESP32-S3 (#2882)
* Create ESP32-S3-WROOM-1-N4.json

* Create pins_arduino.h

* Create platformio.ini

* Create variant.h

* Update mesh.pb.h

* Update architecture.h

* Update mesh.pb.h

* Update variant.h

* Update variant.h

Add example schematic

* Update architecture.h

* Revert update architecture.h

* Create variant.h

* Create pins_arduino.h

* Create platformio.ini

* Delete variants/E22-900M_S3 directory

* Update architecture.h

* Update variant.h

* Update platformio.ini

* Update variant.h

* Update variant.h

* Update architecture.h

* Update platformio.ini

* Update architecture.h

* Update ESP32-S3-WROOM-1-N4.json

* Update platformio.ini

* Update ESP32-S3-WROOM-1-N4.json

* Update variant.h

* Update variant.h

* Update variant.h

* Update variant.h

* Update pins_arduino.h

* Update architecture.h

* add SX1268 allow

* GPS

* Commit

* Whitespace

* Update variant.h

* Update variant.h

* trunk

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
Co-authored-by: S5NC <>
2024-04-21 08:40:23 -05:00
Thomas Göttgens
a957065fe8 Merge branch 'master' into RCWL-9620 2024-04-21 14:47:29 +02:00
Ben Meadors
41f3557491 Refactor smart position to use throttle helper (#3671)
* Added one minute throttling to NodeDB

* Derp

* Refactor smart-position to use throttle
2024-04-21 07:42:36 -05:00
Thomas Göttgens
402b0d7e0b ditch that no-good m5 dependancy and do it ourself 2024-04-21 14:39:55 +02:00
Thomas Göttgens
13ebda6b2f Merge branch 'RCWL-9620' of github.com:meshtastic/firmware into RCWL-9620 2024-04-21 14:35:32 +02:00
Ben Meadors
1dd19cec6e Merge branch 'master' into RCWL-9620 2024-04-21 07:34:11 -05:00
Ben Meadors
df718ab294 Merge branch 'master' into RGBLED 2024-04-21 07:31:54 -05:00
todd-herbert
dfc43bae18 Fix crash on shutdown, if Bluetooth not enabled (#3686)
Previously attempted to call deinit method for a nullptr
2024-04-21 07:25:58 -05:00
todd-herbert
f6cfdfe881 (ESP-32S) Fix "critical error 3" after deep-sleep (#3685) 2024-04-21 07:25:12 -05:00
S5NC
820c5dc8c5 Update architecture.h (#3688) 2024-04-21 07:24:39 -05:00
Thomas Göttgens
1f9c295c9e Merge branch 'RCWL-9620' of github.com:meshtastic/firmware into RCWL-9620 2024-04-21 13:48:08 +02:00
Thomas Göttgens
5218aaafcf Change name 2024-04-21 11:41:52 +02:00
Thomas Göttgens
c480f0870c Support radar sensor RCWL-9620 on i2c 2024-04-21 11:41:52 +02:00
Gareth Coleman
9e4ef92e6d lets just define it without guards! 2024-04-21 09:16:50 +01:00
Gareth Coleman
cf65661c7c another silly error 2024-04-21 08:59:40 +01:00
Gareth Coleman
fb7a878d94 tweaked guards to allow various combinations of RGB leds 2024-04-21 08:24:51 +01:00
github-actions[bot]
e72792afc8 [create-pull-request] automated change (#3683)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-20 15:58:42 -05:00
Ric In New Mexico
ec39e1136a INA3221 Mis-identification fix (#3681) 2024-04-20 15:58:21 -05:00
Thomas Göttgens
94e1f016e5 Change name 2024-04-20 20:49:57 +02:00
Thomas Göttgens
9170fe0580 Support radar sensor RCWL-9620 on i2c 2024-04-20 20:30:22 +02:00
Thomas Göttgens
ef9808cdd6 Merge pull request #3680 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-04-20 20:25:14 +02:00
caveman99
0972a8dccb [create-pull-request] automated change 2024-04-20 18:24:40 +00:00
github-actions[bot]
419eb13968 [create-pull-request] automated change (#3679)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-20 09:56:55 -05:00
github-actions[bot]
e7828c4c64 [create-pull-request] automated change (#3676)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-20 07:36:53 -05:00
Manuel
44aa248099 added new display parameters (#3670) 2024-04-19 19:27:13 -05:00
Gareth Coleman
e0513d4078 ahem, another minor edit to have another go at CI 2024-04-19 09:27:10 +01:00
Gareth Coleman
2100f3135e minor edit to have another go at CI 2024-04-19 09:25:38 +01:00
Gareth Coleman
2f36d4990e Merge branch 'master' into RGBLED 2024-04-19 08:12:13 +01:00
github-actions[bot]
65bde8538f [create-pull-request] automated change (#3663)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-18 20:33:23 -05:00
github-actions[bot]
7a3570aecf [create-pull-request] automated change (#3662)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-18 18:29:50 -05:00
Gareth Coleman
4a471ded79 Merge branch 'RGBLED' of github.com:garethhcoleman/firmware into RGBLED 2024-04-19 00:28:39 +01:00
Gareth Coleman
eea85d26ca oh god the bugs, they are everywhere, I feel so dirty... 2024-04-19 00:28:20 +01:00
GUVWAF
64edfb76e0 Uplink to MQTT after potentially altering content (#3646)
Mainly for traceroute module now

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-18 17:44:13 -05:00
Gareth Coleman
8ac308e73b Merge branch 'master' into RGBLED 2024-04-18 23:12:08 +01:00
Gareth Coleman
0ae7674982 I'm sure there's a cleverer way to do this, but I'm stupid and I didn't find it after a few minutes of searching stack overflow 2024-04-18 22:18:50 +01:00
GUVWAF
e4b5f2ce14 NeighborInfo: Only keep neighbors in RAM (#3660)
* NeighborInfo: Only keep neighbors in RAM
It fills up quickly when nodes are running >=2.3

* Defer first transmission as it's usually empty

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-18 16:16:50 -05:00
Gareth Coleman
7d77b23eb6 support for generic 4 pin CC and CA RGB LEDS 2024-04-18 22:00:33 +01:00
Gareth Coleman
a149999cec tidy up first 2024-04-18 20:57:03 +01:00
Ben Meadors
78d915b454 Merge branch 'master' into RGBLED 2024-04-18 14:44:53 -05:00
GUVWAF
4c0b7ea409 StoreForward: Remove assert when receiving unhandled case (#3661) 2024-04-18 14:28:11 -05:00
Ben Meadors
425a715995 Added one minute throttling to NodeDB save to disk (#3648)
* Added one minute throttling to NodeDB

* Derp
2024-04-18 14:20:39 -05:00
Ben Meadors
2e13aeeacb Merge branch 'master' into RGBLED 2024-04-18 07:32:25 -05:00
todd-herbert
747c713ba9 (ESP32) Fix bluetooth after light-sleep; de-init for deep sleep (#3655) 2024-04-18 07:27:18 -05:00
Gareth Coleman
4b5549be8f added vibration notifications 2024-04-18 09:22:31 +01:00
Gareth Coleman
172d271b0b Merge branch 'master' into RGBLED 2024-04-18 07:11:49 +01:00
Oliver Seiler
2e14234b77 don't enable the CDC interface already at boot (#3652)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-17 16:55:47 -05:00
Jonathan Bennett
d47e9bed19 Add multiple SPI devices for Radio, Display, and Touchscreen (#3638)
This changeset gives us the ability to specify a separate SPI device for the LoRa, Display, and Touchscreen. The changes in Portduino also add support for specifying a new SPI speed for each transaction. All together, this means that we can let the Linux OS manage the CS lines, and also get much faster SPI speeds, leading to better framerates.

* Add multiple SPI devices to put Radio, Display, and Touchscreen on each their own

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-17 14:25:52 -05:00
GUVWAF
bc085ab840 Fix #3641: Always set MAC when picking new NodeNum (#3651)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-17 07:07:40 -05:00
Ben Meadors
2450031b1b Add device metrics uptime to MQTT JSON (#3643)
* Add device metrics uptime to MQTT JSON

* Cast a spell
2024-04-17 07:00:18 -05:00
Ben Meadors
2cd877d2eb Merge branch 'master' into RGBLED 2024-04-16 20:37:02 -05:00
GUVWAF
c34956e9d8 Cosmetics: rename remaining plugins → modules and less errors (#3645) 2024-04-16 17:47:56 -05:00
Gareth Coleman
afb4de21d9 yet another random edit, think i'm brushing the touchpad or perhaps my computer is possessed by the devil determined to make me look foolish 2024-04-16 22:37:57 +01:00
Gareth Coleman
86223d8806 Merge branch 'RGBLED' of github.com:garethhcoleman/firmware into RGBLED 2024-04-16 21:41:57 +01:00
Gareth Coleman
0632b96fcb just tiny tweak to minimise changes 2024-04-16 21:40:13 +01:00
Gareth Coleman
dcfc9c9f03 Merge branch 'meshtastic:master' into RGBLED 2024-04-16 21:29:12 +01:00
Gareth Coleman
8a3322fbcb rgb led support for unPhone 2024-04-16 21:28:12 +01:00
David Ellefsen
55c9c3b298 Support for the ATGM336H series of GPS modules (#3610)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-16 09:03:51 -05:00
Andrew Yong
9599549477 Add configuration option for LoRa Region Code override for region-locked builds/variants (#3540)
The main use case for this will be to create a custom Heltec WiFi LoRa 32 V3 SG_923 variant, which will be pre-flashed and sent for regulatory approval for retail sale.

Signed-off-by: Andrew Yong <me@ndoo.sg>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-16 09:03:36 -05:00
S5NC
e813703bf5 Add support for CDEBYTE_EoRa-S3 (#3613)
* Create CDEBYTE_EoRa-S3.json

* Update CDEBYTE_EoRa-S3.json

* Update architecture.h

* Create variant.h

* Create platformio.ini

* Create pins_arduino.h

* Update variant.h

* Update variant.h

* Update variant.h

* Trunk format

* update variant.h

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: S5NC <>
2024-04-16 09:00:16 -05:00
github-actions[bot]
699ea74672 [create-pull-request] automated change (#3642)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-16 08:01:32 -05:00
todd-herbert
a01069a549 No more printing power-state changes to screen (#3640) 2024-04-16 07:36:14 -05:00
Gareth Coleman
3413b9da41 Fixed XPT2046 syntax and using unPhone library to clean up support (#3631)
* Fixed XPT2046 syntax and using unPhone library to clean up main and TFTDisplay.

* strange extra edits removed wtf
2024-04-16 07:29:08 -05:00
Jonathan Bennett
7d3175dc83 More useful default input device for Pi 400 (#3639) 2024-04-16 07:22:31 -05:00
github-actions[bot]
441638c2eb [create-pull-request] automated change (#3636)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-15 20:23:49 -05:00
Ben Meadors
2f9b68e08b File management changes (Part 2 - Reboot instead of reformat NRF52 after two failed file saves) (#3630)
* Add LoadFileState to differentiate types of success / failures

* Try rebooting NRF52s with multiple failed saves

* Trunkate
2024-04-15 16:36:22 -05:00
Ben Meadors
27ae4399bc Zero hop always for connected node (#3634) 2024-04-15 16:35:52 -05:00
Gareth Coleman
385d7296fe strange extra edits removed wtf 2024-04-15 17:37:39 +01:00
Gareth Coleman
d1cd686644 Fixed XPT2046 syntax and using unPhone library to clean up main and TFTDisplay. 2024-04-15 17:24:08 +01:00
Gareth Coleman
1291da746b Support for alt I2C address for LSM6DS3 sensor, identification of TCA9555 IO Expander, resolve serial hang issue (#3622)
* basic identification of TCA9555

* recognise LSM6DS3 on alt address

* keep variant.h changes out of this PR

* 2nd attempt to keep variant.h changes out of this PR

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-15 07:30:45 -05:00
Ben Meadors
2803fa964e Add LoadFileState to differentiate types of success / failures (#3625) 2024-04-15 07:22:05 -05:00
todd-herbert
1d97544041 Wireless Paper: Fix BLE after Lightsleep (#3629)
* NimBLE deinit for deep-sleep only

* Optionally disable blink during light-sleep

* Advised to revert "blink disable"
This reverts commit 66347ce19b.
2024-04-15 06:50:42 -05:00
Jonathan Bennett
5b52c31a76 Fix HAS_WIRE logic in main 2024-04-14 16:44:28 -05:00
Jonathan Bennett
00d4c011c7 Fix sx126x error log logic 2024-04-14 16:44:28 -05:00
Jonathan Bennett
1447148811 Make sure settingsStrings get initialized 2024-04-14 16:44:28 -05:00
Ben Meadors
4f205718f0 Device telemetry uptime in seconds (#3614) 2024-04-14 10:27:01 -05:00
Manuel
5047468d9f fix/enhancement: TFT device powersave (part 3) (#3600)
* fix: device TFT powersave (part 3)

* trunk fmt

* trunk fmt

* undo bluetooth deinit from #3596

* revert code for heltec tracker

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-14 09:11:27 -05:00
Manuel
ec3971bce5 fix upDown ISR (#3612) 2024-04-14 08:11:22 -05:00
Jonathan Bennett
0a246bfe9b Add more useful error output in radio interfaces (#3615)
* Add more useful error output in radio interfaces

* trunk
2024-04-14 00:29:42 -05:00
Jonathan Bennett
f1a1834ee2 Update portduino to include SPI and setSetial fixes (#3611) 2024-04-13 16:14:15 -05:00
Ben Meadors
2a6e26620e Auto-favorite our node (#3609) 2024-04-12 20:17:25 -05:00
Jonathan Bennett
3f45c2d4f0 Fix another LOG_DEBUG message that should be LOG_ERROR (#3607) 2024-04-12 14:14:56 -05:00
Jonathan Bennett
11adfe05ce Drop unishox2 functions from Router (#3606) 2024-04-12 14:06:05 -05:00
Ben Meadors
b4009f9f2f New fixed copy-pasted more corrector hash 2024-04-12 11:49:35 -05:00
Jonathan Bennett
917b739e62 Update TinyGPS version to un-derped commit 2024-04-12 11:29:08 -05:00
Ben Meadors
2c4db16336 TinyGPSAltitude support for negative altitude (#3605) 2024-04-12 10:49:14 -05:00
Manuel
4c9646f7d9 fix: device sleep (part 1) (#3590)
* fix sleep part 1

* always show wakeup reason in debug log

* fix screen turn on issue

* avoid unnecessary reboot when entering light sleep

* set DIO1 based on radio type

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-12 10:01:24 -05:00
Oliver Seiler
8fd32f3452 enable USB CDC (#3597) 2024-04-12 07:19:48 -05:00
todd-herbert
178877f2d9 Enable T-Echo touch button by default (#3604)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-12 07:18:36 -05:00
Jonathan Bennett
6de0363eea Pin RadioLib to 6.5.x (#3601) 2024-04-12 07:17:43 -05:00
Gareth Coleman
f4a2023dba LSM6DS3TR-C support (#3593)
* started work on pulling in the unphone library and dependencies, to do e.g. power switch management and etc.; currently failing at Adafruit_ImageReader

* now compiles with unphoneLibrary included

* successfully pulled in unphone library to manage power switch and init vibe motor and etc.
doesnt print to serial tho...

* simplified the build a bit; when doing meshtastic do not depend on the MCCI lora libs etc., then also no need to config them via build flags

* version that doesnt trigger brownout

* cleaned up initVariant a little

* note re. GPS

* back to mesh upstream version

* this time we're back to mesh upstream version

* getting LSM6DS3TRC driver installed

* shake to wake works, set threshold quite low may need increasing

* whats the crack with these end of file changes?

* paramatize the wake threshold

* try to get the PR to just include real changes

* got the right config item and also not giving compiler messages

* moved the lib_deps for the LSM6DS3TRC driver from our variant platformio.ini to the main one in root so all boards have it

* stuupid error #define-ing

---------

Co-authored-by: Hamish Cunningham <hamish@gate.ac.uk>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-11 19:40:14 -05:00
Manuel
927d07e2c6 fix: device PMU shutdown (part 2) (#3596)
* fix: device PMU shutdown (part 2)

* fix error + enable nimble deinit
2024-04-11 19:39:07 -05:00
github-actions[bot]
a4a8556aa2 [create-pull-request] automated change (#3595)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-11 07:41:37 -05:00
todd-herbert
8e29efcb50 Fix button interrupt after light sleep (#3587)
* Make ButtonThread instance extern
Previously was a static local instance in setup(). Now declared in ButtonThread.cpp, accessible via extern declaration in ButtonThread.

* Extract attachInterrupt() calls to public method; create matching method for detachInterrupt()

* Change suspension of button interrupts for light-sleep

* Fix declaration for ARCH_PORTDUINO

* Remove LOG_DEBUG used during testing

* Don't assume device has a button..

* Guard entire constructor code

* Don't use BUTTON_PIN with ARCH_PORTDUINO

---------

Co-authored-by: Manuel <71137295+mverch67@users.noreply.github.com>
2024-04-11 07:02:50 -05:00
GUVWAF
3bee6ce9c3 Only set NodeNum based on MAC if it's still zero (#3585)
* Only set NodeNum based on MAC if it's still zero

* Already declared
2024-04-10 11:29:29 -05:00
Thomas Göttgens
fcab20fb3b Merge pull request #3580 from meshtastic/add-iaq
add BME680 IAQ reading
2024-04-09 21:55:42 +02:00
Thomas Göttgens
2d81c97b98 fix #2586 (lower IAQ quality for saving to 2 and rework save logic) 2024-04-09 21:20:36 +02:00
Thomas Göttgens
cfd98b2c91 add BME680 IAQ reading. Range is from 0 (clean) - 500 (extremely polluted) 2024-04-09 21:20:36 +02:00
rcarteraz
6e7405e56b add unphone (#3584) 2024-04-09 12:26:03 -05:00
rcarteraz
77082e35f5 Add unPhone to S3 build scripts (#3583)
* add unphone to s3 devices

* add unphone
2024-04-09 11:37:38 -05:00
github-actions[bot]
daa64b055a [create-pull-request] automated change (#3579)
Co-authored-by: caveman99 <caveman99@users.noreply.github.com>
2024-04-09 08:00:19 -05:00
Thomas Göttgens
ec74fba2bd update to nanopb 0.4.8 and fix proto regen script (#3578)
* update to nanopb 0.4.8 and fix proto regen script

* trunk, damnit
2024-04-09 07:40:55 -05:00
github-actions[bot]
e89575bfd1 [create-pull-request] automated change (#3577)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-08 18:43:10 -05:00
Thomas Göttgens
ea61808fd9 tryfix: use UTC on Phone API (#3576) 2024-04-08 17:26:23 -05:00
Thomas Göttgens
b14ac777f1 Merge pull request #3570 from meshtastic/local-time-display
display log and onscreen times in local timezone
2024-04-08 09:18:41 +02:00
Thomas Göttgens
65e5bdc212 display log and onscreen times in local timezone 2024-04-08 00:10:54 +02:00
Jonathan Bennett
aa3280c18c add trunk ignore for docker chmod (#3568)
* add trunk ignore for docker chmod

* Fix incorrect comment type
2024-04-07 17:08:17 -05:00
Jonathan Bennett
68e657fd07 Actually fix Docker - hopefully 2024-04-07 15:52:43 -05:00
Jonathan Bennett
47b8f7b6c6 Don't forget to change directory owner 2024-04-07 14:34:19 -05:00
Jonathan Bennett
fde20db95f move chmod -t to root section 2024-04-07 14:22:39 -05:00
Jonathan Bennett
40a7fd145a Update Dockerfile to remove sticky bit during build (#3567)
* Update Dockerfile to remove sticky bit during build

* no sudo?
2024-04-07 14:15:03 -05:00
Thomas Göttgens
33842b67e8 Merge pull request #3565 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-04-07 16:00:03 +02:00
caveman99
2db061ded9 [create-pull-request] automated change 2024-04-07 13:58:58 +00:00
Thomas Göttgens
1baad2875a Add keymappings for several utility functions (#3536)
* - map fn+m to mute and unmute the external notification module
- map fn+t to be an alternative for the TAB key

* add whitelist to inputbroker

* (maybe) sweet-talking t-deck into tabbing...

* now for real - back in Kansas

* More fancy mappings

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-06 19:12:57 -05:00
Jared Quinn
0e9f1beb40 Native Linux Build (ARM support and webserver deps) (#3506)
* Added webserver libraries to build libs

* Revert "Added webserver libraries to build libs"

This reverts commit bcc72a06b9.

* Added piwebserver library dependencies to native build

* Add webserver libraries to apt install for native build

* Revert additional libraries added by mistake

* Address trunk check issues on Dockerfile

* Ignore linter checks for pinning build packages and apt-get

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-06 10:32:15 -05:00
Jonathan Bennett
03f60dcb49 Make instructions clearer in config.yaml comments (#3559) 2024-04-06 08:04:49 -05:00
todd-herbert
5b5f9c62b5 Remap backlight toggle and touch button (#3560)
* Update E-Ink display after sending adhoc ping or disable/enable GPS

* Resume display updates when touch button pressed

* Use touch hold as modifier; change double-click behavior for user button

* Fix preprocessor exclusions

* Purge backlight behavior

* Distinguish between 3x and 4x multi-presses

* Touch button considers "Wake screen on tap or motion" user-setting

* Don't assume device has BUTTON_PIN

* Rename misleading method
2024-04-06 08:04:26 -05:00
Ric In New Mexico
577de1e517 Merge pull request #3557 from fuutott/master
Update platformio.ini
2024-04-05 14:56:38 -06:00
fuutott
f6e6f975c0 Update platformio.ini
should be dash instead of underscore
2024-04-05 14:58:00 +01:00
Gareth Coleman
902f38238d This change to the I2C Scan is to distinguish between two devices (#3554)
sharing the same I2C address, the QMI8658 IMU and BQ24295 PMU.
2024-04-05 07:20:22 -05:00
Thomas Göttgens
9b2d862b7d Merge pull request #3544 from garethhcoleman/unphone
New device unPhone using HX8357D LCD and XPT2046 touchscreen
2024-04-04 12:47:12 +02:00
Gareth Coleman
4cdfae71cf first attempt at getting trunk to do linting 2024-04-04 11:00:10 +02:00
Gareth Coleman
be889015f7 New device unPhone using HX8357D LCD and XPT2046 touchscreen 2024-04-04 11:00:10 +02:00
Thomas Göttgens
f0b6ff9b2d Merge pull request #3545 from todd-herbert/paper-deepsleep-current
Reduce deep-sleep current for Heltec Wireless Paper
2024-04-04 10:59:20 +02:00
Todd Herbert
30ebb6ae46 use BUTTON_PIN macro 2024-04-04 17:18:40 +13:00
Todd Herbert
d1db51830b set GPIOs for sleep 2024-04-04 17:05:12 +13:00
Todd Herbert
eb0e705ba9 de-init bluetooth 2024-04-04 17:04:10 +13:00
github-actions[bot]
46ad4bf0e5 [create-pull-request] automated change (#3542)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-04-03 08:47:47 -05:00
todd-herbert
a570e50aca Disable holds / isolations on RTC IO pads after deep sleep (#3539)
* disable holds on RTC IO pads after deep sleep

* Don't assume SOC_RTCIO_HOLD_SUPPORTED
2024-04-03 06:59:53 -05:00
AeroXuk
2caed6d29c Feature parity between Pico and Pico W (#3538) 2024-04-02 15:36:15 -05:00
todd-herbert
f2ed0f7c8c Fix Light-sleep for ESP32 (#3521)
* Change wakeup source from EXT0 to GPIO

* Avoid ISR issue on wake

* Detect press from wake reason, instead of digitalRead

* Missing #ifdef

Risky phone-typed commit

* Fix PowerFSM timed transition preventing light sleep
Addresses https://github.com/meshtastic/firmware/issues/3517

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-02 14:55:48 -05:00
Jonathan Bennett
8bb562c5fa Add spiTransfer function to Native to support Linux-managed CS (#3524)
* Add spiTransfer function to Native to support Linux-managed CS

* Trunk

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-04-01 18:31:36 -05:00
rcarteraz
15501e84dd Add Station-G2 to install scripts (#3525)
* add station g2 to device-install.bat

* add station-g2 to device-install.sh

* remove extra space
2024-04-01 05:53:19 -05:00
GUVWAF
a4c22321fc Don't save Neighbors to flash when receiving (#3519)
* Don't save Neighbors to flash when receiving

* Move `shouldSave` to `saveProtoForModule()`

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-31 08:03:29 -05:00
todd-herbert
46a63bf293 Handle edge cases for E-Ink screensaver (#3518)
* remove redundant logic

* Handle special screens for old EInkDisplayClass

* Handle special screens for EInkDynamicDisplay class

* Join an async refresh in progress to avoid skipping screensaver

* attempt trunk fix
2024-03-31 07:04:05 -05:00
Jorropo
279464f96d linux-native: only install linux native deps (#3510)
This is a couple times faster because platformio checks all environment sequentially.

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-29 07:42:20 -05:00
Jorropo
3cf6c47bab replace arch with uname -m for arch linux (#3508)
From the manpage:
> arch - print machine hardware name (same as uname -m)

Arch Linux does not have the `arch` alias, only `uname`, so use `uname` to fix this issue:
> ```
> ./bin/build-native.sh: line 18: arch: command not found
> ```

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-03-29 01:01:40 -05:00
Jonathan Bennett
64fd866494 Make native honor HAS_SCREEN 0 (#3509)
This allows easier building of the native target without the LovyanGFX libraries.
2024-03-29 00:03:19 -05:00
github-actions[bot]
7b391d1a9f [create-pull-request] automated change (#3507)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-28 19:27:34 -05:00
todd-herbert
8187fa7115 E-Ink Screensaver (#3477)
* fix Wireless Paper double-clear screen at boot

* log when flooded with "responsive" frames

* show the "resuming" screen when waking from deep-sleep

* rename drawDeepSleepScreen
avoid future confusion with "Screen Paused" screen

* show a screensaver frame when screen off
The frame shown during deep sleep is now also passed through showScreensaverFrames()

* Add macros for E-Ink color values.
OLEDDISPLAY_COLOR is inverted. Result of light-mode on E-Ink vs dark-mode on OLED?

* adapt drawDeepSleepScreen to new screensaver convention

* Mark Wireless Paper V1.1 as having problems with ghosting
Any other issues can be marked in a similar way, then handled in code where relevant

* Change screensaver from fullscreen logo to overlay

* identify "quirks" rather than "problems"

* move async refresh polling from display() to a NotifiedWorkerThread

* Prevent skipping of deep-sleep screen
(Hopefully)

* Redesign screensaver overlay
Now displays short name

* Optimize refresh for different displays

* Support older EInkDisplay class

* Don't assume text alignment

* fix spelling of a quirk macro
(No impact to code, but avoids future issues)

* Handle impossibly unlikely millis() overflow error
Should have just let it go, but here we are..

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-28 18:31:11 -05:00
Ben Meadors
daa4d387c6 Don't reboot for non-radio lora config changes (#3505) 2024-03-28 18:14:15 -05:00
Ben Meadors
4c2d5c6a89 Reorder structs to fix build 2024-03-28 07:16:07 -05:00
github-actions[bot]
b5ec35ec78 [create-pull-request] automated change (#3502)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-28 06:44:34 -05:00
Ben Meadors
5732eed86b Fixed position admin messages (#3490)
* Bespoke admin messages for setting and clearing fixed positions

* Add guards against remote admin messages setting things

* Flip ifs
2024-03-26 07:29:07 -05:00
Jonathan Bennett
1542afb847 Add libulfius2.7 to .deb debendencies (#3494) 2024-03-26 00:58:47 -05:00
Jim Whitelaw
acc32916c3 Add multiple configuration options for a minimized build (GPS,WiFi,BT,MQTT,Screen). (#3469)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-25 06:33:57 -05:00
github-actions[bot]
728b58fb94 [create-pull-request] automated change (#3489)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-24 18:50:26 -05:00
GUVWAF
77fb230baa Native: fail-safes for simulated node without config file (#3486)
* LinuxInput: only close if file descriptor is assigned

* Native: set some defaults if no configuration file found
2024-03-24 13:42:32 -05:00
Thomas Göttgens
b960dc1b41 Add Shutdown and reboot to CardKB and friends (#3487)
* Add Shutdown and reboot to CardKB and friends

* aw shucks
2024-03-24 13:41:45 -05:00
code8buster
5f529f7ca3 Remove unused defines from nrf52 variants (#3482)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-24 13:41:28 -05:00
github-actions[bot]
b4dbc2b4bf [create-pull-request] automated change (#3485)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-24 12:44:44 -05:00
Ben Meadors
63df972d42 Revert "[create-pull-request] automated change (#3483)" (#3484)
This reverts commit c87fdfece7.
2024-03-24 08:11:47 -05:00
github-actions[bot]
c87fdfece7 [create-pull-request] automated change (#3483)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-23 19:47:43 -05:00
GUVWAF
381d5230b8 Merge pull request #3480 from GUVWAF/logsMapReport
Don't spam logs if no position with map reporting (2)
2024-03-23 20:12:25 +01:00
GUVWAF
a7c005ccdf Merge branch 'meshtastic:master' into logsMapReport 2024-03-23 19:36:21 +01:00
GUVWAF
71ca6f768f Actually update last_report_to_map 2024-03-23 19:35:12 +01:00
GUVWAF
4cce4c7c93 Set unused header bytes to zero for future use (#3479) 2024-03-23 12:38:29 -05:00
Jonathan Bennett
9e8860d188 Crash fix and remove hard-coded path from PiWebServer (#3478)
* Remove hard-coded path from PiWebServer

* Bump portduino to pick up crash fix

* Remove PiWebServer non-ASCII debug output

* Trunk formatting
2024-03-23 12:29:05 -05:00
GUVWAF
d30d6bd3eb Fix #3452: only alter received packet if port number matches (#3474)
* Use `alterReceivedProtobuf()` for NeighborInfo and Traceroute
`alterReceived()` should never return NULL
Traceroute should be promiscuous

* Remove extensive logging from NeighborInfo module
2024-03-23 07:31:58 -05:00
Ben Meadors
94e4301f2f Add set and remove favorite nodes admin commands (#3471) 2024-03-22 10:53:18 -05:00
Ben Meadors
54818b5f8d Enforce consistent polite channel utilization limits except for Sensor role (#3467) 2024-03-22 07:25:00 -05:00
github-actions[bot]
c77c58d656 [create-pull-request] automated change (#3470)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-22 07:24:10 -05:00
Ben Meadors
794e99c2f9 Log warning cleanup and truth (#3466) 2024-03-21 20:45:48 -05:00
Ben Meadors
7aa013a716 Skip favorite nodes when clearing out oldest in NodeDB (#3464)
* Skip favorite nodes when clearing out oldest in NodeDB

* We should actually map between the types
2024-03-21 19:51:02 -05:00
github-actions[bot]
a57f7730ea [create-pull-request] automated change (#3463)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-21 18:55:50 -05:00
Jonathan Bennett
35754d661d Make MAX_NUM_NODES configurable in variant.h (#3453)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-21 18:26:37 -05:00
Jonathan Bennett
79cfb1e876 Revert "Bump actions to node 20 (#3461)" (#3462)
This reverts commit defeb8e52b.

As per https://github.com/actions/upload-artifact/issues/478 the new version of upload-artifact includes a breaking change.
2024-03-21 16:50:44 -05:00
GUVWAF
155df45d92 Add sanity check for map report interval and position precision (#3459)
* Add sanity check for map report interval and position precision

* Use new `Default::` methods
2024-03-21 16:20:20 -05:00
Jonathan Bennett
907d075917 Revert previous attempt 2024-03-21 16:17:13 -05:00
Jonathan Bennett
9c88906acc Remove double run of build-raspbian 2024-03-21 16:14:45 -05:00
Jonathan Bennett
defeb8e52b Bump actions to node 20 (#3461) 2024-03-21 15:24:57 -05:00
Ben Meadors
6dd337a651 Clear local position on nodedb-reset (#3451)
* Clear local position on nodedb-reset

* NodeDB pointer now, yo

---------

Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
2024-03-21 14:43:10 -05:00
GUVWAF
0a7ddb7594 Let NeighborInfo Module ignore packets coming from MQTT (#3457) 2024-03-21 14:42:53 -05:00
GUVWAF
4debcd5ccd Set default position precision of mapReport to 14 (#3456) 2024-03-21 14:35:17 -05:00
Jonathan Bennett
fd26914d88 move nodeDB::init code into nodeDB constructor (#3455) 2024-03-21 13:14:02 -05:00
Jonathan Bennett
dfcd0d14f6 Add MaxNodes to Native config (#3427)
* Add MaxNodes to Native

* It compiles...

* Convert nodedb to use new

* Closer but still broken.

* Finally working

* Remove unintended lines

* Don't include a pointer

* Capitalization matters.

* avoid rename in protocol regen

* When trimming the nodeDB, start with a cleanup

* Remove extra cleanupMeshDB() call for now

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-21 09:06:37 -05:00
Jim Whitelaw
f4095ce00d Adds configuration option to exclude the webserver on esp32. (#3369)
* Adds configuration option to not build/include the webserver.

* Adds configuration option to not build/include the webserver.

* Keep initApiServer when excluding webserver

* fixes for failed formatting check

* Once more with feeling! Fix for regression.

* Fix includes for ARCH_ESP32

* Format changes from trunk

* Merge updates from origin

* Revert "Format changes from trunk"

This reverts commit 436e631774.

* jeez!

* tryfix proto conflict

---------

Co-authored-by: Thomas Göttgens <tgoettgens@gmail.com>
2024-03-21 06:34:34 -05:00
Mictronics
7aa21f6e3f Fixed double and missing Default class. (#3448)
* Fix LED pinout for T-Echo board marked v1.0, date 2021-6-28

* Merge PR #420

* Fixed double and missing Default class.

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-20 10:58:48 -05:00
github-actions[bot]
5e832e2fc6 [create-pull-request] automated change (#3444)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-19 12:02:29 -05:00
Ben Meadors
4fa7f5a748 Fix devicestate persistence bug 2024-03-19 10:31:31 -05:00
Manuel
a6625998f5 fix compiler warnings in NodeDB.h (#3439)
* fix warnings on arm

* make trunk+compiler happy
2024-03-19 06:22:45 -05:00
Manuel
711b85cfe8 fix WLAN crash (#3435)
* fix WLAN crash

* link to commit in arduinothread

* revert usb mode
2024-03-18 15:42:44 -05:00
github-actions[bot]
b98176e73e [create-pull-request] automated change (#3434)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-18 07:33:01 -05:00
Ben Meadors
aae49f5ecf Remove confusing channel suffix (#3432)
* Remove confusing channel suffix

* Missed it
2024-03-17 08:38:49 -05:00
Ben Meadors
0d1d79b6d1 Extract default intervals and coalesce methods into their own file / static class methods (#3425)
* Extract default intervals and coalesce methods into their own file / static class methods

* Missed pax

* Still managed to miss one
2024-03-17 08:18:30 -05:00
Ben Meadors
bb57ccfc9e Remove devicestate no_save (#3424) 2024-03-17 08:16:22 -05:00
Ben Meadors
e27f029d09 Bump minimum NodeInfo send to 5 minutes (#3423)
* Bump minimum NodeInfo send to 3 minutes

* 5
2024-03-16 19:56:42 -05:00
Thomas Göttgens
13cc1b0252 (3/3) Add variant for pico with waveshare and GPS hat (#3412)
* (3/3) Add variant for pico with waveshare and GPS hat, utilizing slow clock.

* Not everybody has Serial2

* Trunk

* Push it real gud

* No init

---------

Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-16 10:01:43 -05:00
github-actions[bot]
54a2a4bcc6 [create-pull-request] automated change (#3422)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-16 07:39:28 -05:00
David Ellefsen
611f291d4d Factory reset GNSS_MODEL_MTK GPS modules with PCAS10,3 (#3388)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-15 19:19:50 -05:00
Ben Meadors
9586606229 Handle for heartbeat toradio packets (#3420) 2024-03-15 18:40:48 -05:00
github-actions[bot]
0de36fbfb0 [create-pull-request] automated change (#3419)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-15 17:12:45 -05:00
Andre K
0dda20bc35 fix for I2C scan getting stuck (#3375)
* refactor: add delay for T-Echo peripherals setup

* comment out `PIN_POWER_EN1`
2024-03-15 17:12:30 -05:00
Ben Meadors
52cfec29fc More comprehensive client proxy queue guards (#3414)
* More comprehensive MQTT thread and queue guards

* Consolidate logic

* Remove channel check

* Check for map_reporting_enabled as well

* Update message

* Remove channel check from here as well

* One liner

* Start the mqtt thread back up when channels change and we want mqtt
2024-03-15 16:17:47 -05:00
Thomas Göttgens
4d0d82f7e7 Merge pull request #3411 from meshtastic/rp2040-slowclock
(2/3) Add Slow Clock Support for RP2040 platform.
2024-03-15 20:56:50 +01:00
Thomas Göttgens
34bc22f94d (2/3) Add Slow Clock Support for RP2040 platform. This will disable USB Softserial. 2024-03-15 20:16:36 +01:00
Thomas Göttgens
cb3740708b Merge pull request #3410 from meshtastic/gnss-l76b
(1/3) Support L76B GNSS chip found on pico waveshare shield.
2024-03-15 20:16:06 +01:00
Thomas Göttgens
e8ec167854 Merge branch 'gnss-l76b' of github.com:meshtastic/firmware into gnss-l76b 2024-03-15 19:48:19 +01:00
Thomas Göttgens
b900415218 that should work now 2024-03-15 19:47:47 +01:00
Thomas Göttgens
2eb78fec53 Merge branch 'master' into gnss-l76b 2024-03-15 19:39:47 +01:00
Thomas Göttgens
da7cd5fc7f new Accelerometer lib (#3413)
* new Accelerometer lib

* Use our fork till upstreasm merges changes.

* that PR escalated quickly

* resurrect display flip
2024-03-15 10:45:14 -05:00
Thomas Göttgens
b06c77d46f don't fix this to a hardware model. 2024-03-15 16:43:39 +01:00
Thomas Göttgens
cbc0aa16c5 fix compilation 2024-03-15 16:37:47 +01:00
github-actions[bot]
876a0520a9 [create-pull-request] automated change (#3418)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-15 08:09:48 -05:00
Thomas Göttgens
50cc4cfcf1 We don't use Lorawan (#3417)
#warning "Persistent storage not supported!" [-Wcpp]
2024-03-15 08:07:54 -05:00
Ben Meadors
ec6bdeed81 NodeInfo broadcast ensure default on 0 and enforce 1 hour minimum (#3415)
* NodeInfo broadcasts ensure defaults on 0 and enforce 1 hour minumum

* Doh!

* Hey that's not on config!
2024-03-15 07:12:03 -05:00
Ben Meadors
a085c3ddb3 Try-fix router missed messages (#3405) 2024-03-14 17:00:57 -05:00
Thomas Göttgens
58cdf360f8 (1/3) Support L76B GNSS chip found on pico waveshare shield. Original work by @Mictronics 2024-03-14 16:18:33 +01:00
Ben Meadors
9c37e57e75 Only allow phone to set time for fixed positions (#3403) 2024-03-13 20:27:26 -05:00
Andre K
9d2fcbe1e1 use decoded packets in public MQTT range test/detection sensor filter (#3404)
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
2024-03-13 18:24:49 -05:00
Ben Meadors
3995e2f708 Remove bunk code 2024-03-13 15:06:52 -05:00
github-actions[bot]
216f85ff22 [create-pull-request] automated change (#3397)
Co-authored-by: thebentern <thebentern@users.noreply.github.com>
2024-03-13 09:02:48 -05:00
Ben Meadors
2efe436102 Update nrf52 platform and consolidate Adafruit Bus IO (#3393) 2024-03-13 07:20:51 -05:00
Thomas Göttgens
fb16390205 Merge pull request #3395 from tavdog/patch_buzzer_no_turnoff_off_by_one_error
fix off by one error
2024-03-13 09:23:14 +01:00
Tavis
333c3c1c9e fix off by one error
buzzer is index 2, but loop was 0-1 so buzzer never got turned off.
2024-03-12 21:42:08 -10:00
GUVWAF
724fa38a55 Fix T-LoRa V2.1-6 with TCXO init (#3392) 2024-03-12 16:42:34 -05:00
Wolfgang Nagele
38ea681433 Fix LTO discharge curve (#3385)
* Fix LTO discharge curve

* Remove duplicate info
2024-03-12 16:42:21 -05:00
Wolfgang Nagele
ee685b4ed7 Check AQ_SET_PIN instead of EINK dependency (#3387) 2024-03-12 13:03:04 -05:00
Thomas Herrmann
cf11807f97 use priority background for low priority messages (#3381) 2024-03-12 12:21:09 -05:00
Wolfgang Nagele
7f063fbf81 Support external charge detection (#3386)
* Support external charge detection

* trunk fmt
2024-03-12 11:55:31 -05:00
Thomas Göttgens
6215495ccc Merge pull request #3379 from meshtastic/create-pull-request/patch
Changes by create-pull-request action
2024-03-12 10:26:17 +01:00
GUVWAF
045dda64e7 Merge pull request #3383 from AeroXuk/patch-1
Fix for incorrect mapTopic mqtt path
2024-03-12 08:39:30 +01:00
AeroXuk
affbd7f2b9 Update MQTT.cpp
Bug fix for #3382
2024-03-12 02:13:52 +00:00
thebentern
f9bf9e2dcc [create-pull-request] automated change 2024-03-11 21:43:46 +00:00
1415 changed files with 161667 additions and 17362 deletions

View File

@@ -0,0 +1,52 @@
# This container is used to build Meshtastic with the libraries required by the fuzzer.
# ClusterFuzzLite starts the container, runs the build.sh script, and then exits.
# As this is not a long running service, health-checks are not required. ClusterFuzzLite
# also only works if the user remains unchanged from the base image (it expects to run
# as root).
# trunk-ignore-all(trivy/DS026): No healthcheck is needed for this builder container
# trunk-ignore-all(checkov/CKV_DOCKER_2): No healthcheck is needed for this builder container
# trunk-ignore-all(checkov/CKV_DOCKER_3): We must run as root for this container
# trunk-ignore-all(trivy/DS002): We must run as root for this container
# trunk-ignore-all(checkov/CKV_DOCKER_8): We must run as root for this container
# trunk-ignore-all(hadolint/DL3002): We must run as root for this container
FROM gcr.io/oss-fuzz-base/base-builder:v1
ENV PIP_ROOT_USER_ACTION=ignore
# trunk-ignore(hadolint/DL3008): apt packages are not pinned.
# trunk-ignore(terrascan/AC_DOCKER_0002): apt packages are not pinned.
RUN apt-get update && apt-get install --no-install-recommends -y \
cmake git zip libgpiod-dev libbluetooth-dev libi2c-dev \
libunistring-dev libmicrohttpd-dev libgnutls28-dev libgcrypt20-dev \
libusb-1.0-0-dev libssl-dev pkg-config && \
apt-get clean && rm -rf /var/lib/apt/lists/* && \
pip install --no-cache-dir -U \
platformio==6.1.16 \
grpcio-tools==1.68.1 \
meshtastic==2.5.9
# Ugly hack to avoid clang detecting a conflict between the math "log" function and the "log" function in framework-portduino/cores/portduino/logging.h
RUN sed -i -e 's/__MATHCALL_VEC (log,, (_Mdouble_ __x));//' /usr/include/x86_64-linux-gnu/bits/mathcalls.h
# A few dependencies are too old on the base-builder image. More recent versions are built from source.
WORKDIR $SRC
RUN git config --global advice.detachedHead false && \
git clone --depth 1 --branch 0.8.0 https://github.com/jbeder/yaml-cpp.git && \
git clone --depth 1 --branch v2.3.3 https://github.com/babelouest/orcania.git && \
git clone --depth 1 --branch v1.4.20 https://github.com/babelouest/yder.git && \
git clone --depth 1 --branch v2.7.15 https://github.com/babelouest/ulfius.git
COPY ./.clusterfuzzlite/build.sh $SRC/
WORKDIR $SRC/firmware
COPY . $SRC/firmware/
# https://docs.platformio.org/en/latest/envvars.html
ENV PLATFORMIO_CORE_DIR=$SRC/pio/core \
PLATFORMIO_LIBDEPS_DIR=$SRC/pio/libdeps \
PLATFORMIO_PACKAGES_DIR=$SRC/pio/packages \
PLATFORMIO_SETTING_ENABLE_CACHE=No \
PIO_ENV=buildroot
RUN platformio pkg install --environment $PIO_ENV

View File

@@ -0,0 +1,59 @@
# ClusterFuzzLite for Meshtastic
This directory contains the fuzzer implementation for Meshtastic using the ClusterFuzzLite framework.
See the [ClusterFuzzLite documentation](https://google.github.io/clusterfuzzlite/) for more details.
## Running locally
ClusterFuzzLite uses the OSS-Fuzz toolchain. To build the fuzzer manually, first grab a copy of OSS-Fuzz.
```shell
git clone https://github.com/google/oss-fuzz.git
cd oss-fuzz
```
To build the fuzzer, run:
```shell
python3 infra/helper.py build_image --external $PATH_TO_MESHTASTIC_FIRMWARE_DIRECTORY
python3 infra/helper.py build_fuzzers --external $PATH_TO_MESHTASTIC_FIRMWARE_DIRECTORY --sanitizer address
```
To run the fuzzer, run:
```shell
python3 infra/helper.py run_fuzzer --external --corpus-dir=<path-to-temp-corpus-dir> $PATH_TO_MESHTASTIC_FIRMWARE_DIRECTORY router_fuzzer
```
More background on these commands can be found in the
[ClusterFuzzLite documentation](https://google.github.io/clusterfuzzlite/build-integration/#testing-locally).
## router_fuzzer.cpp
This fuzzer submits MeshPacket protos to the `Router::enqueueReceivedMessage` method. It takes the binary
data from the fuzzer and decodes that data to a MeshPacket using nanopb. A few fields in
the MeshPacket are modified by the fuzzer.
- If the `to` field is 0, it will be replaced with the NodeID of the running node.
- If the `from` field is 0, it will be replaced with the NodeID of the running node.
- If the `id` field is 0, it will be replaced with an incrementing counter value.
- If the `pki_encrypted` field is true, the `public_key` field will be populated with the first admin key.
The `router_fuzzer_seed_corpus.py` file contains a list of MeshPackets. It is run from inside build.sh and
writes the binary MeshPacket protos to files. These files are use used by the fuzzer as its initial seed data,
helping the fuzzer to start off with a few known inputs.
### Interpreting a fuzzer crash
If the fuzzer crashes, it'll write the input bytes used for the test case to a file and notify about the
location of that file. The contents of the file are a binary serialized MeshPacket protobuf. The following
snippet of Python code can be used to parse the file into a human readable form.
```python
from meshtastic.protobuf import mesh_pb2
mesh_pb2.MeshPacket.FromString(open("crash-XXXX-file", "rb").read())
```
Consider adding any such crash results to the `router_fuzzer_seed_corpus.py` file to ensure there a isn't
a future regression for that crash test case.

71
.clusterfuzzlite/build.sh Normal file
View File

@@ -0,0 +1,71 @@
#!/bin/bash -eu
# Build Meshtastic and a few needed dependencies using clang++
# and the OSS-Fuzz required build flags.
env
cd "$SRC"
NPROC=$(nproc || echo 1)
LDFLAGS=-lpthread cmake -S "$SRC/yaml-cpp" -B "$WORK/yaml-cpp/$SANITIZER" \
-DBUILD_SHARED_LIBS=OFF
cmake --build "$WORK/yaml-cpp/$SANITIZER" -j "$NPROC"
cmake --install "$WORK/yaml-cpp/$SANITIZER" --prefix /usr
cmake -S "$SRC/orcania" -B "$WORK/orcania/$SANITIZER" \
-DBUILD_STATIC=ON
cmake --build "$WORK/orcania/$SANITIZER" -j "$NPROC"
cmake --install "$WORK/orcania/$SANITIZER" --prefix /usr
cmake -S "$SRC/yder" -B "$WORK/yder/$SANITIZER" \
-DBUILD_STATIC=ON -DWITH_JOURNALD=OFF
cmake --build "$WORK/yder/$SANITIZER" -j "$NPROC"
cmake --install "$WORK/yder/$SANITIZER" --prefix /usr
cmake -S "$SRC/ulfius" -B "$WORK/ulfius/$SANITIZER" \
-DBUILD_STATIC=ON -DWITH_JANSSON=OFF -DWITH_CURL=OFF -DWITH_WEBSOCKET=OFF
cmake --build "$WORK/ulfius/$SANITIZER" -j "$NPROC"
cmake --install "$WORK/ulfius/$SANITIZER" --prefix /usr
cd "$SRC/firmware"
PLATFORMIO_EXTRA_SCRIPTS=$(echo -e "pre:.clusterfuzzlite/platformio-clusterfuzzlite-pre.py\npost:.clusterfuzzlite/platformio-clusterfuzzlite-post.py")
STATIC_LIBS=$(pkg-config --libs --static libulfius openssl libgpiod yaml-cpp bluez --silence-errors)
export PLATFORMIO_EXTRA_SCRIPTS
export STATIC_LIBS
export PLATFORMIO_WORKSPACE_DIR="$WORK/pio/$SANITIZER"
export TARGET_CC=$CC
export TARGET_CXX=$CXX
export TARGET_LD=$CXX
export TARGET_AR=llvm-ar
export TARGET_AS=llvm-as
export TARGET_OBJCOPY=llvm-objcopy
export TARGET_RANLIB=llvm-ranlib
mkdir -p "$OUT/lib"
cp .clusterfuzzlite/*_fuzzer.options "$OUT/"
for f in .clusterfuzzlite/*_fuzzer.cpp; do
fuzzer=$(basename "$f" .cpp)
cp -f "$f" src/fuzzer.cpp
pio run -vvv --environment "$PIO_ENV"
program="$PLATFORMIO_WORKSPACE_DIR/build/$PIO_ENV/program"
cp "$program" "$OUT/$fuzzer"
# Copy shared libraries used by the fuzzer.
read -d '' -ra shared_libs < <(ldd "$program" | sed -n 's/[^=]\+=> \([^ ]\+\).*/\1/p') || true
cp -f "${shared_libs[@]}" "$OUT/lib/"
# Build the initial fuzzer seed corpus.
corpus_name="${fuzzer}_seed_corpus"
corpus_generator="$PWD/.clusterfuzzlite/${corpus_name}.py"
if [[ -f $corpus_generator ]]; then
mkdir "$corpus_name"
pushd "$corpus_name"
python3 "$corpus_generator"
popd
zip -D "$OUT/${corpus_name}.zip" "$corpus_name"/*
fi
done

View File

@@ -0,0 +1,35 @@
"""PlatformIO build script (post: runs after other Meshtastic scripts)."""
import os
import shlex
from SCons.Script import DefaultEnvironment
env = DefaultEnvironment()
# Remove any static libraries from the LIBS environment. Static libraries are
# handled in platformio-clusterfuzzlite-pre.py.
static_libs = set(lib[2:] for lib in shlex.split(os.getenv("STATIC_LIBS")))
env.Replace(
LIBS=[
lib for lib in env["LIBS"] if not (isinstance(lib, str) and lib in static_libs)
],
)
# FrameworkArduino/portduino/main.cpp contains the "main" function the binary.
# The fuzzing framework also provides a "main" function and needs to be run
# before Meshtastic is started. We rename the "main" function for Meshtastic to
# "portduino_main" here so that it can be called inside the fuzzer.
env.AddPostAction(
"$BUILD_DIR/FrameworkArduino/portduino/main.cpp.o",
env.VerboseAction(
" ".join(
[
"$OBJCOPY",
"--redefine-sym=main=portduino_main",
"$BUILD_DIR/FrameworkArduino/portduino/main.cpp.o",
]
),
"Renaming main symbol to portduino_main",
),
)

View File

@@ -0,0 +1,52 @@
"""PlatformIO build script (pre: runs before other Meshtastic scripts).
ClusterFuzzLite executes in a different container from the build. During the build,
attempt to link statically to as many dependencies as possible. For dependencies that
do not have static libraries, the shared library files are copied to the output
directory by the build.sh script.
"""
import glob
import os
import shlex
from SCons.Script import DefaultEnvironment, Literal
env = DefaultEnvironment()
cxxflags = shlex.split(os.getenv("CXXFLAGS"))
sanitizer_flags = shlex.split(os.getenv("SANITIZER_FLAGS"))
lib_fuzzing_engine = shlex.split(os.getenv("LIB_FUZZING_ENGINE"))
statics = glob.glob("/usr/lib/lib*.a") + glob.glob("/usr/lib/*/lib*.a")
no_static = set(("-ldl",))
def replaceStatic(lib):
"""Replace -l<libname> with the static .a file for the library."""
if not lib.startswith("-l") or lib in no_static:
return lib
static_name = f"/lib{lib[2:]}.a"
static = [s for s in statics if s.endswith(static_name)]
if len(static) == 1:
return static[0]
return lib
# Setup the environment for building with Clang and the OSS-Fuzz required build flags.
env.Append(
CFLAGS=os.getenv("CFLAGS"),
CXXFLAGS=cxxflags,
LIBSOURCE_DIRS=["/usr/lib/x86_64-linux-gnu"],
LINKFLAGS=cxxflags
+ sanitizer_flags
+ lib_fuzzing_engine
+ ["-stdlib=libc++", "-std=c++17"],
_LIBFLAGS=[replaceStatic(s) for s in shlex.split(os.getenv("STATIC_LIBS"))]
+ [
"/usr/lib/x86_64-linux-gnu/libunistring.a", # Needs to be at the end.
# Find the shared libraries in a subdirectory named lib
# within the same directory as the binary.
Literal("-Wl,-rpath,$ORIGIN/lib"),
"-Wl,-z,origin",
],
)

View File

@@ -0,0 +1 @@
language: c++

View File

@@ -0,0 +1,206 @@
// Fuzzer implementation that sends MeshPackets to Router::enqueueReceivedMessage.
#include <condition_variable>
#include <cstdlib>
#include <mutex>
#include <pb_decode.h>
#include <stdexcept>
#include <string>
#include <thread>
#include "PortduinoGPIO.h"
#include "PortduinoGlue.h"
#include "PowerFSM.h"
#include "mesh/MeshTypes.h"
#include "mesh/NodeDB.h"
#include "mesh/Router.h"
#include "mesh/TypeConversions.h"
#include "mesh/mesh-pb-constants.h"
namespace
{
constexpr uint32_t nodeId = 0x12345678;
// Set to true when lateInitVariant finishes. Used to ensure lateInitVariant was called during startup.
bool hasBeenConfigured = false;
// These are used to block the Arduino loop() function until a fuzzer input is ready. This is
// an optimization that prevents a sleep from happening before the loop is run. The Arduino loop
// function calls loopCanSleep() before sleeping. loopCanSleep is implemented here in the fuzzer
// and blocks until runLoopOnce() is called to signal for the loop to run.
bool fuzzerRunning = false; // Set to true once LLVMFuzzerTestOneInput has started running.
bool loopCanRun = true; // The main Arduino loop() can run when this is true.
bool loopIsWaiting = false; // The main Arduino loop() is waiting to be signaled to run.
bool loopShouldExit = false; // Indicates that the main Arduino thread should exit by throwing ShouldExitException.
std::mutex loopLock;
std::condition_variable loopCV;
std::thread meshtasticThread;
// This exception is thrown when the portuino main thread should exit.
class ShouldExitException : public std::runtime_error
{
public:
using std::runtime_error::runtime_error;
};
// Start the loop for one test case and wait till the loop has completed. This ensures fuzz
// test cases do not overlap with one another. This helps the fuzzer attribute a crash to the
// single, currently running, test case.
void runLoopOnce()
{
realHardware = true; // Avoids delay(100) within portduino/main.cpp
std::unique_lock<std::mutex> lck(loopLock);
fuzzerRunning = true;
loopCanRun = true;
loopCV.notify_one();
loopCV.wait(lck, [] { return !loopCanRun && loopIsWaiting; });
}
} // namespace
// Called in the main Arduino loop function to determine if the loop can delay/sleep before running again.
// We use this as a way to block the loop from sleeping and to start the loop function immediately when a
// fuzzer input is ready.
bool loopCanSleep()
{
std::unique_lock<std::mutex> lck(loopLock);
loopIsWaiting = true;
loopCV.notify_one();
loopCV.wait(lck, [] { return loopCanRun || loopShouldExit; });
loopIsWaiting = false;
if (loopShouldExit)
throw ShouldExitException("exit");
if (!fuzzerRunning)
return true; // The loop can sleep before the fuzzer starts.
loopCanRun = false; // Only run the loop once before waiting again.
return false;
}
// Called just prior to starting Meshtastic. Allows for setting config values before startup.
void lateInitVariant()
{
settingsMap[logoutputlevel] = level_error;
channelFile.channels[0] = meshtastic_Channel{
.has_settings = true,
.settings =
meshtastic_ChannelSettings{
.psk = {.size = 1, .bytes = {/*defaultpskIndex=*/1}},
.name = "LongFast",
.uplink_enabled = true,
.has_module_settings = true,
.module_settings = {.position_precision = 16},
},
.role = meshtastic_Channel_Role_PRIMARY,
};
config.security.admin_key[0] = {
.size = 32,
.bytes = {0xcd, 0xc0, 0xb4, 0x3c, 0x53, 0x24, 0xdf, 0x13, 0xca, 0x5a, 0xa6, 0x0c, 0x0d, 0xec, 0x85, 0x5a,
0x4c, 0xf6, 0x1a, 0x96, 0x04, 0x1a, 0x3e, 0xfc, 0xbb, 0x8e, 0x33, 0x71, 0xe5, 0xfc, 0xff, 0x3c},
};
config.security.admin_key_count = 1;
config.lora.region = meshtastic_Config_LoRaConfig_RegionCode_US;
moduleConfig.has_mqtt = true;
moduleConfig.mqtt = meshtastic_ModuleConfig_MQTTConfig{
.enabled = true,
.proxy_to_client_enabled = true,
};
moduleConfig.has_store_forward = true;
moduleConfig.store_forward = meshtastic_ModuleConfig_StoreForwardConfig{
.enabled = true,
.history_return_max = 4,
.history_return_window = 600,
.is_server = true,
};
meshtastic_Position fixedGPS = meshtastic_Position{
.has_latitude_i = true,
.latitude_i = static_cast<uint32_t>(1 * 1e7),
.has_longitude_i = true,
.longitude_i = static_cast<uint32_t>(3 * 1e7),
.has_altitude = true,
.altitude = 64,
.location_source = meshtastic_Position_LocSource_LOC_MANUAL,
};
nodeDB->setLocalPosition(fixedGPS);
config.has_position = true;
config.position.fixed_position = true;
meshtastic_NodeInfoLite *info = nodeDB->getMeshNode(nodeDB->getNodeNum());
info->has_position = true;
info->position = TypeConversions::ConvertToPositionLite(fixedGPS);
hasBeenConfigured = true;
}
extern "C" {
int portduino_main(int argc, char **argv); // Renamed "main" function from Meshtastic binary.
// Start Meshtastic in a thread and wait till it has reached the ON state.
int LLVMFuzzerInitialize(int *argc, char ***argv)
{
settingsMap[maxtophone] = 5;
meshtasticThread = std::thread([program = *argv[0]]() {
char nodeIdStr[12];
strcpy(nodeIdStr, std::to_string(nodeId).c_str());
int argc = 7;
char *argv[] = {program, "-d", "/tmp/meshtastic", "-h", nodeIdStr, "-p", "0", nullptr};
try {
portduino_main(argc, argv);
} catch (const ShouldExitException &) {
}
});
std::atexit([] {
{
const std::lock_guard<std::mutex> lck(loopLock);
loopShouldExit = true;
loopCV.notify_one();
}
meshtasticThread.join();
});
// Wait for startup.
for (int i = 1; i < 20; ++i) {
if (powerFSM.getState() == &stateON) {
assert(hasBeenConfigured);
assert(router);
assert(nodeDB);
return 0;
}
std::this_thread::sleep_for(std::chrono::seconds(1));
}
return 1;
}
// This is the main entrypoint for the fuzzer (the fuzz target). The fuzzer will provide an array of bytes to be
// interpreted by this method. To keep things simple, the bytes are interpreted as a binary serialized MeshPacket
// proto. Any crashes discovered by the fuzzer will be written to a file. Unserialize that file to print the MeshPacket
// that caused the failure.
//
// This guide provides best practices for writing a fuzzer target.
// https://github.com/google/fuzzing/blob/master/docs/good-fuzz-target.md
int LLVMFuzzerTestOneInput(const uint8_t *data, size_t length)
{
meshtastic_MeshPacket p = meshtastic_MeshPacket_init_default;
pb_istream_t stream = pb_istream_from_buffer(data, length);
// Ignore any inputs that fail to decode or have fields set that are not transmitted over LoRa.
if (!pb_decode(&stream, &meshtastic_MeshPacket_msg, &p) || p.rx_time || p.rx_snr || p.priority || p.rx_rssi || p.delayed ||
p.public_key.size || p.next_hop || p.relay_node || p.tx_after)
return -1; // Reject: The input will not be added to the corpus.
if (p.which_payload_variant == meshtastic_MeshPacket_decoded_tag) {
meshtastic_Data d;
stream = pb_istream_from_buffer(p.decoded.payload.bytes, p.decoded.payload.size);
if (!pb_decode(&stream, &meshtastic_Data_msg, &d))
return -1; // Reject: The input will not be added to the corpus.
}
// Provide default values for a few fields so the fuzzer doesn't need to guess them.
if (p.from == 0)
p.from = nodeDB->getNodeNum();
if (p.to == 0)
p.to = nodeDB->getNodeNum();
static uint32_t packetId = 0;
if (p.id == 0)
p.id == ++packetId;
if (p.pki_encrypted && config.security.admin_key_count)
memcpy(&p.public_key, &config.security.admin_key[0], sizeof(p.public_key));
router->enqueueReceivedMessage(packetPool.allocCopy(p));
runLoopOnce();
return 0; // Accept: The input may be added to the corpus.
}
}

View File

@@ -0,0 +1,2 @@
[libfuzzer]
max_len=256

View File

@@ -0,0 +1,168 @@
"""Generate an initial set of MeshPackets.
The fuzzer uses these MeshPackets as an initial seed of test candidates.
It's also good to add any previously discovered crash test cases to this list
to avoid future regressions.
If left unset, the following values will be automatically set by the fuzzer.
- to: automatically set to the running node's NodeID
- from: automatically set to the running node's NodeID
- id: automatically set to the value of an incrementing counter
Additionally, if `pki_encrypted` is populated in the packet, the first admin key
will be copied into the `public_key` field.
"""
import base64
from meshtastic import BROADCAST_NUM
from meshtastic.protobuf import (
admin_pb2,
atak_pb2,
mesh_pb2,
portnums_pb2,
telemetry_pb2,
)
def From(node: int = 9):
"""Return a dict suitable for **kwargs for populating the 'from' field.
'from' is a reserved keyword in Python. It can't be used directly as an
argument to the MeshPacket constructor. Rather **From() can be used as
the final argument to provide the from node as a **kwarg.
Defaults to 9 if no value is provided.
"""
return {"from": node}
packets = (
(
"position",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.POSITION_APP,
payload=mesh_pb2.Position(
latitude_i=int(1 * 1e7),
longitude_i=int(2 * 1e7),
altitude=5,
precision_bits=32,
).SerializeToString(),
),
to=BROADCAST_NUM,
**From(),
),
),
(
"telemetry",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.TELEMETRY_APP,
payload=telemetry_pb2.Telemetry(
time=1736192207,
device_metrics=telemetry_pb2.DeviceMetrics(
battery_level=101,
channel_utilization=8,
air_util_tx=2,
uptime_seconds=42,
),
).SerializeToString(),
),
to=BROADCAST_NUM,
**From(),
),
),
(
"text",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.TEXT_MESSAGE_APP,
payload=b"Hello world",
),
to=BROADCAST_NUM,
**From(),
),
),
(
"user",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.NODEINFO_APP,
payload=mesh_pb2.User(
id="!00000009",
long_name="Node 9",
short_name="N9",
macaddr=b"\x00\x00\x00\x00\x00\x09",
hw_model=mesh_pb2.HardwareModel.RAK4631,
public_key=base64.b64decode(
"L0ih/6F41itofdE8mYyHk1SdfOJ/QRM1KQ+pO4vEEjQ="
),
).SerializeToString(),
),
**From(),
),
),
(
"traceroute",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.TRACEROUTE_APP,
payload=mesh_pb2.RouteDiscovery(
route=[10],
).SerializeToString(),
),
**From(),
),
),
(
"routing",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.ROUTING_APP,
payload=mesh_pb2.Routing(
error_reason=mesh_pb2.Routing.NO_RESPONSE,
).SerializeToString(),
),
**From(),
),
),
(
"admin",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.ADMIN_APP,
payload=admin_pb2.AdminMessage(
get_owner_request=True,
).SerializeToString(),
),
pki_encrypted=True,
**From(),
),
),
(
"atak",
mesh_pb2.MeshPacket(
decoded=mesh_pb2.Data(
portnum=portnums_pb2.PortNum.ATAK_PLUGIN,
payload=atak_pb2.TAKPacket(
is_compressed=True,
# Note, the strings are not valid for a compressed message, but will
# give the fuzzer a starting point.
contact=atak_pb2.Contact(
callsign="callsign", device_callsign="device_callsign"
),
chat=atak_pb2.GeoChat(
message="message", to="to", to_callsign="to_callsign"
),
).SerializeToString(),
),
**From(),
),
),
)
for name, packet in packets:
with open(f"{name}.MeshPacket", "wb") as f:
f.write(packet.SerializeToString())

View File

@@ -0,0 +1,183 @@
# Copyright (c) 2014-present PlatformIO <contact@platformio.org>
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
#####################################################################################
#
# INSTALLATION
#
# Please visit > https://docs.platformio.org/en/latest/core/installation/udev-rules.html
#
#####################################################################################
#
# Boards
#
# CP210X USB UART
ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="ea[67][013]", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
ATTRS{idVendor}=="10c4", ATTRS{idProduct}=="80a9", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# FT231XS USB UART
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="6015", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Prolific Technology, Inc. PL2303 Serial Port
ATTRS{idVendor}=="067b", ATTRS{idProduct}=="2303", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# QinHeng Electronics HL-340 USB-Serial adapter
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7523", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# QinHeng Electronics CH343 USB-Serial adapter
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="55d3", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# QinHeng Electronics CH9102 USB-Serial adapter
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="55d4", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Arduino boards
ATTRS{idVendor}=="2341", ATTRS{idProduct}=="[08][023]*", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
ATTRS{idVendor}=="2a03", ATTRS{idProduct}=="[08][02]*", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Arduino SAM-BA
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{MTP_NO_PROBE}="1"
# Digistump boards
ATTRS{idVendor}=="16d0", ATTRS{idProduct}=="0753", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Maple with DFU
ATTRS{idVendor}=="1eaf", ATTRS{idProduct}=="000[34]", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# USBtiny
ATTRS{idProduct}=="0c9f", ATTRS{idVendor}=="1781", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# USBasp V2.0
ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="05dc", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Teensy boards
ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789B]?", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789A]?", ENV{MTP_NO_PROBE}="1"
SUBSYSTEMS=="usb", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789ABCD]?", MODE:="0666"
KERNEL=="ttyACM*", ATTRS{idVendor}=="16c0", ATTRS{idProduct}=="04[789B]?", MODE:="0666"
# TI Stellaris Launchpad
ATTRS{idVendor}=="1cbe", ATTRS{idProduct}=="00fd", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# TI MSP430 Launchpad
ATTRS{idVendor}=="0451", ATTRS{idProduct}=="f432", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# GD32V DFU Bootloader
ATTRS{idVendor}=="28e9", ATTRS{idProduct}=="0189", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# FireBeetle-ESP32
ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="7522", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Wio Terminal
ATTRS{idVendor}=="2886", ATTRS{idProduct}=="[08]02d", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Raspberry Pi Pico
ATTRS{idVendor}=="2e8a", ATTRS{idProduct}=="[01]*", MODE:="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# AIR32F103
ATTRS{idVendor}=="0d28", ATTRS{idProduct}=="0204", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# STM32 virtual COM port
ATTRS{idVendor}=="0483", ATTRS{idProduct}=="5740", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
#
# Debuggers
#
# Black Magic Probe
SUBSYSTEM=="tty", ATTRS{interface}=="Black Magic GDB Server", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
SUBSYSTEM=="tty", ATTRS{interface}=="Black Magic UART Port", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# opendous and estick
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="204f", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Original FT232/FT245/FT2232/FT232H/FT4232
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="60[01][104]", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# DISTORTEC JTAG-lock-pick Tiny 2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8220", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# TUMPA, TUMPA Lite
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="8a9[89]", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# XDS100v2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="a6d0", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Xverve Signalyzer Tool (DT-USB-ST), Signalyzer LITE (DT-USB-SLITE)
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bca[01]", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# TI/Luminary Stellaris Evaluation Board FTDI (several)
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bcd[9a]", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# egnite Turtelizer 2
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="bdc8", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Section5 ICEbear
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="c14[01]", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Amontec JTAGkey and JTAGkey-tiny
ATTRS{idVendor}=="0403", ATTRS{idProduct}=="cff8", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# TI ICDI
ATTRS{idVendor}=="0451", ATTRS{idProduct}=="c32a", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# STLink probes
ATTRS{idVendor}=="0483", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Hilscher NXHX Boards
ATTRS{idVendor}=="0640", ATTRS{idProduct}=="0028", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Hitex probes
ATTRS{idVendor}=="0640", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Altera USB Blaster
ATTRS{idVendor}=="09fb", ATTRS{idProduct}=="6001", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Amontec JTAGkey-HiSpeed
ATTRS{idVendor}=="0fbb", ATTRS{idProduct}=="1000", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# SEGGER J-Link
ATTRS{idVendor}=="1366", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Raisonance RLink
ATTRS{idVendor}=="138e", ATTRS{idProduct}=="9000", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Debug Board for Neo1973
ATTRS{idVendor}=="1457", ATTRS{idProduct}=="5118", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Olimex probes
ATTRS{idVendor}=="15ba", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# USBprog with OpenOCD firmware
ATTRS{idVendor}=="1781", ATTRS{idProduct}=="0c63", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# TI/Luminary Stellaris In-Circuit Debug Interface (ICDI) Board
ATTRS{idVendor}=="1cbe", ATTRS{idProduct}=="00fd", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Marvell Sheevaplug
ATTRS{idVendor}=="9e88", ATTRS{idProduct}=="9e8f", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Keil Software, Inc. ULink
ATTRS{idVendor}=="c251", ATTRS{idProduct}=="2710", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# CMSIS-DAP compatible adapters
ATTRS{product}=="*CMSIS-DAP*", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Atmel AVR Dragon
ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2107", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Espressif USB JTAG/serial debug unit
ATTRS{idVendor}=="303a", ATTRS{idProduct}=="1001", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"
# Zephyr framework USB CDC-ACM
ATTRS{idVendor}=="2fe3", ATTRS{idProduct}=="0100", MODE="0666", ENV{ID_MM_DEVICE_IGNORE}="1", ENV{ID_MM_PORT_IGNORE}="1"

45
.devcontainer/Dockerfile Normal file
View File

@@ -0,0 +1,45 @@
# trunk-ignore-all(terrascan/AC_DOCKER_0002): Known terrascan issue
# trunk-ignore-all(hadolint/DL3008): Do not pin apt package versions
# trunk-ignore-all(hadolint/DL3013): Do not pin pip package versions
FROM mcr.microsoft.com/devcontainers/cpp:1-debian-12
USER root
RUN apt-get update && export DEBIAN_FRONTEND=noninteractive \
&& apt-get -y install --no-install-recommends \
ca-certificates \
g++ \
git \
libbluetooth-dev \
libgpiod-dev \
liborcania-dev \
libssl-dev \
libulfius-dev \
libyaml-cpp-dev \
pipx \
pkg-config \
python3 \
python3-pip \
python3-venv \
python3-wheel \
wget \
zip \
usbutils \
hwdata \
gpg \
gnupg2 \
libusb-1.0-0-dev \
libuv1-dev \
libi2c-dev \
libxcb-xkb-dev \
libxkbcommon-dev \
libinput-dev \
&& apt-get clean && rm -rf /var/lib/apt/lists/*
RUN pipx install platformio
COPY 99-platformio-udev.rules /etc/udev/rules.d/99-platformio-udev.rules
USER vscode
HEALTHCHECK NONE

View File

@@ -0,0 +1,36 @@
// For format details, see https://aka.ms/devcontainer.json. For config options, see the
// README at: https://github.com/devcontainers/templates/tree/main/src/cpp
{
"name": "Meshtastic Firmware Dev",
"build": {
"dockerfile": "Dockerfile"
},
"features": {
"ghcr.io/devcontainers/features/python:1": {
"installTools": true,
"version": "latest"
}
},
"customizations": {
"vscode": {
"extensions": [
"ms-vscode.cpptools",
"platformio.platformio-ide",
"Trunk.io"
],
"unwantedRecommendations": ["ms-azuretools.vscode-docker"],
"settings": {
"extensions.ignoreRecommendations": true
}
}
},
// Use 'forwardPorts' to make a list of ports inside the container available locally.
"forwardPorts": [4403],
// Use "--device=" to make a local device available inside the container.
// "runArgs": ["--device=/dev/ttyACM0"],
// Run commands to prepare the container for use
"postCreateCommand": ".devcontainer/setup.sh"
}

6
.devcontainer/setup.sh Executable file
View File

@@ -0,0 +1,6 @@
#!/usr/bin/env sh
git submodule update --init
pip install --no-cache-dir setuptools
pipx install esptool

1
.dockerignore Symbolic link
View File

@@ -0,0 +1 @@
.gitignore

4
.env.example Normal file
View File

@@ -0,0 +1,4 @@
# Absolute path to the local meshtastic config.yaml file
CONFIG_PATH=/path/to/meshtastic/config.yaml
# USB device to passthrough (`lsusb -t`: look for `ch341`)
USB_DEVICE=/dev/bus/usb/001/037

5
.gitattributes vendored
View File

@@ -1,4 +1,5 @@
* text=auto eol=lf
*.{cmd,[cC][mM][dD]} text eol=crlf
*.{bat,[bB][aA][tT]} text eol=crlf
*.cmd text eol=crlf
*.bat text eol=crlf
*.ps1 text eol=crlf
*.{sh,[sS][hH]} text eol=lf

3
.github/FUNDING.yml vendored Normal file
View File

@@ -0,0 +1,3 @@
# These are supported funding model platforms
open_collective: meshtastic

View File

@@ -1,7 +1,7 @@
name: Bug Report
description: File a bug report
title: "[Bug]: "
labels: ["bug", "triage"]
labels: [bug, triage]
body:
- type: markdown
attributes:
@@ -49,14 +49,38 @@ body:
- Heltec V3
- Heltec Wireless Paper
- Heltec Wireless Tracker
- Heltec Mesh Node T114
- Heltec Vision Master E213
- Heltec Vision Master E290
- Heltec Vision Master T190
- Nano G1
- Nano G1 Explorer
- Nano G2 Ultra
- Raspberry Pi Pico (W)
- Relay v1
- Relay v2
- Seeed Wio Tracker 1110
- Seeed Card Tracker T1000-E
- Station G1
- Station G2
- unPhone
- CanaryOne
- Chatter
- Linux Native
- DIY
- Other
validations:
required: true
- type: checkboxes
id: mui
attributes:
label: Is this bug report about any UI component firmware like InkHUD or Meshtatic UI (MUI)?
options:
- label: Meshtastic UI aka MUI colorTFT
- label: InkHUD ePaper
- label: OLED slide UI on any display
- type: input
id: version
attributes:

View File

@@ -1,7 +1,7 @@
name: New Board
description: Request us to support new hardware
title: "[Board]: "
labels: ["enhancement", "triage"]
labels: [enhancement, triage]
body:
- type: markdown
attributes:

View File

@@ -1,7 +1,7 @@
name: Feature Request
description: Request a new feature
title: "[Feature Request]: "
labels: ["enhancement"]
labels: [enhancement]
body:
- type: markdown
attributes:
@@ -16,6 +16,10 @@ body:
options:
- NRF52
- ESP32
- RP2040
- Linux Native
- Cross-Platform
- other
validations:
required: true
- type: textarea

5
.github/actionlint.yaml vendored Normal file
View File

@@ -0,0 +1,5 @@
# Configuration related to self-hosted runner.
self-hosted-runner:
# Labels of self-hosted runner in array of strings.
labels:
- test-runner

108
.github/actions/build-variant/action.yml vendored Normal file
View File

@@ -0,0 +1,108 @@
name: Setup Build Variant Composite Action
description: Variant build actions for Meshtastic Platform IO steps
inputs:
board:
description: The board to build for
required: true
github_token:
description: GitHub token
required: true
build-script-path:
description: Path to the build script
required: true
remove-debug-flags:
description: A space separated list of files to remove debug flags from
required: false
default: ""
ota-firmware-source:
description: The OTA firmware file to pull
required: false
default: ""
ota-firmware-target:
description: The target path to store the OTA firmware file
required: false
default: ""
artifact-paths:
description: A newline separated list of paths to store as artifacts
required: false
default: ""
# include-web-ui:
# description: Include the web UI in the build
# required: false
# default: "false"
arch:
description: Processor arch name
required: true
default: esp32
runs:
using: composite
steps:
- name: Build base
id: base
uses: ./.github/actions/setup-base
# - name: Get web ui version
# if: inputs.include-web-ui == 'true'
# id: webver
# shell: bash
# run: |
# echo "ver=$(cat bin/web.version)" >> $GITHUB_OUTPUT
# - name: Pull web ui
# if: inputs.include-web-ui == 'true'
# uses: dsaltares/fetch-gh-release-asset@master
# with:
# repo: meshtastic/web
# file: build.tar
# target: build.tar
# token: ${{ inputs.github_token }}
# version: tags/v${{ steps.webver.outputs.ver }}
# - name: Unpack web ui
# if: inputs.include-web-ui == 'true'
# shell: bash
# run: |
# tar -xf build.tar -C data/static
# rm build.tar
- name: Remove debug flags for release
shell: bash
if: inputs.remove-debug-flags != ''
run: |
for INI_FILE in ${{ inputs.remove-debug-flags }}; do
sed -i '/DDEBUG_HEAP/d' ${INI_FILE}
done
- name: PlatformIO ${{ inputs.arch }} download cache
uses: actions/cache@v4
with:
path: ~/.platformio/.cache
key: pio-cache-${{ inputs.arch }}-${{ hashFiles('.github/actions/**', '**.ini') }}
- name: Build ${{ inputs.board }}
shell: bash
run: ${{ inputs.build-script-path }} ${{ inputs.board }}
- name: Pull OTA Firmware
if: inputs.ota-firmware-source != '' && inputs.ota-firmware-target != ''
uses: dsaltares/fetch-gh-release-asset@master
with:
repo: meshtastic/firmware-ota
file: ${{ inputs.ota-firmware-source }}
target: ${{ inputs.ota-firmware-target }}
token: ${{ inputs.github_token }}
- name: Get release version string
shell: bash
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v4
with:
name: firmware-${{ inputs.arch }}-${{ inputs.board }}-${{ steps.version.outputs.long }}.zip
overwrite: true
path: |
${{ inputs.artifact-paths }}

View File

@@ -1,52 +1,39 @@
name: "Setup Build Base Composite Action"
description: "Base build actions for Meshtastic Platform IO steps"
name: Setup Build Base Composite Action
description: Base build actions for Meshtastic Platform IO steps
runs:
using: "composite"
using: composite
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v5
with:
submodules: "recursive"
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install cppcheck
- name: Install dependencies
shell: bash
run: |
sudo apt-get install -y cppcheck
- name: Install libbluetooth
shell: bash
run: |
sudo apt-get install -y libbluetooth-dev
- name: Install libgpiod
shell: bash
run: |
sudo apt-get install -y libgpiod-dev
- name: Install libyaml-cpp
shell: bash
run: |
sudo apt-get install -y libyaml-cpp-dev
sudo apt-get -y update --fix-missing
sudo apt-get install -y cppcheck libbluetooth-dev libgpiod-dev libyaml-cpp-dev lsb-release
- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v6
with:
python-version: 3.x
- name: Cache python libs
uses: actions/cache@v3
id: cache-pip # needed in if test
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip
cache: pip
cache-dependency-path: |
.github/actions/**
**.ini
- name: Upgrade python tools
shell: bash
run: |
python -m pip install --upgrade pip
pip install -U platformio adafruit-nrfutil
pip install -U meshtastic --pre
pip install -U --no-build-isolation --no-cache-dir "setuptools<72"
pip install -U platformio adafruit-nrfutil --no-build-isolation
pip install -U poetry --no-build-isolation
pip install -U meshtastic --pre --no-build-isolation
- name: Upgrade platformio
shell: bash

14
.github/actions/setup-native/action.yml vendored Normal file
View File

@@ -0,0 +1,14 @@
name: Setup native build
description: Install libraries needed for building the Native/Portduino build
runs:
using: composite
steps:
- name: Setup base
id: base
uses: ./.github/actions/setup-base
- name: Install libs needed for native build
shell: bash
run: |
sudo apt-get install -y libbluetooth-dev libgpiod-dev libyaml-cpp-dev openssl libssl-dev libulfius-dev liborcania-dev libusb-1.0-0-dev libi2c-dev libuv1-dev

BIN
.github/meshtastic_logo.png vendored Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 89 KiB

View File

@@ -1,9 +1,9 @@
## Thank you for sending in a pull request, here's some tips to get started!
## 🙏 Thank you for sending in a pull request, here's some tips to get started!
(Please delete all these tips and replace with your text)
### ❌ (Please delete all these tips and replace them with your text)
- Before starting on some new big chunk of code, it it is optional but highly recommended to open an issue first
to say "hey, I think this idea X should be implemented and I'm starting work on it. My general plan is Y, any feedback
to say "Hey, I think this idea X should be implemented and I'm starting work on it. My general plan is Y, any feedback
is appreciated." This will allow other devs to potentially save you time by not accidentially duplicating work etc...
- Please do not check in files that don't have real changes
- Please do not reformat lines that you didn't have to change the code on
@@ -12,3 +12,17 @@
- If your PR fixes a bug, mention "fixes #bugnum" somewhere in your pull request description.
- If your other co-developers have comments on your PR please tweak as needed.
- Please also enable "Allow edits by maintainers".
- Please do not submit untested code.
- If you do not have the affected hardware to test your code changes adequately against regressions, please indicate this, so that contributors and commnunity members can help test your changes.
- If your PR gets accepted you can request a "Contributor" role in the Meshtastic Discord
## 🤝 Attestations
- [ ] I have tested that my proposed changes behave as described.
- [ ] I have tested that my proposed changes do not cause any obvious regressions on the following devices:
- [ ] Heltec (Lora32) V3
- [ ] LilyGo T-Deck
- [ ] LilyGo T-Beam
- [ ] RAK WisBlock 4631
- [ ] Seeed Studio T-1000E tracker card
- [ ] Other (please specify below)

72
.github/workflows/build_debian_src.yml vendored Normal file
View File

@@ -0,0 +1,72 @@
name: Build Debian Source Package
on:
workflow_call:
secrets:
PPA_GPG_PRIVATE_KEY:
required: false
inputs:
series:
description: Ubuntu/Debian series to target
required: true
type: string
build_location:
description: Location where build will execute
required: true
type: string
permissions:
contents: write
packages: write
jobs:
build-debian-src:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
path: meshtasticd
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install deps
shell: bash
working-directory: meshtasticd
run: |
sudo apt-get update -y --fix-missing
sudo apt-get install -y software-properties-common build-essential devscripts equivs
sudo add-apt-repository ppa:meshtastic/build-tools -y
sudo apt-get update -y --fix-missing
sudo mk-build-deps --install --remove --tool='apt-get -o Debug::pkgProblemResolver=yes --no-install-recommends --yes' debian/control
- name: Import GPG key
uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.PPA_GPG_PRIVATE_KEY }}
id: gpg
- name: Get release version string
working-directory: meshtasticd
run: |
echo "deb=$(./bin/buildinfo.py deb)" >> $GITHUB_OUTPUT
env:
BUILD_LOCATION: ${{ inputs.build_location }}
id: version
- name: Fetch libdeps, package debian source
working-directory: meshtasticd
run: debian/ci_pack_sdeb.sh
env:
SERIES: ${{ inputs.series }}
GPG_KEY_ID: ${{ steps.gpg.outputs.keyid }}
PKG_VERSION: ${{ steps.version.outputs.deb }}
- name: Store binaries as an artifact
uses: actions/upload-artifact@v4
with:
name: firmware-debian-${{ steps.version.outputs.deb }}~${{ inputs.series }}-src
overwrite: true
path: |
meshtasticd_${{ steps.version.outputs.deb }}*

View File

@@ -1,62 +0,0 @@
name: Build ESP32
on:
workflow_call:
inputs:
board:
required: true
type: string
jobs:
build-esp32:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Pull web ui
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/web
file: build.tar
target: build.tar
token: ${{ secrets.GITHUB_TOKEN }}
- name: Unpack web ui
run: |
tar -xf build.tar -C data/static
rm build.tar
- name: Remove debug flags for release
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s2.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s3.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32c3.ini
- name: Build ESP32
run: bin/build-esp32.sh ${{ inputs.board }}
- name: Pull OTA Firmware
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/firmware-ota
file: firmware.bin
target: release/bleota.bin
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get release version string
shell: bash
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-${{ inputs.board }}-${{ steps.version.outputs.version }}.zip
path: |
release/*.bin
release/*.elf

View File

@@ -1,62 +0,0 @@
name: Build ESP32-C3
on:
workflow_call:
inputs:
board:
required: true
type: string
permissions: read-all
jobs:
build-esp32-c3:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Pull web ui
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/web
file: build.tar
target: build.tar
token: ${{ secrets.GITHUB_TOKEN }}
- name: Unpack web ui
run: |
tar -xf build.tar -C data/static
rm build.tar
- name: Remove debug flags for release
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s2.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s3.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32c3.ini
- name: Build ESP32
run: bin/build-esp32.sh ${{ inputs.board }}
- name: Pull OTA Firmware
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/firmware-ota
file: firmware-c3.bin
target: release/bleota-c3.bin
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get release version string
shell: bash
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-${{ inputs.board }}-${{ steps.version.outputs.version }}.zip
path: |
release/*.bin
release/*.elf

View File

@@ -1,60 +0,0 @@
name: Build ESP32-S3
on:
workflow_call:
inputs:
board:
required: true
type: string
jobs:
build-esp32-s3:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Pull web ui
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/web
file: build.tar
target: build.tar
token: ${{ secrets.GITHUB_TOKEN }}
- name: Unpack web ui
run: |
tar -xf build.tar -C data/static
rm build.tar
- name: Remove debug flags for release
if: ${{ github.event_name == 'workflow_dispatch' }}
run: |
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s2.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32s3.ini
sed -i '/DDEBUG_HEAP/d' ./arch/esp32/esp32c3.ini
- name: Build ESP32
run: bin/build-esp32.sh ${{ inputs.board }}
- name: Pull OTA Firmware
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/firmware-ota
file: firmware-s3.bin
target: release/bleota-s3.bin
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get release version string
shell: bash
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-${{ inputs.board }}-${{ steps.version.outputs.version }}.zip
path: |
release/*.bin
release/*.elf

66
.github/workflows/build_firmware.yml vendored Normal file
View File

@@ -0,0 +1,66 @@
name: Build
on:
workflow_call:
inputs:
version:
required: true
type: string
platform:
required: true
type: string
pio_env:
required: true
type: string
permissions: read-all
jobs:
pio-build:
name: build-${{ inputs.platform }}
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v5
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Set OTA firmware source and target
if: startsWith(inputs.platform, 'esp32')
id: ota_dir
env:
PIO_PLATFORM: ${{ inputs.platform }}
run: |
if [ "$PIO_PLATFORM" = "esp32s3" ]; then
echo "src=firmware-s3.bin" >> $GITHUB_OUTPUT
echo "tgt=release/bleota-s3.bin" >> $GITHUB_OUTPUT
elif [ "$PIO_PLATFORM" = "esp32c3" ] || [ "$PIO_PLATFORM" = "esp32c6" ]; then
echo "src=firmware-c3.bin" >> $GITHUB_OUTPUT
echo "tgt=release/bleota-c3.bin" >> $GITHUB_OUTPUT
elif [ "$PIO_PLATFORM" = "esp32" ]; then
echo "src=firmware.bin" >> $GITHUB_OUTPUT
echo "tgt=release/bleota.bin" >> $GITHUB_OUTPUT
fi
- name: Build ${{ inputs.platform }}
id: build
uses: meshtastic/gh-action-firmware@main
with:
pio_platform: ${{ inputs.platform }}
pio_env: ${{ inputs.pio_env }}
pio_target: build
ota_firmware_source: ${{ steps.ota_dir.outputs.src || '' }}
ota_firmware_target: ${{ steps.ota_dir.outputs.tgt || '' }}
- name: Store binaries as an artifact
uses: actions/upload-artifact@v4
with:
name: firmware-${{ inputs.platform }}-${{ inputs.pio_env }}-${{ inputs.version }}.zip
overwrite: true
path: |
release/*.bin
release/*.elf
release/*.uf2
release/*.hex
release/*-ota.zip

View File

@@ -1,33 +0,0 @@
name: Build NRF52
on:
workflow_call:
inputs:
board:
required: true
type: string
jobs:
build-nrf52:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Build NRF52
run: bin/build-nrf52.sh ${{ inputs.board }}
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-${{ inputs.board }}-${{ steps.version.outputs.version }}.zip
path: |
release/*.uf2
release/*.elf
release/*.zip

View File

@@ -1,45 +0,0 @@
name: Build Raspbian
on: workflow_call
permissions:
contents: write
packages: write
jobs:
build-raspbian:
runs-on: [self-hosted, linux, ARM64]
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Upgrade python tools
shell: bash
run: |
python -m pip install --upgrade pip
pip install -U platformio adafruit-nrfutil
pip install -U meshtastic --pre
- name: Upgrade platformio
shell: bash
run: |
pio upgrade
- name: Build Raspbian
run: bin/build-native.sh
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-raspbian-${{ steps.version.outputs.version }}.zip
path: |
release/meshtasticd_linux_aarch64
bin/config-dist.yaml

View File

@@ -1,32 +0,0 @@
name: Build RPI2040
on:
workflow_call:
inputs:
board:
required: true
type: string
jobs:
build-rpi2040:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Build Raspberry Pi 2040
run: ./bin/build-rpi2040.sh ${{ inputs.board }}
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-${{ inputs.board }}-${{ steps.version.outputs.version }}.zip
path: |
release/*.uf2
release/*.elf

55
.github/workflows/daily_packaging.yml vendored Normal file
View File

@@ -0,0 +1,55 @@
name: Daily Packaging
on:
schedule:
- cron: 0 2 * * *
workflow_dispatch:
push:
branches:
- master
paths:
- debian/**
- "*.rpkg"
- .github/workflows/nightly_packaging.yml
- .github/workflows/build_debian_src.yml
- .github/workflows/package_ppa.yml
- .github/workflows/package_obs.yml
- .github/workflows/hook_copr.yml
permissions:
contents: write
packages: write
jobs:
docker-multiarch:
uses: ./.github/workflows/docker_manifest.yml
with:
release_channel: daily
secrets: inherit
package-ppa:
strategy:
fail-fast: false
matrix:
series:
- jammy # 22.04
- noble # 24.04
- plucky # 25.04
- questing # 25.10
uses: ./.github/workflows/package_ppa.yml
with:
ppa_repo: ppa:meshtastic/daily
series: ${{ matrix.series }}
secrets: inherit
package-obs:
uses: ./.github/workflows/package_obs.yml
with:
obs_project: network:Meshtastic:daily
series: unstable
secrets: inherit
hook-copr:
uses: ./.github/workflows/hook_copr.yml
with:
copr_project: daily
secrets: inherit

99
.github/workflows/docker_build.yml vendored Normal file
View File

@@ -0,0 +1,99 @@
name: Build Docker
# Build Docker image, push untagged (digest-only)
on:
workflow_call:
secrets:
DOCKER_FIRMWARE_TOKEN:
required: false # Only required for push
inputs:
distro:
description: Distro to target
required: true
type: string
# choices: [debian, alpine]
platform:
description: Platform to target
required: true
type: string
runs-on:
description: Runner to use
required: true
type: string
push:
description: Push images to registry
required: false
type: boolean
default: false
pio_env:
description: PlatformIO environment to build
required: false
type: string
default: native
outputs:
digest:
description: Digest of built image
value: ${{ jobs.docker-build.outputs.digest }}
permissions:
contents: write
packages: write
jobs:
docker-build:
outputs:
digest: ${{ steps.docker_variant.outputs.digest }}
runs-on: ${{ inputs.runs-on }}
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Get release version string
run: |
echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Docker login
if: ${{ inputs.push }}
uses: docker/login-action@v3
with:
username: meshtastic
password: ${{ secrets.DOCKER_FIRMWARE_TOKEN }}
- name: Set up QEMU
uses: docker/setup-qemu-action@v3
- name: Docker setup
uses: docker/setup-buildx-action@v3
- name: Sanitize platform string
id: sanitize_platform
# Replace slashes with underscores
run: echo "cleaned_platform=${{ inputs.platform }}" | sed 's/\//_/g' >> $GITHUB_OUTPUT
- name: Docker tag
id: meta
uses: docker/metadata-action@v5
with:
images: meshtastic/meshtasticd
tags: |
GHA-${{ steps.version.outputs.long }}-${{ inputs.distro }}-${{ steps.sanitize_platform.outputs.cleaned_platform }}
flavor: latest=false
- name: Docker build and push
uses: docker/build-push-action@v6
id: docker_variant
with:
context: .
file: |
${{ contains(inputs.distro, 'debian') && './Dockerfile' || contains(inputs.distro, 'alpine') && './alpine.Dockerfile' }}
push: ${{ inputs.push }}
tags: ${{ steps.meta.outputs.tags }} # Tag is only meant to be consumed by the "manifest" job
platforms: ${{ inputs.platform }}
build-args: |
PIO_ENV=${{ inputs.pio_env }}

186
.github/workflows/docker_manifest.yml vendored Normal file
View File

@@ -0,0 +1,186 @@
name: Build Docker Multi-Arch Manifest
on:
workflow_call:
secrets:
DOCKER_FIRMWARE_TOKEN:
required: true
inputs:
release_channel:
description: Release channel to target
required: true
type: string
permissions:
contents: write
packages: write
jobs:
docker-debian-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/amd64
runs-on: ubuntu-24.04
push: true
secrets: inherit
docker-debian-arm64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm64
runs-on: ubuntu-24.04-arm
push: true
secrets: inherit
docker-debian-armv7:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm/v7
runs-on: ubuntu-24.04-arm
push: true
secrets: inherit
docker-alpine-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/amd64
runs-on: ubuntu-24.04
push: true
secrets: inherit
docker-alpine-arm64:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/arm64
runs-on: ubuntu-24.04-arm
push: true
secrets: inherit
docker-alpine-armv7:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/arm/v7
runs-on: ubuntu-24.04-arm
push: true
secrets: inherit
docker-manifest:
needs:
# Debian
- docker-debian-amd64
- docker-debian-arm64
- docker-debian-armv7
# Alpine
- docker-alpine-amd64
- docker-alpine-arm64
- docker-alpine-armv7
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Get release version string
run: |
echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
echo "short=$(./bin/buildinfo.py short)" >> $GITHUB_OUTPUT
id: version
- name: Enumerate tags
shell: python
run: |
import os
short = "${{ steps.version.outputs.short }}"
long = "${{ steps.version.outputs.long }}"
release_channel = "${{ inputs.release_channel }}"
tags = {
"beta": {
"debian": [
f"{short}", f"{long}", f"{short}-beta", f"{long}-beta", "beta", "latest",
f"{short}-debian", f"{long}-debian", f"{short}-beta-debian", f"{long}-beta-debian", "beta-debian"
],
"alpine": [
f"{short}-alpine", f"{long}-alpine", f"{short}-beta-alpine", f"{long}-beta-alpine", "beta-alpine"
]
},
"alpha": {
"debian": [
f"{short}-alpha", f"{long}-alpha", "alpha",
f"{short}-alpha-debian", f"{long}-alpha-debian", "alpha-debian"
],
"alpine": [
f"{short}-alpha-alpine", f"{long}-alpha-alpine", "alpha-alpine"
]
},
"daily": {
"debian": ["daily", "daily-debian"],
"alpine": ["daily-alpine"]
}
}
with open(os.environ["GITHUB_OUTPUT"], "a") as fh:
fh.write("debian<<EOF\n")
fh.write("\n".join(tags[release_channel]["debian"]))
fh.write("\nEOF\n")
fh.write("alpine<<EOF\n")
fh.write("\n".join(tags[release_channel]["alpine"]))
fh.write("\nEOF\n")
id: tags
- name: Docker login
uses: docker/login-action@v3
with:
username: meshtastic
password: ${{ secrets.DOCKER_FIRMWARE_TOKEN }}
- name: Docker meta (Debian)
id: meta_debian
uses: docker/metadata-action@v5
with:
images: meshtastic/meshtasticd
tags: |
${{ steps.tags.outputs.debian }}
flavor: latest=false
- name: Create Docker manifest (Debian)
id: manifest_debian
uses: int128/docker-manifest-create-action@v2
with:
tags: |
${{ steps.meta_debian.outputs.tags }}
push: true
sources: |
meshtastic/meshtasticd@${{ needs.docker-debian-amd64.outputs.digest }}
meshtastic/meshtasticd@${{ needs.docker-debian-arm64.outputs.digest }}
meshtastic/meshtasticd@${{ needs.docker-debian-armv7.outputs.digest }}
- name: Docker meta (Alpine)
id: meta_alpine
uses: docker/metadata-action@v5
with:
images: meshtastic/meshtasticd
tags: |
${{ steps.tags.outputs.alpine }}
- name: Create Docker manifest (Alpine)
id: manifest_alpine
uses: int128/docker-manifest-create-action@v2
with:
tags: |
${{ steps.meta_alpine.outputs.tags }}
push: true
sources: |
meshtastic/meshtasticd@${{ needs.docker-alpine-amd64.outputs.digest }}
meshtastic/meshtasticd@${{ needs.docker-alpine-arm64.outputs.digest }}
meshtastic/meshtasticd@${{ needs.docker-alpine-armv7.outputs.digest }}

38
.github/workflows/hook_copr.yml vendored Normal file
View File

@@ -0,0 +1,38 @@
name: Trigger COPR build
on:
workflow_call:
secrets:
COPR_API_CONFIG:
inputs:
copr_project:
description: COPR project to target
required: true
type: string
permissions:
contents: write
packages: write
jobs:
build-copr-hook:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
ref: ${{ github.ref }}
repository: ${{ github.repository }}
- name: Trigger COPR build
uses: vidplace7/copr-build@main
id: copr_build
env:
COPR_API_TOKEN_CONFIG: ${{ secrets.COPR_API_CONFIG }}
with:
owner: "@meshtastic"
package-name: meshtasticd
project-name: ${{ inputs.copr_project }}
git-remote: "${{ github.server_url }}/${{ github.repository }}.git"
committish: ${{ github.sha }}

View File

@@ -1,18 +1,24 @@
name: CI
#concurrency:
# group: ${{ github.ref }}
# cancel-in-progress: ${{ github.ref != 'refs/heads/master' }}
concurrency:
group: ci-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
on:
# # Triggers the workflow on push but only for the master branch
# # Triggers the workflow on push but only for the main branches
push:
branches: [master, develop]
branches:
- master
- develop
- event/*
paths-ignore:
- "**.md"
- "version.properties"
- version.properties
# Note: This is different from "pull_request". Need to specify ref when doing checkouts.
pull_request_target:
branches: [master, develop]
branches:
- master
- develop
- event/*
paths-ignore:
- "**.md"
#- "**.yml"
@@ -20,266 +26,307 @@ on:
workflow_dispatch:
jobs:
check:
setup:
strategy:
fail-fast: false
matrix:
include:
- board: rak11200
- board: tlora-v2-1-1_6
- board: tbeam
- board: heltec-v2_1
- board: meshtastic-diy-v1
- board: rak4631
- board: t-echo
- board: station-g2
- board: m5stack-coreink
- board: tbeam-s3-core
- board: tlora-t3s3-v1
- board: t-watch-s3
- board: t-deck
#- board: rak11310
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
- check
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v5
- uses: actions/setup-python@v6
with:
python-version: 3.x
cache: pip
- run: pip install -U platformio
- name: Generate matrix
id: jsonStep
run: |
if [[ "$GITHUB_HEAD_REF" == "" ]]; then
TARGETS=$(./bin/generate_ci_matrix.py ${{matrix.arch}})
else
TARGETS=$(./bin/generate_ci_matrix.py ${{matrix.arch}} pr)
fi
echo "Name: $GITHUB_REF_NAME Base: $GITHUB_BASE_REF Ref: $GITHUB_REF Targets: $TARGETS"
echo "${{matrix.arch}}=$(jq -cn --argjson environments "$TARGETS" '{board: $environments}')" >> $GITHUB_OUTPUT
outputs:
esp32: ${{ steps.jsonStep.outputs.esp32 }}
esp32s3: ${{ steps.jsonStep.outputs.esp32s3 }}
esp32c3: ${{ steps.jsonStep.outputs.esp32c3 }}
esp32c6: ${{ steps.jsonStep.outputs.esp32c6 }}
nrf52840: ${{ steps.jsonStep.outputs.nrf52840 }}
rp2040: ${{ steps.jsonStep.outputs.rp2040 }}
rp2350: ${{ steps.jsonStep.outputs.rp2350 }}
stm32: ${{ steps.jsonStep.outputs.stm32 }}
check: ${{ steps.jsonStep.outputs.check }}
version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/checkout@v5
- name: Get release version string
run: |
echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
echo "deb=$(./bin/buildinfo.py deb)" >> $GITHUB_OUTPUT
id: version
env:
BUILD_LOCATION: local
outputs:
long: ${{ steps.version.outputs.long }}
deb: ${{ steps.version.outputs.deb }}
check:
needs: setup
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.setup.outputs.check) }}
runs-on: ubuntu-latest
if: ${{ github.event_name != 'workflow_dispatch' }}
steps:
- uses: actions/checkout@v5
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Trunk Check
if: ${{ github.event_name != 'workflow_dispatch' }}
uses: trunk-io/trunk-action@782e83f803ca6e369f035d64c6ba2768174ba61b
- name: Check ${{ matrix.board }}
run: bin/check-all.sh ${{ matrix.board }}
build-esp32:
needs: [setup, version]
strategy:
fail-fast: false
matrix:
include:
- board: rak11200
- board: tlora-v2
- board: tlora-v1
- board: tlora_v1_3
- board: tlora-v2-1-1_6
- board: tlora-v2-1-1_6-tcxo
- board: tlora-v2-1-1_8
- board: tbeam
- board: heltec-v2_0
- board: heltec-v2_1
- board: tbeam0_7
- board: meshtastic-diy-v1
- board: hydra
- board: meshtastic-dr-dev
- board: nano-g1
- board: station-g1
- board: m5stack-core
- board: m5stack-coreink
- board: nano-g1-explorer
- board: chatter2
uses: ./.github/workflows/build_esp32.yml
matrix: ${{ fromJson(needs.setup.outputs.esp32) }}
uses: ./.github/workflows/build_firmware.yml
with:
board: ${{ matrix.board }}
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32
build-esp32-s3:
build-esp32s3:
needs: [setup, version]
strategy:
fail-fast: false
matrix:
include:
- board: heltec-v3
- board: heltec-wsl-v3
- board: heltec-wireless-tracker
- board: heltec-wireless-tracker-V1-0
- board: heltec-wireless-paper-v1_0
- board: heltec-wireless-paper #v1.1
- board: tbeam-s3-core
- board: tlora-t3s3-v1
- board: t-watch-s3
- board: t-deck
- board: picomputer-s3
- board: station-g2
uses: ./.github/workflows/build_esp32_s3.yml
matrix: ${{ fromJson(needs.setup.outputs.esp32s3) }}
uses: ./.github/workflows/build_firmware.yml
with:
board: ${{ matrix.board }}
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32s3
build-esp32-c3:
build-esp32c3:
needs: [setup, version]
strategy:
fail-fast: false
matrix:
include:
- board: heltec-ht62-esp32c3-sx1262
uses: ./.github/workflows/build_esp32_c3.yml
matrix: ${{ fromJson(needs.setup.outputs.esp32c3) }}
uses: ./.github/workflows/build_firmware.yml
with:
board: ${{ matrix.board }}
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32c3
build-nrf52:
build-esp32c6:
needs: [setup, version]
strategy:
fail-fast: false
matrix:
include:
- board: rak4631
- board: rak4631_eink
- board: monteops_hw1
- board: t-echo
- board: canaryone
- board: pca10059_diy_eink
- board: feather_diy
- board: nano-g2-ultra
uses: ./.github/workflows/build_nrf52.yml
matrix: ${{ fromJson(needs.setup.outputs.esp32c6) }}
uses: ./.github/workflows/build_firmware.yml
with:
board: ${{ matrix.board }}
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32c6
build-rpi2040:
build-nrf52840:
needs: [setup, version]
strategy:
fail-fast: false
matrix:
include:
- board: pico
- board: picow
- board: rak11310
- board: senselora_rp2040
- board: rp2040-lora
uses: ./.github/workflows/build_rpi2040.yml
matrix: ${{ fromJson(needs.setup.outputs.nrf52840) }}
uses: ./.github/workflows/build_firmware.yml
with:
board: ${{ matrix.board }}
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: nrf52840
build-raspbian:
build-rp2040:
needs: [setup, version]
strategy:
fail-fast: false
max-parallel: 1
uses: ./.github/workflows/build_raspbian.yml
matrix: ${{ fromJson(needs.setup.outputs.rp2040) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: rp2040
package-raspbian:
uses: ./.github/workflows/package_raspbian.yml
build-rp2350:
needs: [setup, version]
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.setup.outputs.rp2350) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: rp2350
build-native:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Build base
id: base
uses: ./.github/actions/setup-base
build-stm32:
needs: [setup, version]
strategy:
fail-fast: false
matrix: ${{ fromJson(needs.setup.outputs.stm32) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: stm32
# We now run integration test before other build steps (to quickly see runtime failures)
#- name: Build for native
# run: platformio run -e native
#- name: Integration test
# run: |
#.pio/build/native/program
#& sleep 20 # 5 seconds was not enough
#echo "Simulator started, launching python test..."
#python3 -c 'from meshtastic.test import testSimulator; testSimulator()'
build-debian-src:
if: github.repository == 'meshtastic/firmware'
uses: ./.github/workflows/build_debian_src.yml
with:
series: UNRELEASED
build_location: local
secrets: inherit
- name: Build Native
run: bin/build-native.sh
package-pio-deps-native-tft:
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: ./.github/workflows/package_pio_deps.yml
with:
pio_env: native-tft
secrets: inherit
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
test-native:
if: ${{ !contains(github.ref_name, 'event/') }}
uses: ./.github/workflows/test_native.yml
- name: Store binaries as an artifact
uses: actions/upload-artifact@v3
with:
name: firmware-native-${{ steps.version.outputs.version }}.zip
path: |
release/device-*.sh
release/device-*.bat
docker-deb-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
- name: Docker login
if: ${{ github.event_name != 'pull_request_target' && github.event_name != 'pull_request' }}
uses: docker/login-action@v2
with:
username: meshtastic
password: ${{ secrets.DOCKER_TOKEN }}
docker-deb-amd64-tft:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
pio_env: native-tft
- name: Docker setup
if: ${{ github.event_name != 'pull_request_target' && github.event_name != 'pull_request' }}
uses: docker/setup-buildx-action@v2
docker-alp-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
- name: Docker build and push tagged versions
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile
push: true
tags: meshtastic/device-simulator:${{ steps.version.outputs.version }}
docker-alp-amd64-tft:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
pio_env: native-tft
- name: Docker build and push
if: ${{ github.ref == 'refs/heads/master' && github.event_name != 'pull_request_target' && github.event_name != 'pull_request' }}
uses: docker/build-push-action@v3
with:
context: .
file: ./Dockerfile
push: true
tags: meshtastic/device-simulator:latest
docker-deb-arm64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm64
runs-on: ubuntu-24.04-arm
push: false
after-checks:
runs-on: ubuntu-latest
needs: [check]
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
docker-deb-armv7:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm/v7
runs-on: ubuntu-24.04-arm
push: false
gather-artifacts:
# trunk-ignore(checkov/CKV2_GHA_1)
permissions:
contents: write
pull-requests: write
strategy:
fail-fast: false
matrix:
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
runs-on: ubuntu-latest
needs:
[
version,
build-esp32,
build-esp32-s3,
build-esp32-c3,
build-nrf52,
build-raspbian,
build-native,
build-rpi2040,
package-raspbian,
build-esp32s3,
build-esp32c3,
build-esp32c6,
build-nrf52840,
build-rp2040,
build-rp2350,
build-stm32,
]
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v5
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v5
with:
path: ./
pattern: firmware-${{matrix.arch}}-*
merge-multiple: true
- name: Display structure of downloaded files
run: ls -R
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Move files up
run: mv -b -t ./ ./*tbeam-2*/littlefs*.bin ./*tbeam-2*/bleota.bin ./*tbeam-s3*/bleota-s3.bin ./*esp32c3*/bleota-c3.bin ./**/firmware*.bin ./*t-echo*/Meshtastic_nRF52_factory_erase_v2.uf2 ./**/firmware-*.uf2 ./**/firmware-*-ota.zip ./**/*.elf ./*native*/*device-*.sh ./*native*/*device-*.bat ./firmware-raspbian-*/release/meshtasticd_linux_aarch64 ./firmware-raspbian-*/bin/config-dist.yaml
run: mv -b -t ./ ./bin/device-*.sh ./bin/device-*.bat
- name: Repackage in single firmware zip
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: firmware-${{ steps.version.outputs.version }}
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
overwrite: true
path: |
./*.bin
./*.uf2
./firmware-*.bin
./firmware-*.uf2
./firmware-*.hex
./firmware-*-ota.zip
./device-*.sh
./device-*.bat
./meshtasticd_linux_arm64
./config-dist.yaml
retention-days: 90
./littlefs-*.bin
./bleota*bin
./Meshtastic_nRF52_factory_erase*.uf2
retention-days: 30
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v5
with:
name: firmware-${{ steps.version.outputs.version }}
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output
# For diagnostics
@@ -292,55 +339,119 @@ jobs:
chmod +x ./output/device-update.sh
- name: Zip firmware
run: zip -j -9 -r ./firmware-${{ steps.version.outputs.version }}.zip ./output
run: zip -j -9 -r ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./output
- name: Repackage in single elfs zip
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: debug-elfs-${{ steps.version.outputs.version }}.zip
name: debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
overwrite: true
path: ./*.elf
retention-days: 30
- name: Create request artifacts
continue-on-error: true # FIXME: Why are we getting 502, but things still work?
if: ${{ github.event_name == 'pull_request_target' || github.event_name == 'pull_request' }}
uses: gavv/pull-request-artifacts@v2.1.0
- uses: scruplelesswizard/comment-artifact@main
if: ${{ github.event_name == 'pull_request' }}
with:
commit: ${{ (github.event.pull_request_target || github.event.pull_request).head.sha }}
repo-token: ${{ secrets.GITHUB_TOKEN }}
artifacts-token: ${{ secrets.ARTIFACTS_TOKEN }}
artifacts-repo: meshtastic/artifacts
artifacts-branch: device
artifacts: ./firmware-${{ steps.version.outputs.version }}.zip
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
description: "Download firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip. This artifact will be available for 90 days from creation"
github-token: ${{ secrets.GITHUB_TOKEN }}
release-artifacts:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'workflow_dispatch' }}
needs: [gather-artifacts, after-checks]
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
needs:
- version
- gather-artifacts
- build-debian-src
- package-pio-deps-native-tft
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v5
- name: Setup Python
uses: actions/setup-python@v4
uses: actions/setup-python@v6
with:
python-version: 3.x
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- uses: actions/download-artifact@v3
- name: Create release
uses: softprops/action-gh-release@v2
id: create_release
with:
name: firmware-${{ steps.version.outputs.version }}
draft: true
prerelease: true
name: Meshtastic Firmware ${{ needs.version.outputs.long }} Alpha
tag_name: v${{ needs.version.outputs.long }}
body: |
Autogenerated by github action, developer should edit as required before publishing...
- name: Download source deb
uses: actions/download-artifact@v5
with:
pattern: firmware-debian-${{ needs.version.outputs.deb }}~UNRELEASED-src
merge-multiple: true
path: ./output/debian-src
- name: Download `native-tft` pio deps
uses: actions/download-artifact@v5
with:
pattern: platformio-deps-native-tft-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output/pio-deps-native-tft
- name: Zip Linux sources
working-directory: output
run: |
zip -j -9 -r ./meshtasticd-${{ needs.version.outputs.deb }}-src.zip ./debian-src
zip -9 -r ./platformio-deps-native-tft-${{ needs.version.outputs.long }}.zip ./pio-deps-native-tft
# For diagnostics
- name: Display structure of downloaded files
run: ls -lR
- name: Add Linux sources to GtiHub Release
# Only run when targeting master branch with workflow_dispatch
if: ${{ github.ref_name == 'master' }}
run: |
gh release upload v${{ needs.version.outputs.long }} ./output/meshtasticd-${{ needs.version.outputs.deb }}-src.zip
gh release upload v${{ needs.version.outputs.long }} ./output/platformio-deps-native-tft-${{ needs.version.outputs.long }}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
release-firmware:
strategy:
fail-fast: false
matrix:
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
runs-on: ubuntu-latest
if: ${{ github.event_name == 'workflow_dispatch' }}
needs: [release-artifacts, version]
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: 3.x
- uses: actions/download-artifact@v5
with:
pattern: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output
- uses: actions/download-artifact@v3
with:
name: artifact-deb
- name: Display structure of downloaded files
run: ls -R
run: ls -lR
- name: Device scripts permissions
run: |
@@ -348,69 +459,65 @@ jobs:
chmod +x ./output/device-update.sh
- name: Zip firmware
run: zip -j -9 -r ./firmware-${{ steps.version.outputs.version }}.zip ./output
run: zip -j -9 -r ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./output
- uses: actions/download-artifact@v3
- uses: actions/download-artifact@v5
with:
name: debug-elfs-${{ steps.version.outputs.version }}.zip
name: debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
merge-multiple: true
path: ./elfs
- name: Zip Elfs
run: zip -j -9 -r ./debug-elfs-${{ steps.version.outputs.version }}.zip ./elfs
- name: Zip debug elfs
run: zip -j -9 -r ./debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./elfs
# For diagnostics
- name: Show artifacts
- name: Display structure of downloaded files
run: ls -lR
- name: Create release
uses: actions/create-release@v1
id: create_release
with:
draft: true
prerelease: true
release_name: Meshtastic Firmware ${{ steps.version.outputs.version }} Alpha
tag_name: v${{ steps.version.outputs.version }}
body: |
Autogenerated by github action, developer should edit as required before publishing...
- name: Add bins and debug elfs to GitHub Release
# Only run when targeting master branch with workflow_dispatch
if: ${{ github.ref_name == 'master' }}
run: |
gh release upload v${{ needs.version.outputs.long }} ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
gh release upload v${{ needs.version.outputs.long }} ./debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
env:
GITHUB_TOKEN: ${{ github.token }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Add bins to release
uses: actions/upload-release-asset@v1
publish-firmware:
runs-on: ubuntu-24.04
if: ${{ github.event_name == 'workflow_dispatch' }}
needs: [release-firmware, version]
env:
targets: |-
esp32,esp32s3,esp32c3,esp32c6,nrf52840,rp2040,rp2350,stm32
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: 3.x
- uses: actions/download-artifact@v5
with:
pattern: firmware-{${{ env.targets }}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./publish
- name: Publish firmware to meshtastic.github.io
uses: peaceiris/actions-gh-pages@v4
env:
GITHUB_TOKEN: ${{ github.token }}
# On event/* branches, use the event name as the destination prefix
DEST_PREFIX: ${{ contains(github.ref_name, 'event/') && format('{0}/', github.ref_name) || '' }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./firmware-${{ steps.version.outputs.version }}.zip
asset_name: firmware-${{ steps.version.outputs.version }}.zip
asset_content_type: application/zip
- name: Add debug elfs to release
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./debug-elfs-${{ steps.version.outputs.version }}.zip
asset_name: debug-elfs-${{ steps.version.outputs.version }}.zip
asset_content_type: application/zip
- name: Add raspbian .deb
uses: actions/upload-release-asset@v1
env:
GITHUB_TOKEN: ${{ github.token }}
with:
upload_url: ${{ steps.create_release.outputs.upload_url }}
asset_path: ./meshtasticd_${{ steps.version.outputs.version }}_arm64.deb
asset_name: meshtasticd_${{ steps.version.outputs.version }}_arm64.deb
asset_content_type: application/vnd.debian.binary-package
- name: Bump version.properties
run: >-
bin/bump_version.py
- name: Create version.properties pull request
uses: peter-evans/create-pull-request@v3
with:
add-paths: |
version.properties
deploy_key: ${{ secrets.DIST_PAGES_DEPLOY_KEY }}
external_repository: meshtastic/meshtastic.github.io
publish_branch: master
publish_dir: ./publish
destination_dir: ${{ env.DEST_PREFIX }}firmware-${{ needs.version.outputs.long }}
keep_files: true
user_name: github-actions[bot]
user_email: github-actions[bot]@users.noreply.github.com
commit_message: ${{ needs.version.outputs.long }}
enable_jekyll: true

508
.github/workflows/merge_queue.yml vendored Normal file
View File

@@ -0,0 +1,508 @@
name: Merge Queue
# Not sure how concurrency works in merge_queue, removing for now.
# concurrency:
# group: merge-queue-${{ github.head_ref || github.run_id }}
# cancel-in-progress: true
on:
# Merge group is a special trigger that is used to trigger the workflow when a merge group is created.
merge_group:
env:
FAIL_FAST_PER_ARCH: true
jobs:
setup:
strategy:
fail-fast: true
matrix:
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
- check
runs-on: ubuntu-24.04
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
cache: pip
- run: pip install -U platformio
- name: Generate matrix
id: jsonStep
run: |
if [[ "$GITHUB_HEAD_REF" == "" ]]; then
TARGETS=$(./bin/generate_ci_matrix.py ${{matrix.arch}})
else
TARGETS=$(./bin/generate_ci_matrix.py ${{matrix.arch}} pr)
fi
echo "Name: $GITHUB_REF_NAME Base: $GITHUB_BASE_REF Ref: $GITHUB_REF Targets: $TARGETS"
echo "${{matrix.arch}}=$(jq -cn --argjson environments "$TARGETS" '{board: $environments}')" >> $GITHUB_OUTPUT
outputs:
esp32: ${{ steps.jsonStep.outputs.esp32 }}
esp32s3: ${{ steps.jsonStep.outputs.esp32s3 }}
esp32c3: ${{ steps.jsonStep.outputs.esp32c3 }}
esp32c6: ${{ steps.jsonStep.outputs.esp32c6 }}
nrf52840: ${{ steps.jsonStep.outputs.nrf52840 }}
rp2040: ${{ steps.jsonStep.outputs.rp2040 }}
rp2350: ${{ steps.jsonStep.outputs.rp2350 }}
stm32: ${{ steps.jsonStep.outputs.stm32 }}
check: ${{ steps.jsonStep.outputs.check }}
version:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Get release version string
run: |
echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
echo "deb=$(./bin/buildinfo.py deb)" >> $GITHUB_OUTPUT
id: version
env:
BUILD_LOCATION: local
outputs:
long: ${{ steps.version.outputs.long }}
deb: ${{ steps.version.outputs.deb }}
check:
needs: setup
strategy:
fail-fast: true
matrix: ${{ fromJson(needs.setup.outputs.check) }}
runs-on: ubuntu-latest
if: ${{ github.event_name != 'workflow_dispatch' }}
steps:
- uses: actions/checkout@v4
- name: Build base
id: base
uses: ./.github/actions/setup-base
- name: Check ${{ matrix.board }}
run: bin/check-all.sh ${{ matrix.board }}
build-esp32:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.esp32) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32
build-esp32s3:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.esp32s3) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32s3
build-esp32c3:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.esp32c3) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32c3
build-esp32c6:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.esp32c6) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: esp32c6
build-nrf52840:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.nrf52840) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: nrf52840
build-rp2040:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.rp2040) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: rp2040
build-rp2350:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.rp2350) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: rp2350
build-stm32:
needs: [setup, version]
strategy:
fail-fast: ${{ vars.FAIL_FAST_PER_ARCH == true }}
matrix: ${{ fromJson(needs.setup.outputs.stm32) }}
uses: ./.github/workflows/build_firmware.yml
with:
version: ${{ needs.version.outputs.long }}
pio_env: ${{ matrix.board }}
platform: stm32
build-debian-src:
if: github.repository == 'meshtastic/firmware'
uses: ./.github/workflows/build_debian_src.yml
with:
series: UNRELEASED
build_location: local
secrets: inherit
package-pio-deps-native-tft:
if: ${{ github.event_name == 'workflow_dispatch' }}
uses: ./.github/workflows/package_pio_deps.yml
with:
pio_env: native-tft
secrets: inherit
test-native:
if: ${{ !contains(github.ref_name, 'event/') }}
uses: ./.github/workflows/test_native.yml
docker-deb-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
docker-deb-amd64-tft:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
pio_env: native-tft
docker-alp-amd64:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
docker-alp-amd64-tft:
uses: ./.github/workflows/docker_build.yml
with:
distro: alpine
platform: linux/amd64
runs-on: ubuntu-24.04
push: false
pio_env: native-tft
docker-deb-arm64:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm64
runs-on: ubuntu-24.04-arm
push: false
docker-deb-armv7:
uses: ./.github/workflows/docker_build.yml
with:
distro: debian
platform: linux/arm/v7
runs-on: ubuntu-24.04-arm
push: false
gather-artifacts:
# trunk-ignore(checkov/CKV2_GHA_1)
permissions:
contents: write
pull-requests: write
strategy:
fail-fast: false
matrix:
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
runs-on: ubuntu-latest
needs:
[
version,
build-esp32,
build-esp32s3,
build-esp32c3,
build-esp32c6,
build-nrf52840,
build-rp2040,
build-rp2350,
build-stm32,
]
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- uses: actions/download-artifact@v4
with:
path: ./
pattern: firmware-${{matrix.arch}}-*
merge-multiple: true
- name: Display structure of downloaded files
run: ls -R
- name: Move files up
run: mv -b -t ./ ./bin/device-*.sh ./bin/device-*.bat
- name: Repackage in single firmware zip
uses: actions/upload-artifact@v4
with:
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
overwrite: true
path: |
./firmware-*.bin
./firmware-*.uf2
./firmware-*.hex
./firmware-*-ota.zip
./device-*.sh
./device-*.bat
./littlefs-*.bin
./bleota*bin
./Meshtastic_nRF52_factory_erase*.uf2
retention-days: 30
- uses: actions/download-artifact@v4
with:
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output
# For diagnostics
- name: Show artifacts
run: ls -lR
- name: Device scripts permissions
run: |
chmod +x ./output/device-install.sh
chmod +x ./output/device-update.sh
- name: Zip firmware
run: zip -j -9 -r ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./output
- name: Repackage in single elfs zip
uses: actions/upload-artifact@v4
with:
name: debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
overwrite: true
path: ./*.elf
retention-days: 30
- uses: scruplelesswizard/comment-artifact@main
if: ${{ github.event_name == 'pull_request' }}
with:
name: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
description: "Download firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip. This artifact will be available for 90 days from creation"
github-token: ${{ secrets.GITHUB_TOKEN }}
release-artifacts:
runs-on: ubuntu-latest
if: ${{ github.event_name == 'workflow_dispatch' }}
outputs:
upload_url: ${{ steps.create_release.outputs.upload_url }}
needs:
- version
- gather-artifacts
- build-debian-src
- package-pio-deps-native-tft
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Create release
uses: softprops/action-gh-release@v2
id: create_release
with:
draft: true
prerelease: true
name: Meshtastic Firmware ${{ needs.version.outputs.long }} Alpha
tag_name: v${{ needs.version.outputs.long }}
body: |
Autogenerated by github action, developer should edit as required before publishing...
- name: Download source deb
uses: actions/download-artifact@v4
with:
pattern: firmware-debian-${{ needs.version.outputs.deb }}~UNRELEASED-src
merge-multiple: true
path: ./output/debian-src
- name: Download `native-tft` pio deps
uses: actions/download-artifact@v4
with:
pattern: platformio-deps-native-tft-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output/pio-deps-native-tft
- name: Zip Linux sources
working-directory: output
run: |
zip -j -9 -r ./meshtasticd-${{ needs.version.outputs.deb }}-src.zip ./debian-src
zip -9 -r ./platformio-deps-native-tft-${{ needs.version.outputs.long }}.zip ./pio-deps-native-tft
# For diagnostics
- name: Display structure of downloaded files
run: ls -lR
- name: Add Linux sources to GtiHub Release
# Only run when targeting master branch with workflow_dispatch
if: ${{ github.ref_name == 'master' }}
run: |
gh release upload v${{ needs.version.outputs.long }} ./output/meshtasticd-${{ needs.version.outputs.deb }}-src.zip
gh release upload v${{ needs.version.outputs.long }} ./output/platformio-deps-native-tft-${{ needs.version.outputs.long }}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
release-firmware:
strategy:
fail-fast: false
matrix:
arch:
- esp32
- esp32s3
- esp32c3
- esp32c6
- nrf52840
- rp2040
- rp2350
- stm32
runs-on: ubuntu-latest
if: ${{ github.event_name == 'workflow_dispatch' }}
needs: [release-artifacts, version]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.x
- uses: actions/download-artifact@v4
with:
pattern: firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./output
- name: Display structure of downloaded files
run: ls -lR
- name: Device scripts permissions
run: |
chmod +x ./output/device-install.sh
chmod +x ./output/device-update.sh
- name: Zip firmware
run: zip -j -9 -r ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./output
- uses: actions/download-artifact@v4
with:
name: debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
merge-multiple: true
path: ./elfs
- name: Zip debug elfs
run: zip -j -9 -r ./debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip ./elfs
# For diagnostics
- name: Display structure of downloaded files
run: ls -lR
- name: Add bins and debug elfs to GitHub Release
# Only run when targeting master branch with workflow_dispatch
if: ${{ github.ref_name == 'master' }}
run: |
gh release upload v${{ needs.version.outputs.long }} ./firmware-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
gh release upload v${{ needs.version.outputs.long }} ./debug-elfs-${{matrix.arch}}-${{ needs.version.outputs.long }}.zip
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
publish-firmware:
runs-on: ubuntu-24.04
if: ${{ github.event_name == 'workflow_dispatch' }}
needs: [release-firmware, version]
env:
targets: |-
esp32,esp32s3,esp32c3,esp32c6,nrf52840,rp2040,rp2350,stm32
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: 3.x
- uses: actions/download-artifact@v4
with:
pattern: firmware-{${{ env.targets }}}-${{ needs.version.outputs.long }}
merge-multiple: true
path: ./publish
- name: Publish firmware to meshtastic.github.io
uses: peaceiris/actions-gh-pages@v4
env:
# On event/* branches, use the event name as the destination prefix
DEST_PREFIX: ${{ contains(github.ref_name, 'event/') && format('{0}/', github.ref_name) || '' }}
with:
deploy_key: ${{ secrets.DIST_PAGES_DEPLOY_KEY }}
external_repository: meshtastic/meshtastic.github.io
publish_branch: master
publish_dir: ./publish
destination_dir: ${{ env.DEST_PREFIX }}firmware-${{ needs.version.outputs.long }}
keep_files: true
user_name: github-actions[bot]
user_email: github-actions[bot]@users.noreply.github.com
commit_message: ${{ needs.version.outputs.long }}
enable_jekyll: true

View File

@@ -4,16 +4,36 @@ on:
- cron: 0 8 * * 1-5
workflow_dispatch: {}
permissions: read-all
jobs:
trunk_check:
name: Trunk Check Upload
runs-on: ubuntu-latest
if: github.repository == 'meshtastic/firmware'
name: Trunk Check and Upload
runs-on: ubuntu-24.04
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v5
- name: Trunk Check
uses: trunk-io/trunk-action@782e83f803ca6e369f035d64c6ba2768174ba61b
uses: trunk-io/trunk-action@v1
with:
trunk-token: ${{ secrets.TRUNK_TOKEN }}
trunk_upgrade:
if: github.repository == 'meshtastic/firmware'
# See: https://github.com/trunk-io/trunk-action/blob/v1/readme.md#automatic-upgrades
name: Trunk Upgrade (PR)
runs-on: ubuntu-24.04
permissions:
contents: write # For trunk to create PRs
pull-requests: write # For trunk to create PRs
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Trunk Upgrade
uses: trunk-io/trunk-action/upgrade@v1
with:
base: master

110
.github/workflows/package_obs.yml vendored Normal file
View File

@@ -0,0 +1,110 @@
name: Package for OpenSUSE Build Service
on:
workflow_call:
secrets:
OBS_PASSWORD:
required: true
PPA_GPG_PRIVATE_KEY:
required: true
inputs:
obs_project:
description: Meshtastic OBS project to target
required: true
type: string
series:
description: Debian series to target
required: true
type: string
permissions:
contents: write
packages: write
jobs:
build-debian-src:
uses: ./.github/workflows/build_debian_src.yml
secrets: inherit
with:
series: ${{ inputs.series }}
build_location: obs
package-obs:
runs-on: ubuntu-24.04
needs: build-debian-src
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
path: meshtasticd
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install OpenSUSE Build Service deps
shell: bash
run: |
echo 'deb http://download.opensuse.org/repositories/openSUSE:/Tools/xUbuntu_24.04/ /' | sudo tee /etc/apt/sources.list.d/openSUSE:Tools.list
curl -fsSL https://download.opensuse.org/repositories/openSUSE:Tools/xUbuntu_24.04/Release.key | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/openSUSE_Tools.gpg > /dev/null
sudo apt-get update -y --fix-missing
sudo apt-get install -y osc
- name: Get release version string
working-directory: meshtasticd
run: |
echo "deb=$(./bin/buildinfo.py deb)" >> $GITHUB_OUTPUT
env:
BUILD_LOCATION: obs
id: version
- name: Download artifacts
uses: actions/download-artifact@v5
with:
name: firmware-debian-${{ steps.version.outputs.deb }}~${{ inputs.series }}-src
merge-multiple: true
- name: Display structure of downloaded files
run: ls -lah
- name: Configure osc
env:
OBS_USERNAME: meshtastic
run: |
# Setup OpenSUSE Build Service credentials
mkdir -p ~/.config/osc
echo "[general]" > ~/.config/osc/oscrc
echo "apiurl=https://api.opensuse.org" >> ~/.config/osc/oscrc
echo "[https://api.opensuse.org]" >> ~/.config/osc/oscrc
echo "user=${{ env.OBS_USERNAME }}" >> ~/.config/osc/oscrc
echo "pass=${{ secrets.OBS_PASSWORD }}" >> ~/.config/osc/oscrc
echo "credentials_mgr_class=osc.credentials.PlaintextConfigFileCredentialsManager" >> ~/.config/osc/oscrc
# Create a temporary directory for osc checkout
mkdir -p osc
# Intentionally fail if credentials are invalid
# Update secrets if this returns `401`
- name: Verify OBS authentication
run: osc token
- name: Upload package to OBS
shell: bash
working-directory: osc
env:
OBS_PROJECT: ${{ inputs.obs_project }}
OBS_PACKAGE: meshtasticd
run: |
# Initialize the package in the current directory
osc checkout --output-dir . $OBS_PROJECT $OBS_PACKAGE
# Remove the existing package files
rm -rf *.dsc *.tar.xz
# Copy new package files to the directory
cp $GITHUB_WORKSPACE/*.dsc .
cp $GITHUB_WORKSPACE/*.tar.xz .
# Add/Remove the files
osc addremove
# Commit changes and push to OpenSUSE Build Service
osc commit -m "GitHub Actions: ${{ steps.version.outputs.deb }}~${{ inputs.series }}"

65
.github/workflows/package_pio_deps.yml vendored Normal file
View File

@@ -0,0 +1,65 @@
name: Package PlatformIO Library Dependencies
# trunk-ignore-all(checkov/CKV_GHA_7): Allow workflow_dispatch inputs for testing
on:
workflow_call:
inputs:
pio_env:
description: PlatformIO environment to target
required: true
type: string
workflow_dispatch:
inputs:
pio_env:
description: PlatformIO environment to target
required: true
type: string
permissions:
contents: write
packages: write
jobs:
pkg-pio-libdeps:
runs-on: ubuntu-24.04
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: 3.x
- name: Install deps
shell: bash
run: |
pip install platformio
- name: Get release version string
run: |
echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Fetch libdeps
shell: bash
run: |-
platformio pkg install -e ${{ inputs.pio_env }}
platformio pkg install -e ${{ inputs.pio_env }} -t platformio/tool-scons@4.40502.0
env:
PLATFORMIO_LIBDEPS_DIR: pio/libdeps
PLATFORMIO_PACKAGES_DIR: pio/packages
PLATFORMIO_CORE_DIR: pio/core
- name: Store binaries as an artifact
uses: actions/upload-artifact@v4
with:
name: platformio-deps-${{ inputs.pio_env }}-${{ steps.version.outputs.long }}
overwrite: true
include-hidden-files: true
path: |
pio/*

74
.github/workflows/package_ppa.yml vendored Normal file
View File

@@ -0,0 +1,74 @@
name: Package for Launchpad PPA
on:
workflow_call:
secrets:
PPA_GPG_PRIVATE_KEY:
required: true
inputs:
ppa_repo:
description: Meshtastic PPA to target
required: true
type: string
series:
description: Ubuntu series to target
required: true
type: string
permissions:
contents: write
packages: write
jobs:
build-debian-src:
uses: ./.github/workflows/build_debian_src.yml
secrets: inherit
with:
series: ${{ inputs.series }}
build_location: ppa
package-ppa:
runs-on: ubuntu-24.04
needs: build-debian-src
steps:
- name: Checkout code
uses: actions/checkout@v5
with:
submodules: recursive
path: meshtasticd
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install deps
shell: bash
run: |
sudo apt-get update -y --fix-missing
sudo apt-get install -y dput
- name: Import GPG key
uses: crazy-max/ghaction-import-gpg@v6
with:
gpg_private_key: ${{ secrets.PPA_GPG_PRIVATE_KEY }}
id: gpg
- name: Get release version string
working-directory: meshtasticd
run: |
echo "deb=$(./bin/buildinfo.py deb)" >> $GITHUB_OUTPUT
env:
BUILD_LOCATION: ppa
id: version
- name: Download artifacts
uses: actions/download-artifact@v5
with:
name: firmware-debian-${{ steps.version.outputs.deb }}~${{ inputs.series }}-src
merge-multiple: true
- name: Display structure of downloaded files
run: ls -lah
- name: Publish with dput
if: ${{ github.event_name != 'pull_request_target' && github.event_name != 'pull_request' }}
run: |
dput ${{ inputs.ppa_repo }} meshtasticd_${{ steps.version.outputs.deb }}~${{ inputs.series }}_source.changes

View File

@@ -1,73 +0,0 @@
name: Package Raspbian
on:
workflow_call:
workflow_dispatch:
permissions:
contents: write
packages: write
jobs:
build-raspbian:
uses: ./.github/workflows/build_raspbian.yml
package-raspbian:
runs-on: ubuntu-latest
needs: build-raspbian
steps:
- name: Checkout code
uses: actions/checkout@v3
with:
submodules: recursive
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Pull web ui
uses: dsaltares/fetch-gh-release-asset@a40c8b4a0471f9ab81bdf73a010f74cc51476ad4
with:
repo: meshtastic/web
file: build.tar
target: build.tar
token: ${{ secrets.GITHUB_TOKEN }}
- name: Get release version string
run: echo "version=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Download artifacts
uses: actions/download-artifact@v3
with:
name: firmware-raspbian-${{ steps.version.outputs.version }}.zip
- name: Display structure of downloaded files
run: ls -R
- name: build .debpkg
run: |
mkdir -p .debpkg/usr/share/doc/meshtasticd/web
mkdir -p .debpkg/usr/sbin
mkdir -p .debpkg/etc/meshtasticd
mkdir -p .debpkg/usr/lib/systemd/system/
tar -xf build.tar -C .debpkg/usr/share/doc/meshtasticd/web
gunzip .debpkg/usr/share/doc/meshtasticd/web/*.gz
cp release/meshtasticd_linux_aarch64 .debpkg/usr/sbin/meshtasticd
cp bin/config-dist.yaml .debpkg/etc/meshtasticd/config.yaml
chmod +x .debpkg/usr/sbin/meshtasticd
cp bin/meshtasticd.service .debpkg/usr/lib/systemd/system/meshtasticd.service
- uses: jiro4989/build-deb-action@v3
with:
package: meshtasticd
package_root: .debpkg
maintainer: Jonathan Bennett
version: ${{ steps.version.outputs.version }} # refs/tags/v*.*.*
arch: arm64
depends: libyaml-cpp0.7, openssl
desc: Native Linux Meshtastic binary.
- uses: actions/upload-artifact@v3
with:
name: artifact-deb
path: |
./*.deb

24
.github/workflows/pr_enforce_labels.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
name: Check PR Labels
on:
pull_request:
types: [opened, edited, labeled, unlabeled, synchronize, reopened]
permissions:
pull-requests: read
contents: read
jobs:
check-label:
runs-on: ubuntu-24.04
steps:
- name: Check for PR labels
uses: actions/github-script@v8
with:
script: |
const labels = context.payload.pull_request.labels.map(label => label.name);
const requiredLabels = ['bugfix', 'enhancement', 'hardware-support', 'dependencies', 'submodules', 'github_actions', 'trunk'];
const hasRequiredLabel = labels.some(label => requiredLabels.includes(label));
if (!hasRequiredLabel) {
core.setFailed(`PR must have at least one of the following labels before it can be merged: ${requiredLabels.join(', ')}.`);
}

238
.github/workflows/pr_tests.yml vendored Normal file
View File

@@ -0,0 +1,238 @@
name: Tests
# DISABLED: Changed from automatic PR triggers to manual only
on:
workflow_dispatch:
inputs:
reason:
description: "Reason for manual test run"
required: false
default: "Manual test execution"
concurrency:
group: tests-${{ github.head_ref || github.run_id }}
cancel-in-progress: true
permissions:
contents: read
actions: read
checks: write
pull-requests: write
jobs:
native-tests:
name: "🧪 Native Tests"
if: github.repository == 'meshtastic/firmware'
uses: ./.github/workflows/test_native.yml
permissions:
contents: read
actions: read
checks: write
test-summary:
name: "📊 Test Results"
runs-on: ubuntu-latest
needs: [native-tests]
if: always()
permissions:
contents: read
actions: read
checks: write
pull-requests: write
steps:
- uses: actions/checkout@v5
with:
submodules: recursive
- name: Get release version string
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Download test artifacts
if: needs.native-tests.result != 'skipped'
uses: actions/download-artifact@v5
with:
name: platformio-test-report-${{ steps.version.outputs.long }}.zip
merge-multiple: true
- name: Parse test results and create detailed summary
id: test-results
run: |
echo "## 🧪 Test Results Summary" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
# Check overall job status first
if [[ "${{ needs.native-tests.result }}" == "success" ]]; then
echo "✅ **Overall Status**: PASSED" >> $GITHUB_STEP_SUMMARY
elif [[ "${{ needs.native-tests.result }}" == "failure" ]]; then
echo "❌ **Overall Status**: FAILED" >> $GITHUB_STEP_SUMMARY
elif [[ "${{ needs.native-tests.result }}" == "cancelled" ]]; then
echo "⏸️ **Overall Status**: CANCELLED" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
echo "Tests were cancelled before completion." >> $GITHUB_STEP_SUMMARY
exit 0
else
echo "⚠️ **Overall Status**: SKIPPED" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
echo "Tests were skipped." >> $GITHUB_STEP_SUMMARY
exit 0
fi
echo "" >> $GITHUB_STEP_SUMMARY
# Parse detailed test results if available
if [ -f "testreport.xml" ]; then
echo "### 🔍 Individual Test Results" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
python3 << 'EOF'
import xml.etree.ElementTree as ET
import os
try:
tree = ET.parse('testreport.xml')
root = tree.getroot()
total_tests = 0
passed_tests = 0
failed_tests = 0
skipped_tests = 0
# Parse testsuite elements
for testsuite in root.findall('.//testsuite'):
suite_name = testsuite.get('name', 'Unknown')
suite_tests = int(testsuite.get('tests', '0'))
suite_failures = int(testsuite.get('failures', '0'))
suite_errors = int(testsuite.get('errors', '0'))
suite_skipped = int(testsuite.get('skipped', '0'))
total_tests += suite_tests
failed_tests += suite_failures + suite_errors
skipped_tests += suite_skipped
passed_tests += suite_tests - suite_failures - suite_errors - suite_skipped
if suite_tests > 0:
status = "✅" if (suite_failures + suite_errors) == 0 else "❌"
print(f"**{status} Test Suite: {suite_name}**")
print(f"- Total: {suite_tests}")
print(f"- Passed: ✅ {suite_tests - suite_failures - suite_errors - suite_skipped}")
print(f"- Failed: ❌ {suite_failures + suite_errors}")
if suite_skipped > 0:
print(f"- Skipped: ⏭️ {suite_skipped}")
print("")
# Show individual test results for failed suites
if suite_failures + suite_errors > 0:
print("**Failed Tests:**")
for testcase in testsuite.findall('testcase'):
test_name = testcase.get('name', 'Unknown')
failure = testcase.find('failure')
error = testcase.find('error')
if failure is not None:
msg = failure.get('message', 'Unknown error')[:100]
print(f"- ❌ `{test_name}`: {msg}")
elif error is not None:
msg = error.get('message', 'Unknown error')[:100]
print(f"- ❌ `{test_name}`: ERROR - {msg}")
print("")
else:
# Show passed tests for successful suites
passed_count = 0
for testcase in testsuite.findall('testcase'):
if testcase.find('failure') is None and testcase.find('error') is None:
if passed_count < 5: # Limit to first 5 to avoid spam
test_name = testcase.get('name', 'Unknown')
print(f"- ✅ `{test_name}`: PASSED")
passed_count += 1
if passed_count > 5:
print(f"- ... and {passed_count - 5} more tests passed")
print("")
# Summary statistics
print("### 📊 Test Statistics")
print(f"- **Total Tests**: {total_tests}")
print(f"- **Passed**: ✅ {passed_tests}")
print(f"- **Failed**: ❌ {failed_tests}")
if skipped_tests > 0:
print(f"- **Skipped**: ⏭️ {skipped_tests}")
if failed_tests > 0:
print(f"\n❌ **{failed_tests} tests failed out of {total_tests} total**")
else:
print(f"\n✅ **All {total_tests} tests passed!**")
except Exception as e:
print(f"❌ Error parsing test results: {e}")
EOF
else
echo "⚠️ **No detailed test report available**" >> $GITHUB_STEP_SUMMARY
echo "" >> $GITHUB_STEP_SUMMARY
echo "Test artifacts may not have been generated properly." >> $GITHUB_STEP_SUMMARY
fi
echo "" >> $GITHUB_STEP_SUMMARY
echo "---" >> $GITHUB_STEP_SUMMARY
echo "View detailed logs in the [Actions tab](${{ github.server_url }}/${{ github.repository }}/actions/runs/${{ github.run_id }})" >> $GITHUB_STEP_SUMMARY
- name: Comment test results on PR
if: github.event_name == 'pull_request' && needs.native-tests.result != 'skipped'
uses: actions/github-script@v8
with:
script: |
const fs = require('fs');
// Read the step summary to use as PR comment
let testSummary = "## 🧪 Test Results Summary\n\n";
if ("${{ needs.native-tests.result }}" === "success") {
testSummary += "✅ **All tests passed!**\n\n";
} else if ("${{ needs.native-tests.result }}" === "failure") {
testSummary += "❌ **Some tests failed.**\n\n";
} else {
testSummary += "⚠️ **Tests did not complete normally.**\n\n";
}
testSummary += `View detailed results: [Actions Run](${context.payload.repository.html_url}/actions/runs/${context.runId})\n\n`;
testSummary += "---\n";
testSummary += "*This comment will be automatically updated when new commits are pushed.*";
// Find existing comment
const comments = await github.rest.issues.listComments({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number
});
const botComment = comments.data.find(comment =>
comment.user.type === 'Bot' &&
comment.body.includes('🧪 Test Results Summary')
);
if (botComment) {
// Update existing comment
await github.rest.issues.updateComment({
owner: context.repo.owner,
repo: context.repo.repo,
comment_id: botComment.id,
body: testSummary
});
} else {
// Create new comment
await github.rest.issues.createComment({
owner: context.repo.owner,
repo: context.repo.repo,
issue_number: context.issue.number,
body: testSummary
});
}
- name: Set overall status
run: |
if [[ "${{ needs.native-tests.result }}" == "success" ]]; then
echo "All tests passed! ✅"
exit 0
else
echo "Some tests failed! ❌"
exit 1
fi

112
.github/workflows/release_channels.yml vendored Normal file
View File

@@ -0,0 +1,112 @@
name: Trigger release workflows upon Publish
on:
release:
types: [published, released]
permissions:
contents: write
packages: write
jobs:
build-docker:
uses: ./.github/workflows/docker_manifest.yml
with:
release_channel: |-
${{ contains(github.event.release.name, 'Beta') && 'beta' || contains(github.event.release.name, 'Alpha') && 'alpha' }}
secrets: inherit
package-ppa:
strategy:
fail-fast: false
matrix:
series:
- jammy # 22.04
- noble # 24.04
- plucky # 25.04
# - questing # 25.10
uses: ./.github/workflows/package_ppa.yml
with:
ppa_repo: |-
ppa:meshtastic/${{ contains(github.event.release.name, 'Beta') && 'beta' || contains(github.event.release.name, 'Alpha') && 'alpha' }}
series: ${{ matrix.series }}
secrets: inherit
package-obs:
uses: ./.github/workflows/package_obs.yml
with:
obs_project: |-
network:Meshtastic:${{ contains(github.event.release.name, 'Beta') && 'beta' || contains(github.event.release.name, 'Alpha') && 'alpha' }}
series: |-
${{ contains(github.event.release.name, 'Beta') && 'beta' || contains(github.event.release.name, 'Alpha') && 'alpha' }}
secrets: inherit
hook-copr:
uses: ./.github/workflows/hook_copr.yml
with:
copr_project: |-
${{ contains(github.event.release.name, 'Beta') && 'beta' || contains(github.event.release.name, 'Alpha') && 'alpha' }}
secrets: inherit
# Create a PR to bump version when a release is Published
bump-version:
if: github.event.action == 'published'
runs-on: ubuntu-latest
permissions:
pull-requests: write
contents: write
defaults:
run:
shell: bash
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Setup Python
uses: actions/setup-python@v6
with:
python-version: 3.x
- name: Bump version.properties
run: |
# Bump version.properties
chmod +x ./bin/bump_version.py
./bin/bump_version.py
- name: Get new release version string
run: |
echo "short=$(./bin/buildinfo.py short)" >> $GITHUB_OUTPUT
id: new_version
- name: Ensure debian deps are installed
run: |
sudo apt-get update -y --fix-missing
sudo apt-get install -y devscripts
- name: Update debian changelog
run: |
# Update debian changelog
chmod +x ./debian/ci_changelog.sh
./debian/ci_changelog.sh
- name: Bump org.meshtastic.meshtasticd.metainfo.xml
run: |
# Bump org.meshtastic.meshtasticd.metainfo.xml
pip install -r bin/bump_metainfo/requirements.txt -q
chmod +x ./bin/bump_metainfo/bump_metainfo.py
./bin/bump_metainfo/bump_metainfo.py --file bin/org.meshtastic.meshtasticd.metainfo.xml "${{ steps.new_version.outputs.short }}"
env:
PIP_DISABLE_PIP_VERSION_CHECK: 1
- name: Create Bumps pull request
uses: peter-evans/create-pull-request@v7
with:
base: ${{ github.event.repository.default_branch }}
branch: create-pull-request/bump-version
labels: github_actions
title: Bump release version
commit-message: Automated version bumps
add-paths: |
version.properties
debian/changelog
bin/org.meshtastic.meshtasticd.metainfo.xml

View File

@@ -1,40 +0,0 @@
---
name: Flawfinder Scan
on:
push:
branches: [master, develop]
paths-ignore:
- "**.md"
- "version.properties"
jobs:
flawfinder:
runs-on: ubuntu-latest
name: Flawfinder
steps:
# step 1
- name: clone application source code
uses: actions/checkout@v3
# step 2
- name: flawfinder_scan
uses: david-a-wheeler/flawfinder@2.0.19
with:
arguments: "--sarif ./"
output: "flawfinder_report.sarif"
# step 3
- name: save report as pipeline artifact
uses: actions/upload-artifact@v3
with:
name: flawfinder_report.sarif
path: flawfinder_report.sarif
# step 4
- name: publish code scanning alerts
uses: github/codeql-action/upload-sarif@v2
with:
sarif_file: flawfinder_report.sarif
category: flawfinder

View File

@@ -3,21 +3,25 @@ name: Semgrep Full Scan
on:
workflow_dispatch:
branches:
- master
schedule:
- cron: "0 1 * * 6"
- cron: 0 1 * * 6
permissions:
actions: read
contents: read
security-events: write
jobs:
semgrep-full:
runs-on: ubuntu-latest
if: github.repository == 'meshtastic/firmware'
runs-on: ubuntu-24.04
container:
image: returntocorp/semgrep
image: semgrep/semgrep
steps:
# step 1
- name: clone application source code
uses: actions/checkout@v3
uses: actions/checkout@v5
# step 2
- name: full scan
@@ -29,14 +33,15 @@ jobs:
# step 3
- name: save report as pipeline artifact
uses: actions/upload-artifact@v3
uses: actions/upload-artifact@v4
with:
name: report.sarif
overwrite: true
path: report.sarif
# step 4
- name: publish code scanning alerts
uses: github/codeql-action/upload-sarif@v2
uses: github/codeql-action/upload-sarif@v3
with:
sarif_file: report.sarif
category: semgrep

View File

@@ -2,16 +2,18 @@
name: Semgrep Differential Scan
on: pull_request
permissions: read-all
jobs:
semgrep-diff:
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
container:
image: returntocorp/semgrep
image: semgrep/semgrep
steps:
# step 1
- name: clone application source code
uses: actions/checkout@v3
uses: actions/checkout@v5
with:
fetch-depth: 0

24
.github/workflows/stale_bot.yml vendored Normal file
View File

@@ -0,0 +1,24 @@
name: process stale Issues and PR's
on:
schedule:
- cron: 0 6 * * *
workflow_dispatch: {}
permissions:
issues: write
pull-requests: write
actions: write
jobs:
stale_issues:
if: github.repository == 'meshtastic/firmware'
name: Close Stale Issues
runs-on: ubuntu-latest
steps:
- name: Stale PR+Issues
uses: actions/stale@v10.0.0
with:
days-before-stale: 45
exempt-issue-labels: pinned,3.0
exempt-pr-labels: pinned,3.0

169
.github/workflows/test_native.yml vendored Normal file
View File

@@ -0,0 +1,169 @@
name: Run Tests on Native platform
on:
workflow_call:
workflow_dispatch:
permissions: {}
env:
LCOV_CAPTURE_FLAGS: --quiet --capture --include "${PWD}/src/*" --exclude '*/src/mesh/generated/*' --directory .pio/build/coverage/src --base-directory "${PWD}"
jobs:
simulator-tests:
name: Native Simulator Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
submodules: recursive
- name: Setup native build
id: base
uses: ./.github/actions/setup-native
- name: Install simulator dependencies
run: pip install -U dotmap
# We now run integration test before other build steps (to quickly see runtime failures)
- name: Build for native/coverage
run: platformio run -e coverage
- name: Capture initial coverage information
shell: bash
run: |
sudo apt-get install -y lcov
lcov ${{ env.LCOV_CAPTURE_FLAGS }} --initial --output-file coverage_base.info
sed -i -e "s#${PWD}#.#" coverage_base.info # Make paths relative.
- name: Integration test
run: |
.pio/build/coverage/program &
PID=$!
timeout 20 bash -c "until ls -al /proc/$PID/fd | grep socket; do sleep 1; done"
echo "Simulator started, launching python test..."
python3 -c 'from meshtastic.test import testSimulator; testSimulator()'
wait
- name: Capture coverage information
if: always() # run this step even if previous step failed
run: |
lcov ${{ env.LCOV_CAPTURE_FLAGS }} --test-name integration --output-file coverage_integration.info
sed -i -e "s#${PWD}#.#" coverage_integration.info # Make paths relative.
- name: Get release version string
if: always() # run this step even if previous step failed
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Save coverage information
uses: actions/upload-artifact@v4
if: always() # run this step even if previous step failed
with:
name: lcov-coverage-info-native-simulator-test-${{ steps.version.outputs.long }}.zip
overwrite: true
path: ./coverage_*.info
platformio-tests:
name: Native PlatformIO Tests
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
submodules: recursive
- name: Setup native build
id: base
uses: ./.github/actions/setup-native
- name: Get release version string
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
# Disable (comment-out) BUILD_EPOCH. It causes a full rebuild between tests and resets the
# coverage information each time.
- name: Disable BUILD_EPOCH
run: sed -i 's/-DBUILD_EPOCH=$UNIX_TIME/#-DBUILD_EPOCH=$UNIX_TIME/' platformio.ini
- name: PlatformIO Tests
run: platformio test -e coverage -v --junit-output-path testreport.xml
- name: Save test results
if: always() # run this step even if previous step failed
uses: actions/upload-artifact@v4
with:
name: platformio-test-report-${{ steps.version.outputs.long }}.zip
overwrite: true
path: ./testreport.xml
- name: Capture coverage information
if: always() # run this step even if previous step failed
run: |
sudo apt-get install -y lcov
lcov ${{ env.LCOV_CAPTURE_FLAGS }} --test-name tests --output-file coverage_tests.info
sed -i -e "s#${PWD}#.#" coverage_tests.info # Make paths relative.
- name: Save coverage information
uses: actions/upload-artifact@v4
if: always() # run this step even if previous step failed
with:
name: lcov-coverage-info-native-platformio-tests-${{ steps.version.outputs.long }}.zip
overwrite: true
path: ./coverage_*.info
generate-reports:
name: Generate Test Reports
runs-on: ubuntu-latest
permissions: # Needed for dorny/test-reporter.
contents: read
actions: read
checks: write
needs:
- simulator-tests
- platformio-tests
if: always()
steps:
- uses: actions/checkout@v5
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Get release version string
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Download test artifacts
uses: actions/download-artifact@v5
with:
name: platformio-test-report-${{ steps.version.outputs.long }}.zip
merge-multiple: true
- name: Test Report
uses: dorny/test-reporter@v2.1.1
with:
name: PlatformIO Tests
path: testreport.xml
reporter: java-junit
- name: Download coverage artifacts
uses: actions/download-artifact@v5
with:
pattern: lcov-coverage-info-native-*-${{ steps.version.outputs.long }}.zip
path: code-coverage-report
merge-multiple: true
- name: Generate Code Coverage Report
run: |
sudo apt-get install -y lcov
lcov --quiet --add-tracefile code-coverage-report/coverage_base.info --add-tracefile code-coverage-report/coverage_integration.info --add-tracefile code-coverage-report/coverage_tests.info --output-file code-coverage-report/coverage_src.info
genhtml --quiet --legend --prefix "${PWD}" code-coverage-report/coverage_src.info --output-directory code-coverage-report
- name: Save Code Coverage Report
uses: actions/upload-artifact@v4
with:
name: code-coverage-report-${{ steps.version.outputs.long }}.zip
path: code-coverage-report

66
.github/workflows/tests.yml vendored Normal file
View File

@@ -0,0 +1,66 @@
name: End to end tests
on:
schedule:
- cron: 0 0 * * * # Run every day at midnight
workflow_dispatch: {}
permissions:
contents: read
actions: read
checks: write
jobs:
native-tests:
if: github.repository == 'meshtastic/firmware'
uses: ./.github/workflows/test_native.yml
hardware-tests:
if: github.repository == 'meshtastic/firmware'
runs-on: test-runner
steps:
- name: Checkout code
uses: actions/checkout@v5
# - uses: actions/setup-python@v5
# with:
# python-version: '3.10'
# pipx install "setuptools<72"
- name: Upgrade python tools
shell: bash
run: |
pipx install adafruit-nrfutil
pipx install poetry
pipx install meshtastic --pip-args=--pre
- name: Install PlatformIO from script
shell: bash
run: |
curl -fsSL -o get-platformio.py https://raw.githubusercontent.com/platformio/platformio-core-installer/master/get-platformio.py
python3 get-platformio.py
- name: Upgrade platformio
shell: bash
run: |
export PATH=$PATH:$HOME/.local/bin
pio upgrade
- name: Setup Node
uses: actions/setup-node@v5
with:
node-version: 22
- name: Setup pnpm
uses: pnpm/action-setup@v4
with:
version: latest
- name: Install dependencies, setup devices and run
shell: bash
run: |
git submodule update --init --recursive
cd meshtestic/
pnpm install
pnpm run setup
pnpm run test

26
.github/workflows/trunk_annotate_pr.yml vendored Normal file
View File

@@ -0,0 +1,26 @@
name: Annotate PR with trunk issues
# See: https://github.com/trunk-io/trunk-action/blob/v1/readme.md#getting-inline-annotations-for-fork-prs
on:
workflow_run:
workflows: [Pull Request] # Name from `trunk_check.yml`
types: [completed]
permissions: read-all
jobs:
trunk_check:
name: Trunk Code Quality Annotate
runs-on: ubuntu-24.04
permissions:
checks: write # For trunk to post annotations
contents: read # For repo checkout
steps:
- name: Checkout
uses: actions/checkout@v5
- name: Trunk Check
uses: trunk-io/trunk-action@v1
with:
post-annotations: true

View File

@@ -9,14 +9,16 @@ permissions: read-all
jobs:
trunk_check:
name: Trunk Check Runner
runs-on: ubuntu-latest
runs-on: ubuntu-24.04
permissions:
checks: write # For trunk to post annotations
contents: read # For repo checkout
steps:
- name: Checkout
uses: actions/checkout@v3
uses: actions/checkout@v5
- name: Trunk Check
uses: trunk-io/trunk-action@v1
with:
save-annotations: true

51
.github/workflows/trunk_format_pr.yml vendored Normal file
View File

@@ -0,0 +1,51 @@
name: Run Trunk Fmt on PR Comment
on:
issue_comment:
types: [created]
permissions: read-all
jobs:
trunk-fmt:
if: github.event.issue.pull_request != null && contains(github.event.comment.body, 'trunk fmt')
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout repository
uses: actions/checkout@v5
with:
ref: ${{github.event.pull_request.head.ref}}
repository: ${{github.event.pull_request.head.repo.full_name}}
- name: Install trunk
run: curl https://get.trunk.io -fsSL | bash
- name: Run Trunk Fmt
run: trunk fmt
- name: Get release version string
run: echo "long=$(./bin/buildinfo.py long)" >> $GITHUB_OUTPUT
id: version
- name: Commit and push changes
run: |
git config --global user.name "github-actions[bot]"
git config --global user.email "github-actions[bot]@users.noreply.github.com"
git add .
git commit -m "Add firmware version ${{ steps.version.outputs.long }}"
git push
- name: Comment on PR
uses: actions/github-script@v8
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
script: |
github.issues.createComment({
issue_number: context.issue.number,
owner: context.repo.owner,
repo: context.repo.repo,
body: '`trunk fmt` has been run on this PR.'
})

View File

@@ -1,33 +1,42 @@
name: "Update protobufs and regenerate classes"
name: Update protobufs and regenerate classes
on: workflow_dispatch
permissions: read-all
jobs:
update-protobufs:
runs-on: ubuntu-latest
permissions:
contents: write
pull-requests: write
steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v5
with:
submodules: true
- name: Update submodule
if: ${{ github.ref == 'refs/heads/master' }}
run: |
git submodule update --remote protobufs
- name: Download nanopb
run: |
wget https://jpa.kapsi.fi/nanopb/download/nanopb-0.4.7-linux-x86.tar.gz
tar xvzf nanopb-0.4.7-linux-x86.tar.gz
mv nanopb-0.4.7-linux-x86 nanopb-0.4.7
wget https://jpa.kapsi.fi/nanopb/download/nanopb-0.4.9.1-linux-x86.tar.gz
tar xvzf nanopb-0.4.9.1-linux-x86.tar.gz
mv nanopb-0.4.9.1-linux-x86 nanopb-0.4.9
- name: Re-generate protocol buffers
run: |
./bin/regen-protos.sh
- name: Create pull request
uses: peter-evans/create-pull-request@v3
uses: peter-evans/create-pull-request@v7
with:
branch: create-pull-request/update-protobufs
labels: submodules
title: Update protobufs and classes
commit-message: Update protobufs
add-paths: |
protobufs
src/mesh

23
.gitignore vendored
View File

@@ -1,6 +1,8 @@
.pio
main/configuration.h
main/credentials.h
pio
pio.tar
web
web.tar
# ignore vscode IDE settings files
.vscode/*
@@ -10,6 +12,9 @@ main/credentials.h
*.code-workspace
.idea
.platformio
.local
.cache
.DS_Store
Thumbs.db
@@ -32,4 +37,16 @@ release/
.vscode/extensions.json
/compile_commands.json
src/mesh/raspihttp/certificate.pem
src/mesh/raspihttp/private_key.pem
src/mesh/raspihttp/private_key.pem
# pioarduino platform
managed_components/*
arduino-lib-builder*
dependencies.lock
idf_component.yml
CMakeLists.txt
sdkconfig.*
.dummy/*
# Ignore logo (set at build time with platformio-custom.py)
data/boot/logo.*

3
.gitmodules vendored
View File

@@ -1,3 +1,6 @@
[submodule "protobufs"]
path = protobufs
url = https://github.com/meshtastic/protobufs.git
[submodule "meshtestic"]
path = meshtestic
url = https://github.com/meshtastic/meshTestic

2
.gitpod.yml Normal file
View File

@@ -0,0 +1,2 @@
tasks:
- init: pip install platformio && pip install --upgrade pip

View File

@@ -1,2 +1,2 @@
.github/workflows/main_matrix.yml
src/mesh/compression/unishox2.c
src/mesh/compression/unishox2.cpp

2
.trunk/configs/.bandit Normal file
View File

@@ -0,0 +1,2 @@
[bandit]
skips = B101

View File

@@ -8,3 +8,4 @@ line_length: false
spaces: false
url: false
whitespace: false
headings: false

View File

@@ -0,0 +1 @@
renovate.json

View File

@@ -0,0 +1,10 @@
{
"overrides": [
{
"files": "userPrefs.jsonc",
"options": {
"trailingComma": "none"
}
}
]
}

View File

@@ -1,41 +1,44 @@
version: 0.1
cli:
version: 1.20.1
version: 1.25.0
plugins:
sources:
- id: trunk
ref: v1.4.4
ref: v1.7.2
uri: https://github.com/trunk-io/plugins
lint:
enabled:
- trufflehog@3.68.5
- yamllint@1.35.1
- bandit@1.7.7
- checkov@3.2.32
- terrascan@1.19.1
- trivy@0.49.1
#- trufflehog@3.63.2-rc0
- taplo@0.8.1
- ruff@0.3.1
- isort@5.13.2
- markdownlint@0.39.0
- oxipng@9.0.0
- svgo@3.2.0
- actionlint@1.6.27
- flake8@7.0.0
- hadolint@2.12.0
- checkov@3.2.471
- renovate@41.115.2
- prettier@3.6.2
- trufflehog@3.90.6
- yamllint@1.37.1
- bandit@1.8.6
- trivy@0.66.0
- taplo@0.10.0
- ruff@0.13.0
- isort@6.0.1
- markdownlint@0.45.0
- oxipng@9.1.5
- svgo@4.0.0
- actionlint@1.7.7
- flake8@7.3.0
- hadolint@2.13.1
- shfmt@3.6.0
- shellcheck@0.9.0
- black@24.2.0
- shellcheck@0.11.0
- black@25.1.0
- git-diff-check
- gitleaks@8.18.2
- gitleaks@8.28.0
- clang-format@16.0.3
- prettier@3.2.5
ignore:
- linters: [ALL]
paths:
- bin/**
runtimes:
enabled:
- python@3.10.8
- go@1.21.0
- node@18.12.1
- node@22.16.0
actions:
disabled:
- trunk-announce

View File

@@ -2,8 +2,9 @@
// See http://go.microsoft.com/fwlink/?LinkId=827846
// for the documentation about the extensions.json format
"recommendations": [
"ms-vscode.cpptools",
"platformio.platformio-ide",
"trunk.io"
"platformio.platformio-ide"
],
"unwantedRecommendations": [
"ms-vscode.cpptools-extension-pack"
]
}

View File

@@ -3,5 +3,12 @@
"editor.defaultFormatter": "trunk.io",
"trunk.enableWindows": true,
"files.insertFinalNewline": false,
"files.trimFinalNewlines": false
"files.trimFinalNewlines": false,
"cmake.configureOnOpen": false,
"[cpp]": {
"editor.defaultFormatter": "trunk.io"
},
"[powershell]": {
"editor.defaultFormatter": "ms-vscode.powershell"
}
}

6
8MB_no_ota.csv Normal file
View File

@@ -0,0 +1,6 @@
# Name, Type, SubType, Offset, Size, Flags
nvs, data, nvs, 0x9000, 0x5000,
otadata, data, ota, 0xe000, 0x2000,
app0, app, ota_0, 0x10000, 0x660000,
spiffs, data, spiffs, 0x670000,0x180000,
coredump, data, coredump,0x7F0000,0x10000,
1 # Name Type SubType Offset Size Flags
2 nvs data nvs 0x9000 0x5000
3 otadata data ota 0xe000 0x2000
4 app0 app ota_0 0x10000 0x660000
5 spiffs data spiffs 0x670000 0x180000
6 coredump data coredump 0x7F0000 0x10000

4
CODE_OF_CONDUCT.md Normal file
View File

@@ -0,0 +1,4 @@
# Contributor Covenant Code of Conduct
The Meshtastic Firmware project is subject to the code of conduct for the parent project, which can be found here:
https://meshtastic.org/docs/legal/conduct/

47
CONTRIBUTING.md Normal file
View File

@@ -0,0 +1,47 @@
# Contributing to Meshtastic Firmware
We're excited that you're interested in contributing to the Meshtastic firmware! This document provides a high-level overview of how you can get involved.
## Important First Steps
Before you begin, please:
1. **Read our documentation**: Our [official documentation](https://meshtastic.org/docs/) is a crucial resource. It contains essential information about the project.
2. **Check out the firmware build guide**: For specific instructions on setting up your development environment and building the firmware, refer to our [Firmware Build Guide](https://meshtastic.org/docs/development/firmware/build/).
3. Read our [Code of Conduct](https://meshtastic.org/docs/legal/conduct/)
4. Join our [Discord community](https://discord.com/invite/ktMAKGBnBs) to connect with developers and other contributors to get help.
## Getting Help and Discussing Ideas
We encourage open communication and discussion before diving into code changes:
1. **Use GitHub Discussions**: For new ideas, questions, or to discuss potential changes, start a conversation in our [GitHub Discussions](https://github.com/meshtastic/firmware/discussions) first. This helps us collaborate and avoid duplicate work.
2. **Join our Discord**: For real-time chat and quick questions, join our [Discord server](https://discord.com/invite/ktMAKGBnBs). It's a great place to get help and connect with other developers and the community.
3. **Reporting Issues**: If you've identified a bug, please use our bug report template when creating a new issue in the [issue tracker](https://github.com/meshtastic/firmware/issues). Ensure you've searched existing issues to avoid duplicates.
## Making Contributions
> [!IMPORTANT]
> Before making any contributions, you must sign our Contributor License Agreement (CLA). You can do this by visiting https://cla-assistant.io/meshtastic/firmware. Be sure to use the GitHub account you will use to submit your contributions when signing.
1. Fork the repository
2. Create a new branch for your feature or bug fix
3. Make your changes
4. Test your changes thoroughly
5. Create a pull request with a clear description, using the provided template, of your changes. Be sure to enable "Allow edits from maintainers".
## Coding Standards
To ensure consistent code formatting across the project:
1. Install the [Trunk](https://marketplace.visualstudio.com/items?itemName=Trunk.io) extension for Visual Studio Code.
2. Before submitting your changes, run `trunk fmt` to automatically format your code according to our standards.
Adhering to these formatting guidelines helps maintain code consistency and makes the review process smoother.
Thank you for contributing to Meshtastic!

View File

@@ -1,41 +1,78 @@
FROM debian:bullseye-slim AS builder
# trunk-ignore-all(trivy/DS002): We must run as root for this container
# trunk-ignore-all(hadolint/DL3002): We must run as root for this container
# trunk-ignore-all(hadolint/DL3008): Do not pin apt package versions
# trunk-ignore-all(hadolint/DL3013): Do not pin pip package versions
FROM python:3.13-slim-trixie AS builder
ARG PIO_ENV=native
ENV DEBIAN_FRONTEND=noninteractive
ENV TZ=Etc/UTC
# http://bugs.python.org/issue19846
# > At the moment, setting "LANG=C" on a Linux system *fundamentally breaks Python 3*, and that's not OK.
ENV LANG C.UTF-8
# Install Dependencies
ENV PIP_ROOT_USER_ACTION=ignore
RUN apt-get update && apt-get install --no-install-recommends -y \
curl wget g++ zip git ca-certificates pkg-config \
libgpiod-dev libyaml-cpp-dev libbluetooth-dev libi2c-dev libuv1-dev \
libusb-1.0-0-dev libulfius-dev liborcania-dev libssl-dev \
libx11-dev libinput-dev libxkbcommon-x11-dev \
&& apt-get clean && rm -rf /var/lib/apt/lists/* \
&& pip install --no-cache-dir -U platformio \
&& mkdir /tmp/firmware
SHELL ["/bin/bash", "-o", "pipefail", "-c"]
# Copy source code
WORKDIR /tmp/firmware
COPY . /tmp/firmware
# Install build deps
# Build
RUN bash ./bin/build-native.sh "$PIO_ENV" && \
cp "/tmp/firmware/release/meshtasticd_linux_$(uname -m)" "/tmp/firmware/release/meshtasticd"
# Fetch web assets
RUN curl -L "https://github.com/meshtastic/web/releases/download/v$(cat /tmp/firmware/bin/web.version)/build.tar" -o /tmp/web.tar \
&& mkdir -p /tmp/web \
&& tar -xf /tmp/web.tar -C /tmp/web/ \
&& gzip -dr /tmp/web \
&& rm /tmp/web.tar
##### PRODUCTION BUILD #############
FROM debian:trixie-slim
LABEL org.opencontainers.image.title="Meshtastic" \
org.opencontainers.image.description="Debian Meshtastic daemon and web interface" \
org.opencontainers.image.url="https://meshtastic.org" \
org.opencontainers.image.documentation="https://meshtastic.org/docs/" \
org.opencontainers.image.authors="Meshtastic" \
org.opencontainers.image.licenses="GPL-3.0-or-later" \
org.opencontainers.image.source="https://github.com/meshtastic/firmware/"
ENV DEBIAN_FRONTEND=noninteractive
ENV TZ=Etc/UTC
# nosemgrep: dockerfile.security.last-user-is-root.last-user-is-root
USER root
RUN apt-get update && \
apt-get -y install wget python3 g++ zip python3-venv git vim ca-certificates libgpiod-dev libyaml-cpp-dev libbluetooth-dev
# create a non-priveleged user & group
RUN groupadd -g 1000 mesh && useradd -ml -u 1000 -g 1000 mesh
RUN apt-get update && apt-get --no-install-recommends -y install \
libc-bin libc6 libgpiod3 libyaml-cpp0.8 libi2c0 libuv1t64 libusb-1.0-0-dev \
liborcania2.3 libulfius2.7t64 libssl3t64 \
libx11-6 libinput10 libxkbcommon-x11-0 \
&& apt-get clean && rm -rf /var/lib/apt/lists/* \
&& mkdir -p /var/lib/meshtasticd \
&& mkdir -p /etc/meshtasticd/config.d \
&& mkdir -p /etc/meshtasticd/ssl
USER mesh
RUN wget https://raw.githubusercontent.com/platformio/platformio-core-installer/master/get-platformio.py -qO /tmp/get-platformio.py && \
chmod +x /tmp/get-platformio.py && \
python3 /tmp/get-platformio.py && \
git clone https://github.com/meshtastic/firmware --recurse-submodules /tmp/firmware && \
cd /tmp/firmware && \
chmod +x /tmp/firmware/bin/build-native.sh && \
source ~/.platformio/penv/bin/activate && \
./bin/build-native.sh
# Fetch compiled binary from the builder
COPY --from=builder /tmp/firmware/release/meshtasticd /usr/bin/
COPY --from=builder /tmp/web /usr/share/meshtasticd/web/
# Copy config templates
COPY ./bin/config.d /etc/meshtasticd/available.d
FROM frolvlad/alpine-glibc:glibc-2.31
WORKDIR /var/lib/meshtasticd
VOLUME /var/lib/meshtasticd
RUN apk --update add --no-cache g++ shadow && \
groupadd -g 1000 mesh && useradd -ml -u 1000 -g 1000 mesh
# Expose Meshtastic TCP API port from the host
EXPOSE 4403
# Expose Meshtastic Web UI port from the host
EXPOSE 9443
COPY --from=builder /tmp/firmware/release/meshtasticd_linux_x86_64 /home/mesh/
CMD [ "sh", "-cx", "meshtasticd --fsdir=/var/lib/meshtasticd" ]
USER mesh
WORKDIR /home/mesh
CMD sh -cx "./meshtasticd_linux_x86_64 --hwid '${HWID:-$RANDOM}'"
HEALTHCHECK NONE
HEALTHCHECK NONE

View File

@@ -1,4 +1,7 @@
# Meshtastic Firmware
<div align="center" markdown="1">
<img src=".github/meshtastic_logo.png" alt="Meshtastic Logo" width="80"/>
<h1>Meshtastic Firmware</h1>
![GitHub release downloads](https://img.shields.io/github/downloads/meshtastic/firmware/total)
[![CI](https://img.shields.io/github/actions/workflow/status/meshtastic/firmware/main_matrix.yml?branch=master&label=actions&logo=github&color=yellow)](https://github.com/meshtastic/firmware/actions/workflows/ci.yml)
@@ -6,13 +9,32 @@
[![Fiscal Contributors](https://opencollective.com/meshtastic/tiers/badge.svg?label=Fiscal%20Contributors&color=deeppink)](https://opencollective.com/meshtastic/)
[![Vercel](https://img.shields.io/static/v1?label=Powered%20by&message=Vercel&style=flat&logo=vercel&color=000000)](https://vercel.com?utm_source=meshtastic&utm_campaign=oss)
<a href="https://trendshift.io/repositories/5524" target="_blank"><img src="https://trendshift.io/api/badge/repositories/5524" alt="meshtastic%2Ffirmware | Trendshift" style="width: 250px; height: 55px;" width="250" height="55"/></a>
</div>
</div>
<div align="center">
<a href="https://meshtastic.org">Website</a>
-
<a href="https://meshtastic.org/docs/">Documentation</a>
</div>
## Overview
This repository contains the device firmware for the Meshtastic project.
This repository contains the official device firmware for Meshtastic, an open-source LoRa mesh networking project designed for long-range, low-power communication without relying on internet or cellular infrastructure. The firmware supports various hardware platforms, including ESP32, nRF52, RP2040/RP2350, and Linux-based devices.
- **[Building Instructions](https://meshtastic.org/docs/development/firmware/build)**
- **[Flashing Instructions](https://meshtastic.org/docs/getting-started/flashing-firmware/)**
Meshtastic enables text messaging, location sharing, and telemetry over a decentralized mesh network, making it ideal for outdoor adventures, emergency preparedness, and remote operations.
### Get Started
- 🔧 **[Building Instructions](https://meshtastic.org/docs/development/firmware/build)** Learn how to compile the firmware from source.
-**[Flashing Instructions](https://meshtastic.org/docs/getting-started/flashing-firmware/)** Install or update the firmware on your device.
Join our community and help improve Meshtastic! 🚀
## Stats
![Alt](https://repobeats.axiom.co/api/embed/a92f097d9197ae853e780ec53d7d126e545629ab.svg "Repobeats analytics image")
![Alt](https://repobeats.axiom.co/api/embed/8025e56c482ec63541593cc5bd322c19d5c0bdcf.svg "Repobeats analytics image")

12
SECURITY.md Normal file
View File

@@ -0,0 +1,12 @@
# Security Policy
## Supported Versions
| Firmware Version | Supported |
| ---------------- | ------------------ |
| 2.6.x | :white_check_mark: |
| <= 2.5.x | :x: |
## Reporting a Vulnerability
We support the private reporting of potential security vulnerabilities. Please go to the Security tab to file a report with a description of the potential vulnerability and reproduction scripts (preferred) or steps, and our developers will review.

62
alpine.Dockerfile Normal file
View File

@@ -0,0 +1,62 @@
# trunk-ignore-all(trivy/DS002): We must run as root for this container
# trunk-ignore-all(hadolint/DL3002): We must run as root for this container
# trunk-ignore-all(hadolint/DL3018): Do not pin apk package versions
# trunk-ignore-all(hadolint/DL3013): Do not pin pip package versions
FROM python:3.13-alpine3.22 AS builder
ARG PIO_ENV=native
ENV PIP_ROOT_USER_ACTION=ignore
RUN apk --no-cache add \
bash g++ libstdc++-dev linux-headers zip git ca-certificates libgpiod-dev yaml-cpp-dev bluez-dev \
libusb-dev i2c-tools-dev libuv-dev openssl-dev pkgconf argp-standalone \
libx11-dev libinput-dev libxkbcommon-dev \
&& rm -rf /var/cache/apk/* \
&& pip install --no-cache-dir -U platformio \
&& mkdir /tmp/firmware
WORKDIR /tmp/firmware
COPY . /tmp/firmware
# Create small package (no debugging symbols)
# Add `argp` for musl
ENV PLATFORMIO_BUILD_FLAGS="-Os -ffunction-sections -fdata-sections -Wl,--gc-sections -largp"
RUN bash ./bin/build-native.sh "$PIO_ENV" && \
cp "/tmp/firmware/release/meshtasticd_linux_$(uname -m)" "/tmp/firmware/release/meshtasticd"
# ##### PRODUCTION BUILD #############
FROM alpine:3.22
LABEL org.opencontainers.image.title="Meshtastic" \
org.opencontainers.image.description="Alpine Meshtastic daemon" \
org.opencontainers.image.url="https://meshtastic.org" \
org.opencontainers.image.documentation="https://meshtastic.org/docs/" \
org.opencontainers.image.authors="Meshtastic" \
org.opencontainers.image.licenses="GPL-3.0-or-later" \
org.opencontainers.image.source="https://github.com/meshtastic/firmware/"
# nosemgrep: dockerfile.security.last-user-is-root.last-user-is-root
USER root
RUN apk --no-cache add \
shadow libstdc++ libgpiod yaml-cpp libusb i2c-tools libuv \
libx11 libinput libxkbcommon \
&& rm -rf /var/cache/apk/* \
&& mkdir -p /var/lib/meshtasticd \
&& mkdir -p /etc/meshtasticd/config.d \
&& mkdir -p /etc/meshtasticd/ssl
# Fetch compiled binary from the builder
COPY --from=builder /tmp/firmware/release/meshtasticd /usr/bin/
# Copy config templates
COPY ./bin/config.d /etc/meshtasticd/available.d
WORKDIR /var/lib/meshtasticd
VOLUME /var/lib/meshtasticd
EXPOSE 4403
CMD [ "sh", "-cx", "meshtasticd --fsdir=/var/lib/meshtasticd" ]
HEALTHCHECK NONE

View File

@@ -1,10 +1,13 @@
; Common settings for ESP targes, mixin with extends = esp32_base
[esp32_base]
extends = arduino_base
platform = platformio/espressif32@6.3.2 # This is a temporary fix to the S3-based devices bluetooth issues until we can determine what within ESP-IDF changed and can develop a suitable patch.
custom_esp32_kind = esp32
platform =
# renovate: datasource=custom.pio depName=platformio/espressif32 packageName=platformio/platform/espressif32
platformio/espressif32@6.11.0
build_src_filter =
${arduino_base.build_src_filter} -<platform/nrf52/> -<platform/stm32wl> -<platform/rp2040> -<mesh/eth/> -<mesh/raspihttp>
${arduino_base.build_src_filter} -<platform/nrf52/> -<platform/stm32wl> -<platform/rp2xx0> -<mesh/eth/> -<mesh/raspihttp>
upload_speed = 921600
debug_init_break = tbreak setup
@@ -15,8 +18,10 @@ board_build.filesystem = littlefs
# Remove -DMYNEWT_VAL_BLE_HS_LOG_LVL=LOG_LEVEL_CRITICAL for low level BLE logging.
# See library directory for BLE logging possible values: .pio/libdeps/tbeam/NimBLE-Arduino/src/log_common/log_common.h
# This overrides the BLE logging default of LOG_LEVEL_INFO (1) from: .pio/libdeps/tbeam/NimBLE-Arduino/src/esp_nimble_cfg.h
build_unflags = -fno-lto
build_flags =
${arduino_base.build_flags}
-flto
-Wall
-Wextra
-Isrc/platform/esp32
@@ -28,23 +33,33 @@ build_flags =
-DCONFIG_BT_NIMBLE_ENABLED
-DCONFIG_NIMBLE_CPP_LOG_LEVEL=2
-DCONFIG_BT_NIMBLE_MAX_CCCDS=20
-DCONFIG_BT_NIMBLE_HOST_TASK_STACK_SIZE=5120
-DCONFIG_BT_NIMBLE_HOST_TASK_STACK_SIZE=8192
-DESP_OPENSSL_SUPPRESS_LEGACY_WARNING
-DSERIAL_BUFFER_SIZE=4096
-DLIBPAX_ARDUINO
-DLIBPAX_WIFI
-DLIBPAX_BLE
-DHAS_UDP_MULTICAST=1
;-DDEBUG_HEAP
lib_deps =
${arduino_base.lib_deps}
${networking_base.lib_deps}
${environmental_base.lib_deps}
https://github.com/meshtastic/esp32_https_server.git#23665b3adc080a311dcbb586ed5941b5f94d6ea2
h2zero/NimBLE-Arduino@^1.4.1
https://github.com/dbSuS/libpax.git#7bcd3fcab75037505be9b122ab2b24cc5176b587
https://github.com/lewisxhe/XPowersLib.git#84b7373faea3118b6c37954d52f98b8a337148d6
https://github.com/meshtastic/ESP32_Codec2.git#633326c78ac251c059ab3a8c430fcdf25b41672f
${environmental_extra.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=git-refs depName=meshtastic-esp32_https_server packageName=https://github.com/meshtastic/esp32_https_server gitBranch=master
https://github.com/meshtastic/esp32_https_server/archive/3223704846752e6d545139204837bdb2a55459ca.zip
# renovate: datasource=custom.pio depName=NimBLE-Arduino packageName=h2zero/library/NimBLE-Arduino
h2zero/NimBLE-Arduino@^1.4.3
# renovate: datasource=git-refs depName=libpax packageName=https://github.com/mverch67/libpax gitBranch=master
https://github.com/mverch67/libpax/archive/6f52ee989301cdabaeef00bcbf93bff55708ce2f.zip
# renovate: datasource=github-tags depName=XPowersLib packageName=lewisxhe/XPowersLib
https://github.com/lewisxhe/XPowersLib/archive/v0.3.0.zip
# renovate: datasource=git-refs depName=meshtastic-ESP32_Codec2 packageName=https://github.com/meshtastic/ESP32_Codec2 gitBranch=master
https://github.com/meshtastic/ESP32_Codec2/archive/633326c78ac251c059ab3a8c430fcdf25b41672f.zip
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0
lib_ignore =
segger_rtt
@@ -60,4 +75,4 @@ lib_ignore =
; customize the partition table
; http://docs.platformio.org/en/latest/platforms/espressif32.html#partition-tables
board_build.partitions = partition-table.csv
board_build.partitions = partition-table.csv

View File

@@ -1,5 +1,6 @@
[esp32c3_base]
extends = esp32_base
custom_esp32_kind = esp32c3
monitor_speed = 115200
monitor_filters = esp32_c3_exception_decoder

47
arch/esp32/esp32c6.ini Normal file
View File

@@ -0,0 +1,47 @@
[esp32c6_base]
extends = esp32_base
platform =
# Do not renovate until we have switched to pioarduino tagged builds
https://github.com/Jason2866/platform-espressif32/archive/22faa566df8c789000f8136cd8d0aca49617af55.zip
build_flags =
${arduino_base.build_flags}
-Wall
-Wextra
-Isrc/platform/esp32
-std=c++11
-DESP_OPENSSL_SUPPRESS_LEGACY_WARNING
-DSERIAL_BUFFER_SIZE=4096
-DLIBPAX_ARDUINO
-DLIBPAX_WIFI
-DLIBPAX_BLE
-DMESHTASTIC_EXCLUDE_WEBSERVER
;-DDEBUG_HEAP
; TEMP
-DHAS_BLUETOOTH=0
-DMESHTASTIC_EXCLUDE_PAXCOUNTER
-DMESHTASTIC_EXCLUDE_BLUETOOTH
lib_deps =
${arduino_base.lib_deps}
${networking_base.lib_deps}
${environmental_base.lib_deps}
${environmental_extra.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=custom.pio depName=XPowersLib packageName=lewisxhe/library/XPowersLib
lewisxhe/XPowersLib@0.3.0
# renovate: datasource=git-refs depName=meshtastic-ESP32_Codec2 packageName=https://github.com/meshtastic/ESP32_Codec2 gitBranch=master
https://github.com/meshtastic/ESP32_Codec2/archive/633326c78ac251c059ab3a8c430fcdf25b41672f.zip
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0
build_src_filter =
${esp32_base.build_src_filter} -<mesh/http>
monitor_speed = 460800
monitor_filters = esp32_c3_exception_decoder
lib_ignore =
NonBlockingRTTTL
NimBLE-Arduino
libpax

View File

@@ -1,15 +1,19 @@
[esp32s2_base]
extends = esp32_base
custom_esp32_kind = esp32s2
build_src_filter =
${esp32_base.build_src_filter} -<nimble/> -<mesh/raspihttp>
${esp32_base.build_src_filter} - <libpax/> -<nimble/> -<mesh/raspihttp>
monitor_speed = 115200
build_flags =
${esp32_base.build_flags}
-DHAS_BLUETOOTH=0
-DMESHTASTIC_EXCLUDE_PAXCOUNTER
-DMESHTASTIC_EXCLUDE_BLUETOOTH
lib_ignore =
${esp32_base.lib_ignore}
NimBLE-Arduino
NimBLE-Arduino
libpax

View File

@@ -1,5 +1,5 @@
[esp32s3_base]
extends = esp32_base
custom_esp32_kind = esp32s3
monitor_speed = 115200

View File

@@ -0,0 +1,208 @@
/*
* lfs utility functions
*
* Copyright (c) 2017, Arm Limited. All rights reserved.
* SPDX-License-Identifier: BSD-3-Clause
*/
// MESHTASTIC/@geeksville note: This file is copied from the Adafruit nrf52 arduino lib. And we use a special -include in
// nrf52.ini to load it before EVERY file we do this hack because the default definitions for LFS_ASSERT are quite poor and we
// don't want to fork the adafruit lib (again) and send in a PR that they probably won't merge anyways. This file might break if
// they ever update lfs.util on their side, in which case we'll need to update this file to match their new version. The version
// this is a copy from is almost exactly
// https://github.com/adafruit/Adafruit_nRF52_Arduino/blob/c25d93268a3b9c23e9a1ccfcaf9b208beca624ca/libraries/Adafruit_LittleFS/src/littlefs/lfs_util.h
#ifndef LFS_UTIL_H
#define LFS_UTIL_H
// Users can override lfs_util.h with their own configuration by defining
// LFS_CONFIG as a header file to include (-DLFS_CONFIG=lfs_config.h).
//
// If LFS_CONFIG is used, none of the default utils will be emitted and must be
// provided by the config file. To start I would suggest copying lfs_util.h and
// modifying as needed.
#ifdef LFS_CONFIG
#define LFS_STRINGIZE(x) LFS_STRINGIZE2(x)
#define LFS_STRINGIZE2(x) #x
#include LFS_STRINGIZE(LFS_CONFIG)
#else
// System includes
#include <stdbool.h>
#include <stdint.h>
#include <string.h>
#ifndef LFS_NO_MALLOC
#include <stdlib.h>
#endif
#ifndef LFS_NO_ASSERT
#include <assert.h>
#endif
#if !defined(LFS_NO_DEBUG) || !defined(LFS_NO_WARN) || !defined(LFS_NO_ERROR)
#include <stdio.h>
#endif
#ifdef __cplusplus
extern "C" {
#endif
// Macros, may be replaced by system specific wrappers. Arguments to these
// macros must not have side-effects as the macros can be removed for a smaller
// code footprint
// Logging functions
#ifndef LFS_NO_DEBUG
void logLegacy(const char *level, const char *fmt, ...);
#define LFS_DEBUG(fmt, ...) logLegacy("DEBUG", "lfs debug:%d: " fmt "\n", __LINE__, __VA_ARGS__)
#else
#define LFS_DEBUG(fmt, ...)
#endif
#ifndef LFS_NO_WARN
#define LFS_WARN(fmt, ...) logLegacy("WARN", "lfs warn:%d: " fmt "\n", __LINE__, __VA_ARGS__)
#else
#define LFS_WARN(fmt, ...)
#endif
#ifndef LFS_NO_ERROR
#define LFS_ERROR(fmt, ...) logLegacy("ERROR", "lfs error:%d: " fmt "\n", __LINE__, __VA_ARGS__)
#else
#define LFS_ERROR(fmt, ...)
#endif
// Runtime assertions
#ifndef LFS_NO_ASSERT
#define LFS_ASSERT(test) assert(test)
#else
extern void lfs_assert(const char *reason);
#define LFS_ASSERT(test) \
if (!(test)) \
lfs_assert(#test)
#endif
// Builtin functions, these may be replaced by more efficient
// toolchain-specific implementations. LFS_NO_INTRINSICS falls back to a more
// expensive basic C implementation for debugging purposes
// Min/max functions for unsigned 32-bit numbers
static inline uint32_t lfs_max(uint32_t a, uint32_t b)
{
return (a > b) ? a : b;
}
static inline uint32_t lfs_min(uint32_t a, uint32_t b)
{
return (a < b) ? a : b;
}
// Find the next smallest power of 2 less than or equal to a
static inline uint32_t lfs_npw2(uint32_t a)
{
#if !defined(LFS_NO_INTRINSICS) && (defined(__GNUC__) || defined(__CC_ARM))
return 32 - __builtin_clz(a - 1);
#else
uint32_t r = 0;
uint32_t s;
a -= 1;
s = (a > 0xffff) << 4;
a >>= s;
r |= s;
s = (a > 0xff) << 3;
a >>= s;
r |= s;
s = (a > 0xf) << 2;
a >>= s;
r |= s;
s = (a > 0x3) << 1;
a >>= s;
r |= s;
return (r | (a >> 1)) + 1;
#endif
}
// Count the number of trailing binary zeros in a
// lfs_ctz(0) may be undefined
static inline uint32_t lfs_ctz(uint32_t a)
{
#if !defined(LFS_NO_INTRINSICS) && defined(__GNUC__)
return __builtin_ctz(a);
#else
return lfs_npw2((a & -a) + 1) - 1;
#endif
}
// Count the number of binary ones in a
static inline uint32_t lfs_popc(uint32_t a)
{
#if !defined(LFS_NO_INTRINSICS) && (defined(__GNUC__) || defined(__CC_ARM))
return __builtin_popcount(a);
#else
a = a - ((a >> 1) & 0x55555555);
a = (a & 0x33333333) + ((a >> 2) & 0x33333333);
return (((a + (a >> 4)) & 0xf0f0f0f) * 0x1010101) >> 24;
#endif
}
// Find the sequence comparison of a and b, this is the distance
// between a and b ignoring overflow
static inline int lfs_scmp(uint32_t a, uint32_t b)
{
return (int)(unsigned)(a - b);
}
// Convert from 32-bit little-endian to native order
static inline uint32_t lfs_fromle32(uint32_t a)
{
#if !defined(LFS_NO_INTRINSICS) && ((defined(BYTE_ORDER) && BYTE_ORDER == ORDER_LITTLE_ENDIAN) || \
(defined(__BYTE_ORDER) && __BYTE_ORDER == __ORDER_LITTLE_ENDIAN) || \
(defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_LITTLE_ENDIAN__))
return a;
#elif !defined(LFS_NO_INTRINSICS) && \
((defined(BYTE_ORDER) && BYTE_ORDER == ORDER_BIG_ENDIAN) || (defined(__BYTE_ORDER) && __BYTE_ORDER == __ORDER_BIG_ENDIAN) || \
(defined(__BYTE_ORDER__) && __BYTE_ORDER__ == __ORDER_BIG_ENDIAN__))
return __builtin_bswap32(a);
#else
return (((uint8_t *)&a)[0] << 0) | (((uint8_t *)&a)[1] << 8) | (((uint8_t *)&a)[2] << 16) | (((uint8_t *)&a)[3] << 24);
#endif
}
// Convert to 32-bit little-endian from native order
static inline uint32_t lfs_tole32(uint32_t a)
{
return lfs_fromle32(a);
}
// Calculate CRC-32 with polynomial = 0x04c11db7
void lfs_crc(uint32_t *crc, const void *buffer, size_t size);
// Allocate memory, only used if buffers are not provided to littlefs
static inline void *lfs_malloc(size_t size)
{
#ifndef LFS_NO_MALLOC
extern void *pvPortMalloc(size_t xWantedSize);
return pvPortMalloc(size);
#else
(void)size;
return NULL;
#endif
}
// Deallocate memory, only used if buffers are not provided to littlefs
static inline void lfs_free(void *p)
{
#ifndef LFS_NO_MALLOC
extern void vPortFree(void *pv);
vPortFree(p);
#else
(void)p;
#endif
}
#ifdef __cplusplus
} /* extern "C" */
#endif
#endif
#endif

View File

@@ -1,20 +1,36 @@
[nrf52_base]
; Instead of the standard nordicnrf52 platform, we use our fork which has our added variant files
platform = platformio/nordicnrf52@^10.1.0
platform =
# renovate: datasource=custom.pio depName=platformio/nordicnrf52 packageName=platformio/platform/nordicnrf52
platformio/nordicnrf52@^10.8.0
extends = arduino_base
platform_packages =
; our custom Git version until they merge our PR
# TODO renovate
platformio/framework-arduinoadafruitnrf52 @ https://github.com/meshtastic/Adafruit_nRF52_Arduino#e13f5820002a4fb2a5e6754b42ace185277e5adf
; Don't renovate toolchain-gccarmnoneeabi
platformio/toolchain-gccarmnoneeabi@~1.90301.0
build_type = debug ; I'm debugging with ICE a lot now
build_flags =
build_type = debug
build_flags =
-include arch/nrf52/cpp_overrides/lfs_util.h
${arduino_base.build_flags}
-DSERIAL_BUFFER_SIZE=1024
-Wno-unused-variable
-Isrc/platform/nrf52
-DLFS_NO_ASSERT ; Disable LFS assertions , see https://github.com/meshtastic/firmware/pull/3818
-DMESHTASTIC_EXCLUDE_AUDIO=1
-DMESHTASTIC_EXCLUDE_PAXCOUNTER=1
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<platform/stm32wl> -<nimble/> -<mesh/wifi/> -<mesh/api/> -<mesh/http/> -<modules/esp32> -<platform/rp2040> -<mesh/eth/> -<mesh/raspihttp>
${arduino_base.build_src_filter} -<platform/esp32/> -<platform/stm32wl> -<nimble/> -<mesh/wifi/> -<mesh/api/> -<mesh/http/> -<modules/esp32> -<platform/rp2xx0> -<mesh/eth/> -<mesh/raspihttp> -<serialization/>
lib_deps=
${arduino_base.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0
lib_ignore =
BluetoothOTA
BluetoothOTA
lvgl

View File

@@ -6,4 +6,75 @@ build_flags = ${nrf52_base.build_flags}
lib_deps =
${nrf52_base.lib_deps}
${environmental_base.lib_deps}
https://github.com/Kongduino/Adafruit_nRFCrypto.git#e31a8825ea3300b163a0a3c1ddd5de34e10e1371
${environmental_extra.lib_deps}
# renovate: datasource=git-refs depName=Kongduino-Adafruit_nRFCrypto packageName=https://github.com/Kongduino/Adafruit_nRFCrypto gitBranch=master
https://github.com/Kongduino/Adafruit_nRFCrypto/archive/5f838d2709461a2c981f642917aa50254a25c14c.zip
; Common NRF52 debugging settings follow. See the Meshtastic developer docs for how to connect SWD debugging probes to your board.
; We want the initial breakpoint at setup() instead of main(). Also we want to enable semihosting at that point so instead of
debug_init_break = tbreak setup
; we just turn off the platformio tbreak and do it in .gdbinit (where we have more flexibility for scripting)
; also we use a permanent breakpoint so it gets reused each time we restart the debugging session?
; debug_init_break = tbreak main
; Note: add "monitor arm semihosting_redirect tcp 4444 all" if you want the stdout from the device to go to that port number instead
; (for use by meshtastic command line)
; monitor arm semihosting disable
; monitor debug_level 3
;
; IMPORTANT: fileio must be disabled before using port 5555 - openocd ver 0.12 has a bug where if enabled it never properly parses the special :tt name
; for stdio access.
; monitor arm semihosting_redirect tcp 5555 stdio
; Also note: it is _impossible_ to do non blocking reads on the semihost console port (an oversight when ARM specified the semihost API).
; So we'll neve be able to general purpose bi-directional communication with the device over semihosting.
debug_extra_cmds =
echo Running .gdbinit script
;monitor arm semihosting enable
;monitor arm semihosting_fileio enable
;monitor arm semihosting_redirect disable
commands 1
; echo Breakpoint at setup() has semihosting console, connect to it with "telnet localhost 5555"
; set wantSemihost = 1
set useSoftDevice = 0
end
; Only reprogram the board if the code has changed
debug_load_mode = modified
;debug_load_mode = manual
; We default to the stlink adapter because it is very cheap and works well, though others (such as jlink) are also supported.
;debug_tool = jlink
debug_tool = stlink
debug_speed = 4000
;debug_tool = custom
; debug_server =
; openocd
; -f
; /usr/local/share/openocd/scripts/interface/stlink.cfg
; -f
; /usr/local/share/openocd/scripts/target/nrf52.cfg
; $PLATFORMIO_CORE_DIR/packages/tool-openocd/openocd/scripts/interface/cmsis-dap.cfg
; Allows programming and debug via the RAK NanoDAP as the default debugger tool for the RAK4631 (it is only $10!)
; programming time is about the same as the bootloader version.
; For information on this see the meshtastic developers documentation for "Development on the NRF52"
; We manually pass in the elf file so that pyocd can reverse engineer FreeRTOS data (running threads, etc...)
;debug_server =
; pyocd
; gdbserver
; -j
; ${platformio.workspace_dir}/..
; -t
; nrf52840
; --semihosting
; --elf
; ${platformio.build_dir}/${this.__env__}/firmware.elf
; If you want to debug the semihosting support you can turn on extra logging in pyocd with
; -L
; pyocd.debug.semihost.trace=debug
; The following is not needed because it automatically tries do this
;debug_server_ready_pattern = -.*GDB server started on port \d+.*
;debug_port = localhost:3333

View File

@@ -1,6 +1,8 @@
; The Portduino based sim environment on top of any host OS, all hardware will be simulated
; The Portduino based 'native' environment. Currently supported on Linux targets with real LoRa hardware (or simulated).
[portduino_base]
platform = https://github.com/meshtastic/platform-native.git#a28dd5a9ccd5c48a9bede46037855ff83915d74b
platform =
# renovate: datasource=git-refs depName=platform-native packageName=https://github.com/meshtastic/platform-native gitBranch=develop
https://github.com/meshtastic/platform-native/archive/c490bcd019e0658404088a61b96e653c9da22c45.zip
framework = arduino
build_src_filter =
@@ -9,29 +11,48 @@ build_src_filter =
-<nimble/>
-<platform/nrf52/>
-<platform/stm32wl/>
-<platform/rp2040>
-<platform/rp2xx0>
-<mesh/wifi/>
-<mesh/http/>
+<mesh/raspihttp/>
-<mesh/eth/>
-<modules/esp32>
-<modules/Telemetry/EnvironmentTelemetry.cpp>
-<modules/Telemetry/AirQualityTelemetry.cpp>
-<modules/Telemetry/Sensor>
+<../variants/portduino>
lib_deps =
${env.lib_deps}
${networking_base.lib_deps}
rweather/Crypto@^0.4.0
lovyan03/LovyanGFX@^1.1.12
${radiolib_base.lib_deps}
${environmental_base.lib_deps}
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0
# renovate: datasource=custom.pio depName=LovyanGFX packageName=lovyan03/library/LovyanGFX
lovyan03/LovyanGFX@^1.2.0
# renovate: datasource=git-refs depName=libch341-spi-userspace packageName=https://github.com/pine64/libch341-spi-userspace gitBranch=main
https://github.com/pine64/libch341-spi-userspace/archive/af9bc27c9c30fa90772279925b7c5913dff789b4.zip
# renovate: datasource=custom.pio depName=adafruit/Adafruit seesaw Library packageName=adafruit/library/Adafruit seesaw Library
adafruit/Adafruit seesaw Library@1.7.9
# renovate: datasource=git-refs depName=RAK12034-BMX160 packageName=https://github.com/RAKWireless/RAK12034-BMX160 gitBranch=main
https://github.com/RAKWireless/RAK12034-BMX160/archive/dcead07ffa267d3c906e9ca4a1330ab989e957e2.zip
build_flags =
${arduino_base.build_flags}
-D ARCH_PORTDUINO
-fPIC
-Isrc/platform/portduino
-DRADIOLIB_EEPROM_UNSUPPORTED
-DPORTDUINO_LINUX_HARDWARE
-DHAS_UDP_MULTICAST=1
-lpthread
-lstdc++fs
-lbluetooth
-lgpiod
-lyaml-cpp
-lyaml-cpp
-li2c
-luv
-std=gnu17
-std=c++17
lib_ignore =
Adafruit NeoPixel
Adafruit ST7735 and ST7789 Library
SD

View File

@@ -1,23 +0,0 @@
; Common settings for rp2040 Processor based targets
[rp2040_base]
platform = https://github.com/maxgerhardt/platform-raspberrypi.git#612de5399d68b359053f1307ed223d400aea975c
extends = arduino_base
platform_packages = framework-arduinopico@https://github.com/earlephilhower/arduino-pico.git#3.6.2
board_build.core = earlephilhower
board_build.filesystem_size = 0.5m
build_flags =
${arduino_base.build_flags} -Wno-unused-variable
-Isrc/platform/rp2040
-D__PLAT_RP2040__
# -D _POSIX_THREADS
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<modules/esp32> -<platform/nrf52/> -<platform/stm32wl> -<mesh/eth/> -<mesh/wifi/> -<mesh/http/> -<mesh/raspihttp>
lib_ignore =
BluetoothOTA
lib_deps =
${arduino_base.lib_deps}
${environmental_base.lib_deps}
rweather/Crypto

34
arch/rp2xx0/rp2040.ini Normal file
View File

@@ -0,0 +1,34 @@
; Common settings for rp2040 Processor based targets
[rp2040_base]
platform =
# TODO renovate
https://github.com/maxgerhardt/platform-raspberrypi#76ecf3c7e9dd4503af0331154c4ca1cddc4b03e5
; For arduino-pico >= 4.4.3
extends = arduino_base
platform_packages =
# TODO renovate
framework-arduinopico@https://github.com/earlephilhower/arduino-pico#4.4.3
board_build.core = earlephilhower
board_build.filesystem_size = 0.5m
build_flags =
${arduino_base.build_flags} -Wno-unused-variable -Wcast-align
-Isrc/platform/rp2xx0
-Isrc/platform/rp2xx0/hardware_rosc/include
-Isrc/platform/rp2xx0/pico_sleep/include
-D__PLAT_RP2040__
# -D _POSIX_THREADS
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<modules/esp32> -<platform/nrf52/> -<platform/stm32wl> -<mesh/eth/> -<mesh/wifi/> -<mesh/http/> -<mesh/raspihttp>
lib_ignore =
BluetoothOTA
lvgl
lib_deps =
${arduino_base.lib_deps}
${environmental_base.lib_deps}
${environmental_extra.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0

31
arch/rp2xx0/rp2350.ini Normal file
View File

@@ -0,0 +1,31 @@
; Common settings for rp2350 Processor based targets
[rp2350_base]
platform =
# TODO renovate
https://github.com/maxgerhardt/platform-raspberrypi#76ecf3c7e9dd4503af0331154c4ca1cddc4b03e5
; For arduino-pico >= 4.4.3
extends = arduino_base
platform_packages =
# TODO renovate
framework-arduinopico@https://github.com/earlephilhower/arduino-pico#4.4.3
board_build.core = earlephilhower
board_build.filesystem_size = 0.5m
build_flags =
${arduino_base.build_flags} -Wno-unused-variable -Wcast-align
-Isrc/platform/rp2xx0
-D__PLAT_RP2350__
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<modules/esp32> -<platform/nrf52/> -<platform/stm32wl> -<mesh/eth/> -<mesh/wifi/> -<mesh/http/> -<mesh/raspihttp> -<platform/rp2xx0/pico_sleep> -<platform/rp2xx0/hardware_rosc>
lib_ignore =
BluetoothOTA
lvgl
lib_deps =
${arduino_base.lib_deps}
${environmental_base.lib_deps}
${environmental_extra.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=custom.pio depName=rweather/Crypto packageName=rweather/library/Crypto
rweather/Crypto@0.4.0

56
arch/stm32/stm32.ini Normal file
View File

@@ -0,0 +1,56 @@
[stm32_base]
extends = arduino_base
platform =
# renovate: datasource=custom.pio depName=platformio/ststm32 packageName=platformio/platform/ststm32
platformio/ststm32@19.3.0
platform_packages =
# TODO renovate
platformio/framework-arduinoststm32@https://github.com/stm32duino/Arduino_Core_STM32/archive/2.10.1.zip
extra_scripts =
${env.extra_scripts}
post:extra_scripts/extra_stm32.py
build_type = release
build_flags =
${arduino_base.build_flags}
-flto
-Isrc/platform/stm32wl -g
-DMESHTASTIC_EXCLUDE_AUDIO=1
-DMESHTASTIC_EXCLUDE_ATAK=1 ; ATAK is quite big, disable it for big flash savings.
-DMESHTASTIC_EXCLUDE_INPUTBROKER=1
-DMESHTASTIC_EXCLUDE_POWERMON=1
-DMESHTASTIC_EXCLUDE_SCREEN=1
-DMESHTASTIC_EXCLUDE_MQTT=1
-DMESHTASTIC_EXCLUDE_BLUETOOTH=1
-DMESHTASTIC_EXCLUDE_WIFI=1
-DMESHTASTIC_EXCLUDE_TZ=1 ; Exclude TZ to save some flash space.
-DSERIAL_RX_BUFFER_SIZE=256 ; For GPS - the default of 64 is too small.
-DHAS_SCREEN=0 ; Always disable screen for STM32, it is not supported.
-DPIO_FRAMEWORK_ARDUINO_NANOLIB_FLOAT_PRINTF ; This is REQUIRED for at least traceroute debug prints - without it the length ends up uninitialized.
-DDEBUG_MUTE ; You can #undef DEBUG_MUTE in certain source files if you need the logs.
-fmerge-all-constants
-ffunction-sections
-fdata-sections
-DRADIOLIB_EXCLUDE_SX128X=1
-DRADIOLIB_EXCLUDE_SX127X=1
-DRADIOLIB_EXCLUDE_LR11X0=1
-DHAL_DAC_MODULE_ONLY
-DHAL_RNG_MODULE_ENABLED
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<mesh/api/> -<mesh/wifi/> -<mesh/http/> -<modules/esp32> -<mesh/eth/> -<input> -<buzz> -<modules/RemoteHardwareModule.cpp> -<platform/nrf52> -<platform/portduino> -<platform/rp2xx0> -<mesh/raspihttp>
board_upload.offset_address = 0x08000000
upload_protocol = stlink
debug_tool = stlink
lib_deps =
${env.lib_deps}
${radiolib_base.lib_deps}
# renovate: datasource=git-refs depName=caveman99-stm32-Crypto packageName=https://github.com/caveman99/Crypto gitBranch=main
https://github.com/caveman99/Crypto/archive/1aa30eb536bd52a576fde6dfa393bf7349cf102d.zip
lib_ignore =
OneButton

View File

@@ -1,28 +0,0 @@
[stm32wl5e_base]
platform_packages = platformio/framework-arduinoststm32 @ https://github.com/stm32duino/Arduino_Core_STM32.git#6e3f9910d0122e82a6c3438507dfac3d2fd80a39
platform = ststm32
board = generic_wl5e
framework = arduino
build_type = debug
build_flags =
${arduino_base.build_flags}
-Isrc/platform/stm32wl -g
-DconfigUSE_CMSIS_RTOS_V2=1
-DVECT_TAB_OFFSET=0x08000000
build_src_filter =
${arduino_base.build_src_filter} -<platform/esp32/> -<nimble/> -<mesh/api/> -<mesh/wifi/> -<mesh/http/> -<modules/esp32> -<mesh/eth/> -<input> -<buzz> -<modules/Telemetry> -<platform/nrf52> -<platform/portduino> -<platform/rp2040> -<mesh/raspihttp>
board_upload.offset_address = 0x08000000
upload_protocol = stlink
lib_deps =
${env.lib_deps}
https://github.com/kokke/tiny-AES-c.git#f06ac37fc31dfdaca2e0d9bec83f90d5663c319b
https://github.com/littlefs-project/littlefs.git#v2.5.1
https://github.com/stm32duino/STM32FreeRTOS.git#10.3.1
lib_ignore =
mathertel/OneButton

1
bin/.gitignore vendored Normal file
View File

@@ -0,0 +1 @@
config.yaml

View File

@@ -0,0 +1,7 @@
# Set spidev ownership to 'spi' group
SUBSYSTEM=="spidev", KERNEL=="spidev*", GROUP="spi", MODE="0660"
# Allow access to USB CH341 devices
SUBSYSTEM=="usb", ATTRS{idVendor}=="1a86", ATTRS{idProduct}=="5512", MODE="0666"
# Set gpio ownership to 'gpio' group
SUBSYSTEM=="*gpiomem*", GROUP="gpio", MODE="0660"
SUBSYSTEM=="gpio", GROUP="gpio", MODE="0660"

Binary file not shown.

Binary file not shown.

33
bin/base64_to_hex.py Normal file
View File

@@ -0,0 +1,33 @@
import sys
import base64
def base64_to_hex_string(b64_string):
try:
# Decode the Base64 string to raw bytes
decoded_bytes = base64.b64decode(b64_string)
except Exception as e:
raise ValueError(f"Invalid Base64 input: {e}")
# Check if the decoded result is exactly 32 bytes
if len(decoded_bytes) != 32:
raise ValueError("Decoded Base64 input must be exactly 32 bytes.")
# Convert each byte to its hex representation
hex_values = [f"0x{byte:02x}" for byte in decoded_bytes]
# Join the formatted hex values with commas
formatted_output = "{ " + ", ".join(hex_values) + " };"
return formatted_output
if __name__ == "__main__":
# Check if a Base64 string was provided in command line arguments
if len(sys.argv) != 2:
print("Usage: python script.py <base64-string>")
sys.exit(1)
b64_string = sys.argv[1]
try:
formatted_hex = base64_to_hex_string(b64_string)
print(formatted_hex)
except ValueError as e:
print(e)

View File

@@ -11,7 +11,7 @@ rm -f $OUTDIR/firmware*
rm -r $OUTDIR/* || true
# Important to pull latest version of libs into all device flavors, otherwise some devices might be stale
platformio pkg update
platformio pkg install -e $1
echo "Building for $1 with $PLATFORMIO_BUILD_FLAGS"
rm -f .pio/build/$1/firmware.*
@@ -34,7 +34,13 @@ SRCBIN=.pio/build/$1/firmware.bin
cp $SRCBIN $OUTDIR/$basename-update.bin
echo "Building Filesystem for ESP32 targets"
# If you want to build the webui, uncomment the following lines
# pio run --environment $1 -t buildfs
# cp .pio/build/$1/littlefs.bin $OUTDIR/littlefswebui-$1-$VERSION.bin
# # Remove webserver files from the filesystem and rebuild
# ls -l data/static # Diagnostic list of files
# rm -rf data/static
pio run --environment $1 -t buildfs
cp .pio/build/$1/littlefs.bin $OUTDIR/littlefs-$VERSION.bin
cp .pio/build/$1/littlefs.bin $OUTDIR/littlefs-$1-$VERSION.bin
cp bin/device-install.* $OUTDIR
cp bin/device-update.* $OUTDIR
cp bin/device-update.* $OUTDIR

16
bin/build-firmware.sh Normal file
View File

@@ -0,0 +1,16 @@
#!/usr/bin/env bash
export PIP_BREAK_SYSTEM_PACKAGES=1
if (echo $2 | grep -q "esp32"); then
bin/build-esp32.sh $1
elif (echo $2 | grep -q "nrf52"); then
bin/build-nrf52.sh $1
elif (echo $2 | grep -q "stm32"); then
bin/build-stm32.sh $1
elif (echo $2 | grep -q "rpi2040"); then
bin/build-rp2xx0.sh $1
else
echo "Unknown target $2"
exit 1
fi

View File

@@ -2,8 +2,20 @@
set -e
platformioFailed() {
[[ $VIRTUAL_ENV != "" ]] && exit 1 # don't hint at virtualenv if it's already in use
echo -e "\nThere were issues running platformio and you are not using a virtual environment." \
"\nYou may try setting up virtualenv and downloading the latest platformio from pip:" \
"\n\tvirtualenv venv" \
"\n\tsource venv/bin/activate" \
"\n\tpip install platformio" \
"\n\t./bin/build-native.sh # retry building"
exit 1
}
VERSION=$(bin/buildinfo.py long)
SHORT_VERSION=$(bin/buildinfo.py short)
PIO_ENV=${1:-native}
OUTDIR=release/
@@ -13,8 +25,7 @@ mkdir -p $OUTDIR/
rm -r $OUTDIR/* || true
# Important to pull latest version of libs into all device flavors, otherwise some devices might be stale
platformio pkg update
pio run --environment native
cp .pio/build/native/program "$OUTDIR/meshtasticd_linux_$(arch)"
cp bin/device-install.* $OUTDIR
cp bin/device-update.* $OUTDIR
pio pkg install --environment "$PIO_ENV" || platformioFailed
pio run --environment "$PIO_ENV" || platformioFailed
cp ".pio/build/$PIO_ENV/program" "$OUTDIR/meshtasticd_linux_$(uname -m)"
cp bin/native-install.* $OUTDIR

View File

@@ -2,8 +2,8 @@
set -e
VERSION=`bin/buildinfo.py long`
SHORT_VERSION=`bin/buildinfo.py short`
VERSION=$(bin/buildinfo.py long)
SHORT_VERSION=$(bin/buildinfo.py short)
OUTDIR=release/
@@ -11,7 +11,7 @@ rm -f $OUTDIR/firmware*
rm -r $OUTDIR/* || true
# Important to pull latest version of libs into all device flavors, otherwise some devices might be stale
platformio pkg update
platformio pkg install -e $1
echo "Building for $1 with $PLATFORMIO_BUILD_FLAGS"
rm -f .pio/build/$1/firmware.*
@@ -23,14 +23,31 @@ basename=firmware-$1-$VERSION
pio run --environment $1 # -v
SRCELF=.pio/build/$1/firmware.elf
DFUPKG=.pio/build/$1/firmware.zip
cp $SRCELF $OUTDIR/$basename.elf
echo "Generating NRF52 dfu file"
DFUPKG=.pio/build/$1/firmware.zip
cp $DFUPKG $OUTDIR/$basename-ota.zip
echo "Generating NRF52 uf2 file"
SRCHEX=.pio/build/$1/firmware.hex
bin/uf2conv.py $SRCHEX -c -o $OUTDIR/$basename.uf2 -f 0xADA52840
cp bin/device-install.* $OUTDIR
cp bin/device-update.* $OUTDIR
cp bin/*.uf2 $OUTDIR
# if WM1110 target, merge hex with softdevice 7.3.0
if (echo $1 | grep -q "wio-sdk-wm1110"); then
echo "Merging with softdevice"
bin/mergehex -m bin/s140_nrf52_7.3.0_softdevice.hex $SRCHEX -o .pio/build/$1/$basename.hex
SRCHEX=.pio/build/$1/$basename.hex
bin/uf2conv.py $SRCHEX -c -o $OUTDIR/$basename.uf2 -f 0xADA52840
cp $SRCHEX $OUTDIR
cp bin/*.uf2 $OUTDIR
else
bin/uf2conv.py $SRCHEX -c -o $OUTDIR/$basename.uf2 -f 0xADA52840
cp bin/device-install.* $OUTDIR
cp bin/device-update.* $OUTDIR
cp bin/*.uf2 $OUTDIR
fi
if (echo $1 | grep -q "rak4631"); then
echo "Copying hex file"
cp .pio/build/$1/firmware.hex $OUTDIR/$basename.hex
fi

Some files were not shown because too many files have changed in this diff Show More