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

7 posts were split to a new topic: [Edge drivers] Connection error Tasmota driver

HC-SR04 support?

I’m building a presence sensor for a vehicle and I’d like to use an esp32 and an ultrasonic sensor I’ve got laying around. I’ve got it configured correctly on the tasmota webui, but I am unable to get any distance output in the ST app (tried creating each type of sensor - contact/smoke/water/alarm) and the sensor discovery hasn’t provided anything I can use. Anyone have any ideas?

Screenshot 2023-04-06 105216

elguapo I’m curious how your presence sensor will work. Is it to tell that you have parked in the right spot?

It’s not supported yet. Can I have the output of http://<-IP->/cm?cmnd=status 0 ?

{“Status”:{“Module”:1,“DeviceName”:“Tasmota”,“FriendlyName”:[“Tasmota”],“Topic”:“tasmota_9A40A8”,“ButtonTopic”:“0”,“Power”:0,“PowerOnState”:3,“LedState”:1,“LedMask”:“FFFF”,“SaveData”:1,“SaveState”:1,“SwitchTopic”:“”,“SwitchMode”:[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],“ButtonRetain”:0,“SwitchRetain”:0,“SensorRetain”:0,“PowerRetain”:0,“InfoRetain”:0,“StateRetain”:0,“StatusRetain”:0},“StatusPRM”:{“Baudrate”:115200,“SerialConfig”:“8N1”,“GroupTopic”:“tasmotas”,“OtaUrl”:“https://ota.tasmota.com/tasmota32/release/tasmota32.bin",“RestartReason”:"Vbat power on reset”,“Uptime”:“0T00:01:20”,“StartupUTC”:“2023-04-07T19:00:49”,“Sleep”:50,“CfgHolder”:4617,“BootCount”:21,“BCResetTime”:“2023-03-24T02:25:44”,“SaveCount”:43},“StatusFWR”:{“Version”:“12.4.0(tasmota)”,“BuildDateTime”:“2023-02-24T15:36:01”,“Core”:“2_0_6”,“SDK”:“4.4.3.20230129”,“CpuFrequency”:160,“Hardware”:“ESP32-D0WDQ6 rev.1”,“CR”:“416/699”},“StatusLOG”:{“SerialLog”:2,“WebLog”:2,“MqttLog”:0,“SysLog”:0,“LogHost”:“”,“LogPort”:514,“SSId”:[“bpr”,“”],“TelePeriod”:300,“Resolution”:“558180C0”,“SetOption”:[“00008009”,“2805C80001000600003C5A0A192800000000”,“00000080”,“00006000”,“00004000”,“00000000”]},“StatusMEM”:{“ProgramSize”:1511,“Free”:1368,“Heap”:157,“StackLowMark”:3,“PsrMax”:0,“PsrFree”:0,“ProgramFlashSize”:4096,“FlashSize”:4096,“FlashChipId”:“164020”,“FlashFrequency”:40,“FlashMode”:“DIO”,“Features”:[“00000809”,“9F9AD7CF”,“0015A001”,“B7F7BFCF”,“05DA9BC0”,“E0360DC7”,“480840D2”,“20200000”,“D43C482D”,“000080B1”],“Drivers”:“1,2,3,4,5,7,8,9,10,11,12,14,16,17,20,21,24,26,27,29,34,35,38,50,52,59,60,62,63,66,82,86,87,88”,“Sensors”:“1,2,3,5,6,7,8,9,10,11,12,13,14,15,17,18,19,20,21,22,26,31,34,37,39,40,42,43,45,51,52,55,56,58,59,64,66,67,74,85,92,95,98,103,127”},“StatusNET”:{“Hostname”:“tasmota-9A40A8-0168”,“IPAddress”:“192.168.X”,“Gateway”:“192.168.X”,“Subnetmask”:“255.255.255.0”,“DNSServer1”:“192.168.X”,“DNSServer2”:“1.1.1.1”,“Mac”:“XX”,“IP6Global”:“XX”,“IP6Local”:“XX”,“Ethernet”:{“Hostname”:“”,“IPAddress”:“0.0.0.0”,“Gateway”:“0.0.0.0”,“Subnetmask”:“0.0.0.0”,“DNSServer1”:“192.168.X”,“DNSServer2”:“1.1.1.1”,“Mac”:“00:00:00:00:00:00”,“IP6Global”:“”,“IP6Local”:“”},“Webserver”:2,“HTTP_API”:1,“WifiConfig”:4,“WifiPower”:17.0},“StatusMQT”:{“MqttHost”:“”,“MqttPort”:1883,“MqttClientMask”:“DVES_%06X”,“MqttClient”:“DVES_9A40A8”,“MqttUser”:“DVES_USER”,“MqttCount”:0,“MAX_PACKET_SIZE”:1200,“KEEPALIVE”:30,“SOCKET_TIMEOUT”:4},“StatusTIM”:{“UTC”:“2023-04-07T19:02:09”,“Local”:“2023-04-07T20:02:09”,“StartDST”:“2023-03-26T02:00:00”,“EndDST”:“2023-10-29T03:00:00”,“Timezone”:“+01:00”,“Sunrise”:“06:15”,“Sunset”:“19:28”},“StatusSNS”:{“Time”:“2023-04-07T20:02:09”,“SR04”:{“Distance”:85.8}},“StatusSTS”:{“Time”:“2023-04-07T20:02:09”,“Uptime”:“0T00:01:20”,“UptimeSec”:80,“Heap”:155,“SleepMode”:“Dynamic”,“Sleep”:50,“LoadAvg”:25,“MqttCount”:0,“Berry”:{“HeapUsed”:3,“Objects”:43},“Wifi”:{“AP”:1,“SSId”:“bpr”,“BSSId”:“D4:5D:64:A3:AD:00”,“Channel”:10,“Mode”:“11n”,“RSSI”:60,“Signal”:-70,“LinkCount”:1,“Downtime”:“0T00:00:07”}}}

network details X’d out

Presence sensor will be used for a conditional to automatically close garage door, ie:
If {garage door sensor} = open
And
If {sensor value} > xxx cm and remains in this state for x minutes
And
{member location} = not at home
Then
trigger {garage door} close

@elguapo - I have pushed an update (2023.4.1) that includes support for SR04 - “distance”.

If you have already created a Tasmota device (any Tasmota device except Sensor), it should automatically discover and create a new device for it.

@hongtat It works swimmingly! Thank you very much.

On the webui, the hc-sr04 distance is updated ~every second. In the ST app, it takes 76-77 seconds to update a distance change. Any idea about the disparity?

Could you try executing this in the Tasmota SR04 device? Does it update in the ST app after that?

Backlog Rule3 ON SR04#Distance DO WebQuery %mem1% POST %mem2% {"Mac":"%MACADDR%","SNS":{"SR04":{"Distance":%value%}}} ENDON ;Rule3 1

Hello, I would use a diy ir blaster to control tv and air conditioner.

I Set the device lik ir blaster and created 2 child devices, virtual Ac and virtual button. Now i’m able to control this device.

The ui of the virtual ac is similar with the original remote. It’s possible to create an ui for tv remote like this?

Thanks

I’ve noticed issues with the DS03 fan speed being incongruent between SmartThings and the switch. Its as if there is an offset. The fan will be set to max on the switch and appear as high in SmartThings. I’ll set the fan to max on the app and the switch will briefly go to max, but then the app will revert to high and the fan will slow down to high. Has anyone else noticed similar behavior? It’s almost as if there is a 0 vs 1 indexing offset.

Hello i have strange issues using the IR bridge to control a Samsung Air conditioner. Some functions doesn’t work, ie I can’t increase or decrease the temperature, I only power on and off and set the mode.

Your virtual device use the commands that are stored in my tasmota library or use a proprietary library?

Another thing is that in the selectable options in your ui there’s not display light (that in the library is off by default), and when i send the commads my ac display goes off.

Could you add this option?

Thanks

I’ll take a look.

It’s using the IRHVAC in Tasmota.

Yes I suppose this, but at least for the temperarature + and - samsung_ac I think that there is an error somewhere in your driver.

And the possibility to set light on for the display could be very useful.

Thanks

What is the IRHVAC command sent by the driver and what is the IRHVAC command that works for the temperature? And is the AC in the supported list?

Yes is supported, the problem is for this 2 buttons:

I saw the console on tasmota that even if i set the temperature of 22 in your ui, the command sent to the ac is 20. Any change about the temperature in ui don’t reported in sent commands.

this is the command sent even if 22 is on the UI:

04:43:20.101 RSL: RESULT = {“IRHVAC”:{“Vendor”:“SAMSUNG_AC”,“Model”:1,“Mode”:“Cool”,“Power”:“On”,“Celsius”:“On”,“Temp”:20,“FanSpeed”:“Min”,“SwingV”:“Off”,“SwingH”:“Off”,“Quiet”:“Off”,“Turbo”:“Off”,“Econo”:“Off”,“Light”:“Off”,“Filter”:“Off”,“Clean”:“Off”,“Beep”:“Off”,“Sleep”:-1}}

it’s the same for me, the temperature can’t be set

I have the same issue with the temperature as reported by Vincenzo/bega. This is what I got from the logcat via smartthings-cli:

ERROR Tasmota Edge Virtual Air Conditioner thread encountered error: [string “st/dispatcher.lua”]:233: Error encountered while processing event for <Device: 039f65cb-632c-47d4-b990-abd58837fe2f (Virtual Air Conditioner)>:*

  • arg1: table: 0x253f208*
    [string “st/capabilities/init.lua”]:226: Invalid value for Thermostat Cooling Setpoint.coolingSetpoint value: {value=22} error: Required field missing: unit

Using the IRHVAC command in your Virtual Button works fine (used one the Tasmota logs gave when using the original remote):

IRHVAC {“Vendor”:“MITSUBISHI_HEAVY_152”,“Model”:-1,“Mode”:“Heat”,“Power”:“On”,“Celsius”:“On”,“Temp”:22,“FanSpeed”:“Auto”,“SwingV”:“Off”,“SwingH”:“Off”,“Quiet”:“Off”,“Turbo”:“Off”,“Econo”:“Off”,“Light”:“Off”,“Filter”:“Off”,“Clean”:“Off”,“Beep”:“Off”,“Sleep”:-1}

Hi im having an issue with rf ive created an rf momentry button and added the remote code but when i press it nothing happens. Any help would be great .
Thanks
Martin