For assembly code, look at the beginning lessons in the PICkit 2 Starter Kit user manual. A basic timer can be done in a few assembly language statements and you'd make it a subroutine. In C, you can call the _delay(us) function which delays the specified number of microseconds. Or, you can do it yourself with a busy-wait loop or use a timer and an interrupt.
It has been a while since I finish my last project with pics, but I'm pretty sure you can accomplish the 10 ms timer using two counters, from 25 us to 1 ms the ideal counter will be call 400 times and with 8 bits pics the maxim is 256, thats why it has to be done using two counters. The two counters products must give a result of 400, finally all this should be solved using conditionals
I want to create only a single timer of 25 us which I have done.
Next
x1 has to be performed every 50 ms
x2 has to be performed every 500 ms
x3 has to be performed every 10 ms
Did you bother finding the document I told you about? It gives you the solution you're looking for; it's only a few lines of code and easy to understand.
May I ask why you've chosen 25-usecs as your "base" timing interval? That's a very short interval. I would think a 1 or 10 msec "base" interval would be more appropriate for your 10-msec, 50-msec, and 500-msec intervals.
What kind of processing will you do at 10-msec, 50-msec, and 500-msec intervals. Will you just toggle som pins or run some code. That would be nice to know. I think we need more info about your project
Single step through your code in the simulator. Putting your main code after the interrupt routine is traditional. There are several mistakes in your coding.