Tweeting Arduinos
A useful and interesting hardware kit is Botanicalls.
need water, and if they do, it sends a reminder message via http://twitter.com/. As
soon as you water the plant, Botanicalls dutifully sends a "Thank You" message.
Although the official version of Botanicalls is a specialized piece of hardware, you can
build it using an Arduino.
Botanicalls certainly make your life easier. Whether the Tweeting Vending Machine
improves your life is a matter of taste. Users of this modified vending machine have
to identify themselves using an RFID card. Whenever they buy some sweets, the
vending machine Tweets their name and what they ve bought.
a.
http://www.botanicalls.com/
b.
http://www.botanicalls.com/archived_kits/twitter/
c.
http://www.popsugar.com/tech/Tweeting-Vending-Machine-34558986
credentials. Finally, we invoke
success message to the console. If anything goes wrong,
an exception, and we ll print its stack trace for debugging purposes.
That s all the code we need, so connect your Arduino to your PC and run it!
The following figure shows what happens on Twitter when the temperature
in my working room is higher than 32 degrees Celsius. (For your first tests,
you might have to change
it, why aren t you at the beach?)
Using a full-blown PC as an Internet relay for your Arduino is convenient,
but it s also overkill for most applications. In the next section, you ll learn
how to turn an Arduino into a real networking device.
Chapter 10. Networking with Arduino
b
updateStatus
. If everything went fine, we print a
to a smaller value. If you don t have to change
32.0
www.it-ebooks.info
a
It checks whether your plants
will raise
updateStatus
172
c
report erratum
discuss
Need help?
Do you have a question about the Arduino Uno and is the answer not in the manual?