In: Physics
"How to get the lineal acceleration of an step motor Nema 17?"
Acceleration/deceleration profile
To accelerate a stepper from a starting speed to a desired target speed, the current speed just needs to be changed at periodic intervals. Most engineers use microcontrollers to achieve stepper control. The most common implementation uses only two timers. The first is a steps-per-second (SPS) timer used to generate an accurate timing function for the stepping rate. The second is an acceleration timer used to alter the first timer on a periodic basis. Since the speed is being changed at timely intervals, in essence the angular velocity with respect to time (dv/dt) is being derived. This derivation is called acceleration, or how speed changes across time. Figure 2 shows an enlarged view of a typical microcontroller-based acceleration profile and what is happening as the stepper is accelerated towards a target speed. The SPS is the desired number of steps per second, or the stepping rate, at which the motor should move. The SPS timer must be programmed to issue pulses at this rate. Depending on the timer’s oscillator frequency, a typical equation is
timer oscillator SPS= timer register / SPS
where SPS_timer_register is a 16-bit number that tells the timer how long it takes to generate subsequent STEP pulses, and timer_oscillator is a constant of how fast the timer is running in megahertz.