🧑💻 Add standard BUZZ types
This commit is contained in:
committed by
Scott Lahteine
parent
f82b133595
commit
c49f26a7ae
@ -4920,18 +4920,10 @@ void CrealityDWINClass::Screen_Update() {
|
||||
}
|
||||
|
||||
void CrealityDWINClass::AudioFeedback(const bool success/*=true*/) {
|
||||
if (success) {
|
||||
if (ui.buzzer_enabled) {
|
||||
BUZZ(100, 659);
|
||||
BUZZ( 10, 0);
|
||||
BUZZ(100, 698);
|
||||
}
|
||||
else Update_Status("Success");
|
||||
}
|
||||
else if (ui.buzzer_enabled)
|
||||
BUZZ(40, 440);
|
||||
if (ui.buzzer_enabled)
|
||||
DONE_BUZZ(success);
|
||||
else
|
||||
Update_Status("Failed");
|
||||
Update_Status(success ? "Success" : "Failed");
|
||||
}
|
||||
|
||||
void CrealityDWINClass::Save_Settings(char *buff) {
|
||||
|
@ -1285,17 +1285,7 @@ void HMI_Printing() {
|
||||
|
||||
#include "../../../libs/buzzer.h"
|
||||
|
||||
void HMI_AudioFeedback(const bool success/*=true*/) {
|
||||
#if HAS_BUZZER
|
||||
if (success) {
|
||||
BUZZ(100, 659);
|
||||
BUZZ(10, 0);
|
||||
BUZZ(100, 698);
|
||||
}
|
||||
else
|
||||
BUZZ(40, 440);
|
||||
#endif
|
||||
}
|
||||
void HMI_AudioFeedback(const bool success/*=true*/) { DONE_BUZZ(success); }
|
||||
|
||||
void Draw_Main_Area() {
|
||||
switch (checkkey) {
|
||||
|
@ -276,11 +276,7 @@ void scroll_screen(const uint8_t limit, const bool is_menu) {
|
||||
#if HAS_BUZZER
|
||||
void MarlinUI::completion_feedback(const bool good/*=true*/) {
|
||||
TERN_(HAS_TOUCH_SLEEP, wakeup_screen()); // Wake up on rotary encoder click...
|
||||
if (good) {
|
||||
BUZZ(100, 659);
|
||||
BUZZ(100, 698);
|
||||
}
|
||||
else BUZZ(20, 440);
|
||||
if (good) OKAY_BUZZ(); else ERR_BUZZ();
|
||||
}
|
||||
#endif
|
||||
|
||||
|
Reference in New Issue
Block a user