Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

StillClock

Low-power clock for the M5Stack CoreInk. It synchronizes Brisbane time over NTP at startup, switches Wi-Fi off, updates at minute boundaries, and uses partial e-ink refreshes to avoid unnecessary full-screen flashing.

CoreInk StillClock

Hardware and libraries

  • M5Stack CoreInk
  • Board FQBN: m5stack:esp32:m5stack_coreink
  • Arduino libraries: M5Unified, M5GFX

The displayed TEMP value comes from the ESP32 die sensor, which is not a calibrated ambient sensor. The sketch applies TEMPERATURE_CALIBRATION_C as a one-point correction; adjust that constant against a trusted thermometer for this particular device and operating conditions.

Google Calendar

Deploy the adapter in Google Apps Script/README.md, then add its /exec URL and matching Script Property token to .env:

CALENDAR_URL=https://script.google.com/macros/s/DEPLOYMENT_ID/exec
CALENDAR_TOKEN=use-a-long-random-token

The adapter runs as your Google account and exposes only one active or upcoming event. Treat both values as secrets.

Private Wi-Fi configuration

Copy .env.example to .env, enter one or more networks, then generate the private firmware header:

Copy-Item ".env.example" ".env"
& ".\tools\generate-config.ps1"

Networks are tried in numeric order. The generated header is written beside the sketch as StillClock/app_config_private.h and excluded from Git.

Build

& "$env:LOCALAPPDATA\Programs\Arduino IDE\resources\app\lib\backend\resources\arduino-cli.exe" compile --quiet --fqbn m5stack:esp32:m5stack_coreink ".\StillClock"

Runtime behavior

  • Timezone: Brisbane, fixed AEST (UTC+10) with no daylight saving.
  • Display: connected SSID, battery voltage/percentage, HH:MM, date, and chip temperature.
  • Wi-Fi is used for startup NTP/calendar synchronization and a calendar poll every 15 minutes, then remains off.
  • The device uses timer-only M5.Power.lightSleep(..., false) between minute boundaries. Deep sleep is intentionally avoided because waking through setup() reinitializes the panel and causes objectionable flashing.
  • Normal updates use fast partial refreshes and touch only changed rows.
  • A full text-mode refresh occurs at startup and every 180 displayed minutes to control ghosting.
  • Wi-Fi or NTP failures remain visible on the e-ink screen, then the CoreInk powers off to conserve battery. Reset or power it on to retry.
  • Calendar failures replace the event area with a concise error while the clock continues and retries at the next poll.
  • The calendar area shows the active or next event within seven days: relative/start time, two title lines, and location.

About

Clock. Shows upcoming Google calendar event.

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages