ST7066U requires double-init sequence?

Quazar

New member
Hello,

I've got a project using an CFAH1602D-YYH-ET with the ST7066U controller.
It is driven in 4-bit parallel mode from a PIC18F microcontroller running at 5V.

I have it working and displaying OK, but have to run the init sequence twice to get it going.
I am religiously following the init sequence as described on 25/42 of the v2.1 spec sheet.
All my delays are at least 1.5x the required minimum.
I've verified the sequence using a logic analyzer, and all the bit states and timing are as expected.

I can live with running the init sequence twice, but I'd like to understand what I'm doing wrong, since I want my project to be completely reliable.

A few questions/thoughts

  1. Is there any errata to the spec sheet (I'm using the v2.1 spec sheet from this page).
  2. I am using the indicated delays rather than checking the Busy Flag. Perhaps I need to do both?
  3. I'm confused by the comments in the spec that state you must wait at least 80uS before checking the BF. That seems odd, since most commands are spec'd to take only 37uS. Is the BF only useful for the Clear & Home commands that can take 1.52mS?
  4. Is there an additional delay (beyond 37uS) needed after the last step of the init sequence? I assume not, since after the "Function Set" part of the init sequence, the rest appear to be regular commands.
  5. I've left DB0-DB3 floating. Do they need to be tied high or low for reliable operation, or is floating OK?

Thanks,
- Dean
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
 
Last edited:

CF Support2

Administrator
1 - As far as we are aware, there is is no errata for the ST7066U controller.
2 - We rarely use the busy flag and just use delays, so this should not be a probelm at all.
3 - Some functions just take longer. Part of being compatible with the HD44780 (e.g. slow)
4 - It can't hurt with a character LCD controller to put in a bit more delay.
5 - You should be fine leaving them floating. When we've worked with 4 bit mode, that's what we have done.

If you could post your init code - that would help us out to see where we can help you out better!
 

Quazar

New member
Thanks for the reply - I really appreciate you double-checking my assumptions.
I'm going to run a few more experiments and I'll post my code if I still haven't worked it out.

Thanks,
- Dean
 

Quazar

New member
I found the problem, though it took a bit of experimenting: My supply voltage was out of spec.

I was powering the display and the microcontroller from a PICKit3, which got its power from USB. The final voltage at the Vdd pin of the display was around 4.45V. The thing that got me thinking along these lines was when I noticed it was slightly more reliable with the backlight off.

After switching to an independent 5V supply, it comes up and works reliably with a single init sequence.

Thanks for the information and advice,
- Dean
 
Top