Modified FiveTalk with GPS coordinates, Power has OLED display at outset
This commit is contained in:
parent
61cf7e5191
commit
38b80f97e5
4 changed files with 423 additions and 4 deletions
30
exercises/14_Power/README.md
Normal file
30
exercises/14_Power/README.md
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
# Exercise 14: Power (Charging + Visual)
|
||||
|
||||
This exercise is intentionally narrow in scope:
|
||||
- Detect if a battery is present.
|
||||
- Detect if USB/VBUS power is present.
|
||||
- Determine if charging is needed.
|
||||
- Keep charging enabled through AXP2101 PMU settings.
|
||||
- Flash the PMU charge LED while charging.
|
||||
- If fully charged, leave LED off (do nothing).
|
||||
|
||||
OLED behavior:
|
||||
- For the first 2 minutes after boot, OLED shows:
|
||||
- `Exercise 14 Power`
|
||||
- node name (`NODE_LABEL`)
|
||||
- time (RTC/system time if available, else uptime)
|
||||
- charging state and battery stats
|
||||
- After 2 minutes, it switches to a steady `Power Monitor` header while continuing live stats.
|
||||
|
||||
## Meshtastic references used
|
||||
- `src/Power.cpp`
|
||||
- charging detection path (`isCharging()`, `isVbusIn()`, battery checks)
|
||||
- `src/modules/StatusLEDModule.cpp`
|
||||
- PMU charging LED control via `PMU->setChargingLedMode(...)`
|
||||
|
||||
## Build and upload
|
||||
```bash
|
||||
cd /usr/local/src/microreticulum/microReticulumTbeam/exercises/14_Power
|
||||
pio run -e ed -t upload
|
||||
pio device monitor -b 115200
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue