Wanted some more details on why stalls happen and how to decrease number of occurrences.
I found that if the driver stalls, calling the reset method to clear status and reset the settings ends up resolving the stalling problem and allows the motor to continue running.
Would really appreciate some insight into how to help improve this. Utilizing the driver with an Arduino Nano Every and a NEMA 34 motor that can use up to 4.2 Amps (I have set the current limit to 4A). Also some advice on how to best utilize the STALL or BEMF ports would be great. Thanks!
Below is my reset() method:
void reset(){
// Reset the driver to its default settings and clear latched status
// conditions.
sd.resetSettings();
sd.clearStatus();
// Select auto mixed decay. TI's DRV8711 documentation recommends this mode
// for most applications, and we find that it usually works well.
sd.setDecayMode(HPSDDecayMode::AutoMixed);
// Set the current limit. You should change the number here to an appropriate
// value for your particular system.
sd.setCurrentMilliamps36v4(4000);
// Set the number of microsteps that correspond to one full step.
sd.setStepMode(HPSDStepMode::MicroStep16);
// Enable the motor outputs.
sd.enableDriver();
}