Society of Robots - Robot Forum

Electronics => Electronics => Topic started by: knossos on October 19, 2011, 06:50:30 AM

Title: LCD Display: Problem using WebbotLib with 8 bit I/O
Post by: knossos on October 19, 2011, 06:50:30 AM
I am having trouble getting my LCD Display to work in 8 bit IO using WebbotLib. 

I am using an Axon II and a HD44780 and a 6V regulated power supply (see below for all related links). I am using current versions of Project Designer to lay out the project.  I have tried using Webbotlib v1 and v2 with C only and with C++.

I have no trouble getting 4 bit IO mode to work with my LCD display, although I have to tie the R/W pin to ground or I have problems with the output flickering.

When I duplicate the project with 8 bit IO mode, I get no output at all.  I have double checked all my wiring and the only difference is the 4 additional data lines (have tried with the R/W pin tied to ground and tied to the Axon).  The code is virtually unchanged between the two (minus the background changes made by Project Designer and the different versions of WebbotLib).

I would appreciate any suggestions.

Related Links:
Axon II (http://www.societyofrobots.com/axon2/)
HD44780 - 20x4 Character LCD Display (http://www.adafruit.com/products/198)
Adjustable Breadboard Power Supply (https://www.adafruit.com/products/184)
WebbotLib (http://webbot.org.uk/iPoint/30.page)
Project Designer (http://webbot.org.uk/iPoint/37.page)
Title: Re: LCD Display: Problem using WebbotLib with 8 bit I/O
Post by: Webbot on October 19, 2011, 11:46:53 AM
something spooky ! Am having a look
Title: Re: LCD Display: Problem using WebbotLib with 8 bit I/O
Post by: Webbot on October 20, 2011, 07:17:51 AM
Ok found and fixed the problem.

If you send me a Personal Message then I'll email you a replacement webbotlib library if you cannot wait until the next release.
Title: Re: LCD Display: Problem using WebbotLib with 8 bit I/O
Post by: knossos on October 20, 2011, 09:02:49 AM
Thanks a lot!  I'll probably just wait till next release, I have no real need for the 8-bit, was just using it since I had never tried it before :)
Title: Re: LCD Display: Problem using WebbotLib with 8 bit I/O
Post by: Webbot on October 20, 2011, 09:36:20 AM
I have no real need for the 8-bit, was just using it since I had never tried it before :)
Yep - think thats why the issue went un-noticed. After all - why use 8 wires when you can just use 4  :D

Also I was interested in your 'display flickering' problem as I don't get that. WebbotLib uses the R/W wire to poll the device so that it doesn't send new commands when the display is busy processing the old one. By tying it to ground you are stopping it from doing that. I think more recent displays are fast enough that it probably makes no difference. But I was wondering why you experience flickering. Are you continually writing stuff to the display ie lines of text with a CR/LF on the end so that it scrolls - if so then that 'may' be the issue since the displays themselves don't support it - but WebbotLib simulates it for you by redrawing the screen contents so that it looks like it has scrolled. So if you are writing out a lot of stuff and scrolling the screen constantly then the 'flicker' may be caused by constantly redrawing the screen.