I2C LCD-4 Line LCD Example Build error | Arduino Compatible Compiler for LabVIEW Discussions | Forum

Avatar
Please consider registering
guest
sp_LogInOut Log In sp_Registration Register
Register | Lost password?
Advanced Search
Forum Scope


Match



Forum Options



Minimum search word length is 3 characters - maximum search word length is 84 characters
sp_Feed Topic RSS sp_TopicIcon
I2C LCD-4 Line LCD Example Build error
March 23, 2016
4:01 am
Avatar
scadao
Member
Members
Forum Posts: 24
Member Since:
June 5, 2015
sp_UserOfflineSmall Offline

Arduino IDE 1.6.8 and Compiler 1.0.0.21

Compile error reports are as follows:

1.0.0.21, Arduino/Genuino Uno
Loading configuration...
正在初始化包...
正在准备开发板...
正在验证、上传...
C:\Users\Administrator\Documents\Arduino\libraries\LiquidCrystal\I2CIO.cpp:35:26: fatal error: ../Wire/Wire.h: No such file or directory

#include <../Wire/Wire.h>

^

compilation terminated.

exit status 1
Error compiling for board Arduino/Genuino Uno.

-------------------------
Arduino IDE 1.6.5 and Compiler 1.0.0.21

Compile successfully, run OK!

March 23, 2016
4:46 am
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

Thanks for bringing this to our attention.  It appears that the location of the Wire library source files was changed in 1.6.8, although there is no mention of it in the Arduino IDE release notes.  The source files are now at \Arduino\hardware\arduino\avr\libraries\Wire\src instead of in the root Wire lib folder.  I created Case 133 to track this issue and we will hopefully have a fix in the next release.  For now here is a workaround:

In \Program Files (x86)\National Instruments\LabVIEW 2014\vi.lib\Aledyne-TSXperts\Arduino Compatible Compiler for LabVIEW\Arduino Libraries\LiquidCrystal\I2CIO.cpp

CHANGE:

#include <../Wire/Wire.h>

TO

#include <Wire.h>

March 24, 2016
2:00 am
Avatar
scadao
Member
Members
Forum Posts: 24
Member Since:
June 5, 2015
sp_UserOfflineSmall Offline

Steffan said
Thanks for bringing this to our attention.  It appears that the location of the Wire library source files was changed in 1.6.8, although there is no mention of it in the Arduino IDE release notes.  The source files are now at \Arduino\hardware\arduino\avr\libraries\Wire\src instead of in the root Wire lib folder.  I created Case 133 to track this issue and we will hopefully have a fix in the next release.  For now here is a workaround:

In \Program Files (x86)\National Instruments\LabVIEW 2014\vi.lib\Aledyne-TSXperts\Arduino Compatible Compiler for LabVIEW\Arduino Libraries\LiquidCrystal\I2CIO.cpp

CHANGE:

#include <../Wire/Wire.h>

TO

#include

Thank you for your prompt reply!

April 7, 2016
6:36 pm
Avatar
griff32
Member
Members
Forum Posts: 4
Member Since:
April 7, 2016
sp_UserOfflineSmall Offline

I get this error when compiling the I2C LCD - 4 Line LCD.vi

 

1.0.0.21, Arduino/Genuino Uno
Loading configuration...
Initializing packages...
Preparing boards...
Verifying...
C:\Users\Barkel\AppData\Local\Temp\58e9973bb6e2e908c6c199f5a9d39075.tmp\temp\temp.ino:4:17: fatal error: LCD.h: No such file or directory

#include "LCD.h"

^

compilation terminated.

exit status 1
Error compiling for board Arduino/Genuino Uno.

April 25, 2016
6:55 pm
Avatar
griff32
Member
Members
Forum Posts: 4
Member Since:
April 7, 2016
sp_UserOfflineSmall Offline

Is this forum not a working forum anymore?

April 27, 2016
5:13 pm
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

griff32 said
Is this forum not a working forum anymore?

Sorry for the late reply, yes it is still active but your initial post on this thread got missed.  Sorry about that.  I suspect that your Arduino sketchbook path is not pointing to the Libraries directory so the Arduino compiler cannot find the LCD.h header file that is part of that library.  Open the Arduino IDE and go to File>Preferences and make sure sketchbook location is set to:

C:\Users\[USERNAME]\Documents\Arduino.

Let us know if that solves your problem.

April 28, 2016
12:25 pm
Avatar
griff32
Member
Members
Forum Posts: 4
Member Since:
April 7, 2016
sp_UserOfflineSmall Offline

The location is set to that directory. I get the same error.

I did some research on the LCD with shield I bought, and it is not a I2C display. So I cannot use the example code that came with the compiler.

 

Is there any sample Labview code that works for a standard 16X2 LCD.

 

Thanks

April 28, 2016
2:23 pm
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

For the include problem, that is definitely an issue with Arduino finding the LiquidCrystal library.  Make sure it is located in the C:\Users\[USERNAME]\Documents\Arduino\Libraries\LiquidCrystal directory.

You can also take a look at this post for additional info:

https://forum.arduino.cc/index.php?topic=330766.0

 

There is currently no library for the parallel LCDs.  You would have to create one, which is possible using the"Porting an Arduino Library to the Arduino Compatible Compiler for LabVIEW" section of the user manual.  But this is an advanced feature and I would advise just buying an I2C 16x2 LCD, they are quite cheap and require much less I/O and wiring.

May 3, 2016
11:57 am
Avatar
griff32
Member
Members
Forum Posts: 4
Member Since:
April 7, 2016
sp_UserOfflineSmall Offline

Thanks Steffan,

 

Would you have a recommendation on which display to buy?

May 11, 2016
9:37 pm
Avatar
miche91
Member
Members
Forum Posts: 35
Member Since:
May 11, 2016
sp_UserOfflineSmall Offline

Hi,

 

i have the same problem of griff 32! I have a 16x2 i2c lcd but I can't compile the example file cause I receive that error!

anyone solved it?

thanks everybody 

November 27, 2016
6:44 am
Avatar
scadao
Member
Members
Forum Posts: 24
Member Since:
June 5, 2015
sp_UserOfflineSmall Offline

Arduino IDE 1.6.13, Compiler 1.0.0.21,Arduino Due Board

CHANGED:

#include <../Wire/Wire.h>

TO

#include <Wire.h>

Compile error reports are as follows:

1.0.0.21, Arduino Due (Programming Port)
正在加载配置...
正在初始化包...
正在准备开发板...
正在验证...
C:\Users\Administrator\Documents\Arduino\libraries\LiquidCrystal\I2CIO.cpp:130:20: error: 'int I2CIO::write' is not a static member of 'class I2CIO'

int I2CIO::write ( uinte8_t value )

^

C:\Users\Administrator\Documents\Arduino\libraries\LiquidCrystal\I2CIO.cpp:130:20: error: 'uinte8_t' was not declared in this scope

C:\Users\Administrator\Documents\Arduino\libraries\LiquidCrystal\I2CIO.cpp:131:1: error: expected ',' or ';' before '{' token

{

^

exit status 1
为开发板 Arduino Due (Programming Port) 编译时出错。

November 28, 2016
9:07 pm
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

You must have a typo in I2CIO.cpp.  Read your errors, it tells you right there.  "uinte8_t" is not a valid datatype.  It should be "uint8_t".

November 30, 2016
4:04 am
Avatar
scadao
Member
Members
Forum Posts: 24
Member Since:
June 5, 2015
sp_UserOfflineSmall Offline

Thank Steffan, I changed  "uinte8_t" into "uint8_t", the build is successful, but "DPI detection failed,fallback to 96 dpi".

I2C-LCD-Failed.gifImage Enlarger

sp_PlupAttachments Attachments
November 30, 2016
5:28 am
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

That looks related to you monitor settings and the Arduino IDE, nothing specific to the Compiler.  Might be able to just ignore it but search online.  I found this link for starters.

November 30, 2016
9:38 am
Avatar
scadao
Member
Members
Forum Posts: 24
Member Since:
June 5, 2015
sp_UserOfflineSmall Offline

I still don't understand. IDE's build is OK. I installed Arduino IDE 1.6.9 last. It's OK.

December 13, 2016
4:56 am
Avatar
KDan
Member
Members
Forum Posts: 7
Member Since:
May 20, 2015
sp_UserOfflineSmall Offline

This problem still seems to exist. I'm surprised it hasn't been resolved yet. This appears to render all of the I2C LCD VI's useless.

Same issue as griff32 and miche91...

1.0.0.21, Arduino/Genuino Mega or Mega 2560
Loading configuration...
Initializing packages...
Preparing boards...
Verifying...
C:\Users\Greg\AppData\Local\Temp\58e9973bb6e2e908c6c199f5a9d39075.tmp\temp\temp.ino:4:17: fatal error: LCD.h: No such file or directory

 #include "LCD.h"

                 ^

compilation terminated.

exit status 1
Error compiling.

The sketchbook location is definitely set to C:\Users\Greg\Documents\Arduino in the preferences.

It appears that when the compiler runs it is looking for various files in that cryptic temp directory - but they are not getting copied there. I tried rolling back to Arduino IDE 1.6.7 but that didn't help...

Any suggestions would be most welcome. I have a project that I really need the I2C LCD display for.

December 13, 2016
5:29 am
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

The temp directory will not contain the source files.  This particular header file is part of the Liquid Crystal library.  Look in "C:\Users\Greg\Documents\Arduino\Libraries\LiquidCrystal" and this is where LCD.h should be.  If it is there, then you must have an IDE configuration issue. Here is a reference describing common issues with libraries.  You can also try compiling a simple Arduino example using the same header file and you should get the same error, which tells you it is an issue with the Arduino IDE.

December 13, 2016
12:25 pm
Avatar
KDan
Member
Members
Forum Posts: 7
Member Since:
May 20, 2015
sp_UserOfflineSmall Offline

OK, thanks. I do get the same error in the Arduino IDE. The multiple locations of the libraries is quite confusing. They are located in

C:\Users\[Username]\Documents\Arduino\libraries

also

C:\Program Files (x86)\Arduino\libraries

and also

C:\Program Files (x86)\National Instruments\LabVIEW 2014\vi.lib\Aledyne-TSXperts\Arduino Compatible Compiler for LabVIEW\Arduino Libraries

I guess I need to understand which are needed/used and under what circumstances.

Thanks again...

December 13, 2016
8:01 pm
Avatar
Steffan
Admin
Forum Posts: 408
Member Since:
March 12, 2015
sp_UserOfflineSmall Offline

The one in the LabVIEW directory is expected.  The Compiler ships with it and copies to your C:\Users\[Username]\Documents\Arduino\libraries folder if it is not there already for convenience.  The Arduino IDE only checks from the 2 Arduino directories you mentioned.  The LCD.h should only be in the C:\Users\[Username]\Documents\Arduino\libraries related folder, not in the Program Files libraries folder.  You might want to try removing the duplicate library in the C:\Program Files (x86)\Arduino\libraries folder.

December 14, 2016
9:09 am
Avatar
KDan
Member
Members
Forum Posts: 7
Member Since:
May 20, 2015
sp_UserOfflineSmall Offline

Steffan,

I got it to work in the Arduino IDE by using a third party LiquidCrystal_I2C library and then included that in my sketch.

One more question... What is the purpose of the "Copy Libraries.vi" in the

C:Program Files (x86)National InstrumentsLabVIEW 2014vi.libAledyne-TSXpertsArduino Compatible Compiler for LabVIEWArduino Libraries

folder?

Does the Labview Arduino compiler need a mirror of the Arduino libraries in this location? Do I need to run this vi to do this?

 

Thanks...

Forum Timezone: UTC 0
Most Users Ever Online: 100
Currently Online:
5
Guest(s)
Currently Browsing this Page:
1 Guest(s)
Top Posters:
miche91: 33
scottj: 28
scadao: 23
Member Stats:
Guest Posters: 5
Members: 202
Moderators: 0
Admins: 3
Forum Stats:
Groups: 1
Forums: 2
Topics: 266
Posts: 1222
Newest Members:
pujacontrol
Administrators: geadmin: 22, filipealtoe: 96, Steffan: 356