Is your home energy efficient? Bluemix can figure it out.

Share this post:

pubnublogo2014_hero-e1470329965179 There are quite a few things we take for granted in our day-to-day lives. Public utilities are one such example. We assume that the electricity and water supply will be at our disposal 24/7. This leads to wastage, and excessive wastage and malpractice lead to further deterioration of the environment.

Thanks to the awareness around climate change and the advancements in renewable energy sources, we are in a better position to safeguard our future generations by ensuring a sustainable supply of energy for our day-to-day needs. Still, a lot needs to be done toward achieving self-sustained living and this is where technology can help us.

Below, I present yet another amalgamation of things that can be managed using that game-changer, the “Internet of Things.” In this case, it’s a project for tracking public utilities using IoT, specifically the electricity supply system.


Smart energy grids are already in place, and we see a boom in this space with innovative business models like energy credits which can immensely benefit the consumers. But for a homeowner, this comes with the added complexity of having to install more components. For starters, there needs to be a renewable source of energy—either a solar panel or a wind turbine—along with an energy storage system. We also need a net metering system, which is a special kind of electricity meter that tracks both the energy consumption as well as the generation from a household, and rolls back the meter in case of excess generation given back to the grid.

A lot of data gets generated by these systems, and this is where IoT can help in harnessing it for our best interests. If we accumulate this per household data and combine with a smart grid, then there is potential to offer insights at the town or city level, which can help in framing benevolent policies for energy security.



Project Overview

For this project, we have tried to replicate the electricity distribution of a household by using a solar panel, a few appliances, and a battery, which acts as the electricity supply from the grid. A web-based dashboard tracks the whole system via IBM Bluemix hosted portal.

Below is a block diagram for this replicated setup for a single household.



There are two loads, “LOAD 1” and “LOAD 2,” representing a light point and a fan point in the house. Also, there are three sensors, labeled as “CURRENT SENSOR 1,” “CURRENT SENSOR 2” and “CURRENT SENSOR 3.” These are current sensors used for sensing the magnitude of current through the various paths of household electricity distribution.

  • CURRENT SENSOR 1 measures the excess energy given back from the solar panel to the grid in case of underutilization.
  • CURRENT SENSOR 2 measures the total energy consumed from the solar panels
  • CURRENT SENSOR 3 measures the total energy consumed from the grid.

The data captured in these sensors is in the form of Amperes, which is the unit for measuring electric current passing through the wire. The sensor readings are accumulated in a controller (Arduino YUN) and sent to the Bluemix cloud where they can be analyzed via a dashboard.

Note: For the sake of simplicity, this setup is based on the Direct Current (DC) system, as opposed to the Alternating Current (AC) system deployed all over the world for commercial electricity distribution.

Measurement Parameters

Using the current sensors, we can sense a few meaningful parameters such as

  • Power Consumption/Generation: Amount of current consumed by the household and generated by the renewable sources in the household. This is also known as the Watts (or Wattage).
  • Energy Consumption/Generation: Amount of energy consumed or generated by the household. This is a function of power consumption over a period of time. The standard unit of measuring this is KiloWatt/Hour (kWh). By measuring the kWh of consumption vis-a-vis generation, we can find how energy efficient the household truly is.

Data Push and Cloud Storage

All the sensors are connected to Arduino YUN controller, which also acts as an energy monitor. It takes a sample of the sensor readings at periodic intervals and then pushes them to the cloud. To do this reliably, we have used PubNub. PubNub provides a data streaming service for sending data across the internet in real-time, with the utmost reliability and security.

Data storage on the cloud is facilitated by the IBM DashDB data warehousing technology.


Both PubNub and DashDB are available as services within the IBM Bluemix catalog of services.

What’s next

In part two of this post, we will show you how to build this prototype system with the help of a few inexpensive components to deploy it on the Bluemix cloud, and most importantly, what insights can we derive from the captured data.

See you soon!

More How-tos stories
May 3, 2019

Kubernetes Tutorials: 5 Ways to Get You Building Fast

Ready to start working with Kubernetes? Want to build your Kubernetes skills? The five tutorials in this post will teach you everything you need to know about how to manage your containerized apps with Kubernetes.

Continue reading

May 3, 2019

Using Portworx to Deploy and Manage an HA MySQL Cluster on IBM Cloud Kubernetes Service

This tutorial is a walkthrough of the steps involved in deploying and managing a highly available MySQL cluster on IBM Cloud Kubernetes Service.

Continue reading

May 2, 2019

Kubernetes v1.14.1 Now Available in IBM Cloud Kubernetes Service

We are excited to announce the availability of Kubernetes v1.14.1 for your clusters that are running in IBM Cloud Kubernetes Service. IBM Cloud Kubernetes Service continues to be the first public managed Kubernetes service to support the latest upstream versions from the community.

Continue reading