

The MCP23017 IO Expander Breakout, manufactured by Soldered (Part ID: 333007), is a versatile 16-bit I/O expander that communicates via the I2C protocol. It allows microcontrollers to extend their GPIO capabilities by adding 16 additional input/output pins. This breakout board simplifies the integration of the MCP23017 into your projects by providing easy access to all pins and connections.








The MCP23017 breakout board provides access to all necessary pins for operation. Below is the pinout:
| Pin Name | Description |
|---|---|
| VCC | Power supply input (1.8V to 5.5V). |
| GND | Ground connection. |
| SDA | I2C data line. |
| SCL | I2C clock line. |
| A0, A1, A2 | Address selection pins (configure I2C address). |
| RESET | Active-low reset pin (optional, can be tied to VCC for normal operation). |
| INT A | Interrupt output for GPIOA (active-low). |
| INT B | Interrupt output for GPIOB (active-low). |
| GPIOA0-7 | General-purpose I/O pins for Port A. |
| GPIOB0-7 | General-purpose I/O pins for Port B. |
Below is an example of how to use the MCP23017 with an Arduino UNO to toggle an LED connected to GPIOA0:
#include <Wire.h>
#include "Adafruit_MCP23017.h"
// Create an MCP23017 object
Adafruit_MCP23017 mcp;
void setup() {
Wire.begin(); // Initialize I2C communication
mcp.begin(0); // Initialize MCP23017 with default I2C address (0x20)
// Set GPIOA0 as output
mcp.pinMode(0, OUTPUT);
// Set GPIOA1 as input with pull-up resistor
mcp.pinMode(1, INPUT);
mcp.pullUp(1, HIGH); // Enable pull-up resistor on GPIOA1
}
void loop() {
// Read the state of GPIOA1
int buttonState = mcp.digitalRead(1);
// Toggle GPIOA0 based on button state
if (buttonState == LOW) {
mcp.digitalWrite(0, HIGH); // Turn on LED
} else {
mcp.digitalWrite(0, LOW); // Turn off LED
}
delay(100); // Small delay for debounce
}
I2C Communication Not Working:
GPIO Pins Not Responding:
Interrupts Not Triggering:
Overheating or Malfunction:
Q: Can I use multiple MCP23017 breakout boards in the same project?
A: Yes, you can use up to 8 MCP23017 devices on the same I2C bus by configuring unique addresses using the A0, A1, and A2 pins.
Q: What is the maximum cable length for I2C communication?
A: The maximum length depends on the pull-up resistor values and the capacitance of the cable, but typically it is recommended to keep I2C lines under 1 meter for reliable communication.
Q: Can the MCP23017 handle analog signals?
A: No, the MCP23017 is designed for digital input/output only. Use an ADC (Analog-to-Digital Converter) for analog signals.
Q: How do I reset the MCP23017?
A: You can reset the MCP23017 by pulling the RESET pin low momentarily or by cycling the power supply.