View previous topic :: View next topic |
Author |
Message |
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Wed Dec 01, 2021 8:11 pm Post subject: LCD problem |
|
|
Hello to all.
I can't get a 20 x 4 lcd with SPLC780D1 controller to work.
I'm afraid the controller is not fully compatible with the HD44780.
Has anyone tried using a similar display?
Do I have any hope of making it work?
Thanks in advance
Pier
(BASCOM-AVR version : 2.0.8.4 ) |
|
Back to top |
|
|
Evert :-)
Joined: 18 Feb 2005 Posts: 2156
|
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Thu Dec 02, 2021 1:55 pm Post subject: |
|
|
Unfortunately the jtag seems to be excluded from the possible causes because it seems to me that Arduino Uno does not support the Jtag and I am using an Arduino Uno. |
|
Back to top |
|
|
Duval JP
Joined: 22 Jun 2004 Posts: 1161 Location: France
|
Posted: Thu Dec 02, 2021 6:40 pm Post subject: |
|
|
with arduino uno (atmega328) in fact you don't have JTAG. the remark was made because with some other ATMEGA 32, 644 and so on for example if you don't disable the JTAG you can't use some ports : PC2-PC5 port as I/O
so forget it
JP _________________ pleasure to learn, to teach, to create |
|
Back to top |
|
|
Evert :-)
Joined: 18 Feb 2005 Posts: 2156
|
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
|
Back to top |
|
|
MWS
Joined: 22 Aug 2009 Posts: 2262
|
Posted: Fri Dec 03, 2021 1:58 pm Post subject: |
|
|
Try with a INITLCD and make sure in case ISP is used, that the ISP-cable is disconnected from the controller while running. |
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Fri Dec 03, 2021 2:33 pm Post subject: |
|
|
Unfortunately I have already tried with INITLCD also inserting immediately after a delay of 200msec without success. The result does not change (only a series of dark rectangles if I put the contrast to the maximum). For programming I use the USB connection that the Arduino UNO board is equipped with, therefore no ISP |
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Fri Dec 03, 2021 2:34 pm Post subject: |
|
|
The board and connections is ok |
|
Back to top |
|
|
MWS
Joined: 22 Aug 2009 Posts: 2262
|
Posted: Fri Dec 03, 2021 3:49 pm Post subject: |
|
|
4 lines? Looking up the SPLC780D1's data sheet there aren't any applications with 4 lines described.
Your display isn't by chance one where two of SPLC780D1 cooperate?
One E or E and E1? |
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
|
Back to top |
|
|
Duval JP
Joined: 22 Jun 2004 Posts: 1161 Location: France
|
Posted: Fri Dec 03, 2021 5:22 pm Post subject: |
|
|
This prog works with atmega 8 to atmega328
Code: |
$regfile = "M168def.dat"
$crystal = 11052000
$hwstack = 32
$swstack = 32
$framesize = 32
Config Lcdmode = Port
Config Lcdpin = Pin , Db4 = Portb.2 , Db5 = Portb.3 , Db6 = Portb.4 , Db7 = Portb.5 , E = Portb.1 , Rs = Portb.0
Config Lcd = 20 * 4
Cls
Wait 1
Locate 1 , 1 : Lcd "123456789A123456789A"
Locate 2 , 1 : Lcd "123456789B123456789B"
Locate 3 , 1 : Lcd "123456789C123456789C"
Locate 4 , 1 : Lcd "123456789D123456789D"
|
I use it on my test board since years.... _________________ pleasure to learn, to teach, to create |
|
Back to top |
|
|
MWS
Joined: 22 Aug 2009 Posts: 2262
|
Posted: Fri Dec 03, 2021 5:56 pm Post subject: Re: LCD problem |
|
|
pierscintilla wrote: | I can't get a 20 x 4 lcd with SPLC780D1 controller to work. |
In the ad it's a HD44780, which is something a standard device for Bascom.
Before trying by error, I would write a short code to count up a byte on the port, to see whether every pin works.
If everything is ok, you can try to use lcd4busy_anypin.LiB, but you need to connect the RW pin too. |
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Sun Dec 05, 2021 9:50 am Post subject: |
|
|
Changed Arduino board and changed LCD (always the same type as the non-working one). Nothing. The result is always unchanged (black squares if I put the contrast to the maximum). Evidently the problem is the controller not totally compatible with the HD44780 even though the contrary is stated. I think I'll change LCD !! |
|
Back to top |
|
|
pierscintilla
Joined: 08 Aug 2005 Posts: 54 Location: italy
|
Posted: Sun Dec 05, 2021 2:26 pm Post subject: |
|
|
Solved. I humbly apologize. My problem was due to an incorrect potential on the contrast control that I put to GND or VDD. Not having a potentiometer available, it was difficult for me to test but the problem was there. |
|
Back to top |
|
|
|