_08_Buzzer2.ino View on Little Bird ↗
int lowTone = 400;
int highTone = 600;
const int ALARMSOUNDER = 3;     // the buzzer is on pin D3

void setup() {
  pinMode(ALARMSOUNDER, OUTPUT);
}

void loop() {
  tone(ALARMSOUNDER, lowTone, 500);   // low tone for half a second
  delay(500);
  tone(ALARMSOUNDER, highTone, 500);  // high tone for half a second
  delay(500);
}