This clock had many iterations. At first i tried using 50 HZ AC line as a reference but it was going slower. I tried using the micro-controller quartz but was terrible. So i used a dedicated real time clock IC that has an integrated oscillator, very precise and temperature compensated . Three rechargeable NI-CD batteries hold the clock in case of black out. The AC line power supply is needed as the stepper motors would quickly run out the batteries. If the clock is moving during a black out the micro-controller drives the stepping motors when the power is restored.
When the reset button is pressed starts a procedure to set the positions of each number that indicates the hours on the painting (can be in any position and any order), the lowest and highest position of the minutes scale (can be inverted) and the current time. The microcontroller is a PIC16F883, and uses a DS3231 as real time clock. The geared stepper motor used are the ones that move the fin in the AC conditioners.