0

Adafruit pwm shield frequency for digital servo with Arduino
Moderators: adafruit_support_bill, adafruit

Please be positive and constructive with your questions and comments.

Adafruit pwm shield frequency for digital servo with Arduino

by aive on Fri Oct 26, 2018 8:39 pm

I'm using Adafruit 16 channel pwm servo shield with Arduino Uno controller. Here is example code from Adafruit PWM Servo Driver Library. It says that analog servos run at ~60 Hz updates `pwm.setPWMFreq(60);`.

I'm using Power HD High-Speed Digital Micro Servo DSM44 which runs fine with ~60 Hz, but I'm trying to figure out what should be appropriate frequency for particular digital servo?

Any advice, guide or example would be helpful

aive
 
Posts: 8
Joined: Wed Oct 03, 2018 9:28 pm

Re: Adafruit pwm shield frequency for digital servo with Ard

by franklin97355 on Fri Oct 26, 2018 8:45 pm

What are the specs of the servo? The frequency is dictated by what the servo signal is expected by the servo.

franklin97355
 
Posts: 20978
Joined: Mon Apr 21, 2008 2:33 pm
Location: Lacomb, OR.

Re: Adafruit pwm shield frequency for digital servo with Ard

by aive on Fri Oct 26, 2018 10:08 pm

Hello,

With DSM44, I'm expecting handle with reaching of position destination endpoint in maximal range 0-100 degree with 2-3 messages per second received to controller from control application. I'm using 5 digital and 3 regular servos on the shield, both works same way, without any failures with ~60 Hz, but I'm wondering, what should be reason for changing this value for example to 333hz as shown in specifications, because I have to note I suspect that I will running into problems with the .NET Serial class, because it is a C# desktop control application:

Torque(4.8V): 1.20 kg-cm (16.7 oz/in)
Torque(6.0V): 1.60 kg-cm (22.2 oz/in)
Speed: 0.09 sec (4.8V) │ 0.07 sec (6.0V)
Operating Voltage:4.8 ~ 6.0 DC Volts
Weight: 5.8 g (0.20 oz)
Bearing Type:1BB
Motor Type:Coreless Motor
Gear Type:Aluminum
Operating Temperature:-20℃~60℃
Working frequence:1520μs / 333hz
Size:19.6 x 8.0 x 24.3 mm ( 0.77 x 0.32 x 0.96 in)

aive
 
Posts: 8
Joined: Wed Oct 03, 2018 9:28 pm

Re: Adafruit pwm shield frequency for digital servo with Ard

by franklin97355 on Fri Oct 26, 2018 10:28 pm

For that servo there is no reason. For a servo that requires different specs it's there to modify.

franklin97355
 
Posts: 20978
Joined: Mon Apr 21, 2008 2:33 pm
Location: Lacomb, OR.

Re: Adafruit pwm shield frequency for digital servo with Ard

by 062400 on Fri Jan 18, 2019 3:08 am

My apologies if this question doesn't belong here as it is only somewhat related but I could not figure out hoe to start a new question.

Is there a way to set the PWM frequency with a method like pwm.setPWMFreq for the stepper motor library but while working with DC motors? I know that begin() can set the frequency but I need to change it in the main loop. Thanks

062400
 
Posts: 5
Joined: Sat Dec 22, 2018 2:38 am

Please be positive and constructive with your questions and comments.