Files
powerpods/main/powerpod.h
skrueckenandCursor 7f28a48a10 Add runtime UV protection toggle and treat near-zero sense as external power.
Per-pod NVS enable (default off) via UART/ESP-NOW/dashboard, and skip UV latch when LiPo ADC reads ~0 mV so USB/external supply still boots.

Co-authored-by: Cursor <cursoragent@cursor.com>
2026-11-01 22:51:17 +01:00

24 lines
633 B
C

#ifndef POWERPOD_H
#define POWERPOD_H
/** 1 = software LiPo UV latch + energy-save mode; 0 = disabled (LED mode 6 still works). */
#ifndef POWERPOD_BATTERY_UV_ENABLE
#define POWERPOD_BATTERY_UV_ENABLE 1
#endif
#define DIP_MASTER 4
#define I2C_SCL 5
#define I2C_SDA 6
#define I2C_PORT 0
#define IO_EXPANDER_ADDRESS 0x20
/* TODO: Hardware pinning not finalized — verify against schematic before production. */
/** Front-panel button (active low, internal pull-up). */
#define TASTER_GPIO 12
/** LiPo voltage sense inputs (ADC-capable GPIOs; GPIO11 = ADC2 on ESP32-S3). */
#define V_LIPO_1_GPIO 1
#define V_LIPO_2_GPIO 11
#endif