32 7-Segment Digital Desk Clock

32 : 7-Segment Digital Desk Clock

Design render

How it works

Simple digital clock, displays hours, minutes, and seconds in either a 24h format. Since there are not enough output pins to directly drive a 6x 7-segment displays, the data is shifted out over SPI to a MAX7219 in 7-segment mode. The time can be set using the hours_set and minutes_set inputs. If set_fast is high, then the the hours or minutes will be incremented at a rate of 5Hz, otherwise it will be set at a rate of 2Hz. Note that when setting either the minutes, rolling-over will not affect the hours setting. If both hours_set and minutes_set are presssed at the same time the seconds will be cleared to zero.

A block diagram of the system is shown below.

How to test

Apply a 5MHz clock to the clock pin and 32.786Khz signal to the refclk pin. Use the hours_set and minutes_set pins to set the time.

External hardware

Connect the BIDIR PMOD to a MAX7219 7-segment display, For reference Tiny Tapeout SPI

IO

#InputOutputBidirectional
0refclkDisplay CS
1Display MOSI
2Fast/Slow Set
3Set HoursDisplay SCK
4Set Minutes
512-Hour Mode
6
7

Chip location

Controller Mux Mux Mux Mux Mux Mux Mux Mux tt_um_chip_rom (Chip ROM) tt_um_factory_test (Tiny Tapeout Factory Test) tt_um_htfab_r2r_dac (R-2R DAC) tt_um_algofoogle_antonalog (Antonalog analog VGA) tt_um_NicklausThompson_555_1x1 (HBT Comparator) tt_um_urish_dickson_pump (Dickson Charge Pump) tt_um_htfab_yadge (Yet Another Diffraction Grating Experiment) tt_um_colorful_stripes (Colorful stripes) tt_um_rte_eink_driver (E-ink display driver) tt_um_bleeptrack_prism (Prism) tt_um_calonso88_spi_test (SPI test) tt_um_sathworld_spi_pwm_peripheral (SPI-connected PWM generator) tt_um_lfsr_stevej (Linear Feedback Shift Register) tt_um_strau0106_simple_viii (simple-viii) tt_um_algofoogle_ro_worker (Ring Oscillator Worker) tt_um_vga_clock (VGA clock) tt_um_a1k0n_demo (Demo by a1k0n) tt_um_algofoogle_fun_vga_clock (Fun VGA Clock) tt_um_digital_clock_example (7-Segment Digital Desk Clock) tt_um_urish_simon (Simon Says memory game) tt_um_ihp_logo_screensaver (VGA Screensaver with the IHP Logo) tt_um_zerotoasic_logo_screensaver (VGA Screensaver with Zero to ASIC Logo) tt_um_arud4172_ROOTS_vga (ROOTS logo vga) Available