Don't keep overwriting the duty cycle value. Just write it once and let it run unless it changes.
If you look at the datasheet, you'll see that a few things tend to reset themselves whenever the duty cycle register is written, thereby screwing up your duty cycle.