MCP23017 I2C 16 I/O Port Expander

Breakout boards, sensors, Drawdio, Game of Life, other Adafruit kits, etc.

Moderators: adafruit_support_bill, adafruit

MCP23017 I2C 16 I/O Port Expander

Postby 7H3LaughingMan » Mon Dec 03, 2012 10:24 pm

I have recently ordered a MCP23017 to mess around with for a project on my Raspberry Pi and I am having issues with the address randomly jumping around whenever I am trying to run "sudo i2cdetect -y 1". I have even gotten it a few times where it says there is a device on 0x20 and 0x27 at the same time just about. I have nothing else hooked up to the I2C Bus and I am using a Pi Cobbler to connect my Raspberry Pi to the Breadboard, I then have 4 wires coming from the Pi Cobbler to the MCP23017 Chip for 3v3, Ground, SCL, & SDA. I have gone over the connections 20+ times now and I am 100% positive there is nothing wrong with the wiring but I am having the issues where the Address is jumping around randomly.
7H3LaughingMan
 
Posts: 3
Joined: Mon Dec 03, 2012 10:14 pm

Re: MCP23017 I2C 16 I/O Port Expander

Postby adafruit_support_bill » Tue Dec 04, 2012 7:10 am

Post a photo showing your soldering. And make sure all your breadboard connections are firm. The spring contacts do tend to loosen up over time. If it does not grip the wire tightly, try an adjacent hole in the same row.
User avatar
adafruit_support_bill
 
Posts: 16647
Joined: Sat Feb 07, 2009 9:11 am

Re: MCP23017 I2C 16 I/O Port Expander

Postby 7H3LaughingMan » Tue Dec 04, 2012 5:55 pm

Image
Image
Image
Image
Image
Image
Image
7H3LaughingMan
 
Posts: 3
Joined: Mon Dec 03, 2012 10:14 pm

Re: MCP23017 I2C 16 I/O Port Expander

Postby adafruit_support_bill » Wed Dec 05, 2012 7:26 am

Looks like your address pins (15,16 & 17) are floating. You should tie them to ground. From the datasheet: http://www.adafruit.com/datasheets/mcp23017.pdf

The address pins should be externally biased
even if disabled
User avatar
adafruit_support_bill
 
Posts: 16647
Joined: Sat Feb 07, 2009 9:11 am

Re: MCP23017 I2C 16 I/O Port Expander

Postby 7H3LaughingMan » Wed Dec 05, 2012 12:38 pm

Going over that datasheet I noticed the reset pin is externally biased as wrll so I would have to ground thst as well, right? In the tutorial for using this with the Raspberry Pi it should say that the address pins need to be grounded for normal operation like it says for the reset pin so it is clear.
7H3LaughingMan
 
Posts: 3
Joined: Mon Dec 03, 2012 10:14 pm

Re: MCP23017 I2C 16 I/O Port Expander

Postby adafruit_support_bill » Wed Dec 05, 2012 12:47 pm

Reset is active low, so it should be pulled high. And yes, that would be good to mention in the tutorial.

We welcome comments & correction on the tutorials. If you post them in the "Feedback? Corrections" link on the left side of the Adafruit Learning System guide, it will be sure to get back to the author. :)
User avatar
adafruit_support_bill
 
Posts: 16647
Joined: Sat Feb 07, 2009 9:11 am

Re: MCP23017 I2C 16 I/O Port Expander

Postby nigelf » Fri Jun 14, 2013 2:24 pm

I had the dreaded random detection of address and it would clash if all pins for address were selected

so I tried not connecting pin 17 to ground but to supply ie hold it high rather than leaving it floating ...

this seemed to do the trick
nigelf
 
Posts: 1
Joined: Sat Nov 03, 2012 12:26 am


Return to Other Adafruit products

Who is online

Users browsing this forum: No registered users and 1 guest

Stuff to buy from the Adafruit store and links to product documentation!


New Products [113]

Raspberry Pi[82]
 
FLORA[24]
 
Bunnie Studios[9]
 
FPGA[1]
 
mbed[12]
Arduino[60]
 
NETduino[14]
 
BeagleBone[23]
 
Android[6]
 
XBee[10]
More Dev Boards[30]


 
BoArduino[8]
 
SpokePOV[4]
 
TV-B-Gone[4]
 
MiniPOV[3]
 
SIM reader[3]
 
Microtouch[5]
 
Clocks & Watches[18]
 
Drawdio[4]
 
Brain Machine[1]
 
Game of Life[2]
 
MintyBoost[2]
More DIY Kits[16]


 
MaKey MaKey[3]
 
Tweet-a-Watt[5]
 
Young Engineers[39]
 
Discover Electronics[2]
 
Snap Circuits[4]
 
littleBits[3]
 
Project packs[9]


 
Breakout Boards[35]
LCDs & Displays[49]
Components & Parts[70]
Batteries & Power[54]
EL Wire/Tape/Panel[52]
LEDs[112]
 
Wireless[16]
Cables[66]
 
Lasers[6]
Sensors/Parts[147]
 
Enclosures/Cases[11]
 
Solar[11]
 
RFID / NFC[13]
Prototyping[70]
 
iDevices[13]
Tools[71]
 
Wearables[41]
 
CNC[37]
 
Robotics[29]
 
3D printing[1]
 
Materials[25]


 
Stickers[41]
 
Skill badges[55]
 
Books[26]
 
Circuit Playground[7]
 
Gift Certificates[4]