Go Down

Topic: LED DOT MATRIX 64x16 (Read 62863 times) previous topic - next topic


May 01, 2016, 12:01 pm Last Edit: May 01, 2016, 09:43 pm by Error_400

Does anybody have the functional program for Arduino MEGA created by Petabyte in post #11?

That dropbox file is gone and all other programs are only for Arduino UNO which does nothing on MEGA. There is 2 fails I can see by quick look (#include <pgmspace.h> and const byte data_R2=11;) but I can' find any good solution to make it work.

I'm able to run "rotation" in canton-electronics but it's incredibly slow (0,3s for one scroll) and I can't do any other code in main loop because the display turns off on that other tasks.

;tldr: Is there any solution how to make that UNO program work on MEGA?

EDIT: I did it. Key is correct pin names. For details just take both files and compare them (and remove <Arduino.h> from Eclipse
So, for search engines: 64x16 led matrix display for Arduino Mega 2560


Hi everyone, I have just acquired one of these displays and am using Kaziewicz/canton-electonics code as a starting point for a message board. I have it working but am struggling to understand how the code works. I am stuck on trying to get the full two rows to display the text. I understand that you fill the reserved memory and then the interrupt routine pushes the memory map out to the display. The difficulty I am having is when I add "font = 2" on  line 256 only the top 8 pixels of the 16 pixel high text is displayed on the lower row and nothing is displayed on the top row.

You help appreciated, code attached.


on the line:  drawChar(120,8,message[count%(sizeof(message)-1)],0,false);
Play with the second number "8". use only 0,8,16,32... That is in what Y line you want the text to appear.


Fantastic, just the tip I needed, changing the line as you suggest caused some activity in the right most cell, but it did not scroll. Following this tip lead me to change :

moveLeft(1,0,15);        // column spacing,starting row,?

I changed the 2nd parameter from 8 to 0 to correspond to the change  on the drawchar as you suggested.
It now works beautifully.

Thank You !!

Now on to the next challenge to control the display to display and hold individual lines of text according to an external stimulation ( a push button) and a line break character as the delimiter in the text. Perhaps a comma or other character delimited.


good morning master ...
Can you help me?
how to connect to a 32x32 LED PANEL P10 with 1 control arduino arduino?


Any solution to add emoticons? Regards


Hello everyone,

I have few questions:

1) How to extend the ASCII table to other languages? I don't understand how to translate between the ASCII tables I find on the internet, and the one that appears in the nice code sketch of Kaziewicz and others.

2) How can I simplify the code of Kaziewicz, or complicate the code of cannon to display a constant message, without "running text". I mean that I like the option of just entering the message in the code and it appears "right away".

* Many thanks to all the members of the forum. I don't know would I do without the nice code pieces I find here.


I have partially answered my questions, and want to share with you my findings which I've summarized in the attached pdf, for good Karma:)

"How to control 16x64 led matrix by Arduino code (pixel by pixel) using provided canon code as a starting point". See pdf


Sep 09, 2016, 06:55 pm Last Edit: Sep 12, 2016, 05:13 pm by Sunspot
With the help of all here I have managed to drive the 64x16 display by WIFI from a serial string in a terminal in a Linux box (Raspberry Pi) or Mac OSX.
The Arduino receives serial data and displays 8 characters on the top half as a static display and then a string that scrolls along the bottom half.
This can be fed from a serial program but I now use and ESP8266 to receive the data by WIFI from a box on my LAN.

This is very crude since I program by copy - paste - pray. (Thanks!)

EDIT - now multimode
Two lines of fixed 8x8 characters
Top line of fixed 8x8 characters - bottom line scrolling
One line of scrolling 16x8 characters
One line of fixed 16x8 characters

Download from here http://www.sunspot.co.uk/Projects/displays/LEDmatrix16x64/LEDmatrix16x64.html

I hope to add a graph using the draw rectangle code.


I wonder if there is any way to reduce the screen brightness for night use?
I see nothing in the code about changing the pulse width.

If you improve my "lesson one" code (link above) please comment here.


I wonder if there is any way to reduce the screen brightness for night use?
Yes, that should be perfectly possible by controlling the % of time that the ENable pin is high.


Sep 14, 2016, 09:42 pm Last Edit: Sep 15, 2016, 09:56 am by Sunspot
Glad you think it possible - thanks - but interrupt timers are new to me....
I see lines like digitalWrite(en_74138, HIGH); but see no obvious delay statement before a digitalWrite(en_74138, LOW);
I am wondering if the prescaler is the variable to modify?

I aim to have the Arduino read a pot on the analog pin then change the brightness - or perhaps use an ambient light detector.

These display are very good value and almost do the job.

However I have recently noticed these -

which are RGB and about the same cost per pixel as the red one we are playing with-

And I think they can run the Adafruit sketches judging by the pictures the advert displays

(paste the URL please the edit keeps failing)


Sep 15, 2016, 04:30 pm Last Edit: Sep 15, 2016, 04:44 pm by PaulRB


Pasting links seems to be working fine for me, and I'm using an android phone! So please try harder.

To dim your display, there will have to be some significant code changes. Currently, the interrupt occurs one per scan row. To dim, two interrupts per scan row will be needed. One to send out the new data and switch on the display, and the second to simply switch off the display. The gap between these two interrupts will determine the brightness. If the gap is short, the display will be dim. If it is almost the full length of the scan period, the display will be bright.

Your code is not easy to read. It's not indented and the lines wrap, so it looks a mess. But even so, something about it seems odd to me. I don't understand what pin R2 is for, and I wonder if it is in fact not needed for your display. Maybe your code was written for a bi-colour display?


The code by Phil Kaziewicz was posted earlier on this thread - I added the serial input.
Perhaps he should try harder.


Sep 16, 2016, 08:13 am Last Edit: Sep 16, 2016, 08:14 am by PaulRB
Oh yes, he gave the sketch in this post. It is formatted, perhaps you lost it when you copy+pasted it. You just need to use AutoFormat from the Tools menu.

His code has a comment at the top which says it drives a 64x32 display, twice the size of yours. That explains what the R2 pin is for: he other half of a larger display.

When I said "try harder", I was just referring to posting links.

Go Up