Simple Keys and LCD Interfacing 8051

Simple Keys and LCD Interfacing 8051:

Interfacing Diagram :

Interfacing with 8051

In this project we connected the lcd data lines to PORT2 Of 89c51

Controll Pins Connections:
  • P1.0 - Rs
  • P1.1 - Rw
  • P1.2 - En
  • P3.0 - Up
  • P3.1 - Down
  • P3.2 - Left
  • P3.4 - Right
Switches connection:
Description:
                Lcd is connected to Port2 an Port1 pins for our convenience and switches are connected to Port3 pins. when the program compiled the main function will be called and through main function we can call othe sub functions so that we added all sub functions into single include file called "conditions.h" and that file will be included in the project and we can use the functions defined in that include file.

Main.c

When main menu is executed the content in data_write(); will be displayed, after that the while(1); loop will executed i.e the code will be executed forever. then the delay(); function will be called so that we can view the initial data for some time and the preceding codes will be executed.
Menu function
In menu function we have some content to display as menu:
  1. one
  2. two
  3. three
  4. four
etc..

 In this example we just use the all four Push buttons to affect some action. and those actions are decided by us by this simple concept we can able to display any contents as we wish, The main thing is we should think out of box.
Left right keys
In this function we have two navigation keys to perform some task, in this program i just used those keys to display some text. by this way you can configure this depending upon your applications.

Please comment your doubts and reviews

To Download Codes And Simulation Click Here



               

Comments

Popular Posts