MySQL for the Internet of Things

(Steven Felgate) #1
ChApTEr 2 ■ hArdwArE for IoT SoluTIonS

While you can use this shield as a WiFi gateway for your Arduino, it is not programmed the same way.
Instead of using the Ethernet library, it has its own library that you must download and use. This library
(https://github.com/sparkfun/SparkFun_ESP8266_AT_Arduino_Library) allows you to use methods to
access the AT command set of the ESP8266 to connect to the network. Fortunately, the methods are similar
to the Ethernet library but not compatible. Thus, you may need to rewrite the networking portions of your
existing sketches to use the shield.
The ESP8266 WiFi SoC comes programmed to work with the Arduino as a WiFi shield. However, it can
be reprogrammed. Notice the ESP8266 connections at the top of the board. You can use these to program the
ESP8266. All you need to do is solder a pin header on the board and connect it via an FTDI cable. This allows
you to experiment with the ESP8266 chip by modifying it to add additional commands or features, making
this shield a middle ground between an Arduino and the ESP8266 breakout board.
To learn more about this special board, see https://learn.sparkfun.com/tutorials/esp8266-wifi-
shield-hookup-guide.


Adafruit WiFi Shield


The Adafruit WiFi shield is one of the few Arduino Ethernet clone boards that I’ve found to be a good
alternative. The Adafruit WiFi shield uses the CC3000 chipset, which requires a new library. Fortunately,
Adafruit has an excellent tutorial for using the library (https://learn.adafruit.com/adafruit-shield-
compatibility/cc3000-wifi-shield).


Figure 2-20. Sparkfun WiFi shield, ESP8266

Free download pdf