
|
Reflective Heat Technologies
-
Arduino Mega Dual Stack IPv4/v6 Web Server
-
Arduino UNO IPv6 Web Server
|


RHT uses the Arduino platform for
its solar thermal system
sensors. Given that many sensor networks will be built using IPv6 in
the
future, RHT has developed an IPv6 Ethernet library. This work
is offered to the arduino community for its collective benefit.
The official Arduino Ethernet Shield is
based on the WizNet
5100 chip, which implements the IPv4 protocol stack in silicon.
As a consequence, the Arduino Ethernet Shield cannot be used
to implement an IPv6 stack.
To implement an IPv6 stack, it is
necessary to use a shield
based on hardware that permits the management of IP and Ethernet layer
functions. Shields based on the MicroChip
ENC28J60 chip
(such as those sold by Ekitszone
and Nuelectronics)
are suitable for the implementation of an IPv6 or dual IPv4/IPv6 stack.
This approach requires the TCP state machine to be
implemented in software and results in more complex arduino code.
The RHT IPv6 libraries are based on the EtherShield
library developed by Pascal Stang, Xing Yu, and Guido Socher.
The earlier ipv6etherhield
developed by Guenther Hoelzl was tested but found to be unstable and
would not compile on the most recent versions of the Arduino Integrated
Development Environment (IDE). Thank you to all of those whose work was
used as the basis of this effort.
The RHT IPv6 libraries are availbale for
both the
Arduino Mega
and Arduino UNO
platforms. RHT recommends that the Ekitszone
Ethernet Shield for Arduino Mega be used with the Arduino
Mega, and that the Ekitszone
Ethernet Shield for Arduino UNO
be used with the Arduino UNO.
The Ekitszone
Ethernet Shield for Arduino UNO can
be used with the Arduino Mega if the connection of
the ENC28J60-based shield to the Arduino Mega is
modified. Pins 10, 11, 12 and 13 of the ENC28J60-based shield
must be
bent out (or cut), and these pins of the shield must be then connected
(by adding
wires) to the Arduino Mega pins 53, 51, 50 and 52 respectively.
The RHT IPv6 library supports IPv4 and
IPv6 Unicast addresses
(manually configured by user
by editing the sketch)
The RHT IPv4/IPv6
web server application for the Arduino Mega platform
provides a
minimal
implementation of the protocol stack as follows:
- Address Resolution Protocol (ARP) for
IPv4.
- ICMPv6
Neighbor Advertisement messages are provided in
response to ICMPv6 Neighbor Solicitation messages.
- ICMPv4 Echo Reply messages are
provided in response to ICMPv4 Echo Request (ping) messages.
- ICMPv6 Echo Reply messages are
provided in response to ICMPv6 Echo Request
(ping) messages.
- An
HTTP page is provided in a single packet, in response to
an HTTP Request.
- IPv4 and IPv6 stacks can be
individually enabled.
The RHT IPv6 web server application for
the Arduino UNO platform provides a
minimal
implementation of the protocol stack as follows:
- ICMPv6
Neighbor Advertisement messages are provided in
response to ICMPv6 Neighbor Solicitation messages.
- ICMPv6 Echo Reply messages are
provided in response to ICMPv6 Echo Request
(ping) messages.
- An
HTTP page is provided in a single packet, in response to
an HTTP Request.
Potential Applications:
- A
simple web server to confirm ipv6 connectivity when
testing IPv6 network configurations.
- An
HTTP sensor that can be polled using HTTP Requests.
- An
HTTP controller that can receive HTTP messages to turn
devices on or off.
To use the RHT IPv6 libraries:
- Download the RHT Dual Stack IPv4/IPv6
Library for the Arduino Mega or the RHT IPv6 Library for the
Arduino UNO and
copy the library files
into the Arduino IDE libraries directory,
- Open
the Arduino IDE (Arduino IDE version 0022 is recommended, we have had
problems uploading to the Arduino Mega platform with the Arduino IDE
version 1.0.1), and load the example
located in the example sub-directory under the RHT IPv6 library
sub-directory.
- Edit
the IPv6 addresses, and the http data to be returned, at the
top of the Arduino .pde file as appropriate to your environment.
- If
you plan to run more than one Ethernet-connected Arduino on the same
link, be sure to configure distinct Ethernet MAC addresses, IPv6
unicast addresses, and IPv4 addresses for each
Arduino.
- Compile, Upload and Run your Arduino
sketch.
- Note
that some virus scanner programs will block IPv6 packets by default -
you may have to enable IPv6 on the virus scanner, or turn off the virus
scanner for your initial tests to work.
- Use a browser to access your IPv6
Arduino with a URL such as http://[2001:0470:9bca:0815::1234]/.
Questions and comments on the RHT IPv6
library should be addressed to ipv6@reflectiveheat.com.

|
Custom Arduino Development
|
We offer expertise with solutions including;
- XBEE wireless
radios,
- DS18B20 temperature
sensors,
- LCD displays,
- serial interfaces,
- ethernet interfaces (IPv4 and IPv6),
- PHP server data management solutions.
Contact us at arduino@reflectiveheat.com
for a quotation on your requirement.