user87188: I have two different sensors which have SCL and SDA connections which I am trying to connect to an Arduino nano. From what I understand, connecting both of these sensor to the A5 and A4 pins doesn't make any sense, considering that I need to collect data continuously from both sensors. Moreover, there are no other pins with the same functionality as A5 and A4. I am a beginner learning about microcontrollers, but it seems to me like the best practice to follow here would be to use two Arduino nanos. Is this this the only way, or is there another method I am not aware of?

user10794: The whole point of the I2C bus is to allow multiple sensors or devices to be connected, as long as they have different I2C addresses. The addresses are usually built into the part, and often they have some provision for selecting an address from a range.
Whilst you can't simultaneously collect data from two sensors at once, you can certainly query them in quick succession. You need to connect SDA, SCL, Ground and +5V to each sensor, and the Arduino.
Your code would do something like:

Query sensor at address 42
Query sensor at address 43
Do something with the data
Wait a bit before doing it again

You could look at Wikipedia for some general information about I2C, and I also have a page about I2c that might help you.
Note that you also need a pull-up resistor on both SDA and SCL (that is, two resistors), a typical value would be 4.7k (connect the 4.7k resistors between SDA/SCL and your +5V line).

87188: <p>I have two different sensors which have SCL and SDA connections which I am trying to connect to an Arduino nano. From what I understand, connecting both of these sensor to the A5 and A4 pins doesn't make any sense, considering that I need to collect data continuously from both sensors. Moreover, there are no other pins with the same functionality as A5 and A4. I am a beginner learning about microcontrollers, but it seems to me like the best practice to follow here would be to use two Arduino nanos. Is this this the only way, or is there another method I am not aware of?</p>
 10794: <p>The whole point of the I2C bus is to allow multiple sensors or devices to be connected, as long as they have different I2C addresses. The addresses are usually built into the part, and often they have some provision for selecting an address from a range.</p>
<p>Whilst you can't <em>simultaneously</em> collect data from two sensors at once, you can certainly query them in quick succession. You need to connect SDA, SCL, Ground and +5V to each sensor, and the Arduino.</p>
<p>Your code would do something like:</p>
<ul>
<li>Query sensor at address 42</li>
<li>Query sensor at address 43</li>
<li>Do something with the data</li>
<li>Wait a bit before doing it again</li>
</ul>
<p>You could look at Wikipedia for some general information about I2C, and I also have <a href="http://gammon.com.au/i2c" rel="nofollow noreferrer">a page about I2c</a> that might help you.</p>
<p>Note that you also need a pull-up resistor on both SDA and SCL (that is, two resistors), a typical value would be 4.7k (connect the 4.7k resistors between SDA/SCL and your +5V line).</p>
