[ST Edge] •• Tasmota Edge •• for Sonoff, Tuya & many other ESP WiFi & HTTP devices - over 2000 Tasmota supported devices

@hongtat I’ve been trying numerous different things in trying to make some Sonoff dyi mode stuff work. It’s been quite challenging. Just realized there seems to be some truncating occurring sometimes in either the request or the body line on the Gateway interface. Let me illustrate:

The “ON” command line was intended for a tasmotized NSPanel, and the line was written as:
< http://192.168.0.37/cm?cmnd=WebQuery http://192.168.0.20:6666 POST {“deviceid”:“whatever”}

After saving the changes and closing out the screen, if you go back into it, the request line seems to have been truncated to what you see on the image. So < “deviceid”:“whatever”} > is missing.

Any idea what is happening there?

I can actually replicate that behavior in the Body field, per the below:

That is how it is written, before I hit save on the page.

After saving and closing out, then coming back to the screen, the content has changed to:

…so the Body line has been truncated almost entirely. Thoughts???

What happens if you replace all " with \" ? Or maybe try ’ instead of "?

@Gusfmm - I have pushed out a fix (version: 2022.11.2) for this. You can reboot the hub to receive the update immediately.

Please let me know whether it works for you.

@hongtat , let me try to explain my current problem.

I have a Shelly1 device flashed with Tasmota used as a garage door opener. I have integrated it into SmartThings using your driver.
In order to close the garage door, the duration of the impulse needs to be short, e.g. 0.5 seconds or 1 second. A command such as PulseTime 10 sets it to 1 second and it works fine.
When the power is lost or the hub reboots, it writes a new rule1 to the device, for example:

Rule1 ON Power#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW":"%value%"}} ENDON ON Power1#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW1":"%value%"}} ENDON ON Power2#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW2":"%value%"}} ENDON ON Power3#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW3":"%value%"}} ENDON ON Power4#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW4":"%value%"}} ENDON ON Power5#state DO
12:07:45.472 RUL: Rule1 +WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW5":"%value%"}} ENDON ON Power6#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW6":"%value%"}} ENDON ON Power7#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW7":"%value%"}} ENDON ON Power8#state DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","STS":{"POW8":"%value%"}} ENDON ON Wifi#Connected DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","cb":"Status 0"} ENDON

That rule completely messes up the PulseTime setting (basically the power stays on for more than 5 seconds), and the result is that the garage door does not close properly (it starts to close, then reverts to open). If I delete the rule or set it to off, everything works normally, but the next time there is a power loss or hub reboot the rule is there again. Can you think of a solution for this annoyance?

Excellent @HongTat, works as expected now, many thanks!

@hongtat Follow up to the above. It doesn’t quite work yet. The same effect happens on the ‘Web Query’ line. It truncates it when it reaches the first " char. So upon saving, the actual POST request is not properly saved (that is, is saved truncated)

What you see below is a slightly more complex request, issued to a Tasmota device. The intent is to have the Tasmota issue a HTTP POST via “WebQuery”. so the complete command line should be:

http://192.168.0.37/cm?cmnd=WebQuery http://192.168.0.23:8081/zeroconf/switch%20POST%20[Content-type: application/json]%20{“deviceid”:“10014a3350”,“data”:{“switch”:“on”}}

It is missing the ’ “deviceid”:“10014a3350”,“data”:{“switch”:“on”}}

This is certainly an uncommon POST command, but it is a possibility nevertheless. Would it be possible for you to attemp to fix?

@LazyPawn - I don’t have a Shelly 1 or garage door opener.

Do you have the template for Shelly 1 that I can try?

Would it work if you add PulseTime 10 without delete or off the rule?

Does it open/close the shelly 1 when you on/off the switch from ST app?

How is the rule being overwritten?

I ask because I am using rules on my devices and if they get deleted by hub reboot that’s a problem.

I’ve pushed another update. Can you try again?

I was just trying and seeing it was working now. Many thanks!!!

@hongtat Little issue still. Rechecking on the Tasmota console, the driver is NOT sending the whole message, yet. It does show it on the Web Gateway, but it does not send it effectively with the POST request.

notice it is truncated when it reaches the ".

@Gusfmm

Try this -

Perfect!!! Many thanks again!

Will there be a garage door support? Option to change icon maybe

If you use a virtual device (garage door) you can connect the actuator and sensor, it works well although does require multiple routines.

I’ve noticed my bulbs color temperature don’t change and the ST device that represents them has a slider that has a temperature range that is way wider than the bulbs can do. If I type in a specific temperature value that is in the bulb range, there doesn’t seem to be any change on the bulb.

I have CCT and RGBW bulbs, running Tasmota v12.

Am I missing something to make the temperature work?

I want to report that the edge device is now showing up on my hub. Thanks @nayelyz

ok guys… i have a new problem.
I am running tasmota 12.2 on a few NodeMCU ESP8266 and contact sensors status updates from the devices to ST app are super delayed.
It takes 2-3 mins (some times longer) for ST App to update the status. The console from the tasmota shows the changes instantly tho.

1 Like

Will the edge drivers now work with Moes switches and dimmers without flashing Tasmota on it?
Such as this wifi dimmer: