FreeCalypso > hg > freecalypso-hwlab
annotate doc/LCD-backlight-driver @ 121:87b34a244901
fc-simtool: pb-erase-range command implemented
author | Mychaela Falconia <falcon@freecalypso.org> |
---|---|
date | Thu, 28 Jan 2021 05:04:16 +0000 |
parents | b1b027efce8e |
children |
rev | line source |
---|---|
70
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
1 I, Mother Mychaela, have a deep desire to build my own GSM cellphone handset |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
2 that would serve as a published-source replacement for my current Pirelli |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
3 DP-L10, which is laden with unwanted and undocumented extra non-GSM components |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
4 and for which there are no schematics. I already know what kind of display I |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
5 wish to use in my dream FreeCalypso Libre Dumbphone: a 2.0" 176x220 pixel TFT |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
6 color LCD, strictly transmissive, requiring a backlight - same principal class |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
7 of LCD as in the Pirelli DP-L10, but stepping up in size from Pirelli's 128x128 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
8 to 176x220 pixels. There are many vendors who make suitable LCD modules, and |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
9 there are two specific candidate modules already in use at FreeCalypso HQ as |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
10 part of various prototype rigs. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
11 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
12 The backlight is implemented in exactly the same way on all candidate 2.0" |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
13 176x220 pixel TFT LCD modules I have looked at: it consists of 3 white LEDs, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
14 joined together either at the anode or at the cathode, with the opposite |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
15 terminal brought out separately for each of the 3 LEDs, supporting an |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
16 arrangement where the 3 LEDs are driven in parallel rather than in series. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
17 Each of the 3 LEDs needs to have about 15 mA flowing through it for maximum |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
18 display brightness; lower LED currents will produce lower display brightness, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
19 but going significantly above 15 mA would be bad - too much current would burn |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
20 out the LEDs. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
21 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
22 Exactly how should this backlight be driven in our FreeCalypso Libre Dumbphone |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
23 design? In this article I am going to look at some obvious and less obvious |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
24 ways to drive backlight LEDs, and then present my own novel way (novel in that |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
25 I haven't seen it used in any existing design or seen it recommended anywhere) |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
26 which has already been implemented on our current Luna development platform. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
27 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
28 The trivial way: VBAT and series resistors |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
29 ========================================== |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
30 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
31 The most trivial way to drive a backlight LED or a parallel group of such LEDs |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
32 in a mobile phone whose ultimate power source is a single-cell Li-ion battery |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
33 would be to put a current limiting resistor in series with each LED, and then |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
34 connect each LED+resistor set between VBAT and GND, i.e., across battery |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
35 terminals. (Of course a transistor would also need to be inserted somewhere to |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
36 act as on/off switch, turning the backlight on only when it is needed.) |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
37 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
38 With this trivial arrangement the value of the series resistors (one in series |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
39 with each LED) would need to be calculated as follows: |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
40 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
41 R = (VBAT_max - Vled) / Iled_max |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
42 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
43 where VBAT_max is the maximum allowed battery voltage (4.2 V for typical Li-ion |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
44 batteries), Vled is the voltage drop across a backlight LED, and Iled_max is the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
45 maximum current that should ever flow through each individual LED. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
46 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
47 The big problem with this trivial LED driver approach is that the display |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
48 backlight will glow at its maximum brightness only when the battery is at its |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
49 peak charge, and will dim as the battery discharges. Why so? The series |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
50 resistor value would need to be set per the equation above in order to avoid |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
51 damage to the backlight LEDs (the current through each LED must not exceed |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
52 Iled_max at the highest battery voltage), but then as the battery discharges, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
53 the voltage across each LED series resistor will decline (VBAT - Vled, with |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
54 Vled assumed to be constant), and the current through the resistor (and thus |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
55 through the LED as well) will decline proportionally. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
56 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
57 How do LCD backlights in mainstream commercial phones behave in this regard? |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
58 I have a disassembled Pirelli DP-L10 phone (bare motherboard with the LCD and |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
59 the keypad still attached) which I have hacked up to be powered by a lab bench |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
60 power supply instead of the usual battery, and I did an experiment with it: I |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
61 powered up this Pirelli motherboard with my bench supply, running Pirelli's |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
62 original firmware, I got it into a state where both LCD and keypad backlights |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
63 are on (press any keypad button to turn them back on when the fw turns them off |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
64 by timeout), I turned the voltage knob on the power supply up and down, and I |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
65 observed the brightness of both LCD and keypad backlights. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
66 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
67 Observation: Pirelli's keypad backlight does get noticeably brighter or dimmer |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
68 as VBAT goes up and down, indicating that they do use the trivial driver circuit |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
69 for this one (from fw perspective, Pirelli's keypad backlight is driven or at |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
70 least controlled with Iota LED-B), but the LCD brightness stays exactly the same |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
71 as VBAT ranges from the 4.2 V Li-ion maximum to the low-battery emergency |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
72 shut-off voltage (about 2.8 V) at which the Iota VRPC block involuntarily shuts |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
73 down the entire Calypso subsystem. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
74 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
75 It is not clear exactly how Pirelli's LCD backlight driver circuit is |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
76 implemented. There is a component on their motherboard near the LCD connector |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
77 marked as A3-90E - it might be the LED driver - and there is another little |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
78 component next to it that looks like an inductor, suggesting some kind of boost |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
79 converter. There is no documentation for Pirelli's Giantplus GPM526A0 LCD |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
80 module, but it seems to have just two wires for the backlight, suggesting that |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
81 the two backlight LEDs (this LCD module has 2 backlight LEDs rather than 3) may |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
82 be wired in series (not parallel), in which case a boost converter would be |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
83 absolutely required. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
84 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
85 Boost to 5V, then fixed series resistors |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
86 ======================================== |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
87 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
88 The available schematics for Motorola C139 and C155 phones depict an LCD |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
89 backlight driver circuit that seemed bizarre to me at first: they take VBAT, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
90 boost it up to constant 5V with a step-up charge pump (RT9361A on C139 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
91 schematics, REG710NA-5 on C155 schematics), and feed that 5V to their LCD |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
92 module, which presumably expects fixed 5V backlight power and internally |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
93 contains a fixed resistor in series with each LED. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
94 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
95 This approach certainly accomplishes the goal of constant LCD backlight |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
96 brightness irrespective of battery state of charge, but it does so at a huge |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
97 cost in terms of efficiency. Both RT9361A and REG710NA-5 are step-up charge |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
98 pumps, and they work by doubling the current draw. If we were to use the same |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
99 arrangement for our LCD backlight (3 LEDs, each needing 15 mA), then for 45 mA |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
100 of current flowing through the LEDs, 90 mA will be drawn from the battery. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
101 These are not "smart" boost converters that draw less input current as their |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
102 input voltage goes up (for same I*V power), instead the input current is an |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
103 almost constant 2x the output current, thus the overall efficiency gets very |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
104 poor at higher battery voltages. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
105 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
106 I strongly dislike this approach for its wastefulness, hence I sought another |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
107 way. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
108 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
109 My novel 3.5V LDO approach |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
110 ========================== |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
111 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
112 Datasheets for the LCD modules I am working with specify the drop voltage across |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
113 each of the 3 backlight LEDs as 3.2V. The table of battery voltage thresholds |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
114 (mapping VBAT to battery state of charge percentages) inside Pirelli's firmware |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
115 (located and extracted via thorough reverse eng) has these mappings at the lower |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
116 end: |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
117 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
118 3719 20 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
119 3688 15 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
120 3663 10 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
121 3539 5 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
122 3370 0 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
123 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
124 These numbers make it clear that a battery voltage around 3.5 to 3.6 V means |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
125 that the battery is near empty; combining this "low battery" number with the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
126 datsheet-stated LED drop voltage of 3.2 V gave me this idea: what if we feed |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
127 VBAT to a 3.5V LDO regulator and use this LDO output as the backlight power |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
128 source, with the LED series resistor values computed for 3.5 V supply? This |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
129 approach would produce constant LCD brightness for the wide VBAT range from |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
130 just above 3.5 V (the LDO regulator's dropout is very low) to 4.2 V or above, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
131 without doubling the current draw (for 45 mA flowing through the LEDs, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
132 approximately the same 45 mA will be drawn from the battery), with the only |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
133 anticipated penalty being a possible sharp drop-off in LCD brightness when the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
134 battery gets critically low. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
135 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
136 When I was designing my FC Luna UI development platform (an LCD add-on to the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
137 existing historical third-party Caramel board), I sought to test this idea |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
138 empirically. But before actually building this Luna LCD board, I fortunately |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
139 had the foresight to measure the actual voltage drop across the backlight LEDs, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
140 rather than blindly rely on the datasheet spec of 3.2 V. Back in 2018 I had |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
141 tested my chosen LCD modules in a standalone environment without Calypso: I had |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
142 them switched into 8-bit microprocessor bus interface mode (IM0 pin strapping) |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
143 and I drove them with an FT2232D adapter using FTDI's MCU host bus emulation |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
144 mode. I still have the two hardware setups (LCD modules from two different |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
145 vendors) I had put together back then; the backlight power source in these |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
146 setups is USB 5V, with 110 or 120 ohm LED series resistors. I took the one |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
147 setup on which the point between each LED cathode and the connected series |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
148 resistor is easily accessible for probing, and I measured the voltage at that |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
149 point, to see how the overall 5V gets split between the drop across the LED and |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
150 the drop across the resistor. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
151 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
152 The answer was somewhat unexpected: the voltage drop across each LED turned out |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
153 to be somewhere around 2.9 V, as opposed to the 3.2 V datasheet number. This |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
154 difference in the LED forward drop voltage does highlight one major weakness of |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
155 my close-to-Vled LDO approach: by setting the backlight fixed voltage so close |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
156 to the expected forward drop voltage of the actual LEDs, I am making my circuit |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
157 extremely sensitive to slight variations in that forward drop voltage. If I |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
158 had populated LED series resistors on my Luna LCD board based on the 3.2 V |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
159 assumption (assuming 300 mV drop across each resistor), then the current flowing |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
160 through the LEDs would be double of my design intent (with Vled = 2.9 V, the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
161 voltage drop across each resistor becomes 600 mV), possibly burning out the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
162 LEDs! In contrast, a circuit in which each LED+resistor set is driven with a |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
163 much higher voltage (meaning a larger voltage drop across the resistor and a |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
164 larger resistor value) is much less sensitive to variations in Vled, producing |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
165 much less resulting variation in Iled. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
166 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
167 I ended up building my Luna LCD board with my 3.5V LDO backlight LED driver |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
168 circuit intact, but I populated 38.3 ohm series resistors instead of my |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
169 originally intended 20 ohm value. The resulting circuit works well in practice: |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
170 the LDO puts out a very precise 3.5 V for any higher VBAT input, the LCD |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
171 backlight is bright and visually pleasing, the measured voltage drop across the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
172 resistors with the backlight on is right about 600 mV, meaning that the 2.9 V |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
173 LED forward drop voltage hasn't changed, and the current flowing through each |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
174 LED is in the desired 15-16 mA target range. The LDO regulator's enable input |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
175 also conveniently serves as the backlight on/off control, driven by Calypso |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
176 GPIO 9 in the complete Luna setup. (Calypso MCSI is used only in modem configs, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
177 not in handset configs, thus MCSI pins become GPIOs in the latter, available for |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
178 functions like LCD backlight control.) |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
179 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
180 I then set out to test what happens when the VBAT input to my Luna LCD backlight |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
181 driver falls below 3.5 V. At lower voltages the LDO regulator becomes |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
182 essentially a pass-through, with the low battery voltage applied almost directly |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
183 to each LED+resistor set. The current flowing through the LEDs falls |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
184 accordingly, but the question to be answered was what happens to the visual |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
185 readability of the LCD. The answer turned out to be very positive: I set my |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
186 VBAT-generating lab bench power supply as low as 2.8 V (the emergency shut-off |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
187 voltage for Iota VRPC), and while the display naturally gets very dimmed, it is |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
188 still readable! This finding tells us that my 3.5V LDO approach does not |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
189 present the problem I was afraid of (the display going totally dark in |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
190 critically low battery scenarios when the rest of the phone still has some life |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
191 left), and the only remaining concern with this approach is the extremely high |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
192 sensitivity to variations in LED forward drop voltage. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
193 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
194 Where to go from here |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
195 ===================== |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
196 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
197 If I ever get as far as actually building my desired FreeCalypso dream phone, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
198 what LCD backlight driver circuit should I use? Should I keep the 3.5V LDO |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
199 circuit that appears to work OK in our current Luna setup, or would I be heading |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
200 into trouble with LED forward drop voltage variations? I *really* dislike the |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
201 wastefulness of the seemingly-mainstream approach (boost converter to a higher |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
202 voltage, then series resistors based on that higher voltage), but I don't know |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
203 of any better alternative. If someone with better EE knowledge can suggest a |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
204 non-wasteful approach that would eliminate or at least reduce Vled sensitivity, |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
205 it would be great, otherwise I will have to stick with my current approach and |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
206 hope for the best. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
207 |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
208 I also desire to add PWM control to this LCD backlight, so that the 45 mA |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
209 brightness will be the available maximum, rather than required at all times. |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
210 The plan I have in mind is to insert a transistor between the cathode joining |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
211 point (where either the 3 LED cathodes or the 3 resistors connected to these |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
212 cathodes join) and GND, controlled by Calypso PWL output. Unfortunately this |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
213 approach would be difficult to prototype in our current Luna environment |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
214 because Calypso LT/PWL output is not easily accessible on the Caramel board: it |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
215 does come out of the core module, but it goes to an on-board transistor for an |
b1b027efce8e
doc/LCD-backlight-driver article written
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff
changeset
|
216 on-board indicator LED, and does not go to any header pins or test points. |