Adafruit_MCP23x17

Post here about your Arduino projects, get help - for Adafruit customers!

Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.
Locked
User avatar
jfhpacanda
 
Posts: 7
Joined: Wed Dec 12, 2018 5:11 am

Adafruit_MCP23x17

Post by jfhpacanda »

I use MCP23017 16-bit I/O Expander chips to expand the number of digital I/O pins on Arduino-nano boards.
I downloaded the latest Adafruit_MCP_Arduino_Library version 2.0.2.zip, unzipped it and included the Adafruit_MCP23x17.h library, everything conform the instructions in the Arduino-IDE sketch.

In my sketch, I include

Code: Select all

 Adafruit_MCP23x17 mcp1; 
to address the first MCP23017 chip;
Compiling my sketch gives the following error:
'Adafruit_MCP23x17' does not name a type; did you mean 'Adafruit_MCP23X17'?

With a previous library version, there were no compiler errors.
Can someone help me to solve this annoying problem?

User avatar
adafruit_support_carter
 
Posts: 29473
Joined: Tue Nov 29, 2016 2:45 pm

Re: Adafruit_MCP23x17

Post by adafruit_support_carter »

Try installing the library using the Arduino IDE Library Manager and then test with the example here:
https://github.com/adafruit/Adafruit-MC ... _blink.ino

User avatar
jfhpacanda
 
Posts: 7
Joined: Wed Dec 12, 2018 5:11 am

Re: Adafruit_MCP23x17

Post by jfhpacanda »

Thank you for advice. But this was one of the many things I already tried without succes.
However, carefully looking through all the error messages, I discovered a lot of references to various library locations where some libraries were duplicates.
So I removed all of them, completely removed all my IDE's (had some older versions still installed!) made a backup of my sketches, installed a new IDE and restored my backups.
And finally installed the relevant libraries by using the IDE's library manager tool.
And yes, no more errors!
So, maybe this approach is something others can use in solving similar problems.

Locked
Please be positive and constructive with your questions and comments.

Return to “Arduino”