Search icon CANCEL
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Hands-On IoT Solutions with Blockchain
Hands-On IoT Solutions with Blockchain

Hands-On IoT Solutions with Blockchain: Discover how converging IoT and blockchain can help you build effective solutions

Arrow left icon
Profile Icon Santos Profile Icon Enio Moura
Arrow right icon
R$217.99
Paperback Jan 2019 206 pages 1st Edition
eBook
R$80 R$173.99
Paperback
R$217.99
Subscription
Free Trial
Renews at R$50p/m
Arrow left icon
Profile Icon Santos Profile Icon Enio Moura
Arrow right icon
R$217.99
Paperback Jan 2019 206 pages 1st Edition
eBook
R$80 R$173.99
Paperback
R$217.99
Subscription
Free Trial
Renews at R$50p/m
eBook
R$80 R$173.99
Paperback
R$217.99
Subscription
Free Trial
Renews at R$50p/m

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
Table of content icon View table of contents Preview book icon Preview Book

Hands-On IoT Solutions with Blockchain

Creating Your First IoT Solution

In the previous chapter, we explored the Internet of Things (IoT) as well as the IBM Watson IoT Platform. We also created our first simple solution. In this chapter, we will put this into practice by creating a simple end-to-end solution, from selecting the device to creating the device firmware and an application designed to control a simple garden watering system.

The following topics will be covered in this chapter:

  • Understanding how to set up a solution
  • Creating a connected device
  • Creating a simple application connected to the platform
  • Publishing and processing device events
  • Publishing actions to devices
  • How to get help when you're in trouble

Technical requirements

The first IoT solution – the gardening solution

Watering systems are common first projects for using IoT in the DIY community. We too will use it as an example project to get started on the IBM Watson IoT Platform. 

Requirements overview

Good solutions are based on problems that really matter to people. So let's start our solution with an introduction to the actual problem:

John lives alone in an apartment in the city. He is a businessman who has to travel for work for 3-4 days in a week. When not travelling or working, John likes to take care of his plants. However, since he is not home for half the week, John is struggling to keep his garden healthy and beautiful.

John has faced several challenging...

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...

Creating the backend application

With the device firmware setup completed, it's now time to focus on developing the application that will process the device events and send commands so that John's plant will get watered when he's not home.

The code for the application will run on the IBM Cloud Platform (Bluemix). Since this is just an example application, we're going to use environment variables to store parameters (temperature and soil moisture thresholds).

Creating a Cloud Foundry application in the IBM Cloud Platform

  1. To create an application in IBM Cloud, access https://console.bluemix.net, select the Create Resource option, and select Cloud Foundry Apps in the left menu, followed...

Summary

In this chapter, we developed a solution running on a real device that supports Node.js. We also used the low-level mraa library, which interacts with the device GPIO (General Purpose IO), reads analog sensors (temperature and soil moisture sensors) and uses digital pins to switch a relay on and off. This looks very simple but most devices have sensors and actuators, which may change the way in which they are used. However, they essentially follow the same concept.

We created a dashboard in the IBM Watson IoT Platform that is helpful for looking at what real-time data devices are publishing. We also created an application in the IBM Cloud Platform (Bluemix) and attached backing services (the IBM Watson IoT Platform organization) to the application in order to leverage configuration data to connect to the service and deploy the application using the Bluemix command...

Further reading

Most of the resources needed to complete solutions using the IBM Watson IoT Platform can be found in the official documentation at the following link: https://console.bluemix.net/docs/services/IoT/index.html#gettingstartedtemplate. There are also many recipes published by the community that uses IBM Watson IoT, and these are available at the developerWorks Recipes website here: https://developer.ibm.com/recipes/tutorials/category/internet-of-things-iot/.

It's also very helpful to understand how to upload a project to a GitHub repository and how to create a delivery pipeline to automatically build, test, and deploy an application whenever a new change is pushed to the repository. Doing this is not within the scope of this book, but it's still a really good practice to use.

Further information on Grove system platforms, modules, bundles, and component specifications...

Left arrow icon Right arrow icon
Download code icon Download Code

Key benefits

  • Explore practical implementation of ledger technology in the IoT architecture
  • Study security best practices for your smart devices
  • Understand Blockchain implementation for end-to-end IoT solutions

Description

Blockchain has been the hot topic of late thanks to cryptocurrencies. To make matters more interesting, the financial market is looking for ways to reduce operational costs and generate new business models, and this is where blockchain solutions come into the picture. In addition to this, with Internet of Things (IoT) trending and Arduino, Raspberry Pi, and other devices flooding the market, you can now create cheap devices even at home. Hands-On IoT Solutions with Blockchain starts with an overview of IoT concepts in the current business scenario. It then helps you develop your own device on the IBM Watson IoT platform and create your fi rst IoT solution using Watson and Intel Edison.Once you are familiar with IoT, you will learn about Blockchain technology and its use cases. You will also work with the Hyperledger framework and develop your own Blockchain network. As you progress through the chapters, you'll work with problem statements and learn how to design your solution architecture so that you can create your own integrated Blockchain and IoT solution. The next set of chapters will explain how to implement end-to-end Blockchain solutions with IoT using the IBM Cloud platform. By the end of this book, you will have mastered the convergence of IoT and Blockchain technology and exploited the best practices and drivers to develop a bulletproof integrated solution.

Who is this book for?

Hands-On IoT Solutions with Blockchain is for you if you are an Internet of Things (IoT) analyst, architect, engineer, or any stakeholder responsible for security mechanisms on an IoT infrastructure. This book is also for IT professionals who want to start developing solutions using Blockchain and IoT on the IBM Cloud platform. Basic understanding of IoT will assist you in understanding key concepts covered in the book.

What you will learn

  • Understand the key roles of IoT in the current market
  • Study the different aspects of IBM Watson IoT platform
  • Create devices, gateways, and applications connected to the platform
  • Explore the fundamentals of Blockchain
  • Define good use cases for Blockchain
  • Discover the Hyperledger Fabric and Composer frameworks
  • Develop an IBM Watson IoT application using a Intel Edison
  • Integrate IoT with the Blockchain platform
Estimated delivery fee Deliver to Brazil

Standard delivery 10 - 13 business days

R$63.95

Premium delivery 3 - 6 business days

R$203.95
(Includes tracking information)

Product Details

Country selected
Publication date, Length, Edition, Language, ISBN-13
Publication date : Jan 08, 2019
Length: 206 pages
Edition : 1st
Language : English
ISBN-13 : 9781789132243
Vendor :
IBM
Category :
Concepts :
Tools :

What do you get with Print?

Product feature icon Instant access to your digital eBook copy whilst your Print order is Shipped
Product feature icon Paperback book shipped to your preferred address
Product feature icon Download this book in EPUB and PDF formats
Product feature icon Access this title in our online reader with advanced features
Product feature icon DRM FREE - Read whenever, wherever and however you want
Product feature icon AI Assistant (beta) to help accelerate your learning
Estimated delivery fee Deliver to Brazil

Standard delivery 10 - 13 business days

R$63.95

Premium delivery 3 - 6 business days

R$203.95
(Includes tracking information)

Product Details

Publication date : Jan 08, 2019
Length: 206 pages
Edition : 1st
Language : English
ISBN-13 : 9781789132243
Vendor :
IBM
Category :
Concepts :
Tools :

Packt Subscriptions

See our plans and pricing
Modal Close icon
R$50 billed monthly
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Simple pricing, no contract
R$500 billed annually
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just R$25 each
Feature tick icon Exclusive print discounts
R$800 billed in 18 months
Feature tick icon Unlimited access to Packt's library of 7,000+ practical books and videos
Feature tick icon Constantly refreshed with 50+ new titles a month
Feature tick icon Exclusive Early access to books as they're written
Feature tick icon Solve problems while you work with advanced search and reference features
Feature tick icon Offline reading on the mobile app
Feature tick icon Choose a DRM-free eBook or Video every month to keep
Feature tick icon PLUS own as many other DRM-free eBooks or Videos as you like for just R$25 each
Feature tick icon Exclusive print discounts

Frequently bought together


Stars icon
Total R$ 674.97
Hands-On IoT Solutions with Blockchain
R$217.99
Blockchain By Example
R$272.99
Blockchain Quick Start Guide
R$183.99
Total R$ 674.97 Stars icon

Table of Contents

10 Chapters
Understanding IoT and Developing Devices on the IBM Watson IoT Platform Chevron down icon Chevron up icon
Creating Your First IoT Solution Chevron down icon Chevron up icon
Explaining Blockchain Technology and Working with Hyperledger Chevron down icon Chevron up icon
Creating Your Own Blockchain Network Chevron down icon Chevron up icon
Addressing Food Safety - Building around the Blockchain Chevron down icon Chevron up icon
Designing the Solution Architecture Chevron down icon Chevron up icon
Creating Your Blockchain and IoT Solution Chevron down icon Chevron up icon
The IoT, Blockchain, and Industry 4.0 Chevron down icon Chevron up icon
Best Practices for Developing Blockchain and IoT Solutions Chevron down icon Chevron up icon
Other Books You May Enjoy Chevron down icon Chevron up icon
Get free access to Packt library with over 7500+ books and video courses for 7 days!
Start Free Trial

FAQs

What is the delivery time and cost of print book? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela
What is custom duty/charge? Chevron down icon Chevron up icon

Customs duty are charges levied on goods when they cross international borders. It is a tax that is imposed on imported goods. These duties are charged by special authorities and bodies created by local governments and are meant to protect local industries, economies, and businesses.

Do I have to pay customs charges for the print book order? Chevron down icon Chevron up icon

The orders shipped to the countries that are listed under EU27 will not bear custom charges. They are paid by Packt as part of the order.

List of EU27 countries: www.gov.uk/eu-eea:

A custom duty or localized taxes may be applicable on the shipment and would be charged by the recipient country outside of the EU27 which should be paid by the customer and these duties are not included in the shipping charges been charged on the order.

How do I know my custom duty charges? Chevron down icon Chevron up icon

The amount of duty payable varies greatly depending on the imported goods, the country of origin and several other factors like the total invoice amount or dimensions like weight, and other such criteria applicable in your country.

For example:

  • If you live in Mexico, and the declared value of your ordered items is over $ 50, for you to receive a package, you will have to pay additional import tax of 19% which will be $ 9.50 to the courier service.
  • Whereas if you live in Turkey, and the declared value of your ordered items is over € 22, for you to receive a package, you will have to pay additional import tax of 18% which will be € 3.96 to the courier service.
How can I cancel my order? Chevron down icon Chevron up icon

Cancellation Policy for Published Printed Books:

You can cancel any order within 1 hour of placing the order. Simply contact customercare@packt.com with your order details or payment transaction id. If your order has already started the shipment process, we will do our best to stop it. However, if it is already on the way to you then when you receive it, you can contact us at customercare@packt.com using the returns and refund process.

Please understand that Packt Publishing cannot provide refunds or cancel any order except for the cases described in our Return Policy (i.e. Packt Publishing agrees to replace your printed book because it arrives damaged or material defect in book), Packt Publishing will not accept returns.

What is your returns and refunds policy? Chevron down icon Chevron up icon

Return Policy:

We want you to be happy with your purchase from Packtpub.com. We will not hassle you with returning print books to us. If the print book you receive from us is incorrect, damaged, doesn't work or is unacceptably late, please contact Customer Relations Team on customercare@packt.com with the order number and issue details as explained below:

  1. If you ordered (eBook, Video or Print Book) incorrectly or accidentally, please contact Customer Relations Team on customercare@packt.com within one hour of placing the order and we will replace/refund you the item cost.
  2. Sadly, if your eBook or Video file is faulty or a fault occurs during the eBook or Video being made available to you, i.e. during download then you should contact Customer Relations Team within 14 days of purchase on customercare@packt.com who will be able to resolve this issue for you.
  3. You will have a choice of replacement or refund of the problem items.(damaged, defective or incorrect)
  4. Once Customer Care Team confirms that you will be refunded, you should receive the refund within 10 to 12 working days.
  5. If you are only requesting a refund of one book from a multiple order, then we will refund you the appropriate single item.
  6. Where the items were shipped under a free shipping offer, there will be no shipping costs to refund.

On the off chance your printed book arrives damaged, with book material defect, contact our Customer Relation Team on customercare@packt.com within 14 days of receipt of the book with appropriate evidence of damage and we will work with you to secure a replacement copy, if necessary. Please note that each printed book you order from us is individually made by Packt's professional book-printing partner which is on a print-on-demand basis.

What tax is charged? Chevron down icon Chevron up icon

Currently, no tax is charged on the purchase of any print book (subject to change based on the laws and regulations). A localized VAT fee is charged only to our European and UK customers on eBooks, Video and subscriptions that they buy. GST is charged to Indian customers for eBooks and video purchases.

What payment methods can I use? Chevron down icon Chevron up icon

You can pay with the following card types:

  1. Visa Debit
  2. Visa Credit
  3. MasterCard
  4. PayPal
What is the delivery time and cost of print books? Chevron down icon Chevron up icon

Shipping Details

USA:

'

Economy: Delivery to most addresses in the US within 10-15 business days

Premium: Trackable Delivery to most addresses in the US within 3-8 business days

UK:

Economy: Delivery to most addresses in the U.K. within 7-9 business days.
Shipments are not trackable

Premium: Trackable delivery to most addresses in the U.K. within 3-4 business days!
Add one extra business day for deliveries to Northern Ireland and Scottish Highlands and islands

EU:

Premium: Trackable delivery to most EU destinations within 4-9 business days.

Australia:

Economy: Can deliver to P. O. Boxes and private residences.
Trackable service with delivery to addresses in Australia only.
Delivery time ranges from 7-9 business days for VIC and 8-10 business days for Interstate metro
Delivery time is up to 15 business days for remote areas of WA, NT & QLD.

Premium: Delivery to addresses in Australia only
Trackable delivery to most P. O. Boxes and private residences in Australia within 4-5 days based on the distance to a destination following dispatch.

India:

Premium: Delivery to most Indian addresses within 5-6 business days

Rest of the World:

Premium: Countries in the American continent: Trackable delivery to most countries within 4-7 business days

Asia:

Premium: Delivery to most Asian addresses within 5-9 business days

Disclaimer:
All orders received before 5 PM U.K time would start printing from the next business day. So the estimated delivery times start from the next day as well. Orders received after 5 PM U.K time (in our internal systems) on a business day or anytime on the weekend will begin printing the second to next business day. For example, an order placed at 11 AM today will begin printing tomorrow, whereas an order placed at 9 PM tonight will begin printing the day after tomorrow.


Unfortunately, due to several restrictions, we are unable to ship to the following countries:

  1. Afghanistan
  2. American Samoa
  3. Belarus
  4. Brunei Darussalam
  5. Central African Republic
  6. The Democratic Republic of Congo
  7. Eritrea
  8. Guinea-bissau
  9. Iran
  10. Lebanon
  11. Libiya Arab Jamahriya
  12. Somalia
  13. Sudan
  14. Russian Federation
  15. Syrian Arab Republic
  16. Ukraine
  17. Venezuela