Draft of pwmWrite