RC bldc/brushless esc

More
16 Jan 2024 01:03 #290813 by OBEY
RC bldc/brushless esc was created by OBEY
could anyone share the configuration for rc bldc esc?
at the moment my configuration, and the problem is that the motor calibration occurs only with M03 S2000
# spindle setup
# PC0:PWM
loadrt pwmgen output_type=0
addf pwmgen.make-pulses base-thread
addf pwmgen.update servo-thread
setp arisc.pwm.3.freq-cmd    50.0 # Hz
setp arisc.pwm.3.dc-scale    24000.0 # max RPM
setp arisc.pwm.3.pwm-port    2 # PC
setp arisc.pwm.3.pwm-pin     0
setp arisc.pwm.3.dir-port    0 # PA
setp arisc.pwm.3.dir-pin     3
setp arisc.pwm.3.dir-invert  1
net s-rpm  spindle.0.speed-out  arisc.pwm.3.dc-cmd
net s-en   spindle.0.on         arisc.pwm.3.enable  arisc.gpio.PC4-out

Please Log in or Create an account to join the conversation.

More
16 Jan 2024 01:52 - 16 Jan 2024 01:54 #290815 by PCW
Replied by PCW on topic RC bldc/brushless esc
If this is like a standard RC servo, you would need an offset and odd scaling
because the PWM range is from 2% to 4% duty cycle for 0 to full scale range.
(1 to 2 ms at 50 Hz)

So basically if you have a scale of 1200000 and add an offset of 24000
with the offset component would  be close for a 0 to 24000 input range
giving a PWM range or 2 to 4% = 1 to 2 ms at 50 Hz

Note that this reduces the PWM resolution by a factor of 50 which is why
RC PWMgens are typically implemented differently than normal PWMgens.
Last edit: 16 Jan 2024 01:54 by PCW.

Please Log in or Create an account to join the conversation.

Time to create page: 0.088 seconds
Powered by Kunena Forum