RF and SEROUT/IN and TIGERS and BEARS
Oh my.
I am using the RF 433 modules from parallax to send servo controls from one bs2 to another. It seems to be working as desired, I have three servos controlled by the stamp. My cat loves it, biting one servo horn, then the next. (I do plan to utilize these servos in some other fashion...).
What is the "fastest" way to deal with Serout and serin data? I tried DEC (ServoPulse) and it seems slower than ServoPulse.highbyte, ServoPulse.lowbyte. I read the manual about both serin and serout commands, but there isn't much in the way of telling how the different methods of packaging data for transmission vary...
One other question. Is there any good way of changing the ramp speed for the servo using code (short of getting a PSC)?
Any thoughts?
My code is below.
Thanks,
Carlos Ferguson
I am using the RF 433 modules from parallax to send servo controls from one bs2 to another. It seems to be working as desired, I have three servos controlled by the stamp. My cat loves it, biting one servo horn, then the next. (I do plan to utilize these servos in some other fashion...).
What is the "fastest" way to deal with Serout and serin data? I tried DEC (ServoPulse) and it seems slower than ServoPulse.highbyte, ServoPulse.lowbyte. I read the manual about both serin and serout commands, but there isn't much in the way of telling how the different methods of packaging data for transmission vary...
One other question. Is there any good way of changing the ramp speed for the servo using code (short of getting a PSC)?
Any thoughts?
My code is below.
Thanks,
Carlos Ferguson
Comments
·
·· When you use ServoPulse.highbyte/ServoPulse.lowbyte you are sending two bytes of data, which is how you would normally send a word variable.· However, when you use DEC you are sending the ASCII representation of the values, which is going to be between 1 and 3 bytes per upper/lower byte, up to 5 bytes, and then it’s slower to get this on the other side as well using an input formatter.· I hope this helps.· Take care.
▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔▔
Chris Savage
Parallax Tech Support