We are running a survey to help us improve the experience for all of our members. If you see the survey appear, please take the time to tell us about your experience if you can.
this is my lcd code for sending aletter . but iam not getting data on display can any one tell what is the problem with this code.
#include <AT89X51.H> #include<stdio.h> void delay(unsigned int d); void display(unsigned char a); void initial(unsigned char b); unsigned int d; unsigned char a; unsigned char b; unsigned int j; unsigned int i; void main() { initial(0X38); delay(50); initial(0X0f); delay(50); initial(0X01); delay(250); initial(0X06); delay(50); initial(0X80); delay(150); while(1) { display('a'); delay(150); } } void delay(unsigned int d) { for(i=0;i<=d;i++) for(j=0;i<=1275;j++); } void display(unsigned char a) { P1=a; P0_5=1; P0_6=0; P0_4=1; delay(10); P0_4=0; } void initial(unsigned char b) { P1=b; P0_5=0; P0_6=0; P0_4=1; delay(10); P0_4=0; }
.
http://www.keil.com/forum/docs/thread10353.asp