| Abstract: |
This work presents the design and implementation of a two-layer Artificial Neural Network (ANN) framework for intelligent control of a real, operational residential microgrid at Bucknell University. Unlike many existing studies that rely on simulation-based environments, this work is grounded in a fully restored cyber-physical system, where sensing, data acquisition, and control are performed on low-cost embedded hardware using real-time operational data. The proposed architecture follows a structured Predict → Decide → Protect philosophy. The first layer performs next-hour prediction of electricity prices in the PJM Interconnection, a regional transmission organization that coordinates wholesale electricity markets and grid operations across multiple states in the United States, using historical Day-Ahead and Real-Time Locational Marginal Price (LMP) data. This prediction addresses a fundamental constraint of electricity markets, where Real-Time prices are only available after operation, requiring decisions to be made under uncertainty. The second layer translates these predicted price signals into actionable control decisions within the microgrid. Real-time electrical measurements, including voltage, frequency, current, and power, are continuously collected through an AcuRev smart meter and logged via a Raspberry Pi-based controller at five-minute intervals. These measurements, combined with predicted price signals and environmental data, serve as inputs to the intelligent controller, which determines operating modes such as normal operation, load management, pre-heating or pre-cooling, and islanded operation. A key contribution of this work is the integration of artificial intelligence with real-world system constraints. While the ANN-based controller demonstrates measurable improvements in economic performance compared to traditional rule-based strategies, experimental observations reveal that unconstrained optimization can introduce violations in voltage stability. This finding highlights a critical limitation of purely data-driven control in power systems. To address this, the framework incorporates a hybrid control philosophy in which AI-driven decision-making is augmented with rule-based safety constraints that enforce voltage and frequency limits. This ensures that economic optimization does not compromise system reliability. This work is supported by an operational microgrid platform and prior validated results in the price prediction stage. The results demonstrate that effective AI-based microgrid control is not solely a modeling problem but a cyber-physical systems challenge requiring coordinated sensing, communication, and control. |