Text this: Microcontroller Based PWM UPS