Intelligent Micro Grid Controller Development for Hardware-in-the-loop Micro Grid Simulation Subject to Cyber-Attacks


  • Mike Mekkanen
  • Tero Vartiainen
  • Kimmo Kauhaniemi
  • Duong Dang



microgrid controller, co-simulation, EC61850, next-generation power system, real time simulator, cyber attack, HIL, IED


This paper develops Hardware-in-the-loop (HIL) simulation against cyber attacks. We design a light-weight intelligent electronic device (IED) that performs Micro Grid Controller (MGC), interfaces are developed based on International Electrotechnical Commission (IEC) 61850 GOOSE protocol from/to the real-time simulation and the MGC. They are executed on two equipment stages, Field Programmable Gate Array (FPGA) and BeagleBoneBlack. CSIL versus CHIL tests are used to evaluate the Micro Grid (MG) behavior against different cyber attacks. We also evaluate the MGC designed control function in accordance with IEC 61850 GOOSE protocol. The results show that the light-weight MGC approach and data modeling of various IEC 61850 predefined data objects, data attributes and logical nodes (LNs) are correct for the design of the power balance control/protection function against cyber attacks in various cyber-attack case studies.


John Baillieul, Michael C. Caramanis, and Marija D. Ilik. Control Challenges in Microgrids and the Role of Energy-Efficient Buildings. Proceedings of the IEEE 104(4):692–96, 2016. doi: 10.1109/JPROC.2016.2532241.

Colet-Subirachs, Alba, Albert Ruiz-Alvarez, Oriol Gomis-Bellmunt, Felipe Alvarez-Cuevas-Figuerola, and Antoni Sudria-Andreu. Centralized and Distributed Active and Reactive Power Control of a Utility Connected Microgrid Using IEC61850. IEEE Systems Journal 6(1):58–67, 2012.

doi: 10.1109/JSYST.2011.2162924.

Duong Dang, and Tero Vartiainen. Changing Patterns in the Process of Digital Transformation Initiative in Established Firms: The Case of an Energy Sector Company. PACIS 2020 Proceedings, 2020.

Duong Dang, Tero Vartiainen, and Mike Mekkanen. Towards Establishing Principles for Designing Cybersecurity Simulations of Cyber-Physical Artefacts in Real-Time Simulation. Proceedings of the International Conference on Information Systems Development (ISD), 2021.

Eurostats. Wind and Water Provide Most Renewable Electricity. Retrieved May 10, 2021 (, 2020.

Yunwei Li, D. M. Vilathgamuwa, and Poh Chiang Loh. Design, Analysis, and Real-Time Testing of a Controller for Multibus Microgrid System. IEEE Transactions on Power Electronics 19(5):1195–1204, 2004. doi: 10.1109/TPEL.2004.833456.

libiec61850. Libiec61850.

Guodong Liu, Michael R. Starke, and Andrew N. Herron. Microgrid Controller and Advanced Distribution

Management System Survey Report. ORNL/TM-2016/288. Oak Ridge National Lab. (ORNL), Oak Ridge, TN (United States), 2016. doi: 10.2172/1287035.

K. S. Rajesh, S. S. Dash, Ragam Rajagopal, and R. Sridhar. A Review on Control of Ac Microgrid. Renewable and Sustainable Energy Reviews 71:814–19, 2017. doi: 10.1016/j.rser.2016.12.106.

Jim Reilly, Allen Hefner, Brian Marchionini, and Geza Joos. Microgrid Controller Standardization: Approach, Benefits and Implementation. Cleveland, OH, 2017.

Jim Reilly, and Geza Joos. Microgrid Controller Standards for Integration and Interoperability. AIM, 2018.

Albert Ruiz-Alvarez, Alba Colet-Subirachs, Felipe Alvarez-Cuevas Figuerola, Oriol Gomis-Bellmunt, and Antoni

Sudria-Andreu. Operation of a Utility Connected Microgrid Using an IEC 61850-Based Multi-Level Management System. IEEE Transactions on Smart Grid 3(2):858–65, 2012. doi: 10.1109/TSG.2012.2187222.

Sachidananda Sen, and Vishal Kumar. Microgrid Control: A Comprehensive Survey. Annual Reviews in Control

:118–51, 2018. doi: 10.1016/j.arcontrol.2018.04.012.

Katja H. Sirviö, Mike Mekkanen, Kimmo Kauhaniemi, Hannu Laaksonen, Ari Salo, Felipe Castro, and Davood

Babazadeh. Accelerated Real-Time Simulations for Testing a Reactive Power Flow Controller in Long-Term Case Studies. Journal of Electrical and Computer Engineering 2020: e8265373, 2020. doi: 10.1155/2020/8265373.

Taha Selim Ustun, Cagil Ozansoy, and Aladin Zayegh. Modeling of a Centralized Microgrid Protection System and Distributed Energy Resources According to IEC 61850-7-420. IEEE Transactions on Power Systems 27(3):1560–67, 2012. doi: 10.1109/TPWRS.2012.2185072.

Lixi Zhang, Shijia Li, Lloyd Wihl, Mehrdad Kazemtabrizi, Syed Qaseem Ali, Jean-Nicolas Paquin, and Simon Labbé. Cybersecurity Study of Power System Utilizing Advanced CPS Simulation Tools. White Paper, OPAL 13, 2019.

Davy Zhuang. Real Time Testing of Intelligent Relays for Synchronous Distributed Generation Islanding Detection. McGill University, Montréal, Québec, Canada, 2012.

Muhammad Fahad Zia, Elhoussin Elbouchikhi, and Mohamed Benbouzid. Microgrids Energy Management Systems: A Critical Review on Methods, Solutions, and Prospects. Applied Energy 222:1033–55, 2018. doi: