Getting Started: Freetronics … · 2014. 6. 14. · Ethernet Shield Features The Freetronics...

2
Ethernet Shield with PoE Support www.freetronics.com/ethernet-shield Getting Started: Freetronics Ethernet Shield for Arduino The Ethernet Shield is an Arduino-compatible expansion board ("shield") that gives your Arduino the ability to communicate as either a client or a server on an Ethernet network. It plugs directly into the Freetronics TwentyTen, the Arduino Duemilanove, and other Arduino-compatible boards that use the same header format. It uses the same Wiznet W5100 chipset as the official Arduino Ethernet Shield and connects using the same SPI pins, so it is 100% compatible with the official Arduino Ethernet library. Any example code or projects that use the official Ethernet Shield will work perfectly well with the Freetronics Ethernet Shield, and now have added Power-over-Ethernet ability, reset circuitry, SPI bus CS fix, plus a prototyping area for your project. Installation And Testing 1. Place the Ethernet Shield on top of your Arduino so that the header pins align with the Arduino headers, and carefully push it down into place. For the next example steps the Ethernet Shield will be powered by the Arduino's USB power source when it is attached to the computer. There are many other ways to power this device. 2. Plug one end of an Ethernet cable into your Ethernet Shield, and the other end of the cable into a suitable ethernet socket on your network switch, router or similar device. 3. Connect the Arduino to your computer via the USB cable, and check that the Arduino IDE is set to the appropriate COM port. Your Arduino and Ethernet Shield are now powered by USB and ready for a sketch. 4. Open the Arduino IDE, and navigate to File > Examples > Ethernet > WebServer. An example sketch will open. 5. Update the "ip[]" value near the top of the WebServer sketch to suit the settings for your network. The IP address must be within your network range, but not used by any other computer. Note that the IP address numbers must be comma-separated rather than dot-separated because they are stored as separate array elements. 6. Select Sketch > Verify / Compile to check that the sketch compiles without errors. 7. Select File > Upload to I/O Board to upload the sketch to your Arduino. 8. Open a web browser on your computer, and go to the IP address you set for your Arduino in step 5. You should see a web page containing values read from the analog inputs or your Arduino, which will be semi-random numbers since they aren't connected to anything. You can now try any other example code or projects designed for the Ethernet Shield. Online Resources There's a wealth of information, sketches and libraries out on the internet for all things Arduino related. If there's a useful function, IC or shield there is likely to be some example code or a library to support it. And it's being added to almost daily as people like yourself create new solutions and share their projects and code to suit. The official Arduino website includes a wealth of information including tutorials, a language reference, projects, and examples. Official Arduino site www.arduino.cc Arduino discussion forum www.arduino.cc/cgi-bin/yabb2/YaBB.pl Freetronics resources page www.freetronics.com/resources Freeduino knowledgebase www.freeduino.org IRC channel Network: irc.freenode.net. Channel: #arduino A Google search for "arduino projects", "arduino code" or "arduino examples" is recommended too. Arduino Books Getting Started With Arduino by Massimo Banzi (O'Reilly) A gentle introduction to using your Arduino for the first time: how to connect it up, load programs onto it, and do some basic experiments to give you a feel for how it works. Great introduction for the first-time Arduino user. 128 pages. www.oreilly.com/pub/pr/2115 Practical Arduino by Jonathan Oxer and Hugh Blemings (Apress) Taking you far beyond the basics, this book blends theory and practice by using example projects to illustrate some of the more advanced things you can do with Arduino and how to apply those same concepts to your own designs. After working through this book you'll be very confident designing and building your own Arduino creations. 445 pages. www.practicalarduino.com

Transcript of Getting Started: Freetronics … · 2014. 6. 14. · Ethernet Shield Features The Freetronics...

Page 1: Getting Started: Freetronics … · 2014. 6. 14. · Ethernet Shield Features The Freetronics Ethernet Shield uses Arduino digital I/O pins 10, 11, 12, and 13 for SPI communication

Ethernet Shield with PoE Support

www.freetronics.com/ethernet-shield

Getting Started: Freetronics Ethernet Shield for Arduino

The Ethernet Shield is an Arduino-compatible expansion board ("shield") that gives yourArduino the ability to communicate as either a client or a server on an Ethernet network. It plugsdirectly into the Freetronics TwentyTen, the Arduino Duemilanove, and other Arduino-compatibleboards that use the same header format. It uses the same Wiznet W5100 chipset as the officialArduino Ethernet Shield and connects using the same SPI pins, so it is 100% compatible with theofficial Arduino Ethernet library.

Any example code or projects that use the official Ethernet Shield will work perfectly well with theFreetronics Ethernet Shield, and now have added Power-over-Ethernet ability, reset circuitry, SPIbus CS fix, plus a prototyping area for your project.

Installation And Testing1. Place the Ethernet Shield on top of your Arduino so that the header pins align with the Arduino headers, andcarefully push it down into place. For the next example steps the Ethernet Shield will be powered by the Arduino's USBpower source when it is attached to the computer. There are many other ways to power this device.

2. Plug one end of an Ethernet cable into your Ethernet Shield, and the other end of the cable into a suitable ethernetsocket on your network switch, router or similar device.

3. Connect the Arduino to your computer via the USB cable, and check that the Arduino IDE is set to the appropriateCOM port. Your Arduino and Ethernet Shield are now powered by USB and ready for a sketch.

4. Open the Arduino IDE, and navigate to File > Examples > Ethernet > WebServer. An example sketch will open.

5. Update the "ip[]" value near the top of the WebServer sketch to suit the settings for your network. The IP addressmust be within your network range, but not used by any other computer. Note that the IP address numbers must becomma-separated rather than dot-separated because they are stored as separate array elements.

6. Select Sketch > Verify / Compile to check that the sketch compiles without errors.

7. Select File > Upload to I/O Board to upload the sketch to your Arduino.

8. Open a web browser on your computer, and go to the IP address you set for your Arduino in step 5. You should seea web page containing values read from the analog inputs or your Arduino, which will be semi-random numbers sincethey aren't connected to anything.

You can now try any other example code or projects designed for the Ethernet Shield.

Online Resources

There's a wealth of information, sketches and libraries out on the internet for all things Arduino related. If there's a usefulfunction, IC or shield there is likely to be some example code or a library to support it. And it's being added to almost daily aspeople like yourself create new solutions and share their projects and code to suit. The official Arduino website includes a wealthof information including tutorials, a language reference, projects, and examples.

Official Arduino site www.arduino.cc

Arduino discussion forum www.arduino.cc/cgi-bin/yabb2/YaBB.pl

Freetronics resources page www.freetronics.com/resources

Freeduino knowledgebase www.freeduino.org

IRC channel Network: irc.freenode.net. Channel: #arduinoA Google search for "arduino projects", "arduino code" or "arduino examples" is recommended too.

Arduino Books

Getting Started With Arduino by Massimo Banzi (O'Reilly)A gentle introduction to using your Arduino for the first time: how to connect it up, load programsonto it, and do some basic experiments to give you a feel for how it works. Great introduction for thefirst-time Arduino user. 128 pages.

www.oreilly.com/pub/pr/2115Practical Arduino by Jonathan Oxer and Hugh Blemings (Apress)Taking you far beyond the basics, this book blends theory and practice by using example projects toillustrate some of the more advanced things you can do with Arduino and how to apply those sameconcepts to your own designs. After working through this book you'll be very confident designing andbuilding your own Arduino creations. 445 pages.

www.practicalarduino.com

Page 2: Getting Started: Freetronics … · 2014. 6. 14. · Ethernet Shield Features The Freetronics Ethernet Shield uses Arduino digital I/O pins 10, 11, 12, and 13 for SPI communication

Ethernet Shield Features

The Freetronics Ethernet Shield uses Arduino digital I/O pins 10,11, 12, and 13 for SPI communication between the Arduino and theshield. Pin 10 is the CS (select) line that must be uniquely assignedto only one SPI device, while the other lines are shared betweendevices. The Wiznet chipset's "enable" pin has been slaved to theCS line so that it will relinquish the SPI bus when not selected,allowing other SPI devices to share the same bus. LAN status andpower LEDs are also provided. Speeds of 10/100Mbps aresupported.

SpecificationsChipset Wiznet W5100

PoE Support Rectified connections exposedon PoE header

I/O Pins Used By Shield 10, 11, 12, 13 used for SPIMax Simultaneous Connections 4

Power-over-Ethernet Options

The Freetronics Ethernet Shield can use Power-over-Ethernet todraw power from the network for itself, your Arduino, and anyother shields you may have connected. To make it as flexible aspossible the Ethernet Shield itself does not implement any on-boardPoE voltage regulation, but provides a 4-pin PoE header that youcan use in several different ways depending on your requirements.

All the PoE schemes described below require two basic elements:"Power Sourcing Equipment" (or "PSE") located inside or nearyour Ethernet switch to "inject" power onto the network cable, andthe "Powered Device" (or "PD", in this case your Arduino andEthernet Shield) to extract and use the power. A more detailedexplanation of Power-over-Ethernet schemes can be found on the Freetronics website at www.freetronics.com/poe.

DIY 7-12Vdc Power-over-EthernetThis is the cheapest approach because your Ethernet Shield does not need to perform anyvoltage pre-regulation. Strip back the insulation near the end of your network cable and connecta DC power jack as explained at www.freetronics.com/poe, or use a device such as theFreetronics 4-Channel Power-over-Ethernet Midspan Injector (www.freetronics.com/poe-injector-4ch) to inject between 7Vdc and 12Vdc onto the network cable. Because your Arduinocan safely operate on that input voltage range you can fit the pair of supplied 2-way jumperheaders onto the Ethernet Shield PoE header so that you connect "GND" and "PoE-" togetherwith one jumper, and "VIN" and "PoE+" together with the other jumper. Any power you injectonto the network cable as described at the URL above will then be passed directly through toyour Arduino's on-board voltage regulator to be reduced to 5V. Warning: do not fit thesejumpers if your network uses commercial 802.3af/at PoE, which operates at around 48Vdc and will damage yourArduino.

DIY 14-24Vdc Power-over-EthernetMany DIY Power-over-Ethernet systems operate at 16Vdc, 18Vdc, or 24Vdc, which is too high to feeddirectly to the on-board voltage regulator on your Arduino without generating excessive heat. To operate ona network with a PoE supply between 14Vdc and 24Vdc you must first fit a PoE Regulator 24V(www.freetronics.com/poe-regulator-24v) to your Ethernet Shield. The PoE Regulator 24V is a tinydaughter-board that fits onto the PoE header and mounts over part of the prototyping area on the EthernetShield, and includes a 12V voltage regulator that pre-regulates the supplied voltage down to 12V before it ispassed on to the Arduino for further regulation down to 5V. Detailed installation instructions are includedwith the PoE Regulator 24V, and more information is available on the product page linked above.

Commercial 802.3af / 802.3at Power-over-EthernetCommercial PoE equipment that complies with the 802.3af or 802.3at standards supplies around 48Vdc on the network, anduses a signalling scheme to allow powered devices to negotiate a power budget with the Power Sourcing Equipment. To operateon an 802.3af/at network your Ethernet Shield requires a PoE Regulator 802.3 (www.freetronics.com/poe-regulator-8023) that implements the necessary voltage regulation and signalling scheme. This module will be available soonfrom Freetronics. Warning: Do not connect your Arduino and Ethernet Shield to a commercial PoE-enabled networkwith either the jumper headers or the PoE-Regulator-24V fitted. They are not rated to operate at 48Vdc.

About Freetronics

Freetronics is an Australian company created by Jonathan Oxer and Marc Alexander to provide cheap and easy access tohardware, parts, and products related to Arduino projects and the Practical Arduino book. Learn more atwww.freetronics.com. Follow us on Twitter at twitter.com/freetronics.