Add lcd_buzz function to ultralcd.h so that non-LCD code can make use of lcd's buzzer.
Argument order of lcd_buzz was set to mirror that on tone(). Change default M300 frequency to something audible.
This commit is contained in:
@@ -946,6 +946,13 @@ void lcd_buttons_update()
|
||||
lastEncoderBits = enc;
|
||||
}
|
||||
|
||||
void lcd_buzz(long duration, uint16_t freq)
|
||||
{
|
||||
#ifdef LCD_USE_I2C_BUZZER
|
||||
lcd.buzz(duration,freq);
|
||||
#endif
|
||||
}
|
||||
|
||||
bool lcd_clicked()
|
||||
{
|
||||
return LCD_CLICKED;
|
||||
|
||||
Reference in New Issue
Block a user