Thanks a lot Bruce.
I just want to get started with PPWM and then build my own code for brushless DC motor control.
Thanks for your code although its in assembly.i will figure it out.