Live data from Hacker News

Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

github.com

61–70 of 202 posts

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#61
post #14

How does this keep track with DST? Looking at the code [1], it looks like if the actual time is 1 hour ahead of the displayed time, then we get 10 pulses per second to leap forward. Otherwise, the clock stops running for an hour to fall back. https://github.com/jim11662418/ESP8266_WiFi_Analog_Clock/blo...

Yeah, project needs a time-lapse video of their analogue DST transition event.

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#63
post #32

Earlier quoted context omitted.

That's assuming you don't like hacking and would pay to not have to do it, which is generally not the case around here.

I’m think you can go further than that. Days spent modifying cheap electronics is absolutely encouraged.

Cheap electronics are just the feed stock, the basis function for your new creation. Why start with raw matter when you can get fully formed matter for less.

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#64
post #24

Earlier quoted context omitted.

> Early clock - keeps time anywhere between 0 and 10 minutes fast. For those who like to set their watch ahead to avoid being late. This clock keeps you from trying to "compensate," because you never know how early it is at the moment. That's pretty genius for many ADHD-type folks. Only problem is a modern household has many clocks in view, so you'd need to commit to just not setting them.

Oh now that would be a fun version 2 challenge: have all the clocks in one household synchronize such that they're all early by the same amount at any given time. Easy enough for wifi enabled ones: a UDP broadcast to discover other clocks on the network, then sync how you will. For non-wifi-enabled clocks, perhaps something like a CH572 would do the trick: a $0.20 RISC-V microcontroller with BLE support that all the…

You don't already do this with the NTP servers under your control?

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#65
post #5

Cool project! The most interesting part, IMO, is the "SRAM with EEPROM backup" chip. It allows you to persistently save the clock hands' positions every time they're moved, without burning through the limited write endurance of a plain old EEPROM. And it costs less than $1 in single quantities. That's a useful product to know about.

That's really neat. TIL.

So the way this works seems to be this: It's an SRAM and an EEPROM in one little package along with a controller that talks with each, with a little capacitor (this clock uses 4.7uf) placed nearby.

The SRAM part does all of the normal SRAM stuff: It doesn't wear out from reading/writing, and as long as it has power it retains the data it holds.

The EEPROM does all the normal EEPROM stuff: It stores data forever (on the timescale of an individual human, anyway), but has somewhat-limited write cycles.

The controller: When it detects a low voltage, it goes "oh shit!" and immediately dumps the contents of the SRAM into EEPROM. This saves on EEPROM write cycles: If there are no power events, the EEPROM is never written at all.

Meanwhile, the capacitor: It provides the power for the chip to perform this EEPROM write when an "oh shit!" event occurs.

When power comes back, the EEPROM's data is copied back to SRAM.

---

Downsides? This 47L04 only holds 4 kilobits. Upsides? For hobbyist projects and limited production runs, spending $1 to solve a problem is ~nothing. :)

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#66

I want to see someone convert one of those cheap projection clocks like this: https://www.homedepot.com/p/La-Crosse-Technology-5-in-Color-... The red projection is just the right brightness (at night) but it sucks that it's not wifi-enabled so you can't just get it to NTP sync (or hook up a GPS receiver). The projector part of the clock is a separate device that's attached to it via a ribbon cable. I would reverse en…

Depending on how dark your room is you might get by with an ordinary but bright LCD screen and a camera lens. There's a pretty common 240x240px, 1-inch square TFT display on amazon or other usual places you might start with.

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#67

What I really want is one of these powered by gps. The time already comes for free in the signal, and from your location you can derive the time zone. That way DST is accounted for automatically, but you don't have to set up and rely on wifi. This would be truly zero-config and always correct.

You would still need some kind of configuration because the start of DST can change year to year, and this is not accounted for in the time signal from GPS

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#68

Sorry if this is a dumb question, but do you guys not have radio controlled clocks outside of Europe? If I got it right, the only purpose of this project is to always display the correct time. Radio controlled clocks do exactly that. They are cheaper than the one ESP board, and run years on a single AA battery. No WiFi, tinkering, setup, or cables necessary

Googled "radio controlled clock" and seeing results from $20-$200, lots of inconsistency in what the product is.

These are usually marketed as "atomic time" or "atomic clock" here in the US.

Re: Converting a $3.88 analog clock from Walmart into a ESP8266-based Wi-Fi clock

#70
post #64

Earlier quoted context omitted.

Oh now that would be a fun version 2 challenge: have all the clocks in one household synchronize such that they're all early by the same amount at any given time. Easy enough for wifi enabled ones: a UDP broadcast to discover other clocks on the network, then sync how you will. For non-wifi-enabled clocks, perhaps something like a CH572 would do the trick: a $0.20 RISC-V microcontroller with BLE support that all the…

You don't already do this with the NTP servers under your control?

If I had any NTP servers under my control, I probably would :)
Post reply on HN