To set a target speed in rpm, you need to know the following information:
- Gear ratio of the system, GR
- Number of current ripples per motor revolution, NR. This can be
found by taking the lowest common multiple, LCM, of the number of brushes
(NB) and the number of commutator segments (NC).
LCM can easily be calculated using an online calculator.
- Choose an appropriate W_SCALE value.
As an example, if desired target speed is 10000rpm, WSET_VSET value can be calculated
using the following equation :
Equation 5.
Assuming:
- NR=6
- W_SCALE = 00b (16 rad/s)
- Gear ratio = 50:1
Equation 6.
Thus, set WSET_VSET to 0x08.