The controller is based on PIC18F2525, and the timebase is GPS signal received via Quectel's L50 or L80. Both modules have built-in 1.575 GHz antennas. Data transfer between GPS module and the microcontroller is asynchronous serial, 4800 baud. Real time is extracted from GPRMC or GPGGA data packets. Data transfer from MCU to GPS module is not used in this version of firmware.
L50 uses 1.8 V supply, and L80 uses 3.3 V. This should be kept in mind when selecting LDO voltage regulator. Resistors which are used as level shifters should also be calculated.
Seven segment LED displays are not used in multiplex mode, as the SCT2024 is so cheap ($0.3) that it doesn't pay off, at least for a single unit or for very small series. Resistor Rext (4K7) is used to adjust LED display brightness. In this case, it is even outside the catalogue data (sholud be 560-3K9), but the current regulators still works fine, even with much higher resistor values.
Phototransistor is used as light sensor, and the ADC value is directly transfered to PWM module, which controls Output Enable inputs of SCT2024 shift registers. So the automatic brightness control is obtained in the wide range of ambient light conditions.
There is a small speaker, used as the alarm tone output. Driver 4426 is used as an amplifier, and two 1N4148 diodes serve as the noise supressors. Without those diodes, there would be a silent, but constant digital noise in the speaker.
Dynamite is usually packed in cardboard cylinders, about 20 cm (8") long and 32 mm (1.25") in diameter, in yellow, orange or red colour. The best fit which I could get was the plastic plumbing pipe 32 mm in diameter, which I cut in 20 cm pieces and covered with red heat shrink tubes. Two flat walls were cut from the gray plastic sheet, and the detonators were simulated by M3 spacers, coated by yellow heat shrink tubes. Several M3 screws keep all that together, and this makes a fine look, byt yet similar to the original explosive pack.
At this moment, there is only the basic firmware, which supports GPS timing (attached in Files). In the next step, I shall add the alarm clock function, keyboard and speaker support, and the whole scenario which supports the whole defusing scenario - alarm should cause speaker ticking, coloured LED blinking, and the timer countdown. To stop the alarm, user should type the correct code, and/or current time, or to solve some mathematical problem which is printed on the 7-segment displays, or something like that. If he fails to do so, the alarm will be truly loud.
The final look
My first idea was to make the flat side walls (which fit in plumbing tubes) of transparent acryl, to let everybody see that the cylinders are empty. At last I decided to use the opaque gray plastic walls, so the effect is somehow frightening. When my friends see the clock, they mostly like it, but some of them say that they would not dare to sleep in the same room with it.
Honestly speaking, this clock was not made to look like the real bomb, but to look like something what we see in Hollywood movies. And that is not how the real bomb looks - the real terrorist would never build the atractive bomb, with large LED displays (too high current consumption) and with no battery (how to supply it, from the AC outlet?). But it really doesn't matter, if we made something which looks like the bomb, only the expert would be frightened, and the most people would not even notice it.