Designed as a mixture of "mantel clock" and "bakelite radio" ("bakelite", what's that?) styling, "3D Printed Mantel Style Clock" is an analog clock featuring electronic chimes, hourly NTP time synchronization over wifi, daylight savings time (optional) and battery backup (also optional).
Video of the clock is here: https://www.youtube.com/watch?v=FzkRTk0Pcbo.
The clock incorporates an Adafruit Feather ESP32 for time keeping, an Adafruit Feather Music Maker driving twin 1.5 inch speakers for chimes, and a stepper motor / stepper motor controller driving a 3 gear gear train for displaying time in hours and minutes using analog clock hands.
The clock software uses two cpu cores in the ESP32. The setup and loop functions execute in core 1, with the tasks for clock homing, clock hand updating, mp3 startup and mp3 playback executing in both core 0 and core 1. Using this architecture along with a 1hz ESP32 interrupt, the clock timekeeping and display updating occur simultaneously with clock audio.
The clock remains "calibrated" by synchronizing once per hour with an NTP time server. If power is lost, the optional battery backup will keep the clock running during short power outages. If the optional battery backup is not used, when wifi becomes available and power is restored the clock will return to the correct time.
The clock chimes, stored as individual mp3 files on a micro SD card inserted into the music maker, were inspired by an antique clock my wife inherited from her father after his passing, in that I attempted to reproduce the mechanical sounds created by the clock into the mp3 chimes. Based on the time of day, the clock software transfers one of the mp3 files to the music maker via an ESP32 SPI bus. Since each of the chimes (top, quarter, half and three quarter hour, plus the twelve hour count chimes) reside on the micro SD as individual mp3 files, you may load whatever mp3 file desired for the chimes.
The clock daylight savings time feature is optional and is set up at compile time. When enabled, on the user programmable daylight savings time start month and day (either the second Sunday or a specific day of the month) and hour, the clock will wind forward one hour. And on the user programmable daylight savings time end month and day (either the first Sunday or a specific day of the month) and hour, the clock will wind backward one hour.
As usual, I probably forgot a file or two or who knows what else, so if you have any questions, please do not hesitate to point them out as I do make mistakes in plenty.
Designed using Autodesk Fusion 360, sliced using Cura 3.5.1, and printed in PLA on an Ultimaker 2+ Extended and an Ultimaker 3 Extended.