-
Notifications
You must be signed in to change notification settings - Fork 20
/
battery1cell.cfg
60 lines (48 loc) · 1.7 KB
/
battery1cell.cfg
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
[files]
interface = 'from getatod import Raw'
alarms = 'from alarmsnull import Alarms'
logfile = 'log'
# errfile is location and name of error log
errfile = 'data/errorlog'
summaryfile = 'summary'
hoursummaryfile = '/dev/null'
daysummaryfile = '/dev/null'
monthsummaryfile = '/dev/null'
yearsummaryfile = '/dev/null'
[battery]
name = 'My'
numcells = 1
capacity = 360
ahloss = 3.0
vreset = 27.6 # voltage to reset DOD counter
ireset = 9.0 # current to reset DOD counter
ilowcurrent = 7.2 # C/50 lowcurrent voltage logging current
[AtoDs]
atod0 = 'AtoD.ADS1115(address=0x48)'
[VoltageInputs]
v1 = 'atod0.read_adc(0, gain=2)*0.06250197'
vbat = 'v1'
[CurrentInputs]
iin1 = 'atod0.read_adc_difference(2, gain=16)'
iin2 = 'atod0.read_adc_difference(3, gain=16)'
iin3 = 'self.current[0] - self.current[1]'
[sampling]
sampletime = 1.002
samplesav = 10
[calibrate]
pcurrent = 0 # parasitic current in A not measured (battery monitor power)
batvgain = 1 # resistor divider (2.49kohm+33.2kohm)/2.49kohm
# count of 32767=256mV, so 1mV=128 counts
# so gain=current@shuntvoltage/128*shuntvoltage
currentgain = [0.010417, 0.005208, 0.0010417]
currentoffset = [-0.0, 0.0, 0.0]
delta = [0.0, 0.0, 0.0, 0.0]
measured = [0.0, 3.0, 6.0, 9.0, 12.0]
displayed = [0.0, 3.0, 6.0, 9.0, 12.0]
measureddelta = [ 0.0, 3.000, 3.000, 3.000, 3.000]
displayeddelta = [ 0.0, 3.000, 3.000, 3.000, 3.000]
[alarms]
# each alarm has five attributes, the first is the alarm initialisation code
# if the second attribute test is true the third attribute will be executed
# if the fourth attribute is true the fith attribute will be executed
# hvc = ['GPIO.setup("P8_10", GPIO.OUT)', 3.590, 'GPIO.output("P8_10", GPIO.HIGH)', 3.600, 'GPIO.output("P8_10", GPIO.LOW)']