Hi! My name’s Enrique.
I’m wondering if there is an easy way to connect a new I2C sensor to emonTH v2.
As far as I’m concerned, you can add multiple I2C sensors to the same Arduino pins bacause you can communicate with each one differently by using sensors adresses.
The problem is, I2C pins (PC4 and PC5) are directly connected to SI7021 temp. and hum. sensor and I can’t access them to add new devices, at least there’s no way that I can see.
Has someone found a solution to this?
Thank you so much.
I’m currently working on another solution. It is possible to use any digital in/out as I2C with a special library called SoftwareI2C. So far I had no luck but I’m still confident that it should work. The advantage is that I can use the pins which are on the pin header like D3 and D5.
I got it working with PD3 and PD5 and a air quality sensor (sgp30). I modified this software I2C library (Arduino Playground - SoftwareI2CLibrary) to work with the sgp30 test sketch. The modifications was basically the separation to header and code files. Then I had to modify the library for the sgp30 to use the software I2C.