101100 / pca9685

PCA9685 I2C 16-channel PWM/servo driver Node.js module
MIT License
29 stars 7 forks source link

How to reverse the throttle? #22

Open wewlad-dev opened 2 years ago

wewlad-dev commented 2 years ago

Using Adafruit's driver (python), reversing the throttle as easy as: kit.continuous_servo[3].throttle = 1 and to reverse it kit.continuous_servo[3].throttle = -1 I am not finding any details about that in the readme or anywhere in the examples. any details?

Thanks

101100 commented 2 years ago

There was a discussion of this in #21 related to electronic speed controllers that can go in reverse. Typically, the center of a servo's motion or direction is about 1500 milliseconds, so that is a throttle of zero. If you increase it, the throttle should increase. The top of the throttle range will vary, but for me I found it went up to ~1700, while the developer in #21 found theirs went even higher. To go in reverse, you'd use a value less than 1500, with the lower you go, the more in reverse you are going. Mine went down to 1300 for full reverse. Like with the top, you'll have to experiment to find the range, but I imagine you'll find that the amount you can go up is the same as the amount you can go down and you'll never go down to 0 or into negative numbers.