Browse Source

-disalbe beeper if BEEPER_PIN = -1

pull/1/head
Christian Thalhammer 13 years ago
parent
commit
5edef148fe
  1. 34
      Marlin/ultralcd.pde

34
Marlin/ultralcd.pde

@ -130,13 +130,16 @@ void beep()
{ {
//return; //return;
#ifdef ULTIPANEL #ifdef ULTIPANEL
pinMode(BEEPER,OUTPUT); if (BEEPER > -1)
for(int8_t i=0;i<20;i++){ {
WRITE(BEEPER,HIGH); pinMode(BEEPER,OUTPUT);
delay(5); for(int8_t i=0;i<20;i++){
WRITE(BEEPER,LOW); WRITE(BEEPER,HIGH);
delay(5); delay(5);
} WRITE(BEEPER,LOW);
delay(5);
}
}
#endif #endif
} }
@ -144,13 +147,16 @@ void beepshort()
{ {
//return; //return;
#ifdef ULTIPANEL #ifdef ULTIPANEL
pinMode(BEEPER,OUTPUT); if (BEEPER > -1)
for(int8_t i=0;i<10;i++){ {
WRITE(BEEPER,HIGH); pinMode(BEEPER,OUTPUT);
delay(3); for(int8_t i=0;i<10;i++){
WRITE(BEEPER,LOW); WRITE(BEEPER,HIGH);
delay(3); delay(3);
} WRITE(BEEPER,LOW);
delay(3);
}
}
#endif #endif
} }

Loading…
Cancel
Save