brewer 0.1.2 → 0.1.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/Gemfile.lock +1 -1
- data/lib/brewer/controller.rb +5 -7
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: dcccf059d6566dde3876cb9d1869e280d446182d
|
4
|
+
data.tar.gz: 67d320ad0604bc1138367a0f58e5150941a83662
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d09e663ecc78adc4ce6c858c2c8af8eefa73772b2b08b47f4d7ab94e3c938189f8035b30bbaa71daba362dd778ce1bb4b6929f90ecacd5a46031fe21c3d0df8a
|
7
|
+
data.tar.gz: 686a6f129c7be200fa9f1728c3cac79bcbbf80570ed97755ebe5071fc849567a95f8fba4988d294149bead2fd0c9aa0de3d4b3a825a8c880426c94acef5a4346
|
data/Gemfile.lock
CHANGED
data/lib/brewer/controller.rb
CHANGED
@@ -56,7 +56,7 @@ module Brewer
|
|
56
56
|
return script("set_pid_off")
|
57
57
|
end
|
58
58
|
end
|
59
|
-
|
59
|
+
|
60
60
|
# This is for jake's js
|
61
61
|
def pid_to_web
|
62
62
|
return {
|
@@ -135,8 +135,6 @@ module Brewer
|
|
135
135
|
return "off"
|
136
136
|
end
|
137
137
|
end
|
138
|
-
|
139
|
-
|
140
138
|
|
141
139
|
# Returns the status of all relays
|
142
140
|
def all_relays_status
|
@@ -159,13 +157,13 @@ module Brewer
|
|
159
157
|
|
160
158
|
def relays_status_to_web
|
161
159
|
statuses = relays_status
|
162
|
-
|
160
|
+
statuses.each do |k, v|
|
163
161
|
if v == "on"
|
164
|
-
|
162
|
+
statuses[k] = 1
|
165
163
|
else
|
166
|
-
|
164
|
+
statuses[k] = 0
|
167
165
|
end
|
168
|
-
|
166
|
+
end
|
169
167
|
end
|
170
168
|
|
171
169
|
# Give this a relay configuration hash and it will set the relays to that configuration
|