HOW TO CONTROL CHARGING AND DISCHARGING OF SOLAR ENERGY