I have never had any trouble with the standard Liquid crystal library that I have been using successfully, however, I need to install the I2C Liquid crystal version.
I then went to my sketch and then Include Library - Manage Libraries - Add .zip Library - Downloads - LiquidCrystal_v1.2.1.zip and then checked open.
When I run my test sketch I get an error message:
C:Users\User\Documents\Arduino\libraries\LiquidCrystal\I2C_ID.cpp:5:26:fatal error: /Wire/Wire.h: No such file or directory.
My sketch includes Wire.h so ????
Should the library be in the Arduino Program File (x86) or in the Documents Arduino folder?
I have tried to follow the procedure in learning "Installing Additional Arduino Libraries"
// The LCD constructor - address shown is 0x27 - may or may not be correct for yours
// Also based on YWRobot LCM1602 IIC V1
LiquidCrystal_I2C lcd(0x27, 2, 1, 0, 4, 5, 6, 7, 3, POSITIVE);
void setup()
{
lcd.begin(16,2); // sixteen characters across - 2 lines
lcd.backlight();
// first character - 1st line
lcd.setCursor(0,0);
lcd.print("Hello World!");
// 8th character - 2nd line
lcd.setCursor(8,1);
lcd.print("-------");
}
void loop()
{
}
Another problem I have found is that by installing this library it over-rides the old (non I2C) version and existing projects using the old LiquidCrystal.h library don't work.
Another sketch example that also failed: See following error message
/* Demonstration sketch for PCF8574T I2C LCD Backpack
Uses library from https://bitbucket.org/fmalpartida/new-liquidcrystal/downloads GNU General Public License, version 3 (GPL-3.0) */ #include <Wire.h> #include <LCD.h> #include <LiquidCrystal_I2C.h>
LiquidCrystal_I2C lcd(0x27,2,1,0,4,5,6,7); // 0x27 is the I2C bus address for an unmodified backpack
void setup()
{
// activate LCD module
lcd.begin (16,2); // for 16 x 2 LCD module
lcd.setBacklightPin(3,POSITIVE);
lcd.setBacklight(HIGH);
}
void loop()
{
lcd.home (); // set cursor to 0,0
lcd.print(" tronixlabs.com");
lcd.setCursor (0,1); // go to start of 2nd line
lcd.print(millis());
delay(1000);
lcd.setBacklight(LOW); // Backlight off
delay(250);
lcd.setBacklight(HIGH); // Backlight on
delay(1000);
}
Error message after compilation:
WARNING: Category '' in library OneWire is not valid. Setting to 'Uncategorized'
C:\Users\user\Documents\Arduino\libraries\LiquidCrystal\I2CIO.cpp:35:26: fatal error: ../Wire/Wire.h: No such file or directory
Hi,
Also.
Please read the first post in any forum entitled how to use this forum. http://forum.arduino.cc/index.php/topic,148850.0.html then look down to item #7 about how to post your code.
It will be formatted in a scrolling window that makes it easier to read.
Hi,
I don't think the IDE version is the problem, but try it.
Also yes, download the 1.3.4.zip version, that is what I used.
Place the zip file in Documents/Arduino/Library directory.
Do not unzip it.
Tom...
PS you can have more than one IDE version on you computer at once.
That version of the library was written assuming that the library will be installed in the Arduino IDE installation folder, which is a very bad idea, and also that the Wire library is located in a place where it no longer is. I don't know what the author was thinking.