Konubinix' opinionated web of thoughts

Using a Self Power Off Button

Fleeting

micropython

VID_20250918_213818.mp4

VID_20250918_214143.mp4

#!/usr/bin/env python3
# -*- coding:utf-8 -*-
from helpers import lowpower, runner
from comm import ntfy, wifi
from machine import Pin
import time
lowpower()

off = Pin(4, Pin.OUT)

@runner()
def run():
    wifi.on()
    ntfy("Hello, poweroff in 5s")
    time.sleep(5)
    off.value(1)
Sun Nov 16 14:02:20 CET 2025
Checking the current installation
Reading install.json from mpremote
Writing into main.py in mpremote
Writing into comm.py in mpremote
Writing into install.json in mpremote
Writing into error.log in mpremote
Writing into resetdeepsleep in mpremote