(this question is likely similar to another recent question titled "How to eliminate the effect of reverse ampere force"
I have a need to limit torque (basically current) in one direction differently from the other direction of motion.
I am using lab05b and also lab10a (which adds overmodulation). Both work well but I have not found a way to limit torque differently in one direction of rotation versus the other.
I have found and changed settings outMin,outMax in ctrl.h, which does allow me to limit torque differently for different directions, but this limits the modulation instead of the torque setpoint.
Limiting the modulation severely limits the speed, which is not useful to me. I simply want to limit, the negative torque setpoint output of the speed PI controller differently from the positive torque setpoint output.
It may be that I simply stumbled into the wrong outMin to limit, but I have hard a hard time trying to understand the program flow because so many functions are inline so I cannot step through them with breakpoints.
Is there any documentation for these lower level functions?
Can you point me to the general area where I should be experimenting in the code?
Thanks