There is no USPS pickup on Monday Feb 15th, 2016 because of President's Day. USPS orders placed after 11am EST Fri February 12th will go out Tuesday February 16. UPS orders will ship as normal.

LiquidTWI and Adafruit_MCP23008 in same sketch
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

LiquidTWI and Adafruit_MCP23008 in same sketch

by labrat9876 on Tue Feb 26, 2013 3:36 pm

Hello Everyone!

I have been using the I2C LCD backpack for a while now with out issue, I have now tried to expand the project to include some new functionality requiring additional I/O ports. I have added a MCP23008 to the system, and am attempting to update the sketch code to include the new functionality and get an error when compiling.

I have tried with and without the library for the mcp23008 as well as the LiquidTWI library..

My Includes Are:
Code: Select all | TOGGLE FULL SIZE
#include "Adafruit_MCP23008.h"
#include <AccelStepper.h>
#include <Wire.h>
#include <LiquidTWI.h>



Code: Select all | TOGGLE FULL SIZE
In file included from Rotating_Camera_Base_Beta_Control_Branch.ino:26:
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:19: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:22: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:22: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:23: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:23: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:24: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:24: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:25: error: 'uint8_t' does not name a type
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:26: error: 'uint8_t' does not name a type
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:27: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:30: error: 'uint8_t' does not name a type
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:31: error: 'uint8_t' does not name a type
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:32: error: 'uint8_t' has not been declared
D:\Arduino Dev\arduino-1.0.3\libraries\LiquidCrystal/Adafruit_MCP23008.h:32: error: 'uint8_t' has not been declared


Any Help would be appreciated..
labrat9876
 
Posts: 6
Joined: Fri Apr 13, 2012 11:41 am

Re: LiquidTWI and Adafruit_MCP23008 in same sketch

by adafruit_support_rick on Tue Feb 26, 2013 3:41 pm

Odd.

Try moving the adafruit include down to the end of the list:
Code: Select all | TOGGLE FULL SIZE
#include <AccelStepper.h>
#include <Wire.h>
#include <LiquidTWI.h>
#include "Adafruit_MCP23008.h"

adafruit_support_rick
 
Posts: 24865
Joined: Tue Mar 15, 2011 11:42 am
Location: Buffalo, NY

Re: LiquidTWI and Adafruit_MCP23008 in same sketch

by labrat9876 on Tue Feb 26, 2013 3:57 pm

Thanks driverblock! That was all it took...
labrat9876
 
Posts: 6
Joined: Fri Apr 13, 2012 11:41 am

Please be positive and constructive with your questions and comments.