Introduction: Analog Clock With LED Matrix and Arduino

Picture of Analog Clock With LED Matrix and Arduino

LED matrix with MAX7219 are very versatile and can be used in several projects with Arduino.

In this case, I used it to simulate an analog clock without its hands with very interesting results.

The hours and minutes are placed around the center of matrix giving a familiar look of analogs clocks.

The code I have developed applies a little of trigonometry (sine and cosine) to calculate the coordinates of hours and minutes to be shown into LED matrix.

With that I saved many lines of coding.

The assembly is very simple using few components and you will have no problems to work on it.

Let's do it !!

LAGSILVA

** See Video clicking here **

Step 1: Material List

Picture of Material List

The material you need is shown in the following list:

- Arduino UNO R3

- Module of LED Matrix with MAX7219 (Maxim Integrated)

- Tactile Push Buttons (02 x)

- Breadboard (small size)

- Jumper Wires

- Paper template to cover the LED Matrix (see attached file for printing)

Note:

This project uses the Arduino internal clock. It is not so accurate as an external RTC (Real Time Clock), but for the purposes of this project, it works very well.

Step 2: Schematic

Picture of Schematic

The schematic is attached and you should follow it closely to the jumpers connections.

Step 3: Code

The Arduino code is shown in attached file.

The code uses the libraries LedControl and Time.

Fast Tip: You can find many libraries for Arduino at Arduino Library List: http://www.arduinolibraries.info/

Step 4: Setup

Picture of Setup

After start the default time shown is 00:00 hs.

For adjustments there are only two tactile buttons to perform the setup of time:

1- Setup of Hours

2- Setup of Minutes

Just keep it pressed for adjustments.

The hours are shown in the display by numbers between 1 and 12. The minutes are shown by numbers between 0 and 55 in steps of 5 minutes.

In the last column of display is shown the fractional minutes from 1 to 4 that must be added to the minutes shown in the main template of clock.

In the middle of display there is a LED blinking each second and there are also two LEDs for AM and PM indication.

Comments

ravijag (author)2017-09-15

Liked the novel way of using matrix and geometry to display time :)

Kudos!

lagsilva (author)ravijag2017-09-15

Thanks!! :)

Eric Brouwer (author)2017-07-29

This looks nice. Thanks for sharing.

lagsilva (author)Eric Brouwer2017-07-29

Thank you!

About This Instructable

760views

30favorites

License:

Bio: I am a Mechanical Engineer and an enthusiastic Maker. I like to develop new ideas combining electronics and programming.
More by lagsilva:Digital Clock With Mirrored Display Driven by AccelerometersAnalog Clock With LED Matrix and ArduinoChinese Rings Puzzle
Add instructable to: