Skip to content

Commit b82375a

Browse files
authored
Merge pull request #69 from kaulketh/develop
Develop
2 parents 45fc43a + 96b3963 commit b82375a

File tree

8 files changed

+131
-179
lines changed

8 files changed

+131
-179
lines changed

bot/conf/greenhouse_config.py

+13-16
Original file line numberDiff line numberDiff line change
@@ -31,8 +31,8 @@
3131

3232

3333
# keyboard configs
34-
kb1 = [[lib.group1[1], lib.group1[2], lib.group1[3], lib.group3[1]],
35-
[lib.group3[2], lib.group2[1], lib.group2[2], lib.group2[3]],
34+
kb1 = [[lib.channel_1, lib.channel_2, lib.channel_3, lib.channel_4],
35+
[lib.channel_5, lib.channel_6, lib.channel_7, lib.channel_8],
3636
[lib.grouping],
3737
[lib.stop_bot, lib.live_stream, lib.reload]
3838
]
@@ -53,20 +53,17 @@
5353
# Raspi core temperature
5454
core_temp_format = '{0}{1}{4}{2}{3}°C'
5555

56-
# def board pins/channels, refer hardware/raspi_gpio.info
57-
RELAIS_01 = 29
58-
RELAIS_02 = 31
59-
RELAIS_03 = 33
60-
RELAIS_04 = 35
61-
RELAIS_05 = 37
62-
RELAIS_06 = 36
63-
RELAIS_07 = 38
64-
RELAIS_08 = 40
65-
66-
GROUP_ALL = (RELAIS_01, RELAIS_02, RELAIS_03, RELAIS_04, RELAIS_05, RELAIS_06, RELAIS_07, RELAIS_08)
67-
GROUP_01 = (RELAIS_01, RELAIS_02, RELAIS_03)
68-
GROUP_02 = (RELAIS_06, RELAIS_07, RELAIS_08)
69-
GROUP_03 = (RELAIS_04, RELAIS_05)
56+
# board pins of relays, refer hardware/raspi_gpio.info
57+
RELAY_01 = 29
58+
RELAY_02 = 31
59+
RELAY_03 = 33
60+
RELAY_04 = 35
61+
RELAY_05 = 37
62+
RELAY_06 = 36
63+
RELAY_07 = 38
64+
RELAY_08 = 40
65+
66+
ALL = (RELAY_01, RELAY_02, RELAY_03, RELAY_04, RELAY_05, RELAY_06, RELAY_07, RELAY_08)
7067

7168
# live stream address
7269
live = access.live

bot/conf/lib_english.py

+9-3
Original file line numberDiff line numberDiff line change
@@ -31,9 +31,15 @@
3131
btn_finished = 'Finished'
3232
btn_cancel = cancel
3333
reload = 'Reload'
34-
group1 = ('Channel 1 to 3', 'Channel 1', 'Channel 2', 'Channel 3')
35-
group2 = ('Channel 6 to 8', 'Channel 6', 'Channel 7', 'Channel 8')
36-
group3 = ('Channel 4 and 5', 'Channel 4', 'Channel 5')
34+
35+
channel_1 = 'Channel 1'
36+
channel_2 = 'Channel 2'
37+
channel_3 = 'Channel 3'
38+
channel_4 = 'Channel 4'
39+
channel_5 = 'Channel 5'
40+
channel_6 = 'Channel 6'
41+
channel_7 = 'Channel 7'
42+
channel_8 = 'Channel 8'
3743

3844
temp = 'Temperature'
3945
hum = 'Humidity'

bot/conf/lib_german.py

+8-3
Original file line numberDiff line numberDiff line change
@@ -33,9 +33,14 @@
3333
btn_finished = 'Fertig'
3434
btn_cancel = cancel
3535

36-
group1 = ('Kanal 1 bis 3', 'Kanal 1', 'Kanal 2', 'Kanal 3')
37-
group2 = ('Kanal 6 bis 8', 'Kanal 6', 'Kanal 7', 'Kanal 8')
38-
group3 = ('Kanal 4 und 5', 'Kanal 4', 'Kanal 5')
36+
channel_1 = 'Kanal 1'
37+
channel_2 = 'Kanal 2'
38+
channel_3 = 'Kanal 3'
39+
channel_4 = 'Kanal 4'
40+
channel_5 = 'Kanal 5'
41+
channel_6 = 'Kanal 6'
42+
channel_7 = 'Kanal 7'
43+
channel_8 = 'Kanal 8'
3944

4045
temp = 'Temperatur'
4146
hum = 'Luftfeuchtigkeit'

bot/ext_greenhouse.py

+6-15
Original file line numberDiff line numberDiff line change
@@ -22,28 +22,19 @@
2222
import peripherals.monitor as monitor
2323

2424
logging = log.get_logger()
25-
thread = threading.Thread(target=monitor.main, name='ext bot temperature monitoring')
25+
thread = threading.Thread(target=monitor.main, name='ExtendedBot temperature monitoring')
2626
thread.start()
2727

2828
pins_state = False
2929

3030
markdown = "-d parse_mode='Markdown'"
3131
no_parse_mode = conf.lib.empty
3232

33-
relais01 = conf.RELAIS_01
34-
relais02 = conf.RELAIS_02
35-
relais03 = conf.RELAIS_03
36-
relais04 = conf.RELAIS_04
37-
relais05 = conf.RELAIS_05
38-
relais06 = conf.RELAIS_06
39-
relais07 = conf.RELAIS_07
40-
relais08 = conf.RELAIS_08
41-
42-
group_all = (relais01, relais02, relais03, relais04,
43-
relais05, relais06, relais07, relais08)
44-
group_one = (relais01, relais02, relais03)
45-
group_two = (relais06, relais07, relais08)
46-
group_three = (relais04, relais05)
33+
group_all = (conf.RELAY_01, conf.RELAY_02, conf.RELAY_03, conf.RELAY_04,
34+
conf.RELAY_05, conf.RELAY_06, conf.RELAY_07, conf.RELAY_08)
35+
group_one = (conf.RELAY_01, conf.RELAY_02, conf.RELAY_03)
36+
group_two = (conf.RELAY_06, conf.RELAY_07, conf.RELAY_08)
37+
group_three = (conf.RELAY_04, conf.RELAY_05)
4738

4839

4940
# water a group of targets

0 commit comments

Comments
 (0)