# A Simplified Acceleration Model

The logic in the `advance()`

function of the
Switec X25 library
steps the motor forward or backward one step, then computes the delay in
microseconds until the next step is due. This logic determines the acceleration curve and
maximum speed of the needle. My first cut at this
code used floating point arithmetic to model this as time/accel/velocity problem. The
motion was nice and smooth, but it was overkill, and consumes too many precious Arduino
compute cycles. When driving multiple motors, this will create an artificial ceiling on the
maximum motor speed.
I’ve rewritten that logic to use a simple lookup table instead.
This is a fairly obvious approach, but it was
reassuring to see similar approaches recommended in both the
VID 29 documentation
and the MCR MR1107 data sheet
.