Optrex F-51553 Display Problems

pcproa

New member
Hello,

I've been looking around the internet here along with this board and have found people with similar issues to the ones I'm having. It's been haunting me for about a week now. Please keep in mind, that I am new to this controller. I have programmed this ATMEGA324P in the past with an LC7981 controller and no problems.

My Optrex F-51553 is delivering weird results. When I try to display an image of any kind, I get a screen that is either made up of random lines (vertical or horizontal) or a random crosshatch pattern. The thickness of the line varies.




Right after I initialize, if I want to display all points on or all points off, command 10, it works fine and produces the results I expect.

MCU: ATMEGA324P
LCD: F-51553

I am using a 3 charge pump design shown here:


I've tried a few different routines to initialize the LCD. First is taking from the datasheet

commandLCD(0xA2); // (11) LCD Bias Set
commandLCD(0xA1); // (08) ADC Selection
commandLCD(0xC0); // (15) Common Output State Selection
commandLCD(0x26); // (17) Setting Built In Resistance
commandLCD(0x81); // (18) a. Electronic Volume Control
commandLCD(0x20); // (18) b. Arbitrary Eelectronic Volume Constant
commandLCD(0x2F); // (16) Power Control Setting
Second is cosmicvoid

commandLCD(0xE2);
_delay_ms(0);
commandLCD(0xA1);
commandLCD(0xC0);
commandLCD(0xA2);
commandLCD(0xA6);
commandLCD(0x20 + 6);
commandLCD(0x81);
commandLCD(0x20);
commandLCD(0x28 + 4);
_delay_ms(0);
commandLCD(0x28 + 6);
_delay_ms(0);
commandLCD(0x28 + 7);
_delay_ms(0);
commandLCD(0xAF);
commandLCD(0x40);
commandLCD(0xB0);
commandLCD(0);
commandLCD(0x10);
dataDisplayLCD(0x0);
_delay_ms(10);
commandLCD(0x81);
commandLCD(48);
And the third was Graphical Alarm Clock by Matt Meerian, using the ATMEL ATMEGA32

commandLCD(0xE2); // (14) Reset
commandLCD(0xA1); // (08) ADC Select
commandLCD(0xC0); // (15) Common Output Mode Select
commandLCD(0xA6); // (09) Display Normal/Reverse
commandLCD(0x24); // (17) V5 Voltage Regulator Internal Resistor Ration Set
commandLCD(0x81); // (18) a. Electronic Volume mode Set
commandLCD(0x10); // (18) b. Electronic Volume Register Set
commandLCD(0x2F); // (16) Power Control Set
commandLCD(0x40); // (02) Display start line set
commandLCD(0xB0); // (03) Page address set
commandLCD(0x10); // (04) a. Column address set upper bit
commandLCD(0x00); // (04) b. Column address set lower bit
commandLCD(0xAF); // (01) Turn Display ON/OFF
commandLCD(0x1B); // (04) a. Column address set upper bit
commandLCD(0x81); // (18) a. Electronic Volume mode Set
commandLCD(0x30); // (18) b. Electronic volume register set
My command LCD function is as follows (I found based on reading here that if I hold the CS1

pin low all the time the results are more consistent):

void commandLCD(int lcdRegister)
{
PORTB |= 0b00010000; // nRD high
PORTB &= 0b11111011; // A0 low
//PORTB &= 0b11111110; // nCS1 low
PORTB &= 0b11110111; // nWR low

PORTD = lcdRegister;

PORTB |= 0b00001000; // nWR high
//PORTB |= 0b00000001; // nCS1 high
PORTB &= 0b11101111; // nRD low
}
And finally, I've modified my write sequence to display either on and off by means of loops

void dataDisplayLCD(int input)
{
int page = 0, col = 0;

for(page = 0; page < 8; page++)
{
commandLCD(0xB0 + page);
commandLCD(0x10);
commandLCD(0);
for (col = 0; col < 128; col++)
dataWriteLCD(input);
}
}
I've referenced information here from the following posts:
https://forum.crystalfontz.com/showthread.php?t=3619
https://forum.crystalfontz.com/showthread.php?threadid=3808
https://forum.crystalfontz.com/showthread.php?t=3808&highlight=optrex

and website:
Matt Merian's Alarm Clock using ATMEGA32
http://www.geocities.com/matt6ft9/alarm_clock_index.html

Thanks,

Patrick
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
 
The only thing that comes to mind is the signal timing. This display is really fast on the interface, but maybe your signal sequence is faster. You might try some delay in both the command & data write routines. Also, it is a BAD idea to leave the RD signal active when not writing, you should just leave it high unless you are doing a read from the display.
Code:
void commandLCD(int lcdRegister)
{
	PORTB |= 0b00010000; // nRD high
	PORTB &= 0b11111011; // A0 low
	PORTD = lcdRegister;

	PORTB &= 0b11110111; // nWR low
	// insert delay of 100 nS here
	PORTB |= 0b00001000; // nWR high

// get rid of this line ->PORTB &= 0b11101111; // nRD low
}
 
Last edited:

pcproa

New member
Thanks for the help so far cosmicvoid

ok, try not to laugh too hard at this.... I soldered on the FPC connector backwards before..... Never solder a circuit board in the same room as your gf while she's trying to watch TV. Between all the nagging that the room is too hot, and the TV as a distraction, you're bound to get it wrong.

OK, so the update. I've purchased a replacement LCD, and made a small board with the LCD connector on there. I've hooked up everything. Checked many times that everything was right and fired it up on the new LCD.

The LCD remains blank at all times. No flicker. Points always stay off. The screen is just completely dead. I've tried all the coding that I've posted here in the first post and now I don't get any results at all.
 
Are you sure the first connector was backwards? The photos look like you have some contrast, which would be extremely hard to do if the connections were wrong, because of the external charge pump caps. So, if you are sure you have correct connections, then it must be a software issue. BTW, check very carefully, with an ohmmeter, that the FFC connector is indeed soldered to all pcb pads. I've hand-assembled nearly 100 pcbs that use the 30 pin FFC/FPC, and the most common problem was that one or more pins weren't making contact with the board trace (i.e. a bad solder joint). Those can be a real chore, even using a 20 mil soldering tip and solder paste.

For good contrast, Vout should be around -9.5 volts. If it's not, you have a charge pump problem. I recommend a Resistor Ratio setting of 0x26; for me, anything less than 0x25 gave virtually no contrast. Also, Bias will make a difference, try 0xA2 or 0xA3.

Post your actual init values, and your write routine(s) code. You may get better clues if you write a test pattern to the screen, such as 0x55 or 0xAA, or incrementing data.
 

pcproa

New member
I'm at work right now. I'll be home a little later to try what you've suggested.

I've checked to make sure that I've soldered on the connector correctly and there doesn't seem to be any problems. Before I went to bed last night, I noticed that the RESET pin on the LCD would not come on. I figured out why the MCU was doing that and for some reason, when I run the loop to display info on the screen, the reset pin goes low.

I didn't have much time to correct it, but I programmed the MCU to prevent it from going into the display loop for now and just initialized the screen, then ran a the command, Display All Points ON/OFF
The display now switches and shows the points on/off accordingly. Funny enough, I plugged in the old display and it worked fine as well. This was all using the initialization sequence that's laid out in the Datasheet.

I did manage to check Vout tied to CAP3- last night and it only goes down to -5V. When I checked before with the connector backwards, the least I would get was 100mV on that pin, so that's the reason why I think it's the right way now. Seems that the culprit right now will be that some pins are not soldered correctly on the Connector.
 

pcproa

New member
When I started working on it again a couple days ago, I played around with the coding and got it to start displaying things. I made a simple bitmap screen and loaded it onto the MCU. Everything was great and I was fixing Contrast, etc. Both the new screen and the old (supposedly fried) screen were working great. I was getting everything ready to post and update on here.

I shut down the MCU shortly after I loaded the bitmap. Turned it back on and it wouldn't show anything. I found that pins 17, 18 and 19 weren't connected for some reason. So I soldered each of those and cleaned up the flux thoroughly after that. Still nothing.

I tried working on it again yesterday and still no results. I decided to make another board with brand new FPC traces and a connector. The results were still the same. The LCD's are dead. I checked the voltage on the VOut pin and I get -10Volts.

Is there anything else I should be looking for?

Thanks,

Patrick
 
Last edited:
There is information missing from your descriptions.
I shut down the MCU shortly after I loaded the bitmap. Turned it back on and it wouldn't show anything.
Just the MCU turned off, or both the MCU and the display? Since you haven't posted your startup code, I can't tell if you are using the display's reset input. Do you hard reset the display as part of your init?
I found that pins 17, 18 and 19 weren't connected for some reason. So I soldered each of those and cleaned up the flux thoroughly after that. Still nothing.
Hopefully the ZIF tail was disconnected when you did this. BTW, I've found that the traces connecting the charge pump filter caps are very sensitive to leakage currents, and if there is flux left on the board (especially under SM caps), it will affect the voltages.
I checked the voltage on the VOut pin and I get -10Volts.
AFAIK, the only way to get Vout is that the charge pumps are working, which implies that the data and control signals are at least somewhat functional, and that some of your pump caps are making connection. So I suspect more bad ZIF solder connections. Just for reference, here are the voltages that I measure on the filter tree, when Vout is -9.5v: V5 = -4.7v, V4 = -3.6v, V3 = -2.5v, V2 = +2.6v, and V1 = +3.9v. The voltages on C8 & C9 are a square wave, so a meter reading isn't too helpful.

When you solder the ZIF pin tails to the traces, do you push down on them to force contact with the pcb traces? I found that it helps; I use a dull xacto knife to do the pushing, so it doesn't act too much like a heat sink. Do you "pre-tin" the row of pads on the ZIF footprint, leaving a tiny hump of solder on each pad? I also use an aggressive liquid flux, to be sure both tails and pads wet properly.

Anyway, it sounds like your code problems are fixed.
 

pcproa

New member
So I've been able to spend a little time on it today since I got home. I checked each solder connection and they are all connected properly. To answer your questions/statements cosmicvoid

Just the MCU turned off, or both the MCU and the display?
Both the MCU and the screen. The power supply for the MCU is the same as the LCD and I turn off the power supply

Do you hard reset the display as part of your init?
Yes I do. From startup when power is turned on, there is a one second delay where the reset on the screen is held low for that entire second. Then the reset pin goes high and the init is started.

Hopefully the ZIF tail was disconnected when you did this.
Yes it was

BTW, I've found that the traces connecting the charge pump filter caps are very sensitive to leakage currents, and if there is flux left on the board (especially under SM caps), it will affect the voltages.
After I solder these connectors, I spray it 3 to 5 times with flux remover and after each time I spray it I brush it thoroughly between the traces with a small brush

Vout is -9.5v: V5 = -4.7v, V4 = -3.6v, V3 = -2.5v, V2 = +2.6v, and V1 = +3.9v.
I get the exact same voltages when my power supply is regulated to 5V

When you solder the ZIF pin tails to the traces, do you push down on them to force contact with the pcb traces?
Yes

Do you "pre-tin" the row of pads on the ZIF footprint, leaving a tiny hump of solder on each pad?
No I don't

I also use an aggressive liquid flux, to be sure both tails and pads wet properly.
Each time the soldering iron tip touches the pad or the pin, I soak the pin with liquid flux. I use quite a bit of liquid flux whenever I do SMT soldering. Not so much with through hole, but that doesn't apply in this case.

Sorry for being so annoyingly detailed. Just covering all my bases for the next time I'll have a problem, which I anticipate.

So I've found my problem and I now have the screen displaying images with no problem. It seems that the pads on the ribbon cable for the LCD is completely pressed in and it makes it very hard to contact. I'm wondering if I can cut off the end of the LCD ribbon cable a tiny bit to move the contact point into an area where there is lots to contact.

I just wanted to say though, Thanks for everything cosmicvoid. You've gone above and beyond to help solve my problem. Here are the pics of the screen.



 
Congratulations, good troubleshooting. Yeah, you could trim the flex tail a little, to remove the part where the pads get narrow. In my case, using a Hirose brand ZIF connector, the indentations in the flex tail where the contacts press is about 0.06 in from the end of the tail, well beyond the narrow part. Maybe you aren't putting the tail far enough into the ZIF connector.
 

pcproa

New member
Hey cosmicvoid

I also use a Hirose brand ZIF connector seen here:
http://search.digikey.com/scripts/DkSearch/dksus.dll?Detail?name=HFJ130CT-ND

Part Number FH12-30S-0.5SH(55)

I cannot seem to consistently make a good solder connection. I think my iron may be too hot as well, but I can't lower the temp anymore so I may need to buy a different one.

Here's how I do it:
First I line up the connector perfectly on the pads. I solder the end tabs to secure the connector in place. Then I run a bead of solder all along the contact. I then soak it all up with solder wick and fix the bridged connections as necessary. Sometimes to do that I'll coat that section again with solder and soak it up again the same way. All while soaking it constantly with Flux and Flux cleaner.

The last time I did it I decided to keep my iron from contacting for too long so not as much heat would transfer. The end result was a lot better, but still has minor issues with connectivity. Each point is far too small for me to solder individually.

You said you've assembled a lot of units in the past. How did you normally solder it? What type of soldering iron and tip did you use?

Thanks,

Patrick
 
Last time I made a batch of boards, in the spring, I used the same connector as you, except for the "(55)", Digikey HFJ30CT. I have a cheap temperature controlled iron, Weller WLC100, set to "2" on a scale of 0-5, and I use Weller ST7 tips (0.03" conical). I grind the tip down to a slightly blunt point, maybe 15 or 20 mils (see photo), and re-tin the point frequently, in a small pan of tip-tinner compound, as I use it. That's because once the iron plating on the tip is ground away, the copper dissolves slowly in the solder, and the tip gets worn away after a few hours.

On the board, I use either ultra fine 0.015" wire solder or solder paste from a syringe to pre-tin the row of pads. I drag the tip of the iron lightly along the row of pads, to "wipe" them with solder, leaving a small hump of solder on each pad. I think this step is essential, because before I started using this method I had connection problems. Note: the solder hump on each pad is evenly wetting the whole pad area, not just a little bump on one part of the pad.

Then I set the connector in place and solder the two hold-down tabs, pushing down to make the connector tails tight against the solder humps on the pads. Then I take a small brush (like a fingernail polish brush), and apply a liquid flux to the row of tails (an organic-chloride flux, I don't remember what kind).

Then I wear a headband magnifier, and use a strong lamp on a flexible arm to light the work. I go down the row of tails, using a dull exacto knife to push and hold each tail down, while I put the iron tip to the junction of the tail and the pad. As soon as the hump of solder melts and wicks up along the tail, I remove the tip, but keep holding with the exacto for a few seconds until the solder solidifies. Then move to the next pad.

To clean the board, I use a toothbrush and ordinary bar soap and warm running water. Then I blow dry the board with compressed air.
 

Attachments

pcproa

New member
Hey cosmicvoid

I didn't update you since I last posted, but I got a soldering station similar to the one you have with a very fine tip, and I'm able to solder them consistently well now. I tried getting your exact soldering station but the electronics store I went to just sold out of the last unit the hour before I got there, and the next place that had stock was over an hour away.

So everything's been pretty much great with the screen for the past few months, however, there's always been this little annoying issue.
Most of the time, when I turn off all power to the LCD, it starts to display weird lines for a few minutes after the power has been cut. They are usually horizontal patterns, and sometimes I get screens that display only open pixels such as this one



My wiring hasn't changed any from when I last posted it



Any ideas why it could be doing this?

Thanks,

Patrick
 
The display will show random lines because the charge pump capacitors still have voltage on them, which is leaking through to the LCD electrodes. This does not always cause the lines, but I don't know why not.

Some years ago, when I was hired to do programming for automobile instrument cluster boards, which had small LCD displays in them. One constant problem was that when the ignition in the car was turned off, the display panel will sometimes show these streaks, and the company didn't like that. So we put extra code into the program to specifically shut down the charge pump, command 0x28 (these had Epson controller chips, similar instruction set to the ones in the Optrex diplays). So the code would shut off the voltage booster circuit, and wait a few seconds, before removing power to the display. It might also help to turn off the display, command 0xAE, before removing power.
 

pcproa

New member
Yeah, I was thinking the charge pumps were the culprit.
I'm using an Atmega processor to control the screen. I just finished putting a command thats triggered by the Brown Out Detection interrupt that tries to complete a command to reset the LCD before it's shut down entirely. Hopefully that will solve it tomorrow when I test it out.

With the Optrex screens that you've built, you've never had that problem?
I was thinking I could possibly try a circuit like the one that Optrex has posted in their drivers PDF on the website, that is, if this doesn't work.

I'll keep you posted.

Thanks,

Patrick
 

pcproa

New member
Well, unfortunately that didn't work. It still does the same thing.
I guess I'll be trying to revise the circuit like Optrex has listed in their driver sheet.

If that still doesn't work then I will be to try and keep power to the MCU and LCD for a second after power is withdrawn so it has a chance to execute the screen turn off command.
 

andrew99

New member
Just a question.

Cosmicvoid,

I notice you are passing an unsigned int that is o/p to an 8 bit port. Is this typical or am I missing something?

The newbie.

A

The only thing that comes to mind is the signal timing. This display is really fast on the interface, but maybe your signal sequence is faster. You might try some delay in both the command & data write routines. Also, it is a BAD idea to leave the RD signal active when not writing, you should just leave it high unless you are doing a read from the display.
Code:
void commandLCD(int lcdRegister)
{
	PORTB |= 0b00010000; // nRD high
	PORTB &= 0b11111011; // A0 low
	PORTD = lcdRegister;

	PORTB &= 0b11110111; // nWR low
	// insert delay of 100 nS here
	PORTB |= 0b00001000; // nWR high

// get rid of this line ->PORTB &= 0b11101111; // nRD low
}
 
I notice you are passing an unsigned int that is o/p to an 8 bit port. Is this typical or am I missing something?
I am passing an unsigned int :confused: ? I don't actually know what you're referring to, and I think its a piece of code that the OP has posted. I would be much more likely to pass an unsigned char (i.e. "BYTE") if the destination is a 8 bit port. Why do you ask?

BTW, the code in your quoted section is passing a signed int.
 

pcproa

New member
Thanks cosmicvoid
I programmed the MCU to automatically send the commands to the LCD to turn it off when it detects a low voltage. Then I built a simple Capacitive circuit that would allow the device to slowly drain.
It works perfectly now
 

andrew99

New member
Another question.

Guys,

Just another question:

I am working with the same display. I wanted to clarify what is required to make the
display work before I get too far into the project.

It is my understanding that the passing of an int as well as the assigning of it to the
port are best done with an unsigned char. This is what I have done but I thought I
might be missing something.

I notice that the source shows a control byte being written to the display. In the comment
after the code a number is shown in brackets that does not seem the relate to the control
code. How do the two relate?

eg. commandLCD(0xA2) // (11) LCD bias set

Thanks,

A
 
Top