Hello,
i bought a microfon and try to test it, i found this test code but the code shows an error but i dont get it so i hope somebody can help me with it.
The Code:
int sensorPin = A5; // select the input pin for the potentiometer
void setup ()
{
Serial.begin (9600);
}
void loop ()
{
sensorValue = analogRead (sensorPin);
delay (500);
Serial.println (sensorValue, DEC);
}
The error:
Arduino: 1.8.5 (Windows Store 1.8.10.0) (Windows 10), Board: "Arduino/Genuino Uno"
C:\Users+++\Desktop\test\test.ino: In function 'void loop()':
test:8: error: 'sensorValue' was not declared in this scope
sensorValue = analogRead (sensorPin);
^
exit status 1
'sensorValue' was not declared in this scope