Researchers from Canada’s Western University have developed an open-source, blockchain-based virtual utility for peer-to-peer (P2P) solar trading, using smart contracts to save up to $1,600 (US dollars) for 10 homes in simulated scenarios.
Scientists from Canada’s Western University have designed a novel open-source autonomous virtual utility to monitor PV users and enable P2P trading. Their SolarXchange blockchain technology-based system creates smart contracts by itself, facilitating transactions between users on an hourly basis. “We are really interested in working with forward-focused electric utilities that want to enable widespread distributed solar generation and P2P exchanges to make a truly resilient electric grid,” corresponding author Dr. Joshua M. Pearce told pv magazine.
“For utilities that choose to embrace distributed generation there are various business models. One tantalizing approach is to enable P2P trading of solar electricity,” the academics said. “The primary issue is that billing systems have been set up for centralized power production, a new method of billing/ trading is needed that is made for distributed generation. One approach is to use blockchain technology because it allows secure transactions.”
The novel virtual utility is based on two levels of contracts, written using Solidity, one of the popular smart contract languages. In the blockchain context, smart contracts are codes that automatically carry out tasks when certain conditions are met. On the first level, each participating house has a House contract, describing the general state of the user’s PV generation and demand. On the second level, the virtual utility runs the HouseFactory contract, which absorbs information from the first-level contracts, keeping track of the individual homes’ demand and production and deciding when electricity should be exchanged.
“Unit tests for each of the contracts’ methods are written in Solidity, and data on gas usage and costs is collected. It should be noted that the ‘gas’ in the context P2P networks refers to the unit of measurement for transaction fees and computational costs not natural gas,” the group said. “The total cost of deploying the contracts were calculated by migrating the contracts onto the local Truffle blockchain and retrieving the gas usage and cost information from the terminal output.”