Should this setup work with simplefoc?
Because it is only working in one direction.
Does anyone else have such a motor with external Hall sensors?
Is this the problem?
Console output:
MOT: Monitor enabled!
MOT: Init
MOT: Enable driver.
MOT: Align sensor.
MOT: sensor_direction==CW
MOT: PP check: OK!
MOT: Zero elec. angle: 1.05
if(motor.shaft_velocity > 1){
gain= 0.0045; // a gain factor - to try out
delta_angle_max = 1.2;
}
else if(motor.shaft_velocity < -1){
gain= 0.0025; // a gain factor - to try out
delta_angle_max = 0.5;
}
float delta_el_angle = _constrain(motor.shaft_velocity*gain, -delta_angle_max ,delta_angle_max );
// set the new angle
motor.zero_electric_angle = zero_angle_toremember- delta_el_angle ;