Introduction: INTERFACING AN 8X8 DOT MATRIX LED DISPLAY WITH AN AT89C51 MICROCONTROLLER

Interfacing on a 8x8 dot matrix can be fun and is easy to play with, so let's get straight into it!

Step 1: What You Will Need:

AT89C51 MICRCONTROLLER

8X8 DOT MATRIX

A DEVELOPMENT BOARD OR

DOT MATRIX MODULE

Step 2: Principles You Need to Know

Before getting to interfacing anything you need to have some
background knowledge of how it all works. The dot matrix display has 64 LEDs and evenly grouped into 8 columns and 8 rows.

Looking at the diagram 1, for the LED in column 1, row 1
to be on, there has to be a HIGH (1) sent to Pin 13 and a LOW(0) sent to Pin 9. Similarly, for the LED in column 5, row 7 to be on, a HIGH has to be sent to Pin 6 and a low to Pin 2.

There are many programs online that could help you create the HEX value for the character, number or shape you want to display on the LED Display. Or you can calculate the HEX value by drawing small circles on a piece of paper in the form of an 8x8 dot matrix and then shade the ones you want to turn as shown in diagram 2.

The HEX code to display a “1” is {0x00,0x00,0x80,0xfe,0x84,0x00,0x00,0x00}.
So for this code, take it we start from the bottom right corner, right where it says “column 1, row 1”. For the first two columns the code is 0x00. In the third column, the value is 0x80, which is 1000 0000 in binary. So the first LED in the third column will be on. Then for the fourth column, we have 0xFE so all LEDs will be on except the last one since its binary code is 1111 1110. And in the fifth column we have 0x84,which is 1000 0100. So the first LED in row 1 and the sixth LED will be on. The last three columns will not be on because their respective values are all 0x00.So if you want to display a new character and you want to find out the HEX code for that, you can use this method to derive the HEX code.

Step 3: Time for Some Code

Since I am using a development board, I don’t need to make
any connections. If you don’t have a development board and can’t figure out how to make the connections, try find a Dot Matrix Module, to avoid the that problem. In this tutorial I provide code to display a countdown from 10 to 1 and a “I love u” characters on the display. You should be able to upload your hex code to your microcontroller. If everything goes well you should be able to get a countdown from 9 to 0 for the first code and "I love u" from the second.If your girl is the nerdy type, she will be flattered with the "I love u" display. If she isn't she will still find it cute.

You can also create your own characters and play around with the display. Hope you enjoyed this tutorial and had fun!!!

Comments

author
KoN12 (author)2016-08-19

I love it.

author
taifur (author)2015-10-17

good work

author
LadySith (author)2015-08-31

This is great! Thanks Wilfred.

author
DIY Hacks and How Tos (author)2015-08-30

Nice tutorial. If you have any more pictures, it would really help to illustrate your tutorial.

author

Thanks for the advice

About This Instructable

2,865views

6favorites

License:

More by WilfredM1:INTERFACING AN 8X8 DOT MATRIX LED DISPLAY WITH AN AT89C51 MICROCONTROLLER
Add instructable to: