question i wonder :can i connect two or tree sensors or i2c interfaces on sda and scl pin ? is it working?
cause i'd connected i2c real time clock and mpu6050 gyro together,parrallele on sda and scl, but rtc won't return me good time...
ok..but i supose it's only possible if each one are correctly initialised in the sketch before running ?
because i intialise only one device for the moment...may be it's because of that....
Are all devices on the bus the same voltage?
Have you got pull up resistors fitted?
Only one set 4K7 from each bus bit to +5V or the powering voltage. And remember to connect all grounds together.
no pull up resistors..i felt 't was not necessary...may be i'm wrong.
Yes you are wrong. See:-
my mpu6050 is on 3.3v pin and my rtc is on 5v pin
AHGGGG
That makes it very difficult. Pulling up a 3V3 device to 5V can damage it. You have to isolate the 3V3 part of the bus from the 5V part. It is best to use a logic level translator chip or FET to get between the two levels. I think spark fun sells one or just connect two transistors back to back.