New answers tagged

1

From the code you linked to, it appears the SPI port is completely controlled by the software: void loop() { ... msb = SPI.transfer(cmd); lsb = SPI.transfer(0); ... } This means that the timing of the SPI transaction (when exactly it starts) and, by extension, the timing of the ADC conversion, is dependent on the timing of your code ...


2

The problem is repeat: if(digitalRead(ProxSensor==LOW)) goto repeat; ProxSensor==LOW is false so 0. you read the pin 0 and the outcome is random. The surrounding wiring can affect that. If digitalRead(0) is zero the wav starts playing immediately again. At least use while (digitalRead(ProxSensor) == LOW);


0

The TMRpcm and one of your other libraries might use the same timer on Uno which causes one of them to break. Either get a Arduino Mega which can run TMRpcm on TIMER3,4 or 5 or use libraries that don't require a timer.


1

As stated in other answers, sound recognition is completely out of the realm of what an Arduino can do, but recognizing a specific pitch is possible. However, contrary to previous answers, I would recommend against using an FFT. The FFT is the right tool when you need to get all the frequency components. It is, however, overkill when you want to look at a ...


0

No, you cannot recognize a song with an Arduino. It doesn't have enough computing power. I think most solutions, that recognize a song, are based on some kind of machine learning or similar, which is totally out of scope for an Arduino. For this you need a real processor like on a Raspberry Pi or similar Single Board Computers. Identifying a specific pitch/...


1

It sounds like you need to do Fourier analysis on the sound. (Breaking up the sound into its component frequencies.) Most Arduinos are based on AVR chips, which do not have hardware support for floating point math. They use software to do floating point, which makes them a poor choice for this sort of thing. There are FFT libraries for Arduino, but they ...


Top 50 recent answers are included