Can different I2C cable lengths impact the temperature readings?

Hiya there.

I did my first project with a temperature sensor and noticed that the temperature fluctuated if I changed the cable lengths. Upon initial testing, it seems the longer the cable is the lower the temperature.
Even if I added only 10cm VCC and GDN or 10cm SDA, SCL separately the temperature drops. Note the markings in the picture below.

The sensor (SHT4x) is in the same place. No other parameters changed. Is this expected behavior? I am unable to find any clear answers on the internet so hopefully someone here knows. Thank you :pray:

I am new to IOT and not an expert.

No and yes.

No the length of cable can not change the digital value read out from a memory register.

Yes moving the temperature sensor away from a heat source such as a microprocessor can affect the value measured by the sensor. The ESP32 runs particularly warm.

Also some sensors are prone to self heating if not used correctly. The Bosch BME sensors in particular.

Thank you Tom.

I noticed the heating issues with BME, so I bought a few different ones after for testing already.
Makes sense about the digital data and the distance, I noticed when I put the sensor in the 3d printed box it gets about 5 degrees hotter, even though the sensor is in a separate compartment and the box has holes for ventilation and the sensor was at the bottom (heat travels up).

It’s still weird and unexplained to me why it fluctuates that much if I change just VCC/GDN or SDA/SCL cables. I moved the distance of the sensor maybe a centimeter not more and the box is now open and the esp away from the sensor. So I started to suspect if the wires could transfer the heat via esp pins to the sensor chip.

I’ll do a more exact test tomorrow by trying not to move the sensor and box with the esp, I’ll share my findings. Maybe the sensor is still picking up the heat even in this position and cca 10cm away. :open_mouth:
I’ll do that with other sensors too, just to be sure.

Thank you for the feedback. :pray:

So I further tested with different lengths and sensors.
Yesterday when the sensor and esp box were open (not closed in a box) there were no noticeable changes between cable lengths. Only some slight spikes, probably of the sensor being started.

Here is the setup:

However. Today I purposely tried to heat the soldering side of the i2c splitter and the SHT4x temperature jumped. The cables were indeed warm to touch too, but interestingly only the nearest sensor rected. There was also a slight jump in temperature when changing back to shorter-length cables.

So, extreme heating the cables can heat the sensors. I’ll do some further testing on why only the nearest sensor reacted but I got my answers so I will mark solved.

Thank you! :pray: