0% found this document useful (0 votes)
11 views

Iot Based Building Energy Management System

Uploaded by

Rahma Jensen
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
11 views

Iot Based Building Energy Management System

Uploaded by

Rahma Jensen
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 6

See discussions, stats, and author profiles for this publication at: https://www.researchgate.

net/publication/355892114

IoT Based Building Energy Management System

Conference Paper · September 2021


DOI: 10.1109/EECon52960.2021.9580866

CITATIONS READS

2 449

5 authors, including:

Dinidu Jeewandara K T M U Hemapala


University of Moratuwa University of Moratuwa
10 PUBLICATIONS 6 CITATIONS 142 PUBLICATIONS 636 CITATIONS

SEE PROFILE SEE PROFILE

All content following this page was uploaded by Dinidu Jeewandara on 16 November 2021.

The user has requested enhancement of the downloaded file.


IoT Based Building Energy Management System
D.G. Hettiarachchi G.M.A. Jaward V.P.V. Tharaka
Department of Electrical Engineering Department of Electrical Engineering Department of Electrical Engineering
University of Moratuwa University of Moratuwa University of Moratuwa
Colombo, Sri Lanka Colombo, Sri Lanka Colombo, Sri Lanka
[email protected] [email protected] [email protected]

J.M.D.S.Jeewandara K.T.M.U Hemapala


Department of Electrical Engineering Department of Electrical Engineering
University of Moratuwa University of Moratuwa
Colombo, Sri Lanka Colombo, Sri Lanka
[email protected] [email protected]

Abstract—The ever-growing demand for energy and because of the uncertainty of the supply, load demand
uncertainty of supply lead towards a major crisis in the energy forecasting plays a crucial role. Since the possibility of
sector, especially in building energy management. In case of unmatched supply and demand, prior plans should be there
power outages it is crucial to utilize the scarce power sources for on how the system is managed. So, this load prediction has
the most vulnerable cause of demand. Furthermore, it is evident become a key research area for efficient energy utilization in
that due to the lack of monitoring and automation present in buildings. There exist two major load types identifiable in
building energy management systems, a considerable buildings, namely base type, and controllable type. Several
percentage of energy wastage gets reported. Thus the need for a fixed facilities and servers in the building may be considered
proper load forecasting methodology has arisen in the recent
as the base type. The controllable type may include electric
past. Researchers have formulated statistical methods and
machine learning based models to facilitate energy forecasting
heating appliances and air conditioning systems, where the
for future periods. This paper addresses the load forecasting loads from the controllable type can be scheduled and
challenge by proposing an IoT (Internet of Things) based energy controlled by Building Energy Management System (BEMS)
management system that incorporates an XGBoost (Extreme with a deployed energy management strategy. Also, the
Gradient Boost) machine learning model to forecast energy existing Building Management Systems are highly expensive
consumption. The energy management system consists of a user- and there are issues when using small and medium-size
friendly central dashboard that acts as a mediator between a buildings as well [2].
NodeMCU device and a cloud-hosted database with the
Although an extensive amount of research is carried out
aforementioned machine learning model. The paper concludes
with a summarized discussion on the research.
on investigating power controls in large scale sites, centrally
manageable and highly scalable robust power monitoring
Keywords— Building Energy Management Systems, Machine system implementations with split air conditioner control are
Learning, Internet of Things, XGBoost rarely found. The proposed solution exposes the capability to
scale up/down the power consumptions conveniently from a
I. INTRODUCTION single point of control via the dashboard. Furthermore , the
proposed system differentiates from other solutions due to its
The energy usage of the world has increased rapidly in the compact nature as it consists of smart plug devices, dashboard
past few years and by 2035 the demand is predicted to be configurations, cloud-based interconnectivity, and accurate
increased by more than two thirds [1]. Out of the total load forecasting.
electricity consumption, around 60% is consumed by the
buildings, and because of that, efficient controlling of the Addressing these key issues, this paper focuses on
building energy is very crucial [2]. Buildings use 68% of designing a system capable of remotely monitoring and
energy in operation and contribute to 17% of greenhouse gas controlling the plug loads in a building using IoT technology.
(GHG) emissions [3]. Demand Management and the Building This facilitates the remote control of the devices via
Energy Management systems are being developed to mitigate regulating devices’ power supply in response to demand-
inefficient consumption of energy , especially in smart grids. supply shortages. Also, the paper investigates building load
With the smart grid concept, efficient energy utilization and forecasting using Machine Learning for Demand Side
IoT based smart energy management in buildings has become Management. In a situation where a scheduled power outage
a trending research area by now. With urbanization, the is informed and the total power supply does not meet the
number of buildings increase rapidly, leading to a shortfall of building power demand, even after switching to extra power
demand and energy supply across the globe. Along with this sources such as Diesel Generators, if there exists a load
exponential growth of the demand, due to the increasing forecasting model to analyze demand pattern variations at
number of buildings, a better energy management system for each floor, the limited power supply could be effectively
the buildings is needed. Otherwise, there will be more and managed to facilitate the most vulnerable consumers.
more power curtailments unnecessarily without proper
The rest of the paper is organized as follows. Section II is
control. The other crucial factor is the forecasting of the
focusing on the Technology Overview, where the required
energy supply and demand for future time periods. Especially
technological background is presented; Section III is about
in smart grids, the energy mix is given through various
the Proposed System while in Section IV the conclusions are
sources, and most of them are renewable energy. A constant
presented.
electricity generation may not be possible as the renewable
sources are intermittent in nature, and due to that, the
forecasting of the electricity generation is crucial. Similarly,

978-1-6654-1712-9/21/$31.00 ©2021 IEEE


II. TECHNOLOGY OVERVIEW When a microgrid is disconnected from the grid, not all
loads can be supplied by the micro-grid. In order to improve
A. Building Energy Management Systems (BEMS) the reliability of critical loads, some non-critical
The literature reveals three main approaches followed in (controllable) loads need to be shed. DSM promotes the
BEMS according to [4]. efficient usage of power while focusing on network stability
and reliability [7].
1) Centralized System: Under this approach, the load
demand of every building and household is collected and will D. Load Forecasting
be processed in the central system. Then, a control signal will Electricity load forecast predicts the future value from
be transmitted directly to each electrical unit in the buildings. hours to weeks for energy management. Load forecasting can
If the buildings have a connection to the utility grid, the be divided into short term, medium-term and long-term [8].
central controller becomes the gateway to the utility grid. The Load forecasting models have been developed in literature,
advantages are that it becomes convenient to implement and which can be classified into two major varieties, in particular
maintain in case of single-point failure. Disadvantages are the the linear models and the non-linear models.
computational burden, requirement of a high level of
Linear models are typically based on Time-Series
connectivity, and difficulty to expand. Single point failure is approach, while Non-linear models are based on the Artificial
also a disadvantage. Intelligence based approach.
2) Decentralized System: The decentralized approach
places a local controller in each building instead of having 1) Time Series Approach: A time series is a sequence
only one central controller on the building operator side. Each where a measurement is recorded over regular time intervals.
local controller has the capability to make decisions based on Time series forecasting can be of univariate or multivariate
local measurements and is responsible for balancing the type. In time-series approach for load forecasting, the
electricity demand and supply of the related building. This advantages include, having a minimal cost and requiring less
approach has the additional advantage of securing the privacy historical data. However, the time-series approach .does not
of the occupants. The advantages are parallel computation study deeply underlying patterns and it is difficult to interpret
and lack of need for expensive two-way, fast communication. the errors.
The disadvantages are restricted performance due to the 2) Machine Learning Approach: In a sensor-based
absence of communication links, and it moderates scalability. approach, data from energy building management systems
3) Distributed System: This approach has started to draw are fed into machine learning algorithms in order to obtain
more and more attention due to the rise of renewable energy the complex relationships between energy use and
sources and its considerable ability to extend to a complex influencing variables such as temperature, time of day, and
system more easily than a conventional central control occupancy. Machine learning is an application of Artificial
approach. Intelligence (AI) that provides systems the ability to
automatically learn and improve from experience without
B. Micro Grids being explicitly programmed. Machine Learning algorithms
Micro grid is a low voltage distribution network that use past data as inputs in order to predict new output values.
consists of Distributed Generators (DGs), Distributed Energy Machine learning approaches can handle large numbers of
Storage Systems and controllable loads. They are connected variables and can handle missing and noisy data. However,
to the distribution substations via a Point of Common they need more computational work and are more difficult to
Coupling. Micro grids operate in two modes based on the implement. However, they can provide more insights than the
connectedness with the main grid through the distribution time-series model [9].
transformer.
• Interconnected mode In more recent research, machine learning approaches are
• Island mode favored compared to time series methods because they
provide better results. Among the machine learning
Due to the nature of various DGs, they require advanced techniques, XGBoost is recognized as an efficient
power electronic devices to convert energy smoothly into the implementation of gradient boosting that is effective for
grid. Distributed Energy Sources (DES) can be used to make regression predictive modeling. Gradient boosting belongs to
micro-grids more cost-effective. They can be used to store the family of ensemble machine learning algorithms that can
energy when energy is cheap or in excess. They can also be be used in either classification or regression predictive
used during peak periods to act as energy supplies [5]. modeling. In XGBoost models, the ensembles are built from
Controllable loads are the loads that can adjust their own single decision tree models. The decision trees get
electrical energy usage based on real-time set points. amalgamated one at a time to the tree-ensemble in order to
Controllable loads are connected with the concept called correct the prediction deviations done by previous tree
Demand Side Management. models. This is a type of ensemble machine learning model
referred to as boosting. Models are trained and fit using a
C. Demand Side Management (DSM) differentiable loss function and utilizing the gradient descent
When it comes to the loads, they can be divided into three optimization algorithm and thus introduced in the name of
types [6] “gradient boosting”, as the loss/ error function is minimized
as the model gets fit to the train data.
• Uncontrollable loads
• Controllable loads XGBoost can be used and found effective for the
• Semi-controllable utilization of time series forecasting, and in order to be used
in time series, it requires the time series data to be
transformed into a problem of supervised learning. In this microcontroller and sending the readings via Wi-Fi to display
setting, an initial model M0 is defined to predict the target it on the dashboard.
variable y. This initial model gets associated with a residual 2) Air Conditioner Controller: An air-conditioner
(y-M0). Next, a new model M1 gets fitted considering the controller is designed which can set and read the temperature
residuals from the previous model. By utilizing both the values and control the selected air-conditioner unit remotely.
models M0 and M1, a boosted prediction M2 is yielded such The split type of air conditioning units is focused on this
that the Mean Squared Error (MSE) from M2 is lower than scope. This module consists of a NodeMCU ESP8266
the corresponding error from M0. This process repeats by microcontroller, DHT 22 Sensor, Infrared (IR) transmitter,
adding new models for m iterations until the residuals of the
and a receiver which is used to communicate with the air-
previous model are minimized and reports improved
conditioner unit. It will be mounted on the air-conditioner
performance. One such iteration is illustrated in Eq.1,
unit so that it will easily transmit the signals.
Mi+1(x) <- Mi(x) +Mi-1(x) (1) The operator is allowed to give the command to the
selected air-conditioner unit and change the temperature
where Mi(x) denotes the ith model, x is the input feature
value remotely and the power usage of that specific air-
vector and the operation <- denotes assignment.
conditioner unit will also be adjusted. In [10] it is elaborated
III. PROPOSED METHODOLOGY AND DISCUSSION that increasing the air-conditioner temperature to 26 degrees
from 22 degrees, would reduce the energy usage by 50% for
This section briefly discusses the Hardware Designs, a period of 24 hours. For each temperature value, there is an
Load Forecasting Technique, and the Designing of the identical code and that code should be transmitted by the IR
Dashboard for the system. In Fig. 1 the overall system design transmitter of the module to the IR receiver of the air-
is illustrated. conditioner unit; once the code is received as an IR signal, the
A. Hardware Designs air-conditioner unit identifies the temperature value and it
changes the temperature accordingly. These codes are not the
The hardware design of the system is mainly categorized same for different brands of air-conditioner units, but in most
as the Smart Plug-In Device and the Air-Conditioner
cases, they will be the same for similar brands.
Controller. The Smart Plug-In device, as mentioned in
Section III, allows the user to monitor the real-time Root B. Load Forecasting Technique
Mean Square (RMS) value of the current flowing together The proposed load forecasting model is constructed in
with the active power it consumes. And it allows the user to terms of an XGBoost model applied for a time series
remotely switch the devices On/Off through the dashboard. prediction model. The proposed load forecasting model
The air conditioner controller sends the measured forecasts the electricity load/ power consumption. The data
temperature of the air flow and it allows the user to set the collection intends to record electricity load readings from the
temperature values through the dashboard. plug-in devices every one-minute time lag, thus producing
1) Smart Plug-In Device: In a commercial or a residential 1440 readings for the 1440 time-lags on a single day.
building, the types of loads can be categorized as Lighting Although the time lag is a configurable parameter, it is set to
Loads and Plug-In Loads. Since the percentage of building a minute, with the purpose of collecting a sufficient and
lighting loads is less than 40% [2] of total consumption, the necessary amount of data samples while reducing the number
of computations required to process the samples. The overall
research has mainly focused on controlling the other plugged
workflow of the proposed model is illustrated in Fig. 2.
loads within a building premise. A Smart Plug-In Device is
designed in the form of a smart energy meter, which is able Every one-minute, the electricity load data readings from
to monitor the current and the active power readings and the plug-in device, weather data i.e., temperature, humidity
allows the system operator to control the On/Off status of the readings, together with the relevant timestamp are sent as a
load. The ACS712 20A Current Sensor Module and the single post request to the forecasting model in the cloud, via
ZMPT101B sensor are used to get the real-time voltage and the dashboard. Weather data is retrieved based on the
current readings and calculate the real-time active power geographic locations input to the API (Application
usage of the plugged load using a NodeMCU ESP8266 Programing Interface) in OpenWeatherMap [11]. Prior to
sending the data request, data is preprocessed inside the
dashboard and the data array is formatted in order to be input
to the model.
The data preprocessing gets completed fast as it does not
require any data normalization step. As XGBoost model is a
tree-based learner and decision trees are not sensitive to
feature scaling, for XGBoost models also, normalization of
data is not required.
Next, the preprocessed data arrays are input to the
forecasting model residing on the cloud which undergoes
training, testing and validation phases to minimize the error
of model forecasts. Once trained to a satisfactory level with a
generalized forecasting ability and a reduced error, the model
is used to generate forecasts for future input data arrays.

Fig. 1. Overall System Design


Fig. 2. Machine Learning Model Pipeline Fig. 3. The flow diagram of the interactions within the system

C. Cloud and Dashboard A major functionality of the dashboard is providing


energy predictions for a period of time when the user inputs
The load forecasting model is kept up and running in an a particular floor and a room. The dashboard and the backend
EC2 instance in Amazon Web Services (AWS) cloud Express server acts as a mediator between the end-user and
obtained under a free tier. Upon receiving a request consisting the load forecasting model that resides in the cloud. Upon the
of the start-timestamp, end-timestamp, floor id, and the room request of the user, the dashboard sends a request to the
id as data from the dashboard, the load forecasting model forecasting model, fetches the response, and displays the
predicts the load values, and the response is sent back to the time-series forecast in terms of several graphs and a Comma-
dashboard. In addition to the prediction task, the load Separated Value (CSV) file. The graphs on the user-interface
forecasting model is expected to be trained from time to time represent predictions for the power consumption, current
(i.e., once a month) from new forecast data, which is stored utilization, temperature distribution and occupancy
in a MongoDB database setup on AWS. Mongodb is used as predictions given by the forecasting model.
the data storage on the cloud to persist energy consumption The load forecasting model is kept up and running in an
data and sensor data as it is highly scalable, secure, and EC2 instance in AWS cloud obtained under a free tier. Upon
unstructured. The sensors of the NodeMCU and the plug-in receiving a request consisting of the start-timestamp, end-
devices transmit data to the MongoDB data storage timestamp, floor id, and the room id as data from the
periodically. dashboard, the load forecasting model predicts the load
values and the response is sent back to the dashboard. In
The flow diagram of the interactions between end-user, addition to the prediction task, the load forecasting model is
NodeMCU, Smart Plug-In device, and the home appliances expected to be trained time to time (i.e., once a month) from
is illustrated in Fig. 3 in depth. new forecast data, which is stored in a MongoDB database
The dashboard is the central component that connects the setup on AWS. Mongodb is used as the data storage on the
end-user with the load forecasting model. The user-interface cloud to persist energy consumption data and sensor data as
is designed using the JavaScript/ React framework and the it is highly scalable, secure, and unstructured. The sensors of
backend data is managed through the Express web the NodeMCU and the plug-in devices transmit data to the
application framework. There exist three major MongoDB data storage periodically.
functionalities supported by the dashboard user-interface as
Although the system can be implemented using the
listed below.
Ethernet communication protocol at the lowest layer of the
• Customize building configuration networking architecture, the proposed methodology is
• View/Adjust status (On/Off) of devices focused on building a wireless network using Wi-Fi protocol
• Predict energy use. which is more flexible and scalable. As an Application layer
communication protocol Message Queuing Telemetry
The user-friendly interface allows the end-user to Transport (MQTT) is highly recognized mostly due to its
manually customize the building configuration via adding lightweight nature and power saving capability. However in
new floors, rooms and ultimately devices of which the this proposed methodology, Hypertext Transfer Protocol
metered energy data (current and power consumption) gets (HTTP) protocol is selected in the communication between
transferred to the dashboard through plug-in devices. terminal devices, dashboard, and the cloud, because of its
In addition, the end-user is facilitated to view any scalability and convenience to integrate with the developed
floor/room with detailed energy consumption statistics. At Representational State Transfer Application Programming
the same time, if required, the user can switch on/off each Interface (REST API) in the dashboard.
device through a simple toggle operation, and in real-time, The overall system consisting of the hardware and
the respective device status turns on/off accordingly. This software components can be illustrated better with a real-
provides the opportunity of remote controlling the status of world example and this case study is illustrated in Fig. 4 using
devices and mitigating energy wastage as much as possible. flowcharts. There are occasions where a building loses the
ACKNOWLEDGMENT
The authors gratefully acknowledge the support provided
by the Senate Research Council, University of Moratuwa
(SRC/LT/2018/15).
REFERENCES
[1] V. T. Nguyen, T. Luan Vu, N. T. Le and Y. Min Jang, "An Overview
of Internet of Energy (IoE) Based Building Energy Management
System," 2018 International Conference on Information and
Communication Technology Convergence (ICTC), Jeju, 2018, pp.
852-855, doi: 10.1109/ICTC.2018.8539513.
[2] W. Tushar et al., "Internet of Things for Green Building Management:
Disruptive Innovations Through Low-Cost Sensor Technology and
Artificial Intelligence," in IEEE Signal Processing Magazine, vol. 35,
no. 5, pp. 100-110, Sept. 2018, doi: 10.1109/MSP.2018.2842096.
[3] A. Parise, M. A. Manso-Callejo, H. Cao, M. Mendonca, H. Kohli and
M. Wachowicz, "Indoor Occupancy Prediction using an IoT Platform,"
2019 Sixth International Conference on Internet of Things: Systems,
Management and Security (IOTSMS), Granada, Spain, 2019, pp. 26-31,
Fig. 4. Flow chart for the case study doi: 10.1109/IOTSMS48152.2019.8939234.
[4] G. D. Nugraha, A. Musa, J. Cho, K. Park, and D. Choi, “Lambda-based
grid power and powering up using a backup generator but data processing architecture for two-level load forecasting in
residential buildings,” Energies, 2018, doi: 10.3390/en11040772.
could not fulfill the total demand at the exact moment. Since
there is a supply demand imbalance, the system will not work [5] W. Su and J. Wang, “Energy Management Systems in Microgrid
Operations,” Electr. J., 2012, doi: 10.1016/j.tej.2012.09.010.
smoothly and have to go for a DSM strategy, where you have
[6] O. V. G. Swathika and K. T. M. U. Hemapala, “IOT Based Energy
to power off some of the appliances which are not critical. Management System for Standalone PV Systems,” J. Electr. Eng.
With the proposed system, the non-critical loads are Technol., 2019, doi: 10.1007/s42835-019-00193-y.
connected through the smart plug-in device where you are [7] K. T. M. U. Hemapala and A. L. Kulasekera, “Demand side
allowing the operator to fully control the particular appliances mangement for microgrids through smart meters,” 2012, doi:
remotely. Likewise, since the operator has the authority to 10.2316/P.2012.768-060.
control the appliances directly, the smooth operation can be [8] “Comparison of Conventional and Modern Load Forecasting
maintained as he will power off some of the appliances and Techniques Based on Artificial Intelligence and Expert Systems,” Int.
J. Comput. Sci. Issues, 2011.
balance the supply and the demand of the system.
[9] “Various Electricity Load Forecasting Techniques with Pros and
The power of the proposed methodology is tied with the Cons,” Int. J. Recent Technol. Eng., 2020, doi:
automatic control mode in the system. In case the manual 10.35940/ijrte.f6997.038620.
decision making becomes cumbersome or less applicable to [10] M. A. K. S. Boralessa, V. Saravanan and K. T. M. U Hemapala,
"Demand Pattern of Decentralized Fixed Speed Compressor Air-
a selected setting, the automatic mode can be enabled. One Conditioning Systems and Demand Response Potential," 2019 2nd
crucial element in the automatic mode is the ability to mark International Conference on Power and Embedded Drive Control
resources with critical or non-critical tags at the initial setup (ICPEDC), 2019, pp. 541-545, doi:
of the system and thus the system can prioritize the critical 10.1109/ICPEDC47771.2019.9036628.
resources first in facilitating demands. Once automated, the [11] "Weather API - OpenWeatherMap", Openweathermap.org, 2021.
system prioritizes the most vulnerable demands and serves [Online]. Available: https://openweathermap.org/api.
energy as per the criticality of the resources as well as the
predicted statistics. The method to prioritize among various
demands is based on a simple set of logics. For instance, at a
power outage, the system detects resources tagged as critical
and facilitates energy first, via some additional power
sources. If the power source has capacity to supply energy
furthermore, the remaining energy demands are prioritized
based on the highest servable load forecasts and occupancy
predictions.
IV. CONCLUSION
This paper proposes a methodology which can be
implemented for a building energy management system using
machine learning and IoT. Hardware has been developed to
control air-conditioner as well as to remotely monitor and
control the plug loads. Machine learning is used to forecast
future loads. Details related to occupancy are also displayed
to the building manager to take decisions on controlling the
load. The data collection records electricity load readings
from the plug-in devices every one-minute, weather data,
together with the relevant timestamp are sent for the
forecasting process. XGBoost is favored over other machine
learning models based on forecasting accuracy.

View publication stats

You might also like