Chat freely about anything...

User avatar
By Raul Vasquez
#55841 Resistor selection varies with devices on the bus, but a good rule of thumb is to start with 4.7k and adjust down if necessary. I2C is a fairly robust protocol, and can be used with short runs of wire (2-3m). For long runs, or systems with lots of devices, smaller resistors are better.
Signal Levels

Since the devices on the bus don’t actually drive the signals high, I2C allows for some flexibility in connecting devices with different I/O voltages. In general, in a system where one device is at a higher voltage than another, it may be possible to connect the two devices via I2C without any level shifting circuitry in between them. The trick is to connect the pull-up resistors to the lower of the two voltages. This only works in some cases, where the lower of the two system voltages exceeds the high-level input voltage of the the higher voltage system–for example, a 5V Arduino and a 3.3V accelerometer.

If the voltage difference between the two systems is too great (say, 5V and 2.5V), SparkFun offers a simple I2C level shifter board. Since the board also includes an enable line, it can be used to disable communications to selected devices. This is useful in cases where more than one device with the same address is to be connected to a single master–Wii Nunchucks are a good example.

Source: https://learn.sparkfun.com/tutorials/i2c
User avatar
By kaczy1217
#62208 Yes! Pull up resistors solved the problem for me too.

I have ESP-12E with SPI SD card reader, I2C: Adafruit FRAM memory, DS1307 RTC and 20x4 LCD driven by PCF8574A. I have ESP12E breadboard with 7333-1 stabilizer. 470uF condensator at the input of stabilizer and the second one at the output. Also 100nF decoupling between 3V3 and GND. GPIO0 pulled by breadboard 3.3V, GPIO2 pulled with 4,7k resistor to 3.3V and GPIO15 pulled to 3.3V. Everything powered by 5V 6A supply
Once a 20-50 power cycles lcd crashed (whole filled with rectangles), my ESP executed only "setup" part then stopped. I've been checking code, disconnecting next devices from my ESP and no luck.

Yesterday I've been looking for this issue and found that:
viewtopic.php?f=6&t=9928&start=8

Since I've pulled SDA and SCL pins with 2,2k resistor to 3.3V I've made almost 200 power cycles and now everythings seems to be fine and working without a problem. Maybe this will help somebody else.