arendst / Tasmota

Alternative firmware for ESP8266 and ESP32 based devices with easy configuration using webUI, OTA updates, automation using timers or rules, expandability and entirely local control over MQTT, HTTP, Serial or KNX. Full documentation at
https://tasmota.github.io/docs
GNU General Public License v3.0
21.98k stars 4.77k forks source link

Sonoff Dual R3 with Tasmota Switch SW1 is not working #16361

Closed Mario-1977 closed 1 year ago

Mario-1977 commented 2 years ago

PROBLEM DESCRIPTION

A clear and concise description of what the problem is. I flashed 20 Sonoff Dual R3 using Tasmota32-bluetooth 12.1.1.1 and 4 of them are not working properly using the switch inputs. SW2 is working but SW1 is not making any action. On the other hand the relays 1 and 2 work properly when inputs came via WiFi. I don't know if the problem was present using the original firmware because i didn't tested them before flashing. I decided to ask support because 20% of 20 devices are defective and always on SW1. It seems to me too strange. I tried also an older Tasmota32 release (8.5.0) but I didn't see any improvement using the hardware inputs.

REQUESTED INFORMATION

Make sure your have performed every step and checked the applicable boxes before submitting your issue. Thank you!

Program Version 12.1.0.1(bluetooth)

2022-08-24T15:11:13 2_0_4_1/v4.4.3 0T00:30:10 28 5 Vbat power on reset Persiana_cameretta_pt     AndroidAP9830 (82%, -59 dBm) 11n Persiana-cameretta-pt-2156 08:3A:F2:24:E8:6C 192.168.191.172 192.168.191.176 255.255.255.0 192.168.191.176 0.0.0.0   Enabled   192.168.43.42 1883 Disabled Persiana_cameretta_pt DVES_24E86C Persiana_cameretta_pt cmnd/tasmotas/ cmnd/Persiana_cameretta_pt/ cmnd/DVES_24E86C_fb/ Disabled   None   2418796 (ESP32-D0WD-V3 rev.3) 0x16405E (DIO) 4096 KB 4096 KB 1538 KB 1856 KB 103.4 KB (frag. 13%)   1856 KB (used 82%) 1856 KB 320 KB

- [ ] If using rules, provide the output of this command: `Backlog Rule1; Rule2; Rule3`:
```lua
  Rules output here:
- [ ] Set `weblog` to 4 and then, when you experience your issue, provide the output of the Console log:
```lua
  Console output here:

TO REPRODUCE

Steps to reproduce the behavior: I connect the Sonoff Dual R3 to main power (neutral and line) then I connect the L1 phase with SW1

EXPECTED BEHAVIOUR

A clear and concise description of what you expected to happen. I expect the relay action but nothing happen

SCREENSHOTS

If applicable, add screenshots to help explain your problem.

ADDITIONAL CONTEXT

Add any other context about the problem here.

(Please, remember to close the issue when the problem has been addressed)

github-actions[bot] commented 1 year ago

This issue has been automatically marked as stale because it hasn't any activity in last few weeks. It will be closed if no further activity occurs. Thank you for your contributions.

github-actions[bot] commented 1 year ago

This issue was automatically closed because of being stale. Feel free to open a new one if you still experience this problem.

petermicuch commented 1 year ago

Well this sound very familiar @Mario-1977. I bought 10 pieces of Sonoff Dual R3 and on one of them I observed exactly the same behavior as you described here (SW2 working fine, SW1 not). Have you been able to discover the root cause?

Mitch1675 commented 1 year ago

I have the same problem

Mario-1977 commented 1 year ago

I never discovered the root cause. No one help me to understand and solve. Actually I have 5 Sonoff R3 with the same issue of SW1 not working. I'm convinced that is related to some firmware issue so I'm waiting for an update to test it

petermicuch commented 1 year ago

@Mario-1977 - I would definitely like to try with original firmware, but I was not clever enough to back it up before flashing with tasmota. Getting sonoffs firmware for download somewhere seems to be impossible. Would you mind checking difference of CPUs and other components on the board between working and not working ones? I will do the same. And perhaps could you reopen the issue again? It is just strange that multiple people have issues always with switch 1. In my case failrate is 10% in your 20%, which is huge number for Chinese production.

BTW - I like shelly switches much more. They do fit into European wall switches, sonoffs are impossible to fit. I guess in USA wall switches are much bigger than here.

Mitch1675 commented 1 year ago

I tested before flashing. I used eWelink to do the orders as well as with sw1 and sw2 and everything worked. After flashing with Tasmota the sw1 does not work.

arendst commented 1 year ago

Just to verify my working dual r3 uses this template

{"NAME":"Sonoff Dual R3","GPIO":[32,0,0,0,0,0,0,0,0,576,225,0,0,0,0,0,0,0,0,0,0,7296,7328,224,0,0,0,0,160,161,0,0,0,0,0,0],"FLAG":0,"BASE":1}

and switchmodes "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]

petermicuch commented 1 year ago

@arendst I do have newer version of sonoff dual r3, bought just recently: {"NAME":"Sonoff Dual R3 v2","GPIO":[32,0,0,0,0,0,0,0,0,576,225,0,0,0,0,0,0,0,0,0,0,3200,8128,224,0,0,0,0,160,161,0,0,0,0,0,0],"FLAG":0,"BASE":1} But as said, it works on 9 switches out of 10 with no issue. I will try to check if I see any HW difference between those modules later today and will post back here.

petermicuch commented 1 year ago

@Mitch1675 - I totally overlook your comment and it is very valuable that you have tested input before flashing - at least someone is not so in hurry :-)

Could you perhaps post the details of you HW + templates that you used for tasmota?

petermicuch commented 1 year ago

@arendst - I observed working and not working sonoff modules. From the HW point of view, they look the same, same bluetooth chip, same CPU, all part that I was able to read with magnifier glass look the same. Same print out on the board.

Is there anything I could run to gather more data for analysis? Any commands that would help to analyze the problem?

arendst commented 1 year ago

Nope. As it's a haredware issue just get out your multimeter and measure the signal path from the SW connector to the esp32.

petermicuch commented 1 year ago

And is it HW issue even if @Mitch1675 confirmed that eWeLink worked fine?

arendst commented 1 year ago

Yes. If some devices use different gpios we don't know. Therefore it's your task to measure the hardware difference.

arendst commented 1 year ago

Or play with the template and select different type switch for switch1. Be creative. There are switches without pull-ups. Try switch_n or switch_d.

petermicuch commented 1 year ago

Thank you @arendst. I will try to play with it a bit, will be my first time trying to trace something like that. Seem I have to read more about templates in tasmota.

Hoedi1030 commented 2 months ago

My Sonoff DualR3 is suffering from the same problem. Has anyone discovered the cause of Switch1 not responding?

Since I have a second unit which still has the original Sonoff-firmware I am wondering if the original firmware can be backed up and flashed to the "faulty" device?

petermicuch commented 2 months ago

@Hoedi1030 I have not been able to tackle this problem. I even wrote to Sonoff, if they could provide me with the original firmware binary to flash it back. I wnated to check if the switch is working before flashing Tasmota. They replied, that they do not provide firmware binaries 👎.

But since you still have one device without update, could you perhaps share the binary? Try to follow steps here to backup original firmware with esptool.

Hoedi1030 commented 2 months ago

Sure. I will share it as soon as I have made the backup. I will do so probably this weekend. However, I do not know if flashing the firmware from another device would work. I read somewhere, that the firmware (at least for certain Sonoff devices) is tied to the MAC Address, so we'll see...

If someone else could provide an additional backup we would be able to do a file comparison of the binaries and rule out this uncertainty...