I wrote the tutorial so thanks for spotting any errors.
PWM and Timers are rather unportable from one controller/Timer to another - with different bits in different registers etc. So rather complex.
Can you let me know which processor you are using, and which Timer you are using - then I can update it.
Thanks in anticaption.