Four I2C sensors - I2C bus deadlock #12629
-
|
Dear all, For quite some time I used two I2C sensors (one air quality and one temperature/humidity sensors) with a ESP8266 device with Tasmota 9.x based firmware. I compile my firmware using gitpod. This works quite efficient without any issues. For a second project I duplicated the sensors to be able to have a relative measurement inside and outside a room. So now I have two air quality sensors and two temperature humidity sensors running. After some time the sensors stop working and I2CScan provides an output Error 4 at 0x01. Most likely that the I2C bus is in deadlock. The root cause is not clear to me yet. But in case someone has similar issues with I2C communication, I'd like to propose a fix based on https://github.com/maarten-pennings/I2Cbus In I call this function twice with With this setup it works for myself for quite some time now. If someone has a clue / idea what could cause the I2C deadlock and how to prevent it, please let me know. Additional changes:
|
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 3 replies
-
|
The root cause of And most Tasmota I2C drivers only supports one device of the relevant type (a few drivers do support two or even more). |
Beta Was this translation helpful? Give feedback.
The root cause of
Error 4 at 0x01is usually bad wiring/connections, with fixing to focus on making that correct. Sometimes ensuring appropriate pullup resistors on the I2C bus can help, depending on devices.And most Tasmota I2C drivers only supports one device of the relevant type (a few drivers do support two or even more).