Add deep sleep and single-button UX with heartbeat LED
Replace the dual-switch handler with one button: short press cycles patterns, long press arms deep sleep with ext1 GPIO wake. Add a heartbeat LED task and fix the IMU test I2C pins to GPIO21/GPIO6. Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
c07e3e7a07
commit
7e14841478
2 files changed
+81
-20
No files matched your search
@@ -5,7 +5,7 @@ from lsm6ds3 import LSM6DS3, is_lsm6ds3
|
||||
|
||||
|
||||
# XIAO ESP32C3 default I2C pins: SDA=GPIO6 (D4), SCL=GPIO7 (D5)
|
||||
i2c = I2C(0, scl=Pin(23), sda=Pin(22), freq=400000)
|
||||
i2c = I2C(0, scl=Pin(20), sda=Pin(21), freq=400000)
|
||||
|
||||
|
||||
def scan_i2c():
|
||||
|
||||
Reference in new issue
Block a user