Monday, April 22, 2019

Hacking DWex into combo analog-digital clock

DWex, my forgotten watch, was not a successful project, probably because I rushed its design, I spent more money on it than I planned and I did not follow up with revisions. DWex was also not offered as a kit, but as an assembled board with SMD components, not easily hackable or expandable, pretty much a dead end from hardware perspective. Its idea is still sound though, after so many years: mostly sleep, to conserve battery, then, at a press of a button, flicker some LEDs to indicate the time.

This rainy Easter weekend I stumbled upon the few DWex boards I still have, and they brought back memories. One thought lead to another, and I found myself, characteristically (I am the "penny wise, pound foolish"- kind), soldering around once again. So here I am, writing another useless post, about another useless project, on how to convert time, money and energy into joy, sometimes mixed with frustration, when things don't work on the first try (as it's usually the case).

DWex is equivalent to a smaller wsduino (ATmega328 + RTC), with 24 LEDs. Why not recycle it into something physically "bigger", by adding extras (alphanumeric display, micro switches, ESP8266, OLED etc.)?
The design of the DWex board has a few peculiarities:
  • RTC chip is DS1337, with support for alarms;
  • the on-board CR2025 3V battery powers the whole watch, not only the RTC (there is no time keeping without a battery);
  • FTDI connector does not have Vcc wired, relying instead on the battery to power the processor while uploading the sketch;
  • the ATmega328 processor is clocked with an external 8MHz crystal, thus making the board compatible with LilyPad 328;
  • pins available are D11, D12 and D13, all broken out on the ISP connector (unused are also D2 and D10, but they would need to be wired directly from the processor's pins);
  • features only one button.
But the most particular aspect of DWex is the way it shows the time on the analog round face, by blinking LEDs on request (button push). This is actually not suitable for continuous display, simply because it is confusing to make sense of non-stop blinking LEDs.
OK, so enough complaining. Here is what we plan to do:
  • add a 4-digit alphanumeric Adafruit I2C 0.54" display;
  • add ESP8266 module to sync the clock on NTP;
  • add toggle switch for setting up wifi parameters (for ESP8266);
  • use RTC's alarm capability; add toggle switch and buzzer (or other audio module) for alarm mode;
  • add OLED (I2C) for displaying messages, info etc;
  • modify the software, a combination of DWex and WiFiChron, to support all of the above features, plus change the way the time is shown on the analog face (no more sleep, no button press to show the time);
  • add "seconds" mode, on the digital display;
  • maybe adapt the 8-character-based menu system from WiFiChron to 4-character (by showing only the first 1 or 2 letters of the menu);
  • add 3V3/500mA regulator to the board.


This will be a work-in-progress for a while, especially on the software (which I will publish later).

No comments:

Post a Comment