Design and implementation of peer-to-peer energy trading system using internet of things and blockchain

Baig, Mirza Jabbar Aziz (2024) Design and implementation of peer-to-peer energy trading system using internet of things and blockchain. Doctoral (PhD) thesis, Memorial University of Newfoundland.

[img] [English] PDF - Accepted Version
Available under License - The author retains copyright ownership and moral rights in this thesis. Neither the thesis nor substantial extracts from it may be printed or otherwise reproduced without the author's permission.

Download (6MB)

Abstract

With advancements in renewable energy technologies, consumers are becoming prosumers, and renewable energy resources are being used in distributed networks. In an isolated distributed system, peer-to-peer (P2P) energy trading is one of the most promising energy management solutions. In this research, we propose a P2P energy trading method for micro-grids using open resources and technology. A DC-micro-grid has been designed for a remote site in Pakistan. This site is in the northern part of Azad Jammu and Kashmir, Pakistan, within the lower area of the Himalayan Mountain range. Several of the modern amenities, including road access, are lacking in this area. For this remote site, an open-source and low-cost P2P energy trading system is designed and implemented. A photovoltaic (PV) system is also designed using HOMER Pro. The microgrid design is composed of PV panels and battery banks, designed after considering the load profile of each house. The proposed P2P energy trading platforms mainly comprise an Internet-of-Things (IoT) server to transfer the energy amongst the peers without human intervention. An Ethereum based private blockchain is suggested for money transfer in the form of cryptocurrency. The IoT server enables the peers to control and monitor self-produced energy, while Ethereum based private blockchain facilitates the financial transactions associated with the energy transfer. The proposed open-source P2P energy trading platform facilitates energy trading amongst the peers and provides real time data acquisition, monitoring, and control of self-generated energy at a remote location. This research involves the use of four different techniques in order to establish a P2P energy trading architecture, as well as a microgrid design with low-cost, low-power components and open-source technology for a remote community. The first technique to set up the P2P energy trading platform involves the following key components, Arduino UNO, ACS 712 hall-effect current sensor and a relay. The current sensor data is sent in real-time to Arduino for onward communication to the IoT server. A user-friendly interface is developed on the server to perform various energy trading tasks. Peers have the choice to access the server remotely to perform energy trading tasks. Energy trading events can be shared amongst peers through e-mail notifications. For financial transactions, we utilized Ganache graphical user interface (GUI), a private Ethereum blockchain that eliminates the need for financial institutions. The proposed P2P energy trading model has been successfully tested for energy trading between two peers. The details of the proposed hardware and software setup explain how low-cost P2P energy trading can be achieved. In the second technique, the trading activities are done on a web interface that uses a private Ethereum blockchain. A smart contract is deployed on the Ethereum blockchain and the trading activities performed on the web interface are recorded on a tamper-proof blockchain network. An IoT platform is used to monitor and control self-generated energy. Energy data is collected and processed by means of ESP32-S2 microcontrollers using field instrumentation devices that are connected to the voltage source and load. An open source decentralized P2P energy trading system, designed on the blockchain and IoT architecture is proposed. The hardware setup includes a relay, a current sensor, a voltage sensor, a Wi-Fi router and ESP32-S2 microcontroller. For data transfer the Message Queuing Telemetry Transport (MQTT) protocol is used over a local network. ESP32-S2 is set up as MQTT client and Node-Red IoT server is used as MQTT broker. Hypertext Transfer Protocol (http) request method is implemented to connect the Node-Red server with the web interface developed using React.JS library. The third method involves a Raspberry Pi 4 Model B (Pi4B), which is used to host the main server of the trading system, including the user interface and the Ethereum blockchain server. The Ethereum blockchain is used to deploy smart contracts and the IoT servers run on ESP32 microcontrollers. Sensors and actuators connected to the ESP32 are field instrumentation devices that facilitate acquiring, monitoring, and transferring energy data in real-time. A blockchain-enabled user interface is developed using the React.JS open-source library, to perform trading activities. As a communication channel, the proposed system uses a Wi-Fi network. For system security, the designed system has restricted authorization. For information security and data integrity, other security measures are also considered, such as login credentials, private keys, firewalls, and secret recovery phrases. To facilitate communication between the server and the client, a Hypertext Transfer Protocol is implemented. As part of the fourth technique, we have implemented a Raspberry Pi 4 Model B (Pi4B) as the main server on which the user interface (UI) and local Ethereum blockchain are hosted. Additionally, the blockchain implements the smart contract. Open-source Angular framework is used to develop the UI that facilitates trading activities. This method of P2P energy trading also explores the development of an Internet of Things (IoT) server using the latest ESP32-S3 microcontroller. Data is acquired by field instrumentation devices (FIDs) and transmitted to an IoT server via the microcontroller. An immutable record of all transactions is maintained by the blockchain network. By configuring the system locally, hosted on a private network with restricted access, security is ensured. Additional security measures are also considered for information security and data integrity, including a secret recovery phrase, firewalls, login credentials, and a private key. A Hypertext Transfer Protocol is implemented amongst the servers and clients. Within the scope of this thesis, we present four different methods of P2P energy trading designed for remote communities that involve renewable energy sources. All design details, simulations results, experimental test results are included in the thesis.

Item Type: Thesis (Doctoral (PhD))
URI: http://research.library.mun.ca/id/eprint/16398
Item ID: 16398
Additional Information: Includes bibliographical references
Department(s): Engineering and Applied Science, Faculty of
Date: March 2024
Date Type: Submission
Library of Congress Subject Heading: Renewable energy sources--Design and construction; Blockchains (Databases); Electric power distribution; Internet of things; Peer-to-peer architecture (Computer networks); Microgrids (Smart power grids); Azad Kashmir (Pakistan)

Actions (login required)

View Item View Item

Downloads

Downloads per month over the past year

View more statistics