Thursday, 13 December 2007

End Course Project - Sound sensor general tests 2


Date: 13.12.2007
Duration of activity: 4 hours
List of participants: Alessandro, Daniela, Samuele
Goal of the day: investigate on multipath fading problems of previous tests, and on frequency discerning capability of sound sensors.

In previous session we thought that the unreliability of sound sensor for certain frequencies was due to multipath fading. Since this strange behavior showed only for some frequencies, we thought that using sounds with more than a single frequency we wouldn't get the same effect.
So, we tried a test similar to the previous, but using square waves, because they are made up by more frequencies (all odd harmonics).
We used our pc as sound source again, but this time with a synthesizer software, configured with a square wave sample.

These are results we obtained with the sound source distant 50cm from the sensor
do3 -> 5
re3 -> 6
mi3 -> 7
fa3 -> 9
sol3 -> 9
la3 -> 12
si3 -> 13c

do4 -> 11
re4 -> 11
mi4 -> 11
fa4 -> 17
sol4 -> 12
la4 -> 14
si4 -> 20

do5 -> 15
re5 -> 17
mi5 -> 19
fa5 -> 17
sol5 -> 17
la5 -> 20
si5 -> 21

do6 -> 21
re6 -> 14
mi6 -> 20
fa6 -> 19
sol6 -> 17
la6 -> 20
si6 -> 17

and these at distance of 100cm
c4 do -> 4
c4 re -> 7
c4 mi -> 7
c4 fa -> 8
c4 sol -> 9
c4 la -> 11
c4 si -> 11

c5 do -> 11
c5 re -> 19
c5 mi -> 23
c5 fa -> 15
c5 sol -> 7
c5 la -> 13
c5 si -> 14

As it can be easily seen, even if these sounds are not made up by a single frequency, they are affected by the same problem, since there is no smooth change between values.
For some reason with square waves we got very low values, even if we used the sound volumes of the previous test.
We obtained constant values for a wide range of notes, and then we got changes that don't seem to follow any regular function.
In addition to this, sometimes sampling continuously same certain notes, we got really fuzzy results.

Conclusion
Using square waves we got worst results than the previous test.
We think that it is not possible to recognize the frequency range of a sound source, by computing only sound sensor readings in a naive way.
If we still want to do that, we must implement a Fourier transform algorithm, but then we should face some other hardware restrictions, like NXT sensor sampling frequency, or computational capability.
Then we decided to drop the idea of discerning sound sources according to their frequency, even if we could come back to it later. We will use only amplitude of the signal as indication for distance and direction of sound.
Next tests to be done with sounds are only tests with multiple sound sources. We plan to do these tests with a sound follower robot we will build in next sessions, since its results will be easier to understand.

References
http://en.wikipedia.org/wiki/Square_wave

No comments: