Melancholy13
New member
Display: CFAH1604B-TMI-ET
MCU : PIC18F452
Clock : 25Mhz
Intro:
I'm working on a hardware project, and wanted to try using an LCD for outputting information. As such I chose the above mentioned character display. This is my first time trying to interface with a display of any type other than simple LEDs so I apologize in advance if my problem is a simple one.
I have attached both a hardware schematic of my current PIC-to-LCD configuration, as well as my .c file that I am using to try and initialize and output to the screen. I have created the following functions in my code:
LCDCharacterInitialize(void) --LCD initialization function
ICommandThee(unsigned int) --Write command function
SpitItOut(unsigned int) --Display character string function
DummyHalt(void) --Dummy loop used to halt the program for debugging
A few additional details on each of the functions are available in my code file attached.
Problem:
It does not appear that the screen is initializing. When I turn the circuit on, the screen lights up and I can see two lines of squares. I can adjust the intensity of both the squares and the backlight using the attached trimpots. I am using the Delay.h file supplied in MPlab to generate my delay times needed. I am pretty sure that I have calculated out my delay times properly, but am not 100% sure anymore since I am not getting any type of an output on the display.
I have tested the PIC18F452 separate from the LCD to ensure that it is functioning. This test included using a pair of LEDs and jumpering them to various ports on the PIC (i.e. RC0-RC7, RD0-RD7, etc.) I did not check every port to make sure it was functional, but I did test a few, just to make sure that the PIC was indeed functioning.
I am out of ideas as what to test, or look at and am hoping for some input as to things to try. I am sure it is just some little thing that I am missing, but I am at my wits end as to what it is.
Thanks in advance to any who may reply.
MCU : PIC18F452
Clock : 25Mhz
Intro:
I'm working on a hardware project, and wanted to try using an LCD for outputting information. As such I chose the above mentioned character display. This is my first time trying to interface with a display of any type other than simple LEDs so I apologize in advance if my problem is a simple one.
I have attached both a hardware schematic of my current PIC-to-LCD configuration, as well as my .c file that I am using to try and initialize and output to the screen. I have created the following functions in my code:
LCDCharacterInitialize(void) --LCD initialization function
ICommandThee(unsigned int) --Write command function
SpitItOut(unsigned int) --Display character string function
DummyHalt(void) --Dummy loop used to halt the program for debugging
A few additional details on each of the functions are available in my code file attached.
Problem:
It does not appear that the screen is initializing. When I turn the circuit on, the screen lights up and I can see two lines of squares. I can adjust the intensity of both the squares and the backlight using the attached trimpots. I am using the Delay.h file supplied in MPlab to generate my delay times needed. I am pretty sure that I have calculated out my delay times properly, but am not 100% sure anymore since I am not getting any type of an output on the display.
I have tested the PIC18F452 separate from the LCD to ensure that it is functioning. This test included using a pair of LEDs and jumpering them to various ports on the PIC (i.e. RC0-RC7, RD0-RD7, etc.) I did not check every port to make sure it was functional, but I did test a few, just to make sure that the PIC was indeed functioning.
I am out of ideas as what to test, or look at and am hoping for some input as to things to try. I am sure it is just some little thing that I am missing, but I am at my wits end as to what it is.
Thanks in advance to any who may reply.
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
Attachments
-
205.2 KB Views: 623
-
4.6 KB Views: 494