Fixes TMC compilation error

This commit is contained in:
Panayiotis Savva 2018-01-15 12:24:02 +02:00
parent a27fa80a7e
commit ad500b01e0

View File

@ -376,7 +376,10 @@ void _tmc_say_sgt(const char name[], const uint32_t sgt) {
break;
case TMC_TPWMTHRS_MMS: {
uint32_t tpwmthrs_val = st.TPWMTHRS();
tpwmthrs_val ? SERIAL_ECHO(12650000UL * st.microsteps() / (256 * tpwmthrs_val * spmm)) : SERIAL_CHAR('-');
if (tpwmthrs_val)
SERIAL_ECHO(12650000UL * st.microsteps() / (256 * tpwmthrs_val * spmm));
else
SERIAL_CHAR('-');
}
break;
case TMC_OTPW: serialprintPGM(st.otpw() ? PSTR("true") : PSTR("false")); break;