Unify buzz methods as MarlinUI::buzz (#14803)

This commit is contained in:
Ludy
2019-08-20 09:01:37 +02:00
committed by Scott Lahteine
parent 29c12905f5
commit 05995d1fd6
12 changed files with 83 additions and 72 deletions

View File

@ -157,6 +157,8 @@ void PrintCounter::loadStats() {
#endif
#if HAS_BUZZER && SERVICE_WARNING_BUZZES > 0
if (doBuzz) for (int i = 0; i < SERVICE_WARNING_BUZZES; i++) BUZZ(200, 404);
#else
UNUSED(doBuzz);
#endif
#endif // HAS_SERVICE_INTERVALS
}

View File

@ -68,7 +68,7 @@
#include "tool_change.h"
#endif
#if HAS_BUZZER && PIN_EXISTS(BEEPER)
#if USE_BEEPER
#include "../libs/buzzer.h"
#endif
@ -749,7 +749,7 @@ int16_t Temperature::getHeaterPower(const heater_ind_t heater_id) {
inline void loud_kill(PGM_P const lcd_msg) {
Running = false;
#if HAS_BUZZER && PIN_EXISTS(BEEPER)
#if USE_BEEPER
for (uint8_t i = 20; i--;) {
WRITE(BEEPER_PIN, HIGH); delay(25);
WRITE(BEEPER_PIN, LOW); delay(80);