CONSTANTS in Oshonsoft

Thread Starter

camerart

Joined Feb 25, 2013
3,830
hi C,
The servo pulse should occur at a 20mSec rate, the pulse will vary in width from 1mSec thru 2mSec.
The width/period of the pulse sets the servo Angle.
Look at this link.
E
https://www.jameco.com/Jameco/workshop/Howitworks/how-servo-motors-work.html
Hi E,
Yes, I understand that, thanks.

I'm not sure how this CODE works, but I think it is an 8BIT 'shift register', connected directly to the 8x SERVOS, that switches so fast that it appears to switch 'say' SERVO 1 on for 'say' 1.5ms. In a similar way to a dimming LED, all in HW.
To be honest, I haven't quite understood completely, and I'm trying to make a visualisation of the CLOCK PIN and DATA PIN, invovled.
C.
 

djsfantasi

Joined Apr 11, 2010
9,237
Hi E,
Yes, I understand that, thanks.

I'm not sure how this CODE works, but I think it is an 8BIT 'shift register', connected directly to the 8x SERVOS, that switches so fast that it appears to switch 'say' SERVO 1 on for 'say' 1.5ms. In a similar way to a dimming LED, all in HW.
To be honest, I haven't quite understood completely, and I'm trying to make a visualisation of the CLOCK PIN and DATA PIN, invovled.
C.
No. RC servos require a single pulse of 1 to 2 ms width to position itself. It doesn’t switch so fast it “appears” to be a single pulse. It IS a single pulse. You can use a register to update the control signal several times (quickly) as long as each of the 8x control signals stay on or off the required pulse widths.
 

Thread Starter

camerart

Joined Feb 25, 2013
3,830
No. RC servos require a single pulse of 1 to 2 ms width to position itself. It doesn’t switch so fast it “appears” to be a single pulse. It IS a single pulse. You can use a register to update the control signal several times (quickly) as long as each of the 8x control signals stay on or off the required pulse widths.
Hi D,
I'm having a lot of difficulty visualising it all, I'll get it in the end, thanks.
NOTE: As the CONSTANTS question has been asnwered anything on the 'shift register, would be better here please: https://forum.allaboutcircuits.com/...rvo-motor-output-on-18f4431-oshonsoft.186657/
C
 
Top