unnecessary pub functions removing
and use OMG method instead of low level ones
This commit is contained in:
1 parent
1eebf138c2
commit
25375bb37c
2 files changed
+2
-4
No files matched your search
@@ -72,14 +72,12 @@ void MeasureGPIOInput()
|
||||
if (InputState == HIGH)
|
||||
{
|
||||
trc(F("GPIO HIGH"));
|
||||
pub(subjectGPIOInputtoMQTT, "HIGH");
|
||||
GPIOdata.set("gpio", "HIGH");
|
||||
}
|
||||
if (InputState == LOW)
|
||||
{
|
||||
trc(F("GPIO LOW"));
|
||||
GPIOdata.set("gpio", "LOW");
|
||||
pub(subjectGPIOInputtoMQTT, "LOW");
|
||||
}
|
||||
if (GPIOdata.size() > 0)
|
||||
pub(subjectGPIOInputtoMQTT, GPIOdata);
|
||||
|
||||
Reference in new issue
Block a user