Closed gautamjain closed 4 years ago
That call is really a safety measure - particularly for when testing. The 5130 itself disables output after a period when it stops which is OK in most situations.
If you want to add an option to the constructor for chipdrive - disable_on_stop or similar which goto and the other higher level commands check before calling enableOutput(False) I',m happy to pull that later. That way the it can work either way.
Ok that sounds good. I'll work on that.
I'm expecting new kit for a project next week so I'll be doing some more work on this soon - I've pulled the changes ion the meantime
Currently, motor driver output is always turned on right before moving and then turned off after the move finishes.
This doesn't work well in situations when you want the driver to apply a holding torque even when the motor is at standstill.
Would you be ok if
enableOutput()
was removed fromsetspeed()
,goto()
, etc.? Instead it would have to be explicitly called when needed.Alternatively, if you prefer leaving
chipdrive.py
as is, I can create a new 'drive' in a separate file.