Microstep linearity correction, optimized wave compression.

Correction factor can be adjusted from 0.9 to 1.25 by 0.005 steps.
This commit is contained in:
Robert Pelnar 2018-02-17 19:58:40 +01:00
parent 57499dc6a0
commit dff8c29362
4 changed files with 126 additions and 28 deletions
Firmware

View file

@ -542,10 +542,10 @@ void dcode_2130()
}
else if (strncmp(strchr_pointer + 7, "wave", 4) == 0)
{
uint8_t fac200 = atoi(strchr_pointer + 11) & 0xfe;
uint8_t fac200 = atoi(strchr_pointer + 11) & 0xff;
if (fac200 < TMC2130_WAVE_FAC200_MIN) fac200 = 0;
if (fac200 > TMC2130_WAVE_FAC200_MAX) fac200 = TMC2130_WAVE_FAC200_MAX;
tmc2130_set_wave(axis, fac200);
tmc2130_set_wave(axis, 247, fac200);
tmc2130_wave_fac[axis] = fac200;
}
}