Page 1 of 1

ESPEasy/Relay/Switch boolean value required instead binary

Posted: 17 May 2018, 08:54
by kostett
So I have a issue with controlling relay on my ESPEasy Mega on Sonoff TH16 using ioBroker.mobile.
It's all OK, I have setup all parameters, beginning with OpenHAB MQTT and MQTT import, ending with Switch Relay GPIO parameters. But I've discovered one bug (or feature?): ESPEasy.Relay.Switch only can to be 0 and 1, when ioBroker uses for light switches true and false. And I cannot setup ioBroker.mobile because it ignores my switch in cause of inapproprial value.
Now the question: how to set up ESPEasy Mega operating with true/false, but no 1/0?

Re: ESPEasy/Relay/Switch boolean value required instead binary

Posted: 18 May 2018, 15:07
by Drum
Have to look at iOBroker, looks interesting.

Have you tried using rules?
It is an interesting issue as software generally uses boolean value of 1/0 for true/false. I assume iOBroker is sending / receiving MQTT messages? You can probably change the plugin to use whatever iOBroker needs, but for sending rules may work, but I don't know about receiving.

I use Node-red for these things, it is pretty easy to manipulate MQTT messages among other things.

Re: ESPEasy/Relay/Switch boolean value required instead binary

Posted: 20 May 2018, 18:11
by budman1758
I believe there are some as yet to be documented features in the newer firmwares that will make those transformations. See these links.

https://github.com/letscontrolit/ESPEasy/pull/1289

https://www.letscontrolit.com/wiki/inde ... asyFormula