Everything is in the title: I have equipment that is not yet supported under v4, and I therefore want to develop suitable modules (connected outlets « LIDL », without known alternative firmware, but controllable via HTTP, which is currently the case in my home mini-application). How to proceed and where to start (to have the basics and respect the standards)?
Thanks in advance,
Looking forward to your replies,
Jean
Good evening. Not having had the time, nor taken the time to develop a module for Gladys, I am now wondering about it from another angle. Indeed, I am playing with Tasmota and the integration is frankly very simple, via MQTT. I therefore wonder if it would not be simpler to rewrite my Python code that interfaces a home API to make it support MQTT, since what is controlled is an automatic watering system (homemade based on a Raspberry PI Zero W …), so totally adaptable … Currently, the watering circuit is controlled via an HTTP request: http://watering/{set,get}/{pump}/{on,off}.
What do you think?
Thanks in advance for your comments which will be precious for me.
You can therefore use this action to call the API of your automatic watering system.
If you want to have a device in Gladys to manually control your device, you can create a « virtual » device in the MQTT integration, and then in the scenes, when the device goes to 1, send an HTTP request to turn on the watering, and when it goes to 0, send an HTTP request to turn off the watering.
Method via MQTT
Otherwise, you can indeed make an MQTT script that will allow you to turn your watering system on/off.
We have MQTT API documentation on the site:
I also made a video on the subject recently:
(In the second part of the video, I take the example of an on/off, so like what you want to do)
The scenes are created, but… I think we can do better, as I have two scenes per solenoid valve to control (one scene turns on, the other turns off), as the URL contains the ID of the solenoid valve in question and the expected state (ON/1 or OFF/0). I read that it is possible to play with variables, so we can imagine creating a virtual MQTT device (I am actually very interested in knowing how to do this…) that calls a scene with two variables: the ID and the state? Is this possible?
Thank you for your response, but I’ve spent time looking, without really finding any documentation that would allow me to create the MQTT device in question, and then use it in the dashboard… If it were possible to guide me, that would be really nice (I think I’m not the only one who will appreciate your help…).