MCP23017 Library Port

You’ll need to instantiate an instance of the class for each MCP23017 and use the address you assigned them in the mcp.begin(addr) routine. You may not have noticed but it’s overloaded to also take a parameter, the address.

Here’s the link to the source:
https://github.com/pkourany/Adafruit_MCP23017_IDE/blob/master/firmware/Adafruit_MCP23017.cpp#L110

If you’re using the online code editor, there’s a little github icon that shows next to Library name once its selected. This takes you right to the firmware source for the library.

1 Like