servo help needed

after a signal to a servo is sent via the servo command, there is the 20ms gap until the signal is sent again.

im not sure if this is possible but how do i do use readadc and tell it to go to another sub section in the programme inbetween the gap and still be able to send the signal back to the servo after 20ms after the first signal was sent.
 

BeanieBots

Moderator
"servo" is a background task.
That means, once the command has been executed, the pulses continue to be sent every 20mS even while the rest of your code is running. You do not to worry about it. Everything happens in the background.

If however, you want to control your servo with pulsout, then your code must be written such that you send out a new pulse every 20mS. This can be quite a task to get right which is why the servo command exists.
 
so you mean that once the servo command is executed it continues to do it for ever? and that i can do something else like execute another 2 servos?

if this is the case how do i stop the servo command?
 

BeanieBots

Moderator
That's right. On a 28X for example, you could have 8 servos running while your program goes off and does other things.
It is not 'normal' to "stop" a servo but should you wish to do so, simply set the output low. The pulses will stop and the servo will become inactive.
 
na mate im trying to do this with an 08m. is there a servo limit for 08m? also just out of curisoty how many times can i reprogramme an 18m and 18x without it screwing up? i know it is atleast 100,000 times for an 08m but i dont remember where i read that or if my electronics teacher said that.

Edited by - annoyin_kid on 23/01/2007 23:27:26
 

BeanieBots

Moderator
Any PICAXE that supports the servo command can apply it to any of 'standard' output pins. So, for the 08M, that would be four.

Number of program downloads varies between PIC types but 100,000 is a good general figure. The PIC datasheet will give more precise numbers. Never managed to destroy one that way yet and some I've had for several years just for trying out ideas with downloads every minute or so over several evenings at a time.
 
Top