Search icon CANCEL
Subscription
0
Cart icon
Cart
Close icon
You have no products in your basket yet
Save more on your purchases!
Savings automatically calculated. No voucher code required
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Internet of Things with Arduino Cookbook

You're reading from  Internet of Things with Arduino Cookbook

Product type Book
Published in Sep 2016
Publisher Packt
ISBN-13 9781785286582
Pages 188 pages
Edition 1st Edition
Languages
Concepts
Author (1):
Marco Schwartz Marco Schwartz
Profile icon Marco Schwartz
Toc

Table of Contents (14) Chapters close

Internet of Things with Arduino Cookbook
Credits
About the Author
About the Reviewer
www.PacktPub.com
Preface
1. Connecting an Arduino to the Web 2. Cloud Data Monitoring 3. Interacting with Web Services 4. Machine-to-Machine Interactions 5. Home Automation Projects 6. Fun Internet of Things Projects 7. Mobile Robot Applications Index

Posting the sensor data online


Using the Arduino MKR1000 board and the sensors that we connected to it, we are finally going to log data online, using the Dweet.io service.

Getting ready

For this recipe, you simply need to have the previous recipe up and running, so make sure you have all the sensors connected to your board, and that you have tested them with the test sketch.

You should already have it by now, but make sure that you have the Arduino WiFi101 library installed inside the Arduino IDE.

How to do it...

We are now going to configure the board so it sends the measurements from the sensor to Dweet.io at regular intervals. As this sketch is quite similar to what we already saw in previous chapters, I will only highlight the most important parts of the code here:

  1. First, we need to define the libraries that we are going to use in this project:

    #include <SPI.h>
    #include <WiFi101.h>
    #include "DHT.h"
  2. Then, we need to define a name for our thing on Dweet.io, which is the name we will...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}