Pages: [1]   Go Down
Author Topic: Liquid Crystal Library  (Read 624 times)
0 Members and 1 Guest are viewing this topic.
0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi,
I am somewhat new to this so sorry if this is kind of dumb. I am having a bit of a problem. I am trying to use the Liquid Crystal library. I copied the code from the website under this tutorial and tried to compile it. When I do I get the following:

LiquidCrystal.cpp:8: error: declaration of C function 'void pinMode(int, int)' c
onflicts with
C:/arduino-0009/lib/targets/arduino/wiring.h:74: error: previous declaration 'vo
id pinMode(uint8_t, uint8_t)' here
LiquidCrystal.cpp:9: error: declaration of C function 'void digitalWrite(int, in
t)' conflicts with
C:/arduino-0009/lib/targets/arduino/wiring.h:75: error: previous declaration 'vo
id digitalWrite(uint8_t, uint8_t)' here
LiquidCrystal.cpp:10: error: declaration of C function 'int digitalRead(int)' co
nflicts with
C:/arduino-0009/lib/targets/arduino/wiring.h:76: error: previous declaration 'in
t digitalRead(uint8_t)' here
o: In function `setup':
undefined reference to `LiquidCrystal::init()'o: In function `__static_initializ
ation_and_destruction_0(int, int)':

Can anyone help
thanks
Logged

0
Offline Offline
Jr. Member
**
Karma: 0
Posts: 53
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Open LiquidCrystal.cpp and modify the following lines:

Code:
extern void pinMode(int, int);
extern void digitalWrite(int, int);
extern int digitalRead(int);

to

Code:
extern void pinMode(uint8_t, uint8_t);
extern void digitalWrite(uint8_t, uint8_t);
extern int digitalRead(uint8_t);

I just tried it, and it worked for me.
« Last Edit: September 14, 2007, 10:38:53 am by imagitronics » Logged

0
Offline Offline
Newbie
*
Karma: 0
Posts: 2
Arduino rocks
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks
Logged

Pages: [1]   Go Up
Jump to: