0

[solved] 16x32 LED panel blurring/streaking/ghosting
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

[solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Tue Dec 17, 2013 5:13 pm

Many people have a problem with 'ghosting', 'blurring', 'streaking', etc. on the 16x32 displays (see this thread for some, and there are other examples on the web). Here's a summary of the cause and solution.

The problem:

Consider the logical structure of the array: there are FETs that block or allow current to each row and other FETs that block or allow current to each column. When both FETs for a particular LED are 'on', that LED lights; otherwise it's [supposed to be] off.

From a digital standpoint, this is fine, but unfortunately analog comes in and ruins everything. The problem occurs when an LED is OFF for an entire refresh cycle but another LED in its column is ON. In this case, when the OFF LED's row is selected, the high-side FET charges the stray capacitance of that node (which is quite large, as it consists of long lengths of trace as well as quite a few components). Then when a different row is selected and the low-side FET turns on, that parasitic capacitance discharges through the OFF LED, very briefly flashing it.

Here is an example of what the streaking looks like in a very bad case (paper covering the ON LEDs so that they don't ruin the photo):
Image

Since the flash is a constant amount, and occurs each refresh cycle, higher refresh rates exacerbate the problem, as this guy noticed.

The solution:

Unfortunately, the only solution possible with the displays as-is is to keep the refresh rate low (specifically, the cycling of ROWS - you can refresh a particular row repeatedly as quickly as you want). Mostly this just makes the average brightness of the flashes low enough to not be noticed. It does also give the nodes extra time to discharge through other paths, but that effect is negligible until extremely low refresh rates. In my tests, keeping the overall refresh rate <100Hz made the problem barely noticeable under worst-case conditions.

However, if you want to truly fix the problem, you can do it by modifying the display. What you need to do is add resistors that will discharge the problem nodes after they're deselected and before another LED in that column turns on.

This is what it looks like:
Image
The resistors are between ground and the drain of each high-side FET. I used 10k resistors, which I found to be plenty for any realistic refresh rates - up to 6kHz.

This is what the display looks like afterwards (same code running as first photo):
Image

P.S.:
Why is the ghosting green with a hint of red? First of all, because I'm making the ON pixels white. If I made them blue, then there would be blue streaks, because the capacitance would have to discharge through the blue LEDs. Since it can go through any LED (because all the low-side FETs are on), it would normally go through red (because red has the lowest forward voltage), but these displays have resistors in series with the red LEDs to reduce the strain on the constant-current drivers. This evens out green and red, apparently with a slight preference for green (probably because the green voltage-current curve remains exponential whereas red, with the resistors, is linear).
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Tue Dec 17, 2013 7:40 pm

An oscilloscope view of what's going on:
Image

Based on the decay, the capacitance of the node in question is ~5nF.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by adafruit_support_mike on Wed Dec 18, 2013 2:32 am

That's a nice piece of reverse-engineering. Thank you for posting it!
When you void a product warranty, you give up your right to sue the manufacturer if something goes wrong and accept full responsibility for whatever happens next. And then you truly own the product.

adafruit_support_mike
 
Posts: 59156
Joined: Thu Feb 11, 2010 2:51 pm

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by motocoder on Sat Dec 28, 2013 3:41 pm

Here's an alternative solution that does not involve modifying your board. I've been working on my own FPGA driver for this, and I initially had the HDL set up to do PWM and clock the data in as follows:

For each of PWM intervals:
For each row:
For each column:
Clock in both RGB values, 6 bits with each bit either on or off depending on whether
or not the corresponding 8-bit color value is non-zero and greater than or equal to the
PWM counter

But I found a tip from a blog I found that by moving the PWM loop to be the inner loop, the ghosting was greatly eliminated. Ok, great - so now the loop is:

For each row:
For each of PWM intervals:
For each column:
Clock in both RGB values, 6 bits with each bit either on or off depending on whether
or not the corresponding 8-bit color value is non-zero and greater than or equal to the
PWM counter

Note that we're repeatedly drawing the same row over and over, doing the pulse-width modulation (PWM) or Binary Coded Modulation (BCM) on that one row before moving on to the next row.

The other thing that I discovered is that the OE/EN signal is extremely slow, and that clocking in a blank (all zeros) row actually works much better. So if you think about how PWM is implemented, you typically have to do special case behavior for zero values. I initially had my PWM counter starting at 1 and going to 255 so that when I compared to 0 color value (fully off), I got a black (0) pixel, and when I compared with 255 (fully on), I got an enabled (1) pixel for 100% of the PWM cycle. But instead what I do now is allow my counter to go from 0 to 255, and if the counter is 0, set all the pixels to black/off. This naturally gives a brief blanking interval between row transitions, and there is only the faintest ghosting visible when transitioning from 100% on to 100% off across rows. I experimented with disable OE/EN during this blank row, and it makes no difference in visible ghosting, which is what led me to the conclusion that OE is only really useful for blanking the whole display, not for inter-row blanking.

I hope this makes sense. It's a little hard to explain, but it's actually extremely simple.

motocoder
 
Posts: 15
Joined: Tue Jul 23, 2013 12:49 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Sat Dec 28, 2013 5:02 pm

Changing around the order of PWM reduces the number of row switches, which is why it reduces the ghosting. Like I said, the 'solution' is to change rows as infrequently as possible.

By any chance can you trace the OE signal on your displays? Because on mine, OE goes to the LED drivers, but this guy says that on his board it goes to the 3-to-8 decoder. I'm curious because of your comment on OE being slow - I've found that the high-side FETs are quite slow (~500ns to fully switch off), so if OE controls the decoder on your board (meaning it disables all the high-side FETs) then that would indeed be slow. On my board though, it's literally the same thing (electrically) as clocking in a blank row except that it takes one signal transition instead of 32 clocks.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Sat Dec 28, 2013 5:04 pm

Adafruit guys: is it possible to request a certain version of the display, if you have some in stock? I'd be interested in buying some of the versions that I don't have to test the differences.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by adafruit_support_mike on Sun Dec 29, 2013 12:29 am

Unfortunately, no. They come to us in mixed batches, and we greatly fear having the internet declare 50% of our inventory 'good' and the other 50% 'useless'.
When you void a product warranty, you give up your right to sue the manufacturer if something goes wrong and accept full responsibility for whatever happens next. And then you truly own the product.

adafruit_support_mike
 
Posts: 59156
Joined: Thu Feb 11, 2010 2:51 pm

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Sun Dec 29, 2013 2:13 am

I'd be more interested in finding a common set of control parameters to make all versions work as well as possible. I don't want to tell people "this is the best way to do it" if that's not true for an unknown number of people.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by motocoder on Sun Dec 29, 2013 11:00 am

Adafruit guys: is it possible to request a certain version of the display, if you have some in stock? I'd be interested in buying some of the versions that I don't have to test the differences.


You don't need to test differences. If you use the approach I suggest, it should work on either panel. If you like, you can go ahead and de-assert the OE signal at the same time you're blanking the DR* signals, but it won't make any difference in the display IMHO.

And by the way, I understand that increasing the time between row changes is what decreases ghosting, but the benefit of the approach I outline is that you can do this without lowering the overall refresh rate of the display at all.

motocoder
 
Posts: 15
Joined: Tue Jul 23, 2013 12:49 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by motocoder on Sun Dec 29, 2013 11:53 am

By any chance can you trace the OE signal on your displays? Because on mine, OE goes to the LED drivers, but this guy says that on his board it goes to the 3-to-8 decoder.


Ok, now this is strange. I traced the "OE" signal (on my board, it is labeled "EN") this morning. It goes into the HC245, and the output of the HC245 goes to the same signal on the output connector as you might expect. But from there, I couldn't find a connection to any of the other ICs on the board. I'm not able to get to some of the MOSFETs that are under the black plastic center divider, so it is possible that the signal is going there, and I suspect that is the case. But I did check the 74HC138 (3-8 decoder) several times, and the signal is not going there. I suspect one the MOSFETs in one of the SG4953S chips is being used to switch power to all the rows (i.e. it's drain is connected to source on the other MOSFETs) and that this is where the signal is going.

BTW - the data sheet for the LED driver ICs also mentions relatively slow switch times for OE. I had one of the fellows who works for me (who is Chinese) locate this data sheet and between him and some translation software, I was able to figure verify a few assumptions. I've attached the Chinese version of the datasheet to this post.
Attachments
MW5024B_V1.6a.pdf.zip
Datasheet for 16-channel LED driver IC
(732.86 KiB) Downloaded 119 times

motocoder
 
Posts: 15
Joined: Tue Jul 23, 2013 12:49 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Sun Dec 29, 2013 7:27 pm

motocoder wrote:It goes into the HC245, and the output of the HC245 goes to the same signal on the output connector as you might expect.


The input probably splits and goes to two pins on the bus transciever. One of the outputs of the transciever then goes to the output port of the display, and the other transciever line goes somewhere on the board. It's so you can chain the displays without having to drive tons of capacitance. It makes sense then that the output port pin doesn't connect to anything else on the board.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by motocoder on Mon Dec 30, 2013 3:55 am

The input probably splits and goes to two pins on the bus transciever. One of the outputs of the transciever then goes to the output port of the display, and the other transciever line goes somewhere on the board. It's so you can chain the displays without having to drive tons of capacitance. It makes sense then that the output port pin doesn't connect to anything else on the board.


No, I checked for that before posting my last message. Not the case here.

motocoder
 
Posts: 15
Joined: Tue Jul 23, 2013 12:49 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Mon Dec 30, 2013 2:58 pm

That is interesting then.

Looks like our displays use different LED drivers anyway - mine are marked with SM16126ES. Though I can't find a datasheet, I've measured the propagation delay from OE to output as ~20ns off-to-on and ~10ns on-to-off.

In the datasheet you attached, do you know what's in the box coming upwards from LE on page 2? I based my work on the attached datasheet (apparently used in this guy's displays) and I can't think of what might make sense between LE and OE.

CYT62726.zip
LED driver datasheet
(757.27 KiB) Downloaded 100 times
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by KNfLrPn on Mon Dec 30, 2013 3:01 pm

A takeaway so far though is that it does sound like the most-compatible version of control would be to shift in a blank row instead of using OE.
KNfLrPn
 
Posts: 19
Joined: Sat Jun 09, 2012 2:44 am

Re: [solved] 16x32 LED panel blurring/streaking/ghosting

by motocoder on Mon Dec 30, 2013 4:17 pm

In the datasheet you attached, do you know what's in the box coming upwards from LE on page 2? I based my work on the attached datasheet (apparently used in this guy's displays) and I can't think of what might make sense between LE and OE.


The text in the box says "output protection circuit". If LE doesn't toggle for a period of 450ms or greater, it disables the output of the constant current driver.

motocoder
 
Posts: 15
Joined: Tue Jul 23, 2013 12:49 am

Please be positive and constructive with your questions and comments.