Electronic – Driving a 24 BPP display in 5:6:5 mode

displaytft

I have a TFT display which accepts 24 Bits Per Pixel (BPP) display data, but my connector mechanism supports only 5:6:5 mode.

What is the prefered way of getting the display to drop the extra pixel data and use the 5:6:5 data?

Should I just pull-down the unused data lines?

Best Answer

There are two common approaches. One approach is to wire all the unused bits to a fixed value (typically zero). This will cause a slight loss of brightness, but 3% really isn't worth worrying about. The other is to wire them to the upper bits, in sequence, so a 5-bit color value would be wired as [D4 D3 D2 D1 D0 D4 D3 D2]. This will cause every fourth brightness step to increase the pixel brightness by 9 instead of 8, and uses the entire dynamic range.

In deciding on a method, though, one should consider what software is going to be expecting. I prefer 5:5:5 to 5:6:5 (using the upper bit as something like a transparency key) because values with R=G=B will all have the same chrominance and hue. With a 5:6:5 display, software seeking a uniform gray scale might use either (n,2n,n) for all values (assuming white to be 31,62,61), or it might add 1 to the green values for n>=16. If software is going to simply be copying the upper bit of the "green" value to the lower bit, you may achieve the better results with [D5 D4 D3 D2 D1 D0 D4 D3] or [D5 D4 D3 D2 D1 D5 D4 D3] than you'd get with [D5 D4 D3 D2 D1 D0 D5 D4] (which would give the most uniform 63-step ramp). If software will simply be leaving the lower bit blank, you'd be best off with [D5 D4 D3 D2 D1 D5 D4 D3].