Analysis and Design of a Standalone Electric Vehicle Charging Station Supplied by Photovoltaic Energy

Nowadays, there is a great development in electric vehicle production and utilization. It has no pollution, high efficiency, low noise, and low maintenance. However, the charging stations, required to charge the electric vehicle batteries, impose high energy demand on the utility grid. One way to overcome the stress on the grid is the utilization of renewable energy sources such as photovoltaic energy. The utilization of standalone charging stations represents good support to the utility grid. Nevertheless, the electrical design of these systems has different techniques and is sometimes complex. This paper introduces a new simple analysis and design of a standalone charging station powered by photovoltaic energy. Simple closed-form design equations are derived, for all the system components. Case-study design calculations are presented for the proposed charging station. Then, the system is modeled and simulated using Matlab/Simulink platform. Furthermore, an experimental setup is built to verify the system physically. The experimental and simulation results of the proposed system are matched with the design calculations. The results show that the charging process of the electric vehicle battery is precisely steady for all the PV insolation disturbances. In addition, the charging/discharging of the energy storage battery responds perfectly to store and compensate for PV energy variations.


Introduction
Nowadays, classical internal combustion engine (ICE) vehicles are being replaced by electric vehicles (EVs) [1,2]. In fact, the ICEs have many drawbacks that can be mitigated by EVs. The EVs have negligible pollution, higher energy efficiency, lower noise, and lower maintenance compared to the ICE. However, the charging process of the EV battery still has many obstacles such as the charging time, the charging station's infrastructure, and the effect of these stations on the present electrical power system. The charging time can be greatly reduced to minutes by utilizing fast charging techniques [3][4][5]. These techniques represent large electrical loads on the utility grid and affect it adversely. Especially, when there is a high number of charging stations connected simultaneously to the utility grid, many problems would be generated such as excessive overload, voltage instability, and voltage variation [6][7][8]. One of the solutions to these problems is the upgrading of the power system but this will lead to high costs. Another better solution is the use of an energy storage system (ESS) that can act as a buffer between the EV charging station (EVCS) and the utility [9][10][11][12]. Nevertheless, the use of ESS will reduce slightly the stress on the utility grid but the expected large number of EVCSs in the future is still a challenge.
The idea that the EV is an environmentally friendly vehicle could not be accepted if the charging stations rely mainly on the grid power that is usually generated from fossil fuels.

•
Introducing a novel and simple analysis of the energy and power relations of the charging station powered by photovoltaic energy. The analyses produce closed-form equations for the power and energy of the different system components. In addition, relations for the battery state of charge (SOC) and maximum stored energy of the ESS are derived. • Designing the charging station components with the help of the derived equations in the analysis part. The design includes the power electronic converters used. Further, case study design calculations are provided. • Simulating and practically implementing the proposed system. Hence, the system performances are studied indicating the effect of solar energy variations on the system response.
The paper structure is as follows: Section 2 presents the proposed system architecture. Analysis and design of the charging station have been described in Section 3. Section 4 presents the charging converters modelling and design. The proposed control system is shown in Section 5. Section 6 presents the proposed system design. The simulation Processes 2021, 9,1246 3 of 16 and experimental results have been discussed in Section 7. Finally, Section 8 comes with the conclusions.

The Proposed Charging Station Description
The architecture of the proposed EVCS system is shown in Figure 1. The EVCS system is an off-grid type that is powered by solar energy. It is collected by a PV array that generates electrical energy to the EVCS. The PV panel represents the main source of energy for the charging station. However, the generated energy is not steady. It varies according to the solar insolation level and other environmental issues. Hence, ESS batteries are usually used to compensate for the problem of energy intermittence. The output terminals of the PV are connected to a boost converter. Its function is to match the PV voltage level to that of the DC bus and helps in utilizing the maximum power point tracking (MPPT) condition of the PV panel. Two charging converters are connected to the DC bus namely the EV charger and the energy storage converter. These converters are generally DC/DC converters. However, the EV charger is a one quadrant buck converter that is used to charge the EV battery (lithium-ion). It serves in regulating the charging process of the EV battery. However, the energy storage converter is a two-quadrant DC/DC converter. It is used to control the charge/discharge process of the storage battery (lead-acid). In addition, it participates in regulating the DC bus voltage against the variations of the EV load and insolation level. The modelling and theory of operation of these converters will be explained in the next paragraphs.
Processes 2021, 9, x FOR PEER REVIEW 3 of 16 4 presents the charging converters modelling and design. The proposed control system is shown in Section 5. Section 6 presents the proposed system design. The simulation and experimental results have been discussed in Section 7. Finally, Section 8 comes with the conclusions.

The Proposed Charging Station Description
The architecture of the proposed EVCS system is shown in Figure 1. The EVCS system is an off-grid type that is powered by solar energy. It is collected by a PV array that generates electrical energy to the EVCS. The PV panel represents the main source of energy for the charging station. However, the generated energy is not steady. It varies according to the solar insolation level and other environmental issues. Hence, ESS batteries are usually used to compensate for the problem of energy intermittence. The output terminals of the PV are connected to a boost converter. Its function is to match the PV voltage level to that of the DC bus and helps in utilizing the maximum power point tracking (MPPT) condition of the PV panel. Two charging converters are connected to the DC bus namely the EV charger and the energy storage converter. These converters are generally DC/DC converters. However, the EV charger is a one quadrant buck converter that is used to charge the EV battery (lithium-ion). It serves in regulating the charging process of the EV battery. However, the energy storage converter is a two-quadrant DC/DC converter. It is used to control the charge/discharge process of the storage battery (lead-acid). In addition, it participates in regulating the DC bus voltage against the variations of the EV load and insolation level. The modelling and theory of operation of these converters will be explained in the next paragraphs.

Analysis and Design of The Charging Station
The electrical design of the EVSC means designing all electrical parts of the station such as the PV array, the system converters, the DC bus voltage level, all passive components, and the storage battery. Many aspects must be considered in designing the EVSC: • The available solar energy on the site and the maximum permissible area for the PV panels.

Analysis and Design of the Charging Station
The electrical design of the EVSC means designing all electrical parts of the station such as the PV array, the system converters, the DC bus voltage level, all passive components, and the storage battery. Many aspects must be considered in designing the EVSC:

•
The available solar energy on the site and the maximum permissible area for the PV panels. The size of the ESS depends on the available PV power and the demand load of the EV.
As a first step for the design process, the relation among the input solar energy, the output charging power to the EV, and the stored energy in the ESS must be studied. The system power and energy relations will be studied in the next subsection.

Power and Energy Analysis of the System
In this section, the energy and power relations of the system are derived to help in the design process. The assumptions used in this regard are:

•
The storage battery's initial energy is "E i " in Wh.

•
The output power of the EV station "P EV " is constant.

•
The solar power "P pv " of the PV panel changes with time according to: where; "P max " is the PV maximum power and "t" is the time in hours. The relation is sketched in Figure 2. The time axis origin is set at noon where the insolation level is maximum. The period of solar energy is assumed to be 12 H starting at 6:00 a.m. The size of the ESS depends on the available PV power and the demand load of the EV.
As a first step for the design process, the relation among the input solar energy, the output charging power to the EV, and the stored energy in the ESS must be studied. The system power and energy relations will be studied in the next subsection.

Power and Energy Analysis of the System
In this section, the energy and power relations of the system are derived to help in the design process. The assumptions used in this regard are: • The storage battery's initial energy is "Ei" in Wh.
• The output power of the EV station "PEV" is constant. • The solar power "Ppv" of the PV panel changes with time according to: where; "Pmax" is the PV maximum power and "t" is the time in hours. The relation is sketched in Figure 2. The time axis origin is set at noon where the insolation level is maximum. The period of solar energy is assumed to be 12 H starting at 6:00 a.m. From the power balance principle and refer to the system power flow diagram shown in Figure 3.  From the power balance principle and refer to the system power flow diagram shown in Figure 3.

•
The station power is related to the number of EVs to be charged simultaneously. The charging rate is an important issue that affects the charging time. For fast charging, the station should be capable of charging rates of 3 C to 5 C [26]. • The size of the ESS depends on the available PV power and the demand load of the EV.
As a first step for the design process, the relation among the input solar energy, the output charging power to the EV, and the stored energy in the ESS must be studied. The system power and energy relations will be studied in the next subsection.

Power and Energy Analysis of the System
In this section, the energy and power relations of the system are derived to help in the design process. The assumptions used in this regard are: • The storage battery's initial energy is "Ei" in Wh.
• The output power of the EV station "PEV" is constant. • The solar power "Ppv" of the PV panel changes with time according to: where; "Pmax" is the PV maximum power and "t" is the time in hours. The relation is sketched in Figure 2. The time axis origin is set at noon where the insolation level is maximum. The period of solar energy is assumed to be 12 H starting at 6:00 a.m. From the power balance principle and refer to the system power flow diagram shown in Figure 3.   Hence, where; "P bat " is the instantaneous storage battery power. The average power of the storage battery is assumed to be zero along one day period (T = 24 h). Hence, Hence, Battery state of charge and maximum stored energy The battery energy-stored can be calculated through: where; "C" is a constant.
The region (−6 ≤ t ≤ 6) Substitute Equation (3) into Equation (7) and integrate: To get the constant "C", we have that at t = −6 → E bat = E i . Using Equation (8): The instantaneous battery energy is given by: The final value of the energy at this region (t = 6): This value is the initial value for the next region. The region (6 ≤ t ≤ 18) From Equations (7) and (3): where; "C 1 " is constant. From Equations (11) and (12): Hence, Processes 2021, 9, 1246 6 of 16 The maximum stored energy occurs at t = x as shown in Figure 3. It can be shown that the maximum stored energy is given by: From this analysis, if the EV power P EV is known, then using Equations (1), (6) and (15) the PV power rating and the ESS size can be determined. Hence, the PV array area can be calculated.

Charging Converters Modelling and Design
The proposed system has two charging converters. The EV charging converter is a simple buck converter (first-quadrant converter). However, the energy storage battery is a buck-boost converter (two-quadrant converter). The circuit diagrams of the converters are shown in Figure 4. The operation, modeling, and analysis of the two-quadrant converter include that of the first-quadrant converter. The continuous mode is assumed for the converter operation. The converter comprised two IGBT's (S 1 , S 2 ), two antiparallel diodes, and an LC filter. The converter terminals are connected to the DC bus and the storage battery. The battery's internal voltage and resistance are represented by (E b , r b ). The filter inductance is assumed to be large enough to preserve sufficient energy to charge or discharge the battery. Hence, the discontinuous conduction operation mode is neglected. The converter has two modes namely the buck mode and boost mode. The bidirectional converter serves in the boost mode, when the switch S 2 is active and the switch S 1 acts as a diode, for discharging the battery. However, it serves in the buck mode, when switch S 1 is active and the switch S 2 acts as a diode, resulting in the battery charge mode. The converter dynamic model in the state-space form is described as: During buck operation: where; (i l , v c ) are the inductor current and the capacitor voltage, u 1 represents the switch S 1 action with PWM taking values from the set of {0:1}, (L, C) are inductance and the capacitance of the filter, V dc is the DC bus voltage.
Processes 2021, 9, x FOR PEER REVIEW 6 of 16 The maximum stored energy occurs at t = x as shown in Figure 3. It can be shown that the maximum stored energy is given by: From this analysis, if the EV power PEV is known, then using Equations (1), (6), and (15) the PV power rating and the ESS size can be determined. Hence, the PV array area can be calculated.

Charging Converters Modelling and Design
The proposed system has two charging converters. The EV charging converter is a simple buck converter (first-quadrant converter). However, the energy storage battery is a buck-boost converter (two-quadrant converter). The circuit diagrams of the converters are shown in Figure 4. The operation, modeling, and analysis of the two-quadrant converter include that of the first-quadrant converter. The continuous mode is assumed for the converter operation. The converter comprised two IGBT's (S1, S2), two antiparallel diodes, and an LC filter. The converter terminals are connected to the DC bus and the storage battery. The battery's internal voltage and resistance are represented by (Eb, rb). The filter inductance is assumed to be large enough to preserve sufficient energy to charge or discharge the battery. Hence, the discontinuous conduction operation mode is neglected. The converter has two modes namely the buck mode and boost mode. The bidirectional converter serves in the boost mode, when the switch S2 is active and the switch S1 acts as a diode, for discharging the battery. However, it serves in the buck mode, when switch S1 is active and the switch S2 acts as a diode, resulting in the battery charge mode. The converter dynamic model in the state-space form is described as: During buck operation: where; (il, vc) are the inductor current and the capacitor voltage, u1 represents the switch S1 action with PWM taking values from the set of {0:1}, (L, C) are inductance and the capacitance of the filter, Vdc is the DC bus voltage.   During boost operation: where; (d min , d max ) is the minimum and maximum duty cycle, R li is the approximate equivalent resistance of Li-ion battery, f is the switching frequency, (∆I min , ∆I max ) is the minimum and maximum ripple currents, r is the minimum voltage ripple factor, and I b | max is the maximum battery current. The DC bus voltage level is selected according to the charging state of the system as the system converters operate in the buck mode. In this case, the DC bus voltage must be greater than the converter output average voltage. On the other hand, the minimum duty cycle and battery voltage variations affect the value of V dc . These constraints can be written as: is the battery minimum and maximum terminal voltage, and d n is the nominal modulation index. The value of the DC capacitance affects greatly the DC bus stability. Basically, the DC bus capacitor must support a certain voltage and power ripple factor. The DC bus capacitance C dc can be calculated from [28]: where; (∆x, ∆r) is the percentage ripple power and voltage; and P rated is the rated power.

Control System
The controllers of the proposed system, shown in Figure 5, are the MPPT, the EV charger, and the storage converter controller. The function of the MPPT controller is to keep absorbing the peak power from the PV panel. It outputs the suitable duty ratio to the boost converter that maintains the MPPT. However, the EV converter controller regulates the charging of the EV. Finally, the battery storage converter controller is used to control the DC bus voltage and ESS charge/discharge process.
where; u2 represents the switch S2 action with PWM taking values from the set of {0:1}. The filter inductor and capacitor design equations are [27]: where; (dmin, dmax) is the minimum and maximum duty cycle, is the approximate equivalent resistance of Li-ion battery, f is the switching frequency, (∆ , ∆ ) is the minimum and maximum ripple currents, r is the minimum voltage ripple factor, and | is the maximum battery current. The DC bus voltage level is selected according to the charging state of the system as the system converters operate in the buck mode. In this case, the DC bus voltage must be greater than the converter output average voltage. On the other hand, the minimum duty cycle and battery voltage variations affect the value of Vdc. These constraints can be written as: (22) where; ( , ) is the battery minimum and maximum terminal voltage, and dn is the nominal modulation index. The value of the DC capacitance affects greatly the DC bus stability. Basically, the DC bus capacitor must support a certain voltage and power ripple factor. The DC bus capacitance Cdc can be calculated from [28]: where; (∆ , ∆ ) is the percentage ripple power and voltage; and Prated is the rated power.

Control System
The controllers of the proposed system, shown in Figure 5, are the MPPT, the EV charger, and the storage converter controller. The function of the MPPT controller is to keep absorbing the peak power from the PV panel. It outputs the suitable duty ratio to the boost converter that maintains the MPPT. However, the EV converter controller regulates the charging of the EV. Finally, the battery storage converter controller is used to control the DC bus voltage and ESS charge/discharge process.

MPPT Controller
The MPPT controller is necessary to improve the PV system utilization. The algorithm of the MPPT has been implemented using many approaches [29][30][31][32]. For simplicity, the common technique called "perturb and observe" is utilized here. In this technique, a perturb of the boost converter duty ratio is made and the PV voltage and current are measured. After then, the power change is calculated then checked according to the flow chart of Figure 6 [33]. The controller is adapted to generate the necessary duty ratio for the boost converter switch to achieve MPPT conditions.

EV Converter Controller
The target of this controller is to regulate the charging process of the EV.

MPPT Controller
The MPPT controller is necessary to improve the PV system utilization. The algorithm of the MPPT has been implemented using many approaches [29][30][31][32]. For simplicity, the common technique called "perturb and observe" is utilized here. In this technique, a perturb of the boost converter duty ratio is made and the PV voltage and current are measured. After then, the power change is calculated then checked according to the flow chart of Figure 6 [33]. The controller is adapted to generate the necessary duty ratio for the boost converter switch to achieve MPPT conditions.

MPPT Controller
The MPPT controller is necessary to improve the PV system utilization. The algorithm of the MPPT has been implemented using many approaches [29][30][31][32]. For simplicity, the common technique called "perturb and observe" is utilized here. In this technique, a perturb of the boost converter duty ratio is made and the PV voltage and current are measured. After then, the power change is calculated then checked according to the flow chart of Figure 6 [33]. The controller is adapted to generate the necessary duty ratio for the boost converter switch to achieve MPPT conditions.

EV Converter Controller
The target of this controller is to regulate the charging process of the EV.

EV Converter Controller
The target of this controller is to regulate the charging process of the EV. There are various control techniques such as pulse, constant voltage (CV), constant current (CC), and constant current/constant voltage (CC/CV) techniques. Commonly, the (CC and CC/CV) techniques are preferred for their low charging time. In our system, the (CC/CV) technique is utilized. A simple PI controller is adapted for this technique. The proportion and integral gains of the PI controller are tuned using the Ziegler-Nichols method.
The experimental Ziegler-Nichols tuning algorithm can simply be summarized as the following. First, the PI controller is reduced to only the proportional part with very low proportional gain. Hence, remove the integral actions from the controller by setting it to zero. The proportional gain is then increased until continuous oscillations in the output signal are observed. Note that, when the oscillations occur, the controller should not be hitting limits. After each gain increase, you may need to make a disturbance b changing the setpoint to see if the loop oscillates. The oscillations occur at a critical proportional gain (K pc ) with an oscillation period (T osc ). By measuring the parameters K pc and T osc , the proportional and integral gains (K p , K i ) for the PI controller are adjusted as:

Battery Storage Converter Controller
The objective of this controller is to regulate the DC bus voltage at a constant reference value. Consequently, charging and discharging the storage battery are adapted to serve this function. In addition, the PI controller is adapted for this converter. In case that the batteries are fully charged, the converter stops charging except for a small trickle current.

The Proposed System Design Calculations
According to the previous analysis, the system parameters can be calculated. Assume that the proposed system data and parameters are listed in Table 1. The design calculations are carried out as follows:

• Design calculations for ESS
As the available PV panel is 120 W, the EV power can be determined from Equation (6). Hence, using Equation (15) the ESS energy can be calculated. The charge capacity of the ESS is 39 Ah. However, the nearest available standard is 65 Ah. Normally, the range of the SOC of the ESS is from 20% to 95% [34].

• Design calculations for EV converter filter
Let that ∆I min = 0.3 A, V dc = 25 V, and r min = 0.02. Hence, substituting in Equation (19), gives the range of inductance as 325 µH and 9375 µH. The standard inductance value of 560 µH is chosen. Then, substituting in Equation (21), gives C ≥ 363 µF. The standard inductance value of 1000 µF is chosen.

• Design calculations for Storage battery converter filter
Let that ∆I min = 1.3 A and applying the same procedure to the converter of storage battery giving the range of inductance as 74 µH and 1329 µH. The standard inductance value of 560 µH is chosen. Then, substituting in Equation (21), gives C ≥ 446 µF. The standard inductance value of 1000 µF is chosen.

Simulation and Experimental Results
The proposed system, shown in Figure 1, is simulated and implemented physically to verify the paper idea. The parameters in Table 1 are used for both the simulation and the experimental setup. The PV panel is the Copex module of model P120. It is a polycrystalline type and has the specifications listed below. The EV battery is formed by four Li-ion batteries connected in series. Its nominal voltage is 14.8 V, the fully charged voltage is 17 V and its cut-off voltage is 12 V. The results are discussed in the following paragraphs.

Simulation Results
The proposed system is simulated using Matlab/Simulink platform. The system performances according to step changes in the solar irradiation of the PV panel are shown in Figures 7 and 8. Figure 7a shows the irradiation level of solar energy. The DC bus voltage tracks well the reference voltage (25 V), as shown in Figure 7b. The state of charge of the lead-acid battery bank B 2 is shown in Figure 7c. At the first four seconds, the insolation is ≥60%. Therefore, the generated PV power is enough to charge the EV battery and store the reserve in the B 2 . However, the insolation at the remaining period is ≤60% which is not enough to supply the energy to the EV. Hence, the storage battery discharges to compensate for the drop in solar energy. The current of the battery tracks its reference value generated by the DC bus voltage controller, as shown in Figure 7d. In addition, the charging and discharging processes track and compensate for the irradiation level. Figure 7e shows the voltage of the B 2 battery. Its voltage increases with charging and decreases with discharging. The PV current is shown in Figure 7f. The current level is the same as the MPPT conditions. Figure 8a shows the irradiation level of solar energy. The EV current tracks well the reference current generated by the charge controller, as shown in Figure 8b. Figure 8c shows the voltage of the B 1 battery. It is continuously charging. The state of charge of the EV battery is shown in Figure 8d. Figure 8e,f show the PV power, the power of the B 2 battery, and the EV battery power. At the first four seconds, the irradiation is ≥60%. Therefore, the generated PV power is enough to charge the EV battery and store the reserve in the B 2 . However, the insolation at the remaining period is ≤60% which is not enough to supply the energy to the EV. Hence, the storage battery discharges to compensate for the drop in solar energy. In addition, the charging and discharging processes track and compensate for the irradiation level. Its voltage increases with charging and decreases with discharging. The EV power is constant at all conditions, shown in Figure 8f. enough to supply the energy to the EV. Hence, the storage battery discharges to compensate for the drop in solar energy. The current of the battery tracks its reference value generated by the DC bus voltage controller, as shown in Figure 7d. In addition, the charging and discharging processes track and compensate for the irradiation level. Figure 7e shows the voltage of the B2 battery. Its voltage increases with charging and decreases with discharging. The PV current is shown in Figure 7f. The current level is the same as the MPPT conditions.   Figure 8a shows the irradiation level of solar energy. The EV current tracks well the reference current generated by the charge controller, as shown in Figure 8b. Figure 8c shows the voltage of the B1 battery. It is continuously charging. The state of charge of the EV battery is shown in Figure 8d. Figure 8e,f show the PV power, the power of the B2 battery, and the EV battery power. At the first four seconds, the irradiation is ≥60%. Therefore, the generated PV power is enough to charge the EV battery and store the reserve in the B2. However, the insolation at the remaining period is ≤60% which is not enough to supply the energy to the EV. Hence, the storage battery discharges to compensate for the drop in solar energy. In addition, the charging and discharging processes track and compensate for the irradiation level. Its voltage increases with charging and decreases with discharging. The EV power is constant at all conditions, shown in Figure 8f.

Experimental Results
An experimental prototype is built, as shown in Figure 9, to verify the simulation results of the proposed system. The prototype has the same parameters listed in Table 1. A single-chip PIC18F4550 microcontroller, with a 16 MHz oscillator, is utilized to achieve simultaneously five controllers. The five controllers utilize three timers of the microcontroller (T0, T1, and T2) and the PWM module of the microcontroller. The microcontroller generates the control signals for the switches S1, S2, S3, and S4. The switching frequency is suitable for the converters and gives very good results. All the controllers are included in a single chip microcontroller and all control signals are generated from this microcontroller. Therefore, the execution time of different sections in the codes forces the switching frequency to be not so high. A drive circuit for each control signal is used to raise its level voltage to a suitable level. However, the drive circuits invert the generated control signals, and this inversion is considered in the written code of all controllers. The five controllers are described as follows: • The boost converter controller A perturb and observe maximum power point tracker is applied to achieve maximum power extraction of the PV panel. The microcontroller receives the PV voltage and current, performs the perturb-observe algorithm, then generates the control signal to the

Experimental Results
An experimental prototype is built, as shown in Figure 9, to verify the simulation results of the proposed system. The prototype has the same parameters listed in Table 1. A single-chip PIC18F4550 microcontroller, with a 16 MHz oscillator, is utilized to achieve simultaneously five controllers. The five controllers utilize three timers of the microcontroller (T0, T1, and T2) and the PWM module of the microcontroller. The microcontroller generates the control signals for the switches S 1 , S 2 , S 3 , and S 4 . The switching frequency is suitable for the converters and gives very good results. All the controllers are included in a single chip microcontroller and all control signals are generated from this microcontroller. Therefore, the execution time of different sections in the codes forces the switching frequency to be not so high. A drive circuit for each control signal is used to raise its level voltage to a suitable level. However, the drive circuits invert the generated control signals, and this inversion is considered in the written code of all controllers. The five controllers are described as follows:

•
The boost converter controller A perturb and observe maximum power point tracker is applied to achieve maximum power extraction of the PV panel. The microcontroller receives the PV voltage and current, performs the perturb-observe algorithm, then generates the control signal to the boost converter switch. This controller uses T2 and CCP modules are operating in the PWM mode.

•
The DC bus voltage controller The voltage of the DC bus is maintained constant during charging both batteries in the sunshine day hours and during night hours (discharging lead-acid battery). The controller gives the required lead-acid current in both modes of operation of the lead-acid battery considering the maximum charging current and maximum discharging current of the lead-acid battery.

•
The lead-acid battery voltage controller During the constant voltage stage of charging the lead-acid battery, its voltage is maintained at a slight value below the gassing voltage of the battery (14.4 V). During discharging mode of the battery, its voltage starts to decrease. The battery voltage is monitored so that the cut-off voltage should not be reached. This controller utilizes the reference battery voltage which is generated by the previous controller and generates the control signals to S 1 and S 2 . This controller employs T1 and the interrupt module to achieve its target.

•
The lithium-ion voltage and current controllers The lithium-ion battery pack is charged using the constant current-constant voltage charging method. The maximum allowable charging voltage and current of the lithium-ion battery pack are controlled using the two controllers. The outer loop (voltage controller) controls the battery voltage and generates the suitable battery current taking into consideration the maximum charging current (6.5 A). The inner loop (current controller) generates the control signal to S 3 . This controller employs T0 and the interrupt module to realize its target. The voltage of the DC bus is maintained constant during charging both batteries in the sunshine day hours and during night hours (discharging lead-acid battery). The controller gives the required lead-acid current in both modes of operation of the lead-acid battery considering the maximum charging current and maximum discharging current of the lead-acid battery. • The lead-acid battery voltage controller During the constant voltage stage of charging the lead-acid battery, its voltage is maintained at a slight value below the gassing voltage of the battery (14.4 V). During discharging mode of the battery, its voltage starts to decrease. The battery voltage is monitored so that the cut-off voltage should not be reached. This controller utilizes the reference battery voltage which is generated by the previous controller and generates the control signals to S1 and S2. This controller employs T1 and the interrupt module to achieve its target. • The lithium-ion voltage and current controllers The lithium-ion battery pack is charged using the constant current-constant voltage charging method. The maximum allowable charging voltage and current of the lithiumion battery pack are controlled using the two controllers. The outer loop (voltage controller) controls the battery voltage and generates the suitable battery current taking into consideration the maximum charging current (6.5 A). The inner loop (current controller) generates the control signal to S3. This controller employs T0 and the interrupt module to realize its target. The step response of the charge controller of the lithium-ion battery is illustrated in Figure 10. The reference current is stepped at values of 3 A, 2 A, and 1 A. The voltage controller of the battery at the same time keeps the battery voltage at the suitable level corresponding to each current level. The corresponding control signal to S3 is shown. It is The step response of the charge controller of the lithium-ion battery is illustrated in Figure 10. The reference current is stepped at values of 3 A, 2 A, and 1 A. The voltage controller of the battery at the same time keeps the battery voltage at the suitable level corresponding to each current level. The corresponding control signal to S 3 is shown. It is noticed that the duty cycle of S 3 decreases as the reference current decreases. On the other side, the DC bus voltage is maintained constant.  Figure 11 shows the effects of disconnecting the PV panel. The figure presents DC bus voltage, lead-acid battery voltage, lithium-ion battery voltage, and current. The leadacid battery current changes its direction at the instant of disconnection. The controller keeps the DC bus voltage constant after the instant of disconnecting the PV panel where the lead-acid battery operates in the boost mode in which it starts discharging and its voltage slightly decreases. The charge controller of the lithium-ion battery keeps its level voltage and current at the same values before disconnecting the PV panels. Figure 11. The system response upon disconnecting the PV: Ch1: lead acid battery current (6 A/div) Ch2: Li-ion battery voltage (5 V/div) Ch3: lead acid battery voltage (5 V/div), Ch4: Li-ion battery current (4 A/div) Disconnecting and reconnecting the PV panel is illustrated in Figure 12a,b. The figures give the DC bus voltage, lead-acid battery, and lithium-ion battery voltage. In Figure  12a, the PV panel is disconnected and the lead-acid battery lonely charges the lithium-ion battery. The DC bus voltage and lithium-ion battery voltage are kept at the original levels while the slightly decreases. Figure 12b shows the reconnection of the PV panel in which the two batteries are being charged and the lead-acid battery voltage slightly increases.  Figure 11 shows the effects of disconnecting the PV panel. The figure presents DC bus voltage, lead-acid battery voltage, lithium-ion battery voltage, and current. The lead-acid battery current changes its direction at the instant of disconnection. The controller keeps the DC bus voltage constant after the instant of disconnecting the PV panel where the lead-acid battery operates in the boost mode in which it starts discharging and its voltage slightly decreases. The charge controller of the lithium-ion battery keeps its level voltage and current at the same values before disconnecting the PV panels.  Figure 11 shows the effects of disconnecting the PV panel. The figure presents DC bus voltage, lead-acid battery voltage, lithium-ion battery voltage, and current. The leadacid battery current changes its direction at the instant of disconnection. The controller keeps the DC bus voltage constant after the instant of disconnecting the PV panel where the lead-acid battery operates in the boost mode in which it starts discharging and its voltage slightly decreases. The charge controller of the lithium-ion battery keeps its level voltage and current at the same values before disconnecting the PV panels. Figure 11. The system response upon disconnecting the PV: Ch1: lead acid battery current (6 A/div) Ch2: Li-ion battery voltage (5 V/div) Ch3: lead acid battery voltage (5 V/div), Ch4: Li-ion battery current (4 A/div) Disconnecting and reconnecting the PV panel is illustrated in Figure 12a,b. The figures give the DC bus voltage, lead-acid battery, and lithium-ion battery voltage. In Figure  12a, the PV panel is disconnected and the lead-acid battery lonely charges the lithium-ion battery. The DC bus voltage and lithium-ion battery voltage are kept at the original levels Figure 11. The system response upon disconnecting the PV: Ch1: lead acid battery current (6 A/div) Ch2: Li-ion battery voltage (5 V/div) Ch3: lead acid battery voltage (5 V/div), Ch4: Li-ion battery current (4 A/div).
Disconnecting and reconnecting the PV panel is illustrated in Figure 12a,b. The figures give the DC bus voltage, lead-acid battery, and lithium-ion battery voltage. In Figure 12a, the PV panel is disconnected and the lead-acid battery lonely charges the lithium-ion battery. The DC bus voltage and lithium-ion battery voltage are kept at the original levels while the slightly decreases. Figure 12b shows the reconnection of the PV panel in which the two batteries are being charged and the lead-acid battery voltage slightly increases.  Figure 13a,b present the control signals of the switches S1 through S4 during connecting and disconnecting the PV, respectively. The experimental results are summarized in Table 2.

Conclusions
An isolated EV charging station based on a PV energy source is proposed. The system   Table 2.  Figure 13a,b present the control signals of the switches S1 through S4 during connecting and disconnecting the PV, respectively. The experimental results are summarized in Table 2.

Conclusions
An isolated EV charging station based on a PV energy source is proposed. The system

Conclusions
An isolated EV charging station based on a PV energy source is proposed. The system consists of PV panel, boost converter, ESS batteries, two DC/DC charging converters, and an EV battery. The control system consists of three controllers named the MPPT, the EV charger, and the storage converter controller. PI voltage and current controllers are adapted to control charging/discharging of the ESS system and the EV charger as well. The system is simulated and implemented physically. A single-chip PIC18F4550 microcontroller is utilized to realize the system controllers. New simple energy and power analyses procedure has been introduced. Hence, closed-form equations have been derived to help in the design phase. Complete design of the system, including the ESS size, the PV rating, and the filter components, has been proposed. Simulation and experimental results are very close and verify the effectiveness of the proposed system. At different insolation levels, the results show that the charging process of the EV battery is steady without any disturbance. However, the charging/discharging of the ESS battery responds perfectly to store and compensate for PV energy variations. The current and voltage controllers of the converters give good responses and track their references well. In addition, the MPPT controller tracks the peak conditions of the PV precisely.