I have another questions:
1. "Hotplug" - is it safe to connect/disconnect I2C device to working RPi?
If it's safe and should be like this:
In most cases and proper I2C interfaces, ensure all modules have NO pullup resistors on SDA and SCL, then if modules powered from 5V the I2C will work at 3V3. Only checking datasheets for each device can tell if the Voltage high threshold is low enough that when powered by 5V it will recognise anything over 3V as a high input.JacekQ wrote:Hello,
I checked every device and only LCD requires 5V power supply. All other devices work with 3V3 or 5V. I think that better solution is to connect all devices to 5V but I found infromation than i2c devices should be powered 3V3 and if I want to use 5v then I have to use logic level shifter.
Do I have to use logic level shifter or will it work with 5V power supply without level shifter?
Yes - I found that too, until I soldered the pins on the GY-80 board I couldn't detect the sensors. Simply slotting the pins in place was not enough.ember wrote:problem solved.
apparently it is necessary...ember wrote:is it possible, that the fact that I didn't solder the pins in GY-80 are causing so much problems? Is it necessary, or can I just plug it in?
Just because the RPI has pullups does not mean that the remote device should not have them. Having 10k pullups will help balance the impedance at both ends of the wire. If the I2c Bus wires are very short ( < 1 meter) then pullups may be optional depending on bus speed. Try a i2cdetect at 1 mhz with and without pullups for an experiment.PeterO wrote:Pull up resistors are already on the Pi board.
Just wire all the i2c devices in parallel, so connect all the SDA pins together, and all the SCL pins together. as shown here http://en.wikipedia.org/wiki/I%C2%B2C
Each one has it's own address so they don't interfere with each other.