The code that I posted does a 10bit HPWM.