hej
i was wondering if it is possible to record sound from a microphone ( piezo ) and play it back via a speaker ( also piezo ).
i managed to grab the input from a pre-amplified piezo sensor via a digital in pin and play it back through a digital out. as you can imagine it sound very rough.
has anyone ever done something like that more successfully?
maybe even via the analog input?
int inputPin = 2;
int outputPin = 3;
void setup() {
pinMode(outputPin, OUTPUT);
pinMode(inputPin, INPUT);
}
void loop() {
digitalWrite(outputPin, digitalRead(inputPin));
}