The best mode to drive an LCD Display to get noise immunity

Thread Starter

Matheus Soares

Joined Oct 26, 2016
2
Hello guys!

Which one of these modes is the best for get noise immunity when driving a LCD Display 16x02? (or 16x04 etc.)

-I2C module using PCF8574 I/O expansion.
-8 bit Parallel
-4 bit Parallel

I had a PCB which drives an LCD Display 16x02 and drives 4 dc motors (80mA each - no load). When a used to use this pcb I got some problems with noise from the motors and sometimes I got strange characters printed by LCD. I used to use Parallel 4 bit mode. But now I'm designing a new PCB which will drive 4 motors with H-Bridge and 1 LCD Display 16x02 and will have 2 UART and 1 I2C communications using a PIC16F1947 MCU.

I'm going to be sure for have a great ground plane on my PCB (4 layers) and I'm going to increase noise protection too.

Should I still using 4 bit Parallel mode and do something to decrease the noise? Should I change for 8 bit Parallel mode? or Doesn't it make sense? Should I change to use I2C module? I know I2C is for communications between ICs in the same PCB but I think Could be better because 2 wires is less than 8 wires so Could be more difficult to get noise using i2c mode.

The distance between the pcb and the LCD Display is like 20 cm. Should I do somethings on the cables? Like Twist the cables?
I would like to get a project with good noise immunity so I would like to know witch one is the best way to drive the LCD.

I think could be good for all of us know the safest way to drive an LCD Display.

Sorry for my bad English.
 

MrChips

Joined Oct 2, 2009
30,708
Your problem lies not in the modes but in the 20cm cable.
You have to reduce the length of the cable to less than 4cm. Can you do that?
 

jpanhalt

Joined Jan 18, 2008
11,087
For one byte of data, 4-bit mode requires two transmissions. Thus, if noise is related to time in active transmission, 4-bit would be twice as bad as 8-bit parallel. Cable length, as mentioned, could be the real issue.

John
 

Thread Starter

Matheus Soares

Joined Oct 26, 2016
2
Your problem lies not in the modes but in the 20cm cable.
You have to reduce the length of the cable to less than 4cm. Can you do that?
I think I just can reduce 5cm of 20cm. A cable with less than 4cm length is impossible for me. Do you know some mode that is better to drive a common LCD Display 16x02 with 15cm or 20cm of cable length?

I2C would likely cope with longer wires better.
Thank you AlbertHall!

For one byte of data, 4-bit mode requires two transmissions. Thus, if noise is related to time in active transmission, 4-bit would be twice as bad as 8-bit parallel. Cable length, as mentioned, could be the real issue.
John
Yes, the cable length is a problem, but unfortunately I can't reduce more than 5cm of 20cm.
Are there some modes to get on well with this distance driving a common LCD Display 16x02?
And What about the I2C module with PCF8574? Is it better or worse than 8-bit parallel?
 

jpanhalt

Joined Jan 18, 2008
11,087
Your code may be part of the problem too. Many people use fixed delays for writes. Trying to send too quickly can cause strange characters. I check the busy flag in my routines.

John
 

RichardO

Joined May 4, 2013
2,270
If all else fails, you can try putting the cable through a large ferrite toroid core. I have had this work well enough to meet FCC emissions requirements.
 

MrChips

Joined Oct 2, 2009
30,708
A proper solution would necessitate a driver chip such as an MCU located directly where the LCD is located. Display data is transmitted from the present controller to the driver chip via one pair of RS-485 wiring.

If the noise environment is not too severe the following might work:

Make up twisted pairs of wire using 24-28 AWG insulated stranded wire for each of the three control lines, RW, RS and E and each of the four data lines (D7, D6, D5, D4) as per 4-bit mode.

Each pair will consist of two wires, one for signal and the other for GND. All GND wires are connected to SYSTEM GND at both ends of the cable. Do not use ribbon cable.
 
Top