IoT: Building Arduino-Based Projects - Peter Waher - E-Book

IoT: Building Arduino-Based Projects E-Book

Peter Waher

0,0
67,19 €

-100%
Sammeln Sie Punkte in unserem Gutscheinprogramm und kaufen Sie E-Books und Hörbücher mit bis zu 100% Rabatt.

Mehr erfahren.
Beschreibung

Explore and learn about Internet of Things to develop interactive Arduino-based Internet projects

About This Book

  • Learn the capabilities and differences between popular protocols and communication patterns and how they can be used, and should not be used, to create secure and interoperable services and things
  • Build Internet-based Arduino devices to make your home feel more secure
  • Learn to protect cyber-physical systems and utilize forensic data analysis to beat vulnerabilities in your IoT ecosystem
  • Learn best practices to secure your data from device to the cloud

Who This Book Is For

If you're a developer or electronics engineer who is curious about Internet of Things, then this is the course for you. A rudimentary understanding of electronics, Raspberry Pi, or similar credit-card sized computers, and some programming experience using managed code such as C# or Java will be helpful. Business analysts and managers will also find this course useful.

What You Will Learn

  • Know the capabilities and limitations of the HTTP, UPnP, CoAP, MQTT, and XMPP protocols
  • Use important communication patterns, such as the request/respond, publish/subscribe, event subscription, asynchronous messaging, and multicasting patterns
  • Build a portable Wi-Fi signal strength sensor to give haptic feedback about signal strength to the user
  • Measure the water flow speed and volume with liquid flow sensors and record real-time readings
  • Secure your home with motion-activated Arduino security cameras and upload images to the cloud
  • Implement real-time data logging of a solar panel voltage with Arduino cloud connectors
  • Track locations with GPS and upload location data to the cloud
  • Control infrared-enabled devices with IR remote and Arduino
  • Use Systems Security Engineering and Privacy-by-design principles to design a secure IoT ecosystem

In Detail

The IoT: Building Arduino-Based Projects course will take you on a journey to become an expert in the use of IoT by developing a set of projects and finally guide you onto securing your IoT environment.

The course begins with exploring the popular HTTP, UPnP, CoAP, MQTT, and XMPP protocols. In the first module Learning Internet of Things, you will learn how protocols and patterns can put limitations on network topology and how they affect the direction of communication and the use of firewalls. This module gives you a practical overview of the existing protocols, communication patterns, architectures, and security issues important to Internet of Things.

The second module, Internet of Things with Arduino Blueprints provides you up to eight projects that will allow devices to communicate with each other, access information over the Internet, store and retrieve data, and interact with users?creating smart, pervasive, and always-connected environments. You can use these projects as blueprints for many other IoT projects and put them to good use.

It has becomes critical to ensure that cyber security threats are contained to a minimum when implementing new IoT services and solutions. Thus, our third module, Practical Internet of Things Security provides a set of guidelines to architect and deploy a secure IoT in your Enterprise. The aim is to showcase how the IoT is implemented in early adopting industries and describe how lessons can be learned and shared across diverse industries to support a secure IoT.

Style and approach

This course introduces you to the Internet of Things architecture, helps you build Arduino projects based on IoT and cloud computing concepts, create smart, pervasive and always-connected environments, and finally guide you onto securing your IoT environment. Each of these has been covered in individual modules so that you develop your skill after the completion of a module and get ready for the next

Sie lesen das E-Book in den Legimi-Apps auf:

Android
iOS
von Legimi
zertifizierten E-Readern

Seitenzahl: 938

Veröffentlichungsjahr: 2016

Bewertungen
0,0
0
0
0
0
0
Mehr Informationen
Mehr Informationen
Legimi prüft nicht, ob Rezensionen von Nutzern stammen, die den betreffenden Titel tatsächlich gekauft oder gelesen/gehört haben. Wir entfernen aber gefälschte Rezensionen.



Table of Contents

IoT: Building Arduino-Based Projects
IoT: Building Arduino-Based Projects
Credits
Preface
What this learning path covers
What you need for this learning path
Who this learning path is for
Reader feedback
Customer support
Downloading the example code
Errata
Piracy
Questions
1. Module 1
1. Preparing our IoT Projects
Creating the sensor project
Preparing Raspberry Pi
Clayster libraries
Hardware
Interacting with our hardware
Interfacing the hardware
Internal representation of sensor values
Persisting data
External representation of sensor values
Exporting sensor data
Creating the actuator project
Hardware
Interfacing the hardware
Creating a controller
Representing sensor values
Parsing sensor data
Calculating control states
Creating a camera
Hardware
Accessing the serial port on Raspberry Pi
Interfacing the hardware
Creating persistent default settings
Adding configurable properties
Persisting the settings
Working with the current settings
Initializing the camera
Summary
2. The HTTP Protocol
HTTP basics
Adding HTTP support to the sensor
Setting up an HTTP server on the sensor
Setting up an HTTPS server on the sensor
Adding a root menu
Displaying measured information in an HTML page
Generating graphics dynamically
Creating sensor data resources
Interpreting the readout request
Testing our data export
User authentication
Adding events for enhanced network performance
Adding HTTP support to the actuator
Creating the web services resource
Accessing individual outputs
Collective access to outputs
Accessing the alarm output
Using the test form
Accessing WSDL
Using the REST web service interface
Adding HTTP support to the controller
Subscribing to events
Creating the control thread
Controlling the actuator
Summary
3. The UPnP Protocol
Introducing UPnP
Providing a service architecture
Documenting device and service capabilities
Creating a device description document
Choosing a device type
Being friendly
Providing the device with an identity
Adding icons
Adding references to services
Topping off with a URL to a web presentation page
Creating the service description document
Adding actions
Adding state variables
Adding a unique device name
Providing a web interface
Creating a UPnP interface
Registering UPnP resources
Replacing placeholders
Adding support for SSDP
Notifying the network
Responding to searches
Implementing the Still Image service
Initializing evented state variables
Providing web service properties
Adding service properties
Adding actions
Using our camera
Setting up UPnP
Discovering devices and services
Subscribing to events
Receiving events
Executing actions
Summary
4. The CoAP Protocol
Making HTTP binary
Finding development tools
Adding CoAP to our sensor
Defining our first CoAP resources
Manually triggering an event notification
Registering data readout resources
Returning XML
Returning JSON
Returning plain text
Discovering CoAP resources
Testing our CoAP resources
Adding CoAP to our actuator
Defining simple control resources
Parsing the URL in CoAP
Controlling the output using CoAP
Using CoAP in our controller
Monitoring observable resources
Receiving notifications
Performing control actions
Summary
5. The MQTT Protocol
Publishing and subscribing
Adding MQTT support to the sensor
Controlling the thread life cycle
Flagging significant events
Connecting to the MQTT server
Publishing the content
Adding MQTT support to the actuator
Initializing the topic content
Subscribing to topics
Receiving the published content
Decoding and parsing content
Adding MQTT support to the controller
Handling events from the sensor
Decoding and parsing sensor values
Subscribing to sensor events
Controlling the actuator
Controlling the LED output
Controlling the alarm output
Summary
6. The XMPP Protocol
XMPP basics
Federating for global scalability
Providing a global identity
Authorizing communication
Sensing online presence
Using XML
Communication patterns
Extending XMPP
Connecting to a server
Provisioning for added security
Adding XMPP support to a thing
Connecting to the XMPP network
Monitoring connection state events
Notifying your friends
Handling HTTP requests over XMPP
Providing an additional layer of security
The basics of provisioning
Initializing the Thing Registry interface
Registering a thing
Updating a public thing
Claiming a thing
Removing a thing from the registry
Disowning a thing
Initializing the provisioning server interface
Handling friendship recommendations
Handling requests to unfriend somebody
Searching for a provisioning server
Providing registry information
Maintaining a connection
Negotiating friendships
Handling presence subscription requests
Continuing interrupted negotiations
Adding XMPP support to the sensor
Adding a sensor server interface
Updating event subscriptions
Publishing contracts
Adding XMPP support to the actuator
Adding a controller server interface
Adding XMPP support to the camera
Adding XMPP support to the controller
Setting up a sensor client interface
Subscribing to sensor data
Handling incoming sensor data
Setting up a controller client interface
Setting up a camera client interface
Fetching the camera image over XMPP
Identifying peer capabilities
Reacting to peer presence
Detecting rule changes
Connecting it all together
Summary
7. Using an IoT Service Platform
Selecting an IoT platform
The Clayster platform
Downloading the Clayster platform
Creating a service project
Adding references
Making a Clayster module
Executing the service
Using a package manifest
Executing from Visual Studio
Configuring the Clayster system
Using the management tool
Browsing data sources
Interfacing our devices using XMPP
Creating a class for our sensor
Finding the best class
Subscribing to sensor data
Interpreting incoming sensor data
Creating a class for our actuator
Customizing control operations
Creating a class for our camera
Creating our control application
Understanding rendering
Defining the application class
Initializing the controller
Adding control rules
Understanding application references
Defining brieflets
Displaying a gauge
Displaying a binary signal
Pushing updates to the client
Completing the application
Configuring the application
Viewing the 10-foot interface application
Summary
8. Creating Protocol Gateways
Understanding protocol bridging
Using an abstraction model
The basics of the Clayster abstraction model
Understanding editable data sources
Understanding editable objects
Using common data sources
Overriding key properties and methods
Controlling structure
Publishing properties
Publishing commands
Handling communication with devices
Reading devices
Configuring devices
Understanding the CoAP gateway architecture
Summary
9. Security and Interoperability
Understanding the risks
Reinventing the wheel, but an inverted one
Knowing your neighbor
Modes of attack
Denial of Service
Guessing the credentials
Getting access to stored credentials
Man in the middle
Sniffing network communication
Port scanning and web crawling
Search features and wildcards
Breaking ciphers
Tools for achieving security
Virtual Private Networks
X.509 certificates and encryption
Authentication of identities
Usernames and passwords
Using message brokers and provisioning servers
Centralization versus decentralization
The need for interoperability
Solves complexity
Reduces cost
Allows new kinds of services and reuse of devices
Combining security and interoperability
Summary
2. Module 2
1. Internet-Controlled PowerSwitch
Getting started
Hardware and software requirements
Arduino Ethernet Shield
The Arduino Ethernet board
Connecting Arduino Ethernet Shield to the Internet
Testing your Arduino Ethernet Shield
Selecting a PowerSwitch Tail
PN PSSRKT-240
PN80135
Wiring PowerSwitch Tail with Arduino Ethernet Shield
Turning PowerSwitch Tail into a simple web server
What is a web server?
A step-by-step process for building a web-based control panel
Handling client requests by HTTP GET
Sensing the availability of mains electricity
Testing the mains electricity sensor
Building a user-friendly web user interface
Adding a Cascade Style Sheet to the web user interface
Finding the MAC address and obtaining a valid IP address
Finding the MAC address
Obtaining an IP address
Assigning a static IP address
Obtaining an IP address using DHCP
Summary
2. Wi-Fi Signal Strength Reader and Haptic Feedback
Prerequisites
Arduino WiFi Shield
Firmware upgrading
Stacking the WiFi Shield with Arduino
Hacking an Arduino earlier than REV3
Knowing more about connections
Fixing the Arduino WiFi library
Connecting your Arduino to a Wi-Fi network
Wi-Fi signal strength and RSSI
Reading the Wi-Fi signal strength
Haptic feedback and haptic motors
Getting started with the Adafruit DRV2605 haptic controller
Selecting a correct vibrator
Connecting a haptic controller to Arduino WiFi Shield
Soldering a vibrator to the haptic controller breakout board
Downloading the Adafruit DRV2605 library
Making vibration effects for RSSI
Implementing a simple web server
Reading the signal strength over Wi-Fi
Summary
3. Internet-Connected Smart Water Meter
Prerequisites
Water flow sensors
Wiring the water flow sensor with Arduino
Reading pulses
Rising edge and falling edge
Reading and counting pulses with Arduino
Calculating the water flow rate
Calculating the water flow volume
Adding an LCD screen to the water meter
Converting your water meter to a web server
A little bit about plumbing
Summary
4. Arduino Security Camera with Motion Detection
Prerequisites
Getting started with TTL Serial Camera
Wiring the TTL Serial Camera for image capturing
Wiring the TTL Serial Camera for video capturing
Testing NTSC video stream with video screen
Connecting the TTL Serial Camera with Arduino and Ethernet Shield
Image capturing with Arduino
The Software Serial library
How the image capture works
Uploading images to Flickr
Creating a Flickr account
Creating a Temboo account
Creating your first Choreo
Initializing OAuth
Finalizing OAuth
Generating the photo upload sketch
Connecting the camera output with Temboo
Motion detection
Summary
5. Solar Panel Voltage Logging with NearBus Cloud Connector and Xively
Connecting a solar cell with the Arduino Ethernet board
Building a voltage divider
Building the circuit with Arduino
Setting up a NearBus account
Defining a new device
Examining the device lists
Downloading the NearBus agent
Creating and configuring a Xively account
Configuring the NearBus connected device for Xively
Developing a web page to display the real-time voltage values
Displaying data on a web page
Summary
6. GPS Location Tracker with Temboo, Twilio, and Google Maps
Hardware and software requirements
Hardware requirements
Software requirements
Getting started with the Arduino GPS shield
Connecting the Arduino GPS shield with the Arduino Ethernet board
Testing the GPS shield
Displaying the current location on Google Maps
Getting started with Twilio
Creating a Twilio account
Finding Twilio LIVE API credentials
Finding Twilio test API credentials
Get your Twilio number
Creating Twilio Choreo with Temboo
Sending an SMS with Twilio API
Send a GPS location data using Temboo
Summary
7. Tweet-a-Light – Twitter-Enabled Electric Light
Hardware and software requirements
Hardware
Software
Getting started with Python
Installing Python on Windows
Setting environment variables for Python
Installing the setuptools utility on Python
Installing the pip utility on Python
Opening the Python interpreter
Installing the Tweepy library
Installing pySerial
Creating a Twitter app and obtaining API keys
Writing a Python script to read Twitter tweets
Reading the serial data using Arduino
Connecting the PowerSwitch Tail with Arduino
Summary
8. Controlling Infrared Devices Using IR Remote
Building an Arduino infrared recorder and remote
Hardware
Software
Building the IR receiver module
Capturing IR commands in hexadecimal
Capturing IR commands in the raw format
Building the IR sender module
Controlling through the LAN
Adding an IR socket to non-IR enabled devices
Summary
3. Module 3
1. A Brave New World
Defining the IoT
Cybersecurity versus IoT security and cyber-physical systems
Why cross-industry collaboration is vital
IoT uses today
Energy industry and smart grid
Connected vehicles and transportation
Manufacturing
Wearables
Implantables and medical devices
The IoT in the enterprise
The things in the IoT
The IoT device lifecycle
IoT device implementation
IoT service implementation
IoT device and service deployment
The hardware
Operating systems
IoT communications
Messaging protocols
MQTT
CoAP
XMPP
DDS
AMQP
Gateways
Transport protocols
Network protocols
Data link and physical protocols
IEEE 802.15.4
ZWave
Power Line Communications
Cellular communications
IoT data collection, storage, and analytics
IoT integration platforms and solutions
The IoT of the future and the need to secure
The future – cognitive systems and the IoT
Summary
2. Vulnerabilities, Attacks, and Countermeasures
Primer on threats, vulnerability, and risks (TVR)
The classic pillars of information assurance
Threats
Vulnerability
Risks
Primer on attacks and countermeasures
Common IoT attack types
Attack trees
Building an attack tree
Fault (failure) trees and CPS
Fault tree and attack tree differences
Merging fault and attack tree analysis
Example anatomy of a deadly cyber-physical attack
Today's IoT attacks
Attacks
Wireless reconnaissance and mapping
Security protocol attacks
Physical security attacks
Application security attacks
Lessons learned and systematic approaches
Threat modeling an IoT system
Step 1 – identify the assets
Step 2 – create a system/architecture overview
Step 3 – decompose the IoT system
Step 4 – identify threats
Step 5 – document the threats
Step 6 – rate the threats
Summary
3. Security Engineering for IoT Development
Building security in to design and development
Security in agile developments
Focusing on the IoT device in operation
Secure design
Safety and security design
Threat modeling
Privacy impact assessment
Safety impact assessment
Compliance
Monitoring for compliance
Security system integration
Accounts and credentials
Patching and updates
Audit and monitoring
Processes and agreements
Secure acquisition process
Secure update process
Establish SLAs
Establish privacy agreements
Consider new liabilities and guard against risk exposure
Establish an IoT physical security plan
Technology selection – security products and services
IoT device hardware
Selecting an MCU
Selecting a real-time operating system (RTOS)
IoT relationship platforms
Xively
ThingWorx
Cryptographic security APIs
Authentication/authorization
Edge
Security monitoring
Summary
4. The IoT Security Lifecycle
The secure IoT system implementation lifecycle
Implementation and integration
IoT security CONOPS document
Network and security integration
Examining network and security integration for WSNs
Examining network and security integration for connected cars
Planning for updates to existing network and security infrastructures
Planning for provisioning mechanisms
Integrating with security systems
IoT and data buses
System security verification and validation (V&V)
Security training
Security awareness training for users
Security administration training for the IoT
Secure configurations
IoT device configurations
Secure gateway and network configurations
Operations and maintenance
Managing identities, roles, and attributes
Identity relationship management and context
Attribute-based access control
Role-based access control
Consider third-party data requirements
Manage keys and certificates
Security monitoring
Penetration testing
Red and blue teams
Evaluating hardware security
The airwaves
IoT penetration test tools
Compliance monitoring
Asset and configuration management
Incident management
Forensics
Dispose
Secure device disposal and zeroization
Data purging
Inventory control
Data archiving and records management
Summary
5. Cryptographic Fundamentals for IoT Security Engineering
Cryptography and its role in securing the IoT
Types and uses of cryptographic primitives in the IoT
Encryption and decryption
Symmetric encryption
Block chaining modes
Counter modes
Asymmetric encryption
Hashes
Digital signatures
Symmetric (MACs)
Random number generation
Ciphersuites
Cryptographic module principles
Cryptographic key management fundamentals
Key generation
Key establishment
Key derivation
Key storage
Key escrow
Key lifetime
Key zeroization
Accounting and management
Summary of key management recommendations
Examining cryptographic controls for IoT protocols
Cryptographic controls built into IoT communication protocols
ZigBee
Bluetooth-LE
Near field communication (NFC)
Cryptographic controls built into IoT messaging protocols
MQTT
CoAP
DDS
REST
Future directions of the IoT and cryptography
Summary
6. Identity and Access Management Solutions for the IoT
An introduction to identity and access management for the IoT
The identity lifecycle
Establish naming conventions and uniqueness requirements
Naming a device
Secure bootstrap
Credential and attribute provisioning
Local access
Account monitoring and control
Account updates
Account suspension
Account/credential deactivation/deletion
Authentication credentials
Passwords
Symmetric keys
Certificates
X.509
IEEE 1609.2
Biometrics
New work in authorization for the IoT
IoT IAM infrastructure
802.1x
PKI for the IoT
PKI primer
Trust stores
PKI architecture for privacy
Revocation support
OCSP
OCSP stapling
SSL pinning
Authorization and access control
OAuth 2.0
Authorization and access controls within publish/subscribe protocols
Access controls within communication protocols
Summary
7. Mitigating IoT Privacy Concerns
Privacy challenges introduced by the IoT
A complex sharing environment
Wearables
Smart homes
Metadata can leak private information also
New privacy approaches for credentials
Privacy impacts on IoT security systems
New methods of surveillance
Guide to performing an IoT PIA
Overview
Authorities
Characterizing collected information
Uses of collected information
Security
Notice
Data retention
Information sharing
Redress
Auditing and accountability
PbD principles
Privacy embedded into design
Positive-sum, not zero-sum
End-to-end security
Visibility and transparency
Respect for user privacy
Privacy engineering recommendations
Privacy throughout the organization
Privacy engineering professionals
Privacy engineering activities
Summary
8. Setting Up a Compliance Monitoring Program for the IoT
IoT compliance
Implementing IoT systems in a compliant manner
An IoT compliance program
Executive oversight
Policies, procedures, and documentation
Training and education
Skills assessments
Cyber security tools
Data security
Defense-in-depth
Privacy
The IoT, network, and cloud
Threats/attacks
Certifications
Testing
Internal compliance monitoring
Install/update sensors
Automated search for flaws
Collect results
Triage
Bug fixes
Reporting
System design updates
Periodic risk assessments
Black box
White box assessments
Fuzz testing
A complex compliance environment
Challenges associated with IoT compliance
Examining existing compliance standards support for the IoT
Underwriters Laboratory IoT certification
NIST CPS efforts
NERC CIP
HIPAA/HITECH
PCI DSS
NIST Risk Management Framework (RMF)
Summary
9. Cloud Security for the IoT
Cloud services and the IoT
Asset/inventory management
Service provisioning, billing, and entitlement management
Real-time monitoring
Sensor coordination
Customer intelligence and marketing
Information sharing
Message transport/broadcast
Examining IoT threats from a cloud perspective
Exploring cloud service provider IoT offerings
AWS IoT
Microsoft Azure IoT suite
Cisco Fog Computing
IBM Watson IoT platform
MQTT and REST interfaces
Cloud IoT security controls
Authentication (and authorization)
Amazon AWS IAM
Azure authentication
Software/firmware updates
End-to-end security recommendations
Maintain data integrity
Secure bootstrap and enrollment of IoT devices
Security monitoring
Tailoring an enterprise IoT cloud security architecture
New directions in cloud-enabled IOT computing
IoT-enablers of the cloud
Software defined networking (SDN)
Data services
Container support for secure development environments
Containers for deployment support
Microservices
The move to 5G connectivity
Cloud-enabled directions
On-demand computing and the IoT (dynamic compute resources)
New distributed trust models for the cloud
Cognitive IoT
Summary
10. IoT Incident Response
Threats both to safety and security
Planning and executing an IoT incident response
Incident response planning
IoT system categorization
IoT incident response procedures
The cloud provider's role
IoT incident response team composition
Communication planning
Exercises and operationalizing an IRP in your organization
Detection and analysis
Analyzing the compromised system
Analyzing the IoT devices involved
Escalate and monitor
Containment, eradication, and recovery
Post-incident activities
Summary
A. Bibliography
Index

IoT: Building Arduino-Based Projects

IoT: Building Arduino-Based Projects

Explore and learn about Internet of Things to develop interactive Arduino-based Internet projects

A course in three modules

BIRMINGHAM - MUMBAI

IoT: Building Arduino-Based Projects

Copyright © 2016 Packt Publishing

All rights reserved. No part of this course may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this course to ensure the accuracy of the information presented. However, the information contained in this course is sold without warranty, either express or implied. Neither the authors, nor Packt Publishing, and its dealers and distributors will be held liable for any damages caused or alleged to be caused directly or indirectly by this course.

Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this course by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

Published on: August 2016

Published by Packt Publishing Ltd.

Livery Place

35 Livery Street

Birmingham B3 2PB, UK.

ISBN 978-1-78712-063-1

www.packtpub.com

Credits

Authors

Peter Waher

Pradeeka Seneviratne

Brian Russell

Drew Van Duren

Reviewers

Fiore Basile

Dominique Guinard

Phodal Huang

Joachim Lindborg

Ilesh Patel

Francesco Azzola

Paul Deng

Charalampos Doukas

Paul Massey

Aaron Guzman

Content Development Editor

Nikhil Borkar

Graphics

Abhinash Sahu

Production Coordinator

Melwyn Dsa

Preface

Internet of Things is one of the current top tech buzzwords. Large corporations value its market in tens of trillions of dollars for the upcoming years, investing billions into research and development. On top of this, there is the plan for the release of tens of billions of connected devices during the same period. So you can see why it is only natural that it causes a lot of buzz. While we benefit from the IoT, we must prevent, to the highest possible degree, our current and future IoT from harming us; and to do this, we need to secure it properly and safely. We hope you enjoy this course and find the information useful for securing your IoT.

What this learning path covers

Module 1, Learning Internet of Things, begins with exploring the popular HTTP, UPnP, CoAP, MQTT, and XMPP protocols. You will learn how protocols and patterns can put limitations on network topology and how they affect the direction of communication and the use of firewalls. This module gives you a practical overview of the existing protocols, communication patterns, architectures, and security issues important to Internet of Things

There are a few Appendices which are not present in this module but are available for download at the following link: https://www.packtpub.com/sites/default/files/downloads/3494_3532OT_Appendices.pdf

Module 2, Internet of Things with Arduino Blueprints, provides you up to eight projects that will allow devices to communicate with each other, access information over the Internet, store and retrieve data, and interact with users―creating smart, pervasive, and always-connected environments. You can use these projects as blueprints for many other IoT projects and put them to good use.

Module 3, Practical Internet of Things Security, provides a set of guidelines to architect and deploy a secure IoT in your Enterprise. The aim is to showcase how the IoT is implemented in early-adopting industries and describe how lessons can be learned and shared across diverse industries to support a secure IoT.

What you need for this learning path

For Module 1, Apart from a computer running Windows, Linux, or Mac OS, you will need four or five Raspberry Pi model B credit-card-sized computers, with SD cards containing the Raspbian operating system installed. Appendix R, Bill of Materials, which is available online, lists the components used to build the circuits used in the examples presented in this module.

The software used in this module is freely available on the Internet. The source code for all the projects presented in this module is available for download from GitHub. See the section about downloading example code, which will follow, for details.

Module 2, has been written and tested on the Windows environment and uses various software components with Arduino.

For Module 3, you will need SecureITree version 4.3, a common desktop or laptop, and a Windows, Mac, or Linux platform running Java 8.

Who this learning path is for

If you’re a developer or electronics engineer who is curious about Internet of Things, then this is the course for you. A rudimentary understanding of electronics, Raspberry Pi, or similar credit-card sized computers, and some programming experience using managed code such as C# or Java will be helpful. Business analysts and managers will also find this course useful.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this course—what you liked or disliked. Reader feedback is important for us as it helps us develop titles that you will really get the most out of.

To send us general feedback, simply e-mail <[email protected]>, and mention the course’s title in the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide at www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt course, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files for this course from your account at http://www.packtpub.com. If you purchased this course elsewhere, you can visit http://www.packtpub.com/support and register to have the files e-mailed directly to you.

You can download the code files by following these steps:

Log in or register to our website using your e-mail address and password.Hover the mouse pointer on the SUPPORT tab at the top.Click on Code Downloads & Errata.Enter the name of the course in the Search box.Select the course for which you’re looking to download the code files.Choose from the drop-down menu where you purchased this course from.Click on Code Download.

You can also download the code files by clicking on the Code Files button on the course’s webpage at the Packt Publishing website. This page can be accessed by entering the course’s name in the Search box. Please note that you need to be logged in to your Packt account.

Once the file is downloaded, please make sure that you unzip or extract the folder using the latest version of:

WinRAR / 7-Zip for WindowsZipeg / iZip / UnRarX for Mac7-Zip / PeaZip for Linux

The code bundle for the course is also hosted on GitHub at https://github.com/PacktPublishing/IoT-Building-Arduino-based-Projects. We also have other code bundles from our rich catalog of books, videos and courses available at https://github.com/PacktPublishing/. Check them out!

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our courses—maybe a mistake in the text or the code—we would be grateful if you could report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this course. If you find any errata, please report them by visiting http://www.packtpub.com/submit-errata, selecting your course, clicking on the Errata Submission Form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded to our website or added to any list of existing errata under the Errata section of that title.

To view the previously submitted errata, go to https://www.packtpub.com/books/content/support and enter the name of the course in the search field. The required information will appear under the Errata section.

Piracy

Piracy of copyrighted material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works in any form on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at <[email protected]> with a link to the suspected pirated material.

We appreciate your help in protecting our authors and our ability to bring you valuable content.

Questions

If you have a problem with any aspect of this course, you can contact us at <[email protected]>, and we will do our best to address the problem.

Part 1. Module 1

Learning Internet of Things

Explore and learn about Internet of Things with the help of engaging and enlightening tutorials designed for Raspberry Pi

Summary

In this chapter, we presented most of the projects that will be discussed in this book, together with circuit diagrams that show how to connect our hardware components. We also introduced development using C# for Raspberry Pi and presented the basic project structure. Several Clayster libraries were also introduced that help us with common programming tasks such as communication, interoperability, scripting, event logging, interfacing GPIO, and data persistence.

In the next chapter, we will introduce our first communication protocol for the IoT: The Hypertext Transfer Protocol (HTTP).

Chapter 2. The HTTP Protocol

Now that we have a definition for Internet of Things, where do we start? It is safe to assume that most people that use a computer today have had an experience of Hypertext Transfer Protocol (HTTP), perhaps without even knowing it. When they "surf the Web", what they do is they navigate between pages using a browser that communicates with the server using HTTP. Some even go so far as identifying the Internet with the Web when they say they "go on the Internet" or "search the Internet".

Yet HTTP has become much more than navigation between pages on the Internet. Today, it is also used in machine to machine (M2M