diff --git a/Marlin/speaker.h b/Marlin/speaker.h index 0bc2a9a9f601c6c5d55d4eb58954e6a0d6c3f278..e3a0f9670b1c11d97726d2bb1a3b6687b0543f65 100644 --- a/Marlin/speaker.h +++ b/Marlin/speaker.h @@ -70,7 +70,7 @@ class Speaker: public Buzzer { this->state.period = 1000000UL / this->state.tone.frequency; this->state.counter = - (this->state.tone.counter * 1000L) / this->state.period; + (this->state.tone.duration * 1000L) / this->state.period; this->state.period >>= 1; this->state.counter <<= 1;