naldoxable Member Licensed User Longtime User Nov 8, 2015 #1 Hi, there is a way to control one servo-motor using b4j?
Erel B4X founder Staff member Licensed User Longtime User Nov 9, 2015 #2 Have you tried to use SoftPwm: http://pi4j.com/apidocs/com/pi4j/wiringpi/SoftPwm.html ? Upvote 0
KMatle Expert Licensed User Longtime User Nov 9, 2015 #3 Here's an example with PWM: http://razzpisampler.oreilly.com/ch05.html Upvote 0
naldoxable Member Licensed User Longtime User Nov 9, 2015 #4 Thank you all, but this code uses a "virtual" pwm that isn't accurate and uses too cpu. I need to control two servo of a webcam so i need a stable solution! I've read that the Raspi has one or more hardware pwm https://www.raspberrypi.org/forums/viewtopic.php?f=91&t=105044. There is a way to use it? Upvote 0
Thank you all, but this code uses a "virtual" pwm that isn't accurate and uses too cpu. I need to control two servo of a webcam so i need a stable solution! I've read that the Raspi has one or more hardware pwm https://www.raspberrypi.org/forums/viewtopic.php?f=91&t=105044. There is a way to use it?
MaFu Well-Known Member Licensed User Longtime User Nov 9, 2015 #5 For servo controlling i use always the micro maestro servo controller from Pololu. I use it for camera control too for years without problems (but mid-size video cams no webcams), driving is stable and smooth (winch servos with 10 turns and 10:1 gear ratio). The benefits: Controlling is simple with serial interface from Arduino or Pi. I can use it with PC also without the need of an microcontroller. The servo controller can use ramping. Upvote 0
For servo controlling i use always the micro maestro servo controller from Pololu. I use it for camera control too for years without problems (but mid-size video cams no webcams), driving is stable and smooth (winch servos with 10 turns and 10:1 gear ratio). The benefits: Controlling is simple with serial interface from Arduino or Pi. I can use it with PC also without the need of an microcontroller. The servo controller can use ramping.
M Michael1968 Active Member Licensed User Longtime User Nov 9, 2015 #6 for servo control I use a pca9685 it is a i2c controled 12 chanel pwm controler from adafruit you can buy a servo hat. Upvote 0
for servo control I use a pca9685 it is a i2c controled 12 chanel pwm controler from adafruit you can buy a servo hat.