Добавлена команда для зуммера
This commit is contained in:
parent
d2b04d663e
commit
a6e937e6d3
7
UsbTitle/UsbTitle.ino
Executable file → Normal file
7
UsbTitle/UsbTitle.ino
Executable file → Normal file
@ -23,6 +23,7 @@ void setup() {
|
||||
lc.setIntensity(0,0);
|
||||
/* and clear the display */
|
||||
lc.clearDisplay(0);
|
||||
pinMode(3, OUTPUT);
|
||||
delay(1000);
|
||||
}
|
||||
|
||||
@ -65,6 +66,12 @@ void loop() {
|
||||
}else{
|
||||
lc.shutdown(0,true);
|
||||
}
|
||||
}else if (lastCmd == 0x7a){ // команда z0..f
|
||||
if (lastRead == 0x30){
|
||||
noTone(3);
|
||||
}else{
|
||||
tone(3, 100*(lastRead-0x30));
|
||||
}
|
||||
}
|
||||
lastCmd = 0xFF;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user