annotate charging/c1xx/standard @ 8:53223d745c35

Makefile added for make install
author Mychaela Falconia <falcon@freecalypso.org>
date Sat, 13 Jan 2018 07:40:43 +0000
parents 84fbaf39686a
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
7
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
1 # This is the "standard" charging config for Mot C1xx phones running
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
2 # FreeCalypso fw. The key points are:
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
3 #
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
4 # 1) The battery is charged to the full 4.2 V, not a lower voltage,
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
5 # for traditional mobile phone usage patterns in which the user charges
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
6 # the battery fully before going out.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
7 #
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
8 # 2) The start threshold is set fairly high on the reasoning that if
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
9 # the user connects the charging power source (which is not USB and thus
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
10 # not required for computer connection), it means that she actually intends
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
11 # to charge the battery, but it is set to 4100 mV instead of "always"
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
12 # so that if the battery is really full, an explicit AT@CHG=1 command
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
13 # or a future UI equivalent will be needed to force a charging start.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
14 #
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
15 # 3) The restart threshold is a reasonable setting so if the phone is left
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
16 # plugged into the charger for a long time, the user won't be surprised
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
17 # with a battery that has run down significantly after the completion
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
18 # of the initial charging cycle.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
19
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
20 start-threshold 4100 # mV
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
21 restart-threshold 3900 # mV
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
22
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
23 # Constant Voltage charging parameters mostly copied from Pirelli
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
24
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
25 ci2cv-threshold 4245 # mV, lowered from Pirelli's 4250
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
26 cv-initial-setpoint 4220 # mV
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
27 cv-ctrl-loop-high 4236 # mV
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
28 cv-ctrl-loop-low 4170 # mV, bumped up from Pirelli's 4160
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
29 cv-dac-max-incr 8 # DAC units
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
30 cv-dac-max-decr 50 # DAC units
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
31 cv-ctrl-loop-sample-count 6 # our logic is simpler than Pirelli's
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
32 overvoltage 4280 # mV, bumped up from Pirelli's 4270
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
33
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
34 # For the current settings, keep in mind that C1xx phones use a current
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
35 # measurement resistor of 0.15R instead of TI's "canonical" value of 0.20R,
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
36 # hence the conversion factor between mA and ADC/DAC numbers changes
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
37 # accordingly. The CI current setting is based on what Motorola's fw
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
38 # has been observed to set, but the end current setting is our own,
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
39 # chosen empirically.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
40
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
41 ci-current 280 # DAC units, about 320 mA
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
42 end-current 60 # ADC units, about 68 mA
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
43 ichg-max-spike 26 # ADC units, about 30 mA
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
44 ichg-low-samples-needed 30 # sample count
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
45
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
46 # The apppropriate charging time limit and restart delay have yet to be
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
47 # determined; for now we give it a super-generous 6 h charging time limit
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
48 # and 2 h restart delay.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
49
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
50 charging-time-limit 21600
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
51 restart-delay 7200
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
52
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
53 # Motorola's fw does not seem to use the I2V offset mechanism,
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
54 # but we use the same setting as Pirelli.
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
55
84fbaf39686a charging/c1xx/standard: created
Mychaela Falconia <falcon@freecalypso.org>
parents:
diff changeset
56 i2v-offset 0x18 # register setting