DIESEL GENERATOR AND GRID POWER SWITCHING STRATEGY