Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Hands-On IoT Solutions with Blockchain

You're reading from   Hands-On IoT Solutions with Blockchain Discover how converging IoT and blockchain can help you build effective solutions

Arrow left icon
Product type Paperback
Published in Jan 2019
Publisher Packt
ISBN-13 9781789132243
Length 206 pages
Edition 1st Edition
Concepts
Arrow right icon
Authors (2):
Arrow left icon
Maximiliano Santos Maximiliano Santos
Author Profile Icon Maximiliano Santos
Maximiliano Santos
Enio Moura Enio Moura
Author Profile Icon Enio Moura
Enio Moura
Arrow right icon
View More author details
Toc

Table of Contents (11) Chapters Close

Preface 1. Understanding IoT and Developing Devices on the IBM Watson IoT Platform FREE CHAPTER 2. Creating Your First IoT Solution 3. Explaining Blockchain Technology and Working with Hyperledger 4. Creating Your Own Blockchain Network 5. Addressing Food Safety - Building around the Blockchain 6. Designing the Solution Architecture 7. Creating Your Blockchain and IoT Solution 8. The IoT, Blockchain, and Industry 4.0 9. Best Practices for Developing Blockchain and IoT Solutions 10. Other Books You May Enjoy

Coding the device firmware

Next, we will create a device application (firmware) that reads the sensor data and sends it to the backing application. In the previous chapter, we used Node.js to publish events from a device simulator, and now we're going to use this method to leverage the previous chapter's code. Remember that the objective of this solution is to water a plant whenever the temperature is high or the soil moisture is too low.

The next section shows the code needed in order to create the firmware that reads all the sensor data and publishes events to the IBM Watson IoT Platform.

Measuring soil moisture

The sensor probe used in this project is a resistive sensor, which measures the current that is passed...

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 $19.99/month. Cancel anytime
Banner background image