Arduino Forum upgrade scheduled for Monday, October 20th, 11am-4pm (CEST). Sorry for the inconvenience!
Pages: [1]   Go Down
Author Topic: ENC28J60 Ethernet Shield Compile Errors  (Read 546 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hi guys,

I am trying to make this work: http://www.nuelectronics.com/estore/index.php?main_page=product_info&cPath=1&products_id=4

I install the library and run an example but i get many of compile errors.  Here is an example error.
Code:
C:\arduino-1.0.1-windows\arduino-1.0.1\libraries\etherShield\enc28j60.c: In function 'enc28j60WriteOp':
C:\arduino-1.0.1-windows\arduino-1.0.1\libraries\etherShield\enc28j60.c:66: error: 'LOW' undeclared (first use in this function)
C:\arduino-1.0.1-windows\arduino-1.0.1\libraries\etherShield\enc28j60.c:73: error: 'HIGH' undeclared (first use in this function)

I believe the problem is the way the variables were defined.  Example:
Code:
#define CSACTIVE digitalWrite(ENC28J60_CONTROL_CS, LOW)
How can I make this work?  Any suggestions?
Logged

Seattle, WA USA
Offline Offline
Brattain Member
*****
Karma: 671
Posts: 51669
Seattle, WA USA
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Quote
I install the library
In the wrong place. User downloaded libraries do NOT go in the core library folder.

Quote
How can I make this work?  Any suggestions?
That library has not been upgraded to 1.0+. Which version of the IDE are you using?

If it is 1.0+, change WConstants,h to Arduino.h in all the files that include WConstants.h.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 28
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Thanks, it compiles now!
Logged

Pages: [1]   Go Up
Arduino Forum upgrade scheduled for Monday, October 20th, 11am-4pm (CEST). Sorry for the inconvenience!
Jump to: