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
22.2k stars 4.81k forks source link

PZEM-004-T and DS18x20 are not work simultaneously #22089

Closed Csutiman closed 2 months ago

Csutiman commented 2 months ago

PROBLEM DESCRIPTION

Using PZEM-004-T and DS18x20 separately is working, but when both are applied only PZEM-004-T is working.

REQUESTED INFORMATION

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

- [x] If using rules, provide the output of this command: `Backlog Rule1; Rule2; Rule3`:
```lua
  Rules output here:
20:49:21.726 CMD: Grp 0, Cmd 'BACKLOG', Idx 1, Len 19, Pld -99, Data 'Rule1; Rule2; Rule3'
20:49:21.832 SRC: Backlog
20:49:21.835 CMD: Grp 0, Cmd 'RULE', Idx 1, Len 0, Pld -99, Data ''
20:49:21.842 MQT: stat/tasmota_754518/RESULT = {"Rule1":{"State":"OFF","Once":"OFF","StopOnError":"OFF","Length":0,"Free":511,"Rules":""}}
20:49:21.847 DMP: A2 00 00 00 00 00 A2
20:49:22.059 SRC: Backlog
20:49:22.063 CMD: Grp 0, Cmd 'RULE', Idx 2, Len 0, Pld -99, Data ''
20:49:22.073 MQT: stat/tasmota_754518/RESULT = {"Rule2":{"State":"OFF","Once":"OFF","StopOnError":"OFF","Length":0,"Free":511,"Rules":""}}
20:49:22.311 SRC: Backlog
20:49:22.314 CMD: Grp 0, Cmd 'RULE', Idx 3, Len 0, Pld -99, Data ''
20:49:22.322 MQT: stat/tasmota_754518/RESULT = {"Rule3":{"State":"OFF","Once":"OFF","StopOnError":"OFF","Length":0,"Free":511,"Rules":""}}
- [x] Set `weblog` to 4 and then, when you experience your issue, provide the output of the Console log:
```lua
  Console output here:
20:50:14.503 NRG: EnergyTotal[0] 810.9130 kWh
20:50:14.748 DMP: A0 00 E3 01 00 00 84
20:50:15.506 DMP: A1 00 00 00 00 00 A1
20:50:15.754 DMP: A2 00 00 00 00 00 A2
20:50:16.519 DMP: A3 0C 5F A1 00 00 AF
20:50:16.521 NRG: EnergyTotal[0] 810.9130 kWh
20:50:16.766 DMP: A0 00 E3 00 00 00 83
20:50:17.522 DMP: A1 00 00 00 00 00 A1
20:50:17.767 DMP: A2 00 00 00 00 00 A2
21:15:04.767 NRG: EnergyTotal[0] 810.9130 kWh
21:15:05.073 DMP: A0 00 E3 07 00 00 8A
21:15:05.738 DMP: A1 00 00 00 00 00 A1
21:15:05.989 DMP: A2 00 00 00 00 00 A2
21:15:06.744 DMP: A3 0C 5F A1 00 00 AF
21:15:06.747 NRG: EnergyTotal[0] 810.9130 kWh

TO REPRODUCE

Steps to reproduce the behavior:

  1. configure module type to generic
  2. PZEM-004-T to GPIO1 (RX) and GPIO3 (TX)
  3. press save, restart and check homepage
  4. image
  5. remove PZEM-004-T configs and configure GPIO 4 DS18x20
  6. press save, restart and check homepage
  7. image
  8. add to configuration of PZEM-004-T and keep DS18x20 on GPIO4
  9. press save, restart and check homepage
  10. image

EXPECTED BEHAVIOUR

PZEM-004-T and DS18x20 can be used simultaneously.

SCREENSHOTS

See in reproduction steps

ADDITIONAL CONTEXT

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

barbudor commented 2 months ago

What would be usefull are the logs at start when DS18x20 is supposed to be detected

If you configure both PZEM+DS18x20 but do not connect the PZEM (only DS18x20), can you see the DS18x20 ?

How is connected the DS18x20 ? Long line ? short line ? External pull-up ? Fully powered (not parasitic power) ?