December 26, 2011

Creating Characters on Dot matrix display (Proteus Simulation)

In earlier post we have seen how to make a single LED,a Row  or a Column ON. But that's not enough when we want to generate a character like 'K' on a display so what we have to do for that?


Here comes a principle from physics called "Perception of eye" I hope all have studied about that in high school so not discussing more about that in detail just keep in mind that if we constantly change our ON LED we can make an image like any character on human eye.



so

 +

 +

 +

 +


  =

alphanumeric character in dot matrix display
alphanumeric character on dot matrix


this is the magic of perception of eye principle if you will repeat above 5 images at enough faster rate you will be able to see a  'K ' character.



Doing this with microcontroller is damn easy thing.

just try following code in your AVR 8535 microcontroller to see the character being displayed.


//program to display K on dot matrix display

#include"avr/io.h"
#include "delay.h"


void main(void)
 {  
    DDRA=0xFF;            // Port A data direction declaration as out put.
    DDRC=0xFF;          
// Port C data direction declaration as out put.
    while(1)      
    {
    PORTA=0b00000001;            //column 1
    PORTC=0b10000000;          
    delayms(1);
    PORTA=0b00000010;            //column 2
    PORTC=0b11110111;
    delayms(1);
    PORTA=0b00000100;            //column 3
    PORTC=0b11101011;
    delayms(1);
    PORTA=0b00001000;            //column 4
    PORTC=0b11011101;
    delayms(1);
    PORTA=0b00010000;            //column 3
    PORTC=0b10111110;
    delayms(1);
    delayms(1000);
    }
  
}

the circuit diagram for above program is given below...


with this all you can make all your  characters and display them on dot matrix display.


Once you are through with all your characters making you can group them in a standard header file to use later.you can read my earlier post  "how to make a header file?" for the help.

this is good if you want to display something on a single block of dot matrix display but what if you want to display a message such as "KEYUR" on a series of blocks????

1    2      3

2 comments:

Post a Comment

Related Posts Plugin for WordPress, Blogger...