Peculiarities in the LED display of a prop proton pack nearly drive an engineer insane.
This was not a problem that Public Security Section 9 would be well equipped to handle: When ghosting shows up in a production run of electronic displays destined to be mounted in Ghostbusters' Proton Pack Shells, unlicensed particle accelerators designed solely to weaken and help capture ghosts, one has to wonder: "Who you gonna call?"
The display board for the Proton Pack runs the Red Cyclotron illumination as well as the Blue Power Cell illumination that cycles in predetermined patterns to indicate when the pack is functioning properly and when it is becoming overheated and needs to be vented -- critical operations that need to be accurately displayed, or large-scale destruction of property and life could ensue, which would generate even more ghosts!
Of course the haunting did not occur in the prototypes or the pre-production boards. As ghosting does, it would wait until final testing of the production boards. The first few boards worked flawlessly. But then, during a test designed to verify that each individual LED could be separately controlled, other LEDs started glowing... Ghosting?
"Just set this one possessed board aside and keep on testing," I muttered to myself. After a while my pile of defective boards was the size of a giant Twinkie, and I knew I had a problem that rivaled the Stay Puft Marshmallow Man.
A little bit of back story here: Even with a surface mount microcontroller, there was not enough room on the small circuit board to have separate pins driving all 20 LEDs and a communications link to a sound card and an analog input to read the configuration potentiometer.
The Power Cell's 15 LED display (D1 through D15) was divided into two sets of LEDs: the seven even-numbered LEDs and the eight odd-numbered LEDs. Each set of LEDs had its anodes connected together, and they were driven by an enhancement mode p-channel FET connected to the regulated power supply. The FETs would be alternately turned on so each of the sets of LEDs would get 50 percent of the display time. Eight I/O lines each had a current-limiting resistor connected to at most one LED from each of the two sets of LEDs. This configuration allowed driving of the 15 LEDs with just 10 pins. It cost two FETs, but it did save on seven current-limiting resistors, compared to driving each LED with a dedicated pin.
A relatively simple drive scheme:
- Power off both FETs
- Drive the odd LED data pattern on the 8-bit port
- Turn on the odd LED FET
- Wait a while
- Turn off the odd LED FET
- Drive the even LED data pattern on the 8-bit port
- Turn on the even LED FET
- Wait a while
- Turn off the even LED FET
The ghosting could be seen in over 10 percent of the boards. I was the designer, and I realized that the problem had better be defective components or I might be compared to Vigo the Carpathian.
I connected one of the boards to the debugger and stopped the program after the part configuration was complete, and manually controlled the output port levels. Turning on the odd FET and trying a few patterns lighting up the odd LEDs, I could see some of the even LEDs slightly glowing. I could easily see the ghosting even with static signals -- no ecto-goggles required. This was going to be too easy to find and fix.
With a voltmeter I checked the even LED FET. As desired, the gate was at the same voltage as the source, so Vgs was 0 and the FET should be completely off. The drain did have a fairly high voltage on it, so the FET was on even though it should have been totally off. This would allow some current to flow through the even LEDs and show up as my ghosting display.
I figured I must have had a bad bunch of FETs and quickly off to the rework bench to swap out the offending FET. Back to the test harness, and I was ready to bask in the glory of finding an easy fix. But wait: The board is still possessed? How could this be?
Panic started to set in, and this was worse than being slimed! Maybe just a bad board? I put new FETs in a couple of boards -- the ghosting was not vanquished to another realm in any of them. I finally started thinking again and swapped the even and odd FETs, and the problem did not follow the FET. If only Egon was around to help me out of this mess!
Going back to the debugger and trying several patterns, it appeared that only some LED patterns would cause the ghosting. The 8-bit port was set up as an output port, so it was driving the signals low for the LEDs I wanted to turn on, while all of the other lines were driven high. It ended up that anytime I would drive one particular line high the ghosting would show up. This line was connected to the cathode of two LEDs. In desperation I cut out the even LED on that line. All of the ghosting went away. The ghost was in that LED!?
I found out that about 1 percent of my LEDs would have a reverse bias leakage of several mA -- enough to slightly turn on the other LEDs sharing the common anode connection. Light emitting non-diodes?! This was, of course, way out of spec, but I had a lot of boards already built up. I was almost resigned to reworking all of them when an epiphany struck: Don't configure the 8-bit port as an output-only port. Instead make it more of an open drain port by configuring each pin as an output only when you want to sink current, and configuring it as an input instead of driving it high.
I reprogrammed the boards and they all passed. No more ghosts. And I didn't have to call on the mayor.
Submit your product repair or redesign story as part of our Frankenstein's Fix competition on EE Life, and you could win a Tektronix MSO2024B digital oscilloscope. The deadline is Oct. 26, 2013. Submission details and full contest rules here.