We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent b1529e0 commit 0cda258Copy full SHA for 0cda258
mycodo/inputs/power_monitor_rpi_2.py
@@ -275,11 +275,12 @@ def get_measurement(self):
275
276
results = self.sensor.get_power_measurements(duration=0.5)
277
278
+ if self.is_enabled(0):
279
+ self.value_set(0, results['voltage'])
280
+
281
chan = 1
282
for measure_channel in range(1, 7):
283
if self.is_enabled(measure_channel - 1) and measure_channel in results:
- if not self.value_get(0):
- self.value_set(0, results[measure_channel]['voltage'])
284
self.value_set(chan, results[measure_channel]['power'])
285
self.value_set(chan + 1, results[measure_channel]['current'])
286
self.value_set(chan + 2, results[measure_channel]['pf'])
0 commit comments