added current monitoring to pcb, many code fixes for the protocol / feed control logic, completely reworked diagnostic tool

This commit is contained in:
janik
2026-03-30 17:46:52 +07:00
parent 33426570bb
commit a69055b0d4
119 changed files with 31311 additions and 26899 deletions

View File

@@ -82,8 +82,8 @@ static inline pid_motor_cmd_t pid_update_motor(pid_i32_t *pid,
int32_t error = setpoint - position;
// Deadband: if within ±3 counts, hold position and reset integrator
if (error >= -3 && error <= 3) {
// Deadband: if within ±1 count (~0.005mm), hold position and reset integrator
if (error >= -1 && error <= 1) {
pid->integrator = 0;
pid->prev_error = 0;
pid->last_output = 0;