Added PWM functions