<div dir="ltr"><div><div><div><div><div><div>There are two parts to this - the port expander, and the voltage change, so let's take each individually, and then together.<br><br></div>For just a port expander, you can tie the SCL/SDA and GND/3.3 volt lines back to the RPI as shown in that article you provided.<br><br>If
 you want to use an external 3.3v supply, you can connect the external 
3.3v to the port expander and then tie the GND of the RPi to the GND of 
the external 3.3v supply.<br><br></div>Now to go to 5v, you have to be 
very careful as if you just replace the 3.3v supply in the previous 
example with a 5v supply, you will exceed the voltage allowable on the 
RPIs SCL/SDA lines.<br><br></div>So you will need to isolate the (now) 
5v port expander from the 3.3v RPi.  You can do that with a level 
converter.  The level converter takes two power supplies (the 3.3v and 
5v) supplies as input and IO lines from the 3.3v side (RPi's SCL/SDA) 
and IO lines from the 5v side (port expander's SCL/SDA) and it will do 
the voltage conversion.  The software will work the same way as in the 
very first and second example as the RPi does not know (nor does it 
care) that the voltages are being converted before you get to the port 
expander.<br><br>Here is a Sparkfun example of using the logic converter - there is even an example for I2C on the page:<br><br><a href="https://learn.sparkfun.com/tutorials/using-the-logic-level-converter">https://learn.sparkfun.com/tutorials/using-the-logic-level-converter</a><br><br>So to summarize:<br></div>* port expander with RPi - connect as in the URL you sent<br></div>* port expander with external 3.3v - external supply, just tie the GNDs together<br></div>* port expander with external 5v - must use a level converter<br><br><br><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Sep 18, 2014 at 8:50 AM, Grawburg <span dir="ltr"><<a href="mailto:grawburg@myglnc.com" target="_blank">grawburg@myglnc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">I'd like some comments on this Web article, since it describes exactly what I want to do.<br>
<br>
<br>
<a href="http://nathan.chantrell.net/20120610/raspberry-pi-and-i2c-devices-of-different-voltage/" target="_blank">http://nathan.chantrell.net/20120610/raspberry-pi-and-i2c-devices-of-different-voltage/</a><br>
<br>
<br>
I want to use ONLY the SLC and SDA pin on the Pi and power the I/O expander, and hence the LEDs connected to it,<br>
with an external 5VDC or even a 3.3 --- but the 5 is more easily available.  I'm going to test this today.<br>
<br>
<br>
<br>
<br>
Brian Grawburg<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
Triangle, NC Embedded Computing mailing list<br>
<a href="mailto:TriEmbed@triembed.org">TriEmbed@triembed.org</a><br>
<a href="http://mail.triembed.org/mailman/listinfo/triembed_triembed.org" target="_blank">http://mail.triembed.org/mailman/listinfo/triembed_triembed.org</a><br>
TriEmbed web site: <a href="http://TriEmbed.org" target="_blank">http://TriEmbed.org</a><br>
</blockquote></div><br></div></div><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Sep 18, 2014 at 8:50 AM, Grawburg <span dir="ltr"><<a href="mailto:grawburg@myglnc.com" target="_blank">grawburg@myglnc.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I'd like some comments on this Web article, since it describes exactly what I want to do.<br>
<br>
<br>
<a href="http://nathan.chantrell.net/20120610/raspberry-pi-and-i2c-devices-of-different-voltage/" target="_blank">http://nathan.chantrell.net/20120610/raspberry-pi-and-i2c-devices-of-different-voltage/</a><br>
<br>
<br>
I want to use ONLY the SLC and SDA pin on the Pi and power the I/O expander, and hence the LEDs connected to it,<br>
with an external 5VDC or even a 3.3 --- but the 5 is more easily available.  I'm going to test this today.<br>
<br>
<br>
<br>
<br>
Brian Grawburg<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
_______________________________________________<br>
Triangle, NC Embedded Computing mailing list<br>
<a href="mailto:TriEmbed@triembed.org">TriEmbed@triembed.org</a><br>
<a href="http://mail.triembed.org/mailman/listinfo/triembed_triembed.org" target="_blank">http://mail.triembed.org/mailman/listinfo/triembed_triembed.org</a><br>
TriEmbed web site: <a href="http://TriEmbed.org" target="_blank">http://TriEmbed.org</a><br>
</blockquote></div><br></div>