* refactor(io): unique_ptr ownership for motion sensors and I2C keyboard
- AccelerometerThread / MagnetometerThread: the owned MotionSensor
becomes unique_ptr, removing the manual delete/null bookkeeping in
clean(). Deletion behavior is unchanged (MotionSensor's destructor is
virtual).
- KbI2cBase: the TCA keyboard was a reference member bound to an
anonymous heap allocation - ownership was invisible and nothing could
ever free it. It becomes unique_ptr with an out-of-line destructor
(the base type is only forward-declared in the header).
- GeoCoord::pointAtDistance returned shared_ptr with no shared
ownership anywhere (and no callers); return by value instead.
No behavior change.
* fix(io): make TCA8418KeyboardBase destructor public for unique_ptr ownership
* refactor(gps): delete dead pointAtDistance instead of converting it
Per review: zero callers in this repo or device-ui, and the math was
wrong at both ends (rangeMetersToRadians multiplies meters by 1852,
treating meters as nautical miles). Remove it, its now-unused helper,
and the <memory> include the old shared_ptr signature pulled in.
* fix(nrf54l15): restore the nrf54l15dk build
Three unrelated faults stacked up, so the env has not built from a clean
cache for some time. All three were diagnosed in July but never committed.
Pin framework-zephyr to 3.40201.251021 (Zephyr 4.2.1). Seeed's platform
script only maps their own seeed-xiao-* board ids to a package; any other
board -- ours included -- falls back to whatever platform.json declares as
the default, which is now Zephyr 4.4.0. Its west manifest pulls a CMSIS_6
whose cmsis_gcc.h calls the ACLE builtins __sxtb16/__sxtab16, and none of
the GCC ARM toolchains PlatformIO ships (8.2.1/9.2.1/9.3.1) declare them in
arm_acle.h. In C that is only an implicit-declaration warning; in C++ it is
a hard error. So a fresh cache silently breaks the build even though
nothing in the tree changed.
Guard the MMC5983MA case in MagnetometerThread with __has_include. The
switch arm constructs MMC5983MASensor unconditionally, so any env whose
libdeps lack SparkFun_MMC5983MA_Arduino_Library fails with "expected
type-specifier before 'MMC5983MASensor'".
Add Print::availableForWrite() to the nrf54l15 Arduino shim. The shim
declares flush() but not availableForWrite(), which StreamFrameWriter
calls -- so it went unnoticed until that code landed.
Verified: clean build of nrf54l15dk from an empty package cache, SUCCESS in
16:01, FLASH 39.04% (570804 B of 1428 KB), RAM 65.65%. The three had never
been exercised together -- a previous run with only the pin applied got
17:30 in before hitting the other two.
* review: collapse the pin rationale to one repo-local comment
The block was pasted twice, and both copies pointed at a note that does not
exist in this repository. Kept one, and only the part a reader here can act
on: why the fallback happens, and why it is a C++ error rather than the
warning the pure-C Zephyr core gets away with.
---------
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>
* Fixes
* Remove BATTERY_LPCOMP_THRESHOLD
BATTERY_LPCOMP_THRESHOLD is dead code — in main-nrf52.cpp it's inside #ifdef BATTERY_LPCOMP_INPUT, which this board intentionally doesn't define. The threshold value is never reached.
* Trunk fix
* Update MotionSensor.cpp
* fix
---------
Co-authored-by: Ben Meadors <benmmeadors@gmail.com>
Co-authored-by: Jonathan Bennett <jbennett@incomsystems.biz>