I'm assuming there are many ways to complete this task however, I need some assistance with a logic converter.
I've seen the diagrams to wire things up and I am comfortable with what it does and how it works. However I've not seen a diagram showing the following so I want to know it it's possible.
Is this correct or am I being stupid? The GY291 breakout I have, does have a 5V input as well as 3.3V, however from all the data I've read on the 345, I'm going to pretend that's not there, unless someone know something I don't know, which is quite likely.
On the Arduino, start Wire.begin() in setup, and then turn off the internal pullup resistors.
Add two resistors, 2.7K, to pullup SCL & SDA to 3.3V. Now you have I2C running on 3.3V and all devices should be happy.
Power pin needs to be 5V, but the SCL/SDA lines will be fine at 3.3V:
Logic 1 Input
VIH Min 2.2V Max VCC + 0.3V
Logic 0 Input VIL Min -0.3V Max +0.8V
PIN 5 SDA Serial Data Input/Output. SDA is the data input/output for the I2C serial interface. The SDA pin is open drain and requires an external pullup resistor. The pullup voltage can be up to 5.5V regardless of the voltage on VCC.
PIN 6 SCL Serial Clock Input. SCL is the clock input for the I2C interface and is used to synchronize data movement on the serial interface. The pullup voltage can be up to 5.5V regardless of the voltage on VCC.
Brilliant, that explanation certainly makes the I2C bus a lot clearer, I've been wrongly under the assumption that the SDA and SCL lines take their operating power from what ever voltage device they are connected to.
So to clarify SDA and SCL to the RTC (powered by 5V) via 2.7k resistors. Then out the back end of the RTC into the ADLX (powered by 3.3V)
Thank you very much
123Splat, I've downloaded this to my reader, this will be something I'll definitely take the time to read, thank you
Edit
Scratch that, I've just seen how to wire external pull up. I'm now looking into disabling the internal resistors
Sorry for all of the questions, but I have one more to make sure I fully understand what is happening. Am I right in thinking that by disabling the internal pull up resistors on the I2C lines, I am disconnecting it from it's 5V supply. Which I am then replacing with 3.3V to each line via 2.7K resistors?