I2C – connecting 5V device to 3.3V host

i2clevel-shifting

Is it safe to connect any 5V I2C slave device to 3.3V host?

I know, that DS1307 realtime clock can be connected to Raspberry Pi (3.3V IO), because DS1307 just pulls down data lines and 5V voltage never "comes out" from DS1307 SDA and SCL pins.

When I'm connecting pullups to 3.3V – it's not a problem for DS1307.

But what about other I2C devices, like MCP3421 ADC or ADT7420 temperature sensor for example?

Best Answer

I think I got it.

Many I2C devices connected to 5V and 3.3V I2C line (pullups connected to 3.3V) will not work.

High state for many devices is 0.7Vdd.

enter image description here

ADT7420 temperature will not work too - it has minimum high state level = 0.7Vdd.

For 5V Vdd minimum high level is 3.5V (above 3.3V). With 3.3V pullups 5V powered device will read line always as low state.

DS1307 is working, because minimum high state input level is 2.2V (below 3.3V).

enter image description here