top of page

Grid Connected and Standalone Mode Operation of PV with Battery System

5 days ago
7 min read

Grid Connected and Standalone Mode Operation of PV with Battery System


𝐈𝐧𝐭𝐫𝐨𝐝𝐮𝐜𝐭𝐢𝐨𝐧

A PV–battery energy system must supply electrical loads reliably even when solar irradiance changes or the utility grid becomes unavailable. This MATLAB/Simulink model demonstrates how a solar PV system with battery storage operates in both grid-connected and standalone (islanded) modes.


Grid Connected and Standalone Mode Operation of PV with Battery System


Grid Connected and Standalone Mode Operation of PV with Battery System


Grid Connected and standalone mode operation of PV with battery system
₹10,000.00₹5,000.00
Buy Now


A single simulation model is used to study:

  • Solar PV power generation

  • Maximum power extraction

  • Battery charging and discharging

  • DC-bus voltage regulation

  • AC and DC load operation

  • Bidirectional grid power flow

  • Grid-connected-to-standalone transition

  • Standalone-to-grid-connected transition

The system automatically selects the required inverter control strategy according to the grid operating condition.

𝐒𝐲𝐬𝐭𝐞𝐦 𝐎𝐯𝐞𝐫𝐯𝐢𝐞𝐰

The proposed configuration combines a solar PV array, boost converter, battery storage, bidirectional converter, DC bus, single-phase inverter, LCL filter, utility grid, and electrical loads.

System component

Purpose

Solar PV array

Generates electrical power from solar irradiance

Boost converter

Increases and regulates the PV output voltage

Incremental Conductance MPPT

Extracts maximum available power from the PV array

Battery energy storage

Stores surplus energy and supports the loads

Bidirectional DC–DC converter

Controls battery charging and discharging

Common DC bus

Connects the PV, battery, DC load, and inverter

DC load

Receives power directly from the DC bus

Single-phase inverter

Transfers power between the DC and AC sides

LCL filter

Reduces inverter switching harmonics

AC load

Receives regulated AC voltage and power

Utility grid

Supplies or absorbs power during grid-connected operation

Circuit breaker

Connects or disconnects the system from the grid

𝐒𝐲𝐬𝐭𝐞𝐦 𝐎𝐩𝐞𝐫𝐚𝐭𝐢𝐧𝐠 𝐏𝐚𝐫𝐚𝐦𝐞𝐭𝐞𝐫𝐬

The main operating values and conditions described in the simulation are summarized below.

Parameter

Value or condition

DC-bus reference voltage

400 V

Grid mode command

1

Standalone mode command

0

Example mode-transition time

0.8 s

Irradiance change interval

Every 0.3 s

PV irradiance test levels

1500, 200, 500, and 1000 W/m²

Loads supplied

AC load and DC load

MPPT method

Incremental Conductance

Battery converter controller

PI voltage controller

Inverter configuration

Single-phase full-bridge inverter

Output filter

LCL filter

𝐖𝐨𝐫𝐤𝐢𝐧𝐠 𝐏𝐫𝐨𝐜𝐞𝐬𝐬

1. Solar PV power generation

The PV array generates voltage and current according to the applied solar irradiance.

  • PV voltage and current are measured continuously.

  • The available PV power changes with irradiance.

  • An MPPT controller determines the suitable operating point.

  • The boost converter transfers the extracted PV power to the DC bus.

2. DC-bus regulation

The common DC bus connects all major subsystems.

  • The reference DC-bus voltage is maintained at 400 V.

  • The battery converter compensates for variations in PV generation and load demand.

  • The DC load receives power directly from the bus.

  • The inverter transfers the remaining power to the AC side.

3. Battery operation

The battery supports power balancing under changing operating conditions.

  • It charges when surplus power is available.

  • It discharges when PV generation is insufficient.

  • Its voltage, current, and state of charge are monitored.

  • Positive and negative battery-current directions indicate different charging and discharging states.

4. Inverter operation

The single-phase inverter has two separate control strategies:

  • Grid-connected current control

  • Standalone voltage control

The appropriate control output is selected using the operating-mode command.

𝐆𝐫𝐢𝐝-𝐂𝐨𝐧𝐧𝐞𝐜𝐭𝐞𝐝 𝐌𝐨𝐝𝐞

When the mode command is set to 1, the circuit breaker closes and connects the PV–battery system to the utility grid.

Power flow during grid-connected operation

  • The PV array supplies available solar power.

  • The battery charges or discharges according to the power balance.

  • The AC and DC loads receive continuous power.

  • Surplus PV power can be supplied to the utility grid.

  • Grid power can support the loads when PV and battery power are insufficient.

The power-flow direction can be determined using:

  • PV power

  • Load demand

  • Battery state of charge

  • Battery current

  • Grid voltage and current

Grid-connected inverter control

The inverter operates mainly as a current-controlled converter in this mode.

Its control system includes:

  • Grid-voltage measurement

  • Orthogonal signal generation

  • Reference-current generation

  • Direct- and quadrature-axis current processing

  • PI current controllers

  • Reference-frame transformation

  • PWM signal generation

This strategy enables controlled power transfer between the DC system and the utility grid.

𝐒𝐭𝐚𝐧𝐝𝐚𝐥𝐨𝐧𝐞 𝐨𝐫 𝐈𝐬𝐥𝐚𝐧𝐝𝐞𝐝 𝐌𝐨𝐝𝐞

When the mode command is set to 0, the circuit breaker opens and disconnects the system from the grid.

Power flow during standalone operation

  • Grid voltage, current, and power become zero.

  • The PV array and battery supply the complete load demand.

  • The DC load continues receiving power from the DC bus.

  • The inverter maintains the voltage required by the AC load.

  • The battery compensates for differences between PV generation and load demand.

Standalone inverter control

During standalone operation, the inverter becomes a voltage-controlled source.

The controller performs the following tasks:

  • Measures inverter or load voltage

  • Generates orthogonal voltage components

  • Processes voltage quantities in a rotating reference frame

  • Compares measured voltage with its reference

  • Uses PI controllers to regulate the voltage

  • Generates the inverter modulation signal

  • Maintains stable AC-load voltage

This control strategy allows the system to operate independently when grid power is unavailable.

𝐌𝐨𝐝𝐞 𝐒𝐞𝐥𝐞𝐜𝐭𝐢𝐨𝐧 𝐋𝐨𝐠𝐢𝐜

A common command controls both the grid source and circuit breaker.

Command value

Circuit-breaker state

Grid condition

Inverter control

0

Open

Grid disconnected

Standalone voltage control

1

Closed

Grid connected

Grid-connected current control

The switching logic selects the correct inverter modulation signal according to the grid condition.

𝐎𝐩𝐞𝐫𝐚𝐭𝐢𝐧𝐠 𝐌𝐨𝐝𝐞 𝐂𝐨𝐦𝐩𝐚𝐫𝐢𝐬𝐨𝐧

Feature

Grid-connected mode

Standalone mode

Grid availability

Available

Unavailable or disconnected

Circuit breaker

Closed

Open

Grid power

Imported or exported

Zero

Inverter function

Controls current and power exchange

Maintains AC-load voltage

AC-load supply

PV, battery, and grid

PV and battery

DC-load supply

PV, battery, and grid support

PV and battery

Surplus PV power

Battery charging or grid export

Primarily battery charging

Power deficit

Grid or battery support

Battery support

Primary control objective

Controlled grid power exchange

Stable load voltage

𝐂𝐨𝐧𝐭𝐫𝐨𝐥 𝐒𝐭𝐫𝐚𝐭𝐞𝐠𝐲

Incremental Conductance MPPT

The Incremental Conductance algorithm controls the PV boost converter.

Its main functions are to:

  • Track the maximum-power point

  • Respond to irradiance variations

  • Determine the converter control reference

  • Improve PV energy utilization

  • Reduce power loss during changing weather conditions

Bidirectional converter control

A PI-based voltage controller regulates the battery converter.

The controller:

  • Compares the measured DC-bus voltage with the 400 V reference

  • Determines the required battery power contribution

  • Controls charging and discharging

  • Supports DC-bus stability

  • Balances renewable generation and load demand

Dual-mode inverter control

The inverter control system includes two control paths.

Control path

Activated condition

Main objective

Grid-connected controller

Grid available

Control inverter current and grid power

Standalone controller

Grid unavailable

Regulate AC-load voltage

Mode selector

Based on grid command

Select the correct modulation signal

PWM generator

Both operating modes

Produce inverter switching pulses

𝐌𝐞𝐚𝐬𝐮𝐫𝐞𝐝 𝐒𝐲𝐬𝐭𝐞𝐦 𝐐𝐮𝐚𝐧𝐭𝐢𝐭𝐢𝐞𝐬

Several measurement blocks are included for evaluating the system response.

Measurement group

Recorded quantities

PV measurement

PV voltage, current, and power

Battery measurement

Battery voltage and current

DC-bus measurement

DC-bus voltage, current, and power

DC-load measurement

Load voltage, current, and power

AC-load measurement

Load voltage, current, and power

Grid measurement

Grid voltage, current, and power

Inverter measurement

Inverter voltage and current

Battery status

State of charge

These measurements make it easier to analyze power sharing, voltage regulation, and transient behavior.

𝐒𝐢𝐦𝐮𝐥𝐚𝐭𝐢𝐨𝐧 𝐒𝐜𝐞𝐧𝐚𝐫𝐢𝐨𝐬

Scenario 1: Standalone operation

The grid command is set to zero.

Expected response:

  • The circuit breaker remains open.

  • Grid voltage, current, and power are zero.

  • PV and battery power supply the AC and DC loads.

  • AC-load voltage remains sinusoidal.

  • DC-bus voltage remains close to its reference.

Scenario 2: Grid-connected operation

The grid command is set to one.

Expected response:

  • The circuit breaker closes.

  • Grid voltage and current become available.

  • Power flows between the PV–battery system and grid.

  • AC and DC loads remain supplied.

  • The battery responds to PV and load variations.

Scenario 3: Grid connected to standalone

The system initially operates with the grid and changes to standalone operation at approximately 0.8 s.

Expected response:

  • Grid power becomes zero after disconnection.

  • The standalone inverter controller is activated.

  • PV and battery continue supplying both loads.

  • A small transient may occur during changeover.

  • Load power returns quickly to its normal level.

Scenario 4: Standalone to grid connected

The system starts in islanded mode and is connected to the grid at the selected switching time.

Expected response:

  • Grid voltage and current appear after reconnection.

  • The inverter changes from voltage control to current control.

  • Grid power exchange begins.

  • The AC and DC loads continue operating.

  • Battery power adjusts to the new power balance.

𝐒𝐢𝐦𝐮𝐥𝐚𝐭𝐢𝐨𝐧 𝐑𝐞𝐬𝐮𝐥𝐭𝐬

The simulation demonstrates stable operation under PV-power variations and grid-mode transitions.

PV response

  • PV current and power follow the applied irradiance profile.

  • The MPPT controller tracks changing operating conditions.

  • PV voltage remains within the controlled operating region.

  • Converter ripple is visible but bounded.

Battery response

  • Battery voltage remains nearly constant.

  • Battery current changes according to the power imbalance.

  • Charging and discharging occur during different PV conditions.

  • State-of-charge variation remains gradual.

DC-bus response

  • DC-bus voltage is regulated around 400 V.

  • Short transients occur during irradiance and mode changes.

  • The battery converter supports voltage recovery.

  • DC-load power remains available in both modes.

AC-load response

  • The load receives regulated sinusoidal voltage.

  • Load current remains continuous.

  • AC-load power is maintained during grid disconnection.

  • Only a small temporary deviation appears during mode changeover.

Grid response

  • Grid voltage, current, and power are zero in standalone mode.

  • Grid current and power appear after grid connection.

  • Power import or export depends on PV generation, battery condition, and load demand.

𝐊𝐞𝐲 𝐅𝐞𝐚𝐭𝐮𝐫𝐞𝐬

  • Combined grid-connected and standalone operation in one model

  • Automatic selection of inverter control mode

  • Solar PV system with Incremental Conductance MPPT

  • Battery energy storage with a bidirectional converter

  • Regulated 400 V DC bus

  • Simultaneous AC- and DC-load supply

  • Bidirectional power exchange with the utility grid

  • Smooth transition between operating modes

  • Continuous monitoring of electrical quantities

  • Suitable for MATLAB/Simulink-based control-system analysis

𝐀𝐝𝐯𝐚𝐧𝐭𝐚𝐠𝐞𝐬

  • Improves power-supply continuity during grid failure

  • Increases utilization of available solar energy

  • Supports battery charging from surplus PV power

  • Reduces dependence on the utility grid

  • Enables controlled grid power import and export

  • Maintains AC- and DC-load operation during transitions

  • Provides a clear platform for testing energy-management strategies

  • Helps analyze converter and inverter controller performance

𝐀𝐩𝐩𝐥𝐢𝐜𝐚𝐭𝐢𝐨𝐧𝐬

This PV–battery system can be applied to:

  • Residential solar energy systems

  • Commercial buildings

  • Smart homes

  • Grid-interactive renewable-energy systems

  • Remote and rural power supplies

  • Solar-powered laboratories

  • Hybrid AC/DC microgrids

  • Backup power systems

  • Telecom power installations

  • Critical electrical loads

𝐊𝐞𝐲𝐰𝐨𝐫𝐝𝐬

Grid-connected PV system, standalone solar PV system, islanded PV operation, PV system with battery, battery energy storage system, MATLAB Simulink solar model, Incremental Conductance MPPT, bidirectional DC–DC converter, single-phase grid inverter, grid-to-island transition, DC-bus voltage control, solar battery power management, AC/DC microgrid, renewable-energy control, grid power exchange.

𝐂𝐨𝐧𝐜𝐥𝐮𝐬𝐢𝐨𝐧

The grid-connected and standalone PV system with battery storage provides reliable power under different grid conditions. During grid-connected operation, the utility grid can supply deficient power or absorb surplus renewable energy. During standalone operation, the PV array and battery maintain power delivery to both AC and DC loads.

The dual-mode inverter controller allows the system to switch between current-controlled grid operation and voltage-controlled standalone operation. Simulation results show stable DC-bus voltage, effective battery support, continuous load supply, and satisfactory transition between the two operating modes.

This MATLAB/Simulink model is a practical learning and research platform for understanding solar PV integration, battery power management, inverter control, grid synchronization, islanded operation, and hybrid AC/DC power flow.

Comments


bottom of page