Apologies in advance for the lengthy post - the situation here is complicated.
There's a 4x20 LCD character display (Newhaven NHD-0420H1Z-FSW-GBW-33V3) in an aluminum housing, connected to the main electronics box of our machine through a 20 pin ribbon cable. All of its power, grounding, data, etc. comes through this cable with very small gauge wires. There's also a flexible printed circuit with integrated buttons that sticks to the outside of the housing and connects to the PCB inside through a ZIF tail. The button traces pass through the PCB from ZIF tail to ribbon cable as directly as possible, essentially running directly to the MCU inputs inside the main body of the machine (they do also get 3.3V through pullup resistors on the PCB in the display housing.) The shared ground trace for the FPC is the same ground used for all display related functions. In the first picture below, you're seeing a clear prototype of the FPC, so the dark lines are the actual traces (except for the S logo!)
The issue is that if the display housing is touching the machine's frame, or even resting on a steel countertop that the machine is sitting on, some sort of noise related to the motors switching on causes bad characters to appear on the display. Interestingly, the character is always a repeat of whatever character was last printed, and it appears in the next position over. Based on that, I suspect that this noise is only being picked up by the display enable pin, and not necessarily affecting anything else.
The noise seems to get in through the FPC, but it takes the combination of FPC and aluminum housing to make it significant. With the FPC disconnected from the PCB, there are no glitches at all. With an FPC connected, but floating free (not glued onto the housing,) there are very, very few glitches picked up. But when the FPC is stuck to the housing as it's meant to be, the display glitches on almost every motor start.
I believe the housing is picking up whatever the noise is and that it's getting into the FPC through capactive coupling on the ground trace. The other FPC traces are pretty well isolated from the LCD itself, but the ground is shared, and it's got a pretty crummy path back to real ground through the small-gauge ribbon cable, so I could see how it would get noisy. I tried measuring resistance between the FPC traces and any part of the housing and found no evidence of any shorting. Measuring capacitance between traces and housing, I found a range of values that increased relative to the length of the trace, with the ground trace having the highest capacitance at .109nF. Seems like a very small amount of capacitance to be picking up such destructive noise, but I don't see how else it could be getting in!
The way I see it, there are a lot of ways one might try to solve this problem:
1) Eliminate motor noise at source.
2) Improve grounding overall, and especially in display housing.
3) Reduce coupling between FPC and display housing.
4) Make display circuit more robust against noise issues.
5) Somehow filter, protect, smooth LCD Enable pin.
We're doing the best we can at sorting out 1 and 2, but I don't feel like we can count on those right now. Reducing coupling (#3) seems like it would be a huge improvement, but I have no idea how much more space between traces and housing it would take to make it reliable. I fear it would be way too much thickness to be practical. So, even though I think these are the less ideal approaches, I'm here humbly asking for help with numbers 4 and 5.
I've made a rough attempt at simulating a simplified version of the circuit to look at noise filtering approaches. I have no idea how to characterize the noise, so V3 is just a wild guess I created in order to inject a visible spike into the signal through capacitive coupling. Below is my best-guess simulation of how things work now, followed by a version where I added some decoupling caps.
I'm used to using decoupling caps to stabilize a power level, but I've never tried to couple a stable(ish) power line to stabilize a bad ground. Does this seem like a plausible idea? It seems to have a positive effect in the simulation, but that's based on a LOT of my own assumptions.
Another zany idea I had, which I suspect is futile, is to do something (I know not what) to the Enable pin signal to make it less sensitive to noise. My fear is that anything that slows down noise spikes would also slow down legitimate signals and that the timing of the display would go wonky and ruin everything!
Do either of my wacky ideas sound promising? Better yet, do you all have other suggestions for smarter ways to deal with these issues? I'm pretty close to my wit's end!
There's a 4x20 LCD character display (Newhaven NHD-0420H1Z-FSW-GBW-33V3) in an aluminum housing, connected to the main electronics box of our machine through a 20 pin ribbon cable. All of its power, grounding, data, etc. comes through this cable with very small gauge wires. There's also a flexible printed circuit with integrated buttons that sticks to the outside of the housing and connects to the PCB inside through a ZIF tail. The button traces pass through the PCB from ZIF tail to ribbon cable as directly as possible, essentially running directly to the MCU inputs inside the main body of the machine (they do also get 3.3V through pullup resistors on the PCB in the display housing.) The shared ground trace for the FPC is the same ground used for all display related functions. In the first picture below, you're seeing a clear prototype of the FPC, so the dark lines are the actual traces (except for the S logo!)
The issue is that if the display housing is touching the machine's frame, or even resting on a steel countertop that the machine is sitting on, some sort of noise related to the motors switching on causes bad characters to appear on the display. Interestingly, the character is always a repeat of whatever character was last printed, and it appears in the next position over. Based on that, I suspect that this noise is only being picked up by the display enable pin, and not necessarily affecting anything else.
The noise seems to get in through the FPC, but it takes the combination of FPC and aluminum housing to make it significant. With the FPC disconnected from the PCB, there are no glitches at all. With an FPC connected, but floating free (not glued onto the housing,) there are very, very few glitches picked up. But when the FPC is stuck to the housing as it's meant to be, the display glitches on almost every motor start.
I believe the housing is picking up whatever the noise is and that it's getting into the FPC through capactive coupling on the ground trace. The other FPC traces are pretty well isolated from the LCD itself, but the ground is shared, and it's got a pretty crummy path back to real ground through the small-gauge ribbon cable, so I could see how it would get noisy. I tried measuring resistance between the FPC traces and any part of the housing and found no evidence of any shorting. Measuring capacitance between traces and housing, I found a range of values that increased relative to the length of the trace, with the ground trace having the highest capacitance at .109nF. Seems like a very small amount of capacitance to be picking up such destructive noise, but I don't see how else it could be getting in!
The way I see it, there are a lot of ways one might try to solve this problem:
1) Eliminate motor noise at source.
2) Improve grounding overall, and especially in display housing.
3) Reduce coupling between FPC and display housing.
4) Make display circuit more robust against noise issues.
5) Somehow filter, protect, smooth LCD Enable pin.
We're doing the best we can at sorting out 1 and 2, but I don't feel like we can count on those right now. Reducing coupling (#3) seems like it would be a huge improvement, but I have no idea how much more space between traces and housing it would take to make it reliable. I fear it would be way too much thickness to be practical. So, even though I think these are the less ideal approaches, I'm here humbly asking for help with numbers 4 and 5.
I've made a rough attempt at simulating a simplified version of the circuit to look at noise filtering approaches. I have no idea how to characterize the noise, so V3 is just a wild guess I created in order to inject a visible spike into the signal through capacitive coupling. Below is my best-guess simulation of how things work now, followed by a version where I added some decoupling caps.
I'm used to using decoupling caps to stabilize a power level, but I've never tried to couple a stable(ish) power line to stabilize a bad ground. Does this seem like a plausible idea? It seems to have a positive effect in the simulation, but that's based on a LOT of my own assumptions.
Another zany idea I had, which I suspect is futile, is to do something (I know not what) to the Enable pin signal to make it less sensitive to noise. My fear is that anything that slows down noise spikes would also slow down legitimate signals and that the timing of the display would go wonky and ruin everything!
Do either of my wacky ideas sound promising? Better yet, do you all have other suggestions for smarter ways to deal with these issues? I'm pretty close to my wit's end!