forked from snaptec/openWB
-
Notifications
You must be signed in to change notification settings - Fork 0
/
auslademodus.sh
86 lines (82 loc) · 3.2 KB
/
auslademodus.sh
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
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
#!/bin/bash
auslademodus(){
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatus"; then
runs/set-current.sh 0 m
openwbDebugLog "CHARGESTAT" 0 "LP1, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuss1"; then
runs/set-current.sh 0 s1
openwbDebugLog "CHARGESTAT" 0 "LP2, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuss2"; then
runs/set-current.sh 0 s2
openwbDebugLog "CHARGESTAT" 0 "LP3, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp4"; then
runs/set-current.sh 0 lp4
openwbDebugLog "CHARGESTAT" 0 "LP4, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp5"; then
runs/set-current.sh 0 lp5
openwbDebugLog "CHARGESTAT" 0 "LP5, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp6"; then
runs/set-current.sh 0 lp6
openwbDebugLog "CHARGESTAT" 0 "LP6, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp7"; then
runs/set-current.sh 0 lp7
openwbDebugLog "CHARGESTAT" 0 "LP7, Lademodus Stop. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp8"; then
runs/set-current.sh 0 lp8
openwbDebugLog "CHARGESTAT" 0 "LP8, Lademodus Stop. Stoppe Ladung"
fi
if (( ladeleistung > 300 )); then
runs/set-current.sh 0 m
runs/set-current.sh 0 s1
runs/set-current.sh 0 s2
runs/set-current.sh 0 lp4
runs/set-current.sh 0 lp5
runs/set-current.sh 0 lp6
runs/set-current.sh 0 lp7
runs/set-current.sh 0 lp8
openwbDebugLog "CHARGESTAT" 0 "Alle Ladepunkte, Lademodus Stop. Stoppe Ladung"
fi
exit 0
}
semiauslademodus(){
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatus"; then
runs/set-current.sh 0 m
openwbDebugLog "CHARGESTAT" 0 "LP1, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuss1"; then
runs/set-current.sh 0 s1
openwbDebugLog "CHARGESTAT" 0 "LP2, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuss2"; then
runs/set-current.sh 0 s2
openwbDebugLog "CHARGESTAT" 0 "LP3, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp4"; then
runs/set-current.sh 0 lp4
openwbDebugLog "CHARGESTAT" 0 "LP4, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp5"; then
runs/set-current.sh 0 lp5
openwbDebugLog "CHARGESTAT" 0 "LP5, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp6"; then
runs/set-current.sh 0 lp6
openwbDebugLog "CHARGESTAT" 0 "LP6, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp7"; then
runs/set-current.sh 0 lp7
openwbDebugLog "CHARGESTAT" 0 "LP7, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
if grep -q 1 "/var/www/html/openWB/ramdisk/ladestatuslp8"; then
runs/set-current.sh 0 lp8
openwbDebugLog "CHARGESTAT" 0 "LP8, Lademodus Standby. Ladefreigabe noch aktiv. Stoppe Ladung"
fi
exit 0
}