Step/Dir is perhaps slightly better than PWM, but not much. It’s a bit more ‘deterministic’ than PWM, i.e. you can command a fairly precise speed & position, but it’s still another what I would call a ‘lowest common-denominator interface’. I.e. so simplistic that any fool can understand it, but at the same time it’s extremely restrictive for robotics applications - you have no idea what the load on your robot is, whether any axes are in fault, what the following error is and so forth. It’s also not great at commanding both high speed and high precision. But the worst thing about step/dir is that it is incremental and so any errors are cumulative (i.e. any transient noise spike on your step/dir signal would mean that your robot becomes out of calibration and requires homing again) but you wouldn’t know until it crashes into something.
Honestly, I think PWM input should be banned on ODrive - it lets people do silly things, treating it like a hobby ESC and lowering its usefulness to the same.
It will be quicker for you to write the code than it would to buy some RC kit, even if there’s a hobby shop across the road. Don’t be afraid of writing a few lines of code!
The ASCII interface for the ODrive is also extremely simple. A glance at the manual tells you that all you need to do to command a velocity is to send:
v 0 1000
on the UART, followed by a newline character (
and motor m0 will turn at exactly 1000 encoder counts per second. No faffing about scaling to min/max PWM values and trying to place zero in the middle.
That’s IT. It’s probably simpler to use than your daft ‘servo’ library.