nuelectronics

I have developed a Ethernet shield for Arduino boards. The board uses the Microchip's ENC28J60 SPI based ethernet controller. A tiny open-source TCP/IP stack has been developed as an Arduino IDE library. The memory usage is moderate -- 7700 bytes FLASH space and around 520 bytes of SRAM are used for the following application, A webserver with temperature sensor reading. It leaves around half of the FLASH and SRAM space for your own application

nuelectronics

The memory usage -- for the above webserver with Temperature reading example

[size=16]Flash -- 7700 bytes; SRAM -- around 520 bytes [/size]

So for ATMEGA8 with 8K flash and 1K SRAM, this example will be difficult to fit in unless you don't use bootloader. But the temperature reading routine takes around 2K space in the Flash. my other example, the webserver example, only use 5.5K flash space, so it should fit into the ATMEGA8 without problems.

nuelectronics

the library does not compile (on linux) because etherShield.cpp tries to include EtherShield.h but the name of the file is etherShield.h (camelCase).

Ususally the C-header/source-files are in all lower-case so I suggest you rename the files to ethershield.h ethershield.cpp or go with the classname EtherShield.h EtherShield.cpp

Eberhard

Thanks for the advice.

The library was only tested on Windows machine, since I don't have a Linux PC. I've changed the line #include "EtherShield.h to #include "etherShield.h" in file etherShield.cpp. The new file has been uploaded to my website.

Hope it will work on Linux. I'd really appreciate if someone could test it. Thanks

the library does not compile (on linux) because etherShield.cpp tries to include EtherShield.h but the name of the file is etherShield.h (camelCase).

Ususally the C-header/source-files are in all lower-case so I suggest you rename the files to ethershield.h ethershield.cpp or go with the classname EtherShield.h EtherShield.cpp

Eberhard

Thanks for the advice.

The library was only tested on Windows machine, since I don't have a Linux PC. I've changed the line #include "EtherShield.h to #include "etherShield.h" in file etherShield.cpp. The new file has been uploaded to my website.

Hope it will work on Linux. I'd really appreciate if someone could test it. Thanks

Cheater

Also have you considered putting a AVR on the shield so the code required to interface with it is reduced?Put all the low level code on the on board processor and expose a simple API over I2C or something.

Also have you considered putting a AVR on the shield so the code required to interface with it is reduced?Put all the low level code on the on board processor and expose a simple API over I2C or something.

I agree that would be pretty cool and not only for arduino but avr/microcontrollers in general. Just make sure that we can still program the onboard avr as well .... Darn, now I wish I thought of such a shield with the onboard avr idea. Let me know if you need help with the firmware for your onboard avr. if your planning on doing it ...

nuelectronics

Also have you considered putting a AVR on the shield so the code required to interface with it is reduced?Put all the low level code on the on board processor and expose a simple API over I2C or something.

En... It is a good idea - can be implemented with Full TCP/IP protocol rather than the Single data packet at the moment. But are we going to reinvent the WIZNET module?

uh

to make it a bit more straightforward i've pulled out a few of the functions -- probably worth adding something like this to the library to make it simpler for those who basically just want to be able to serve webpages with dynamic values.

you can download the template here (just make sure you have the etherShield library installed; and set your IP address to one that doesn't already exist on your network).