Skip to content

Instantly share code, notes, and snippets.

Embed
What would you like to do?
/*
2 pots 1 speaker
BOM
Arduino Uno
10k A0
10k A1
Pin 13 is output
*/
void setup() {
pinMode(LED_BUILTIN, OUTPUT);
}
void loop() {
for (int j = 0; j < 5; j++)
{
int i = analogRead(1) / 16 ;
delay ( i);
digitalWrite(LED_BUILTIN, HIGH);
delay ( i);
digitalWrite(LED_BUILTIN, LOW);
}
delay (analogRead(0) / 2 );
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment