Asked

Moving Head Sound Detector

How do I get my sound detectors to give constant voltage readings on the ADC Graph?  I am using the two detectors to see where the loudest signal came from then move the robot's head toward the loudest.

I have read all I can find on Synthiam including the Community and Tutorials but can not see anything that will solve my problem.

The problem is I can't get a consistent signal from in the ADC Graph.  The line graph will jump up and down even with the a constant audio signal coming from my sound generator.  Since their is no sound consistency I can't write script to make the head move.

Is my problem having to do with the wrong sound detectors or the way the information is handled by the Ez-Robot program?


Related Hardware EZ-B IoTiny
Related Controls ADC Graph ADC Value ADC Meter

ARC Pro

Upgrade to ARC Pro

Subscribe to ARC Pro, and your robot will become a canvas for your imagination, limited only by your creativity.

#17  

Hi. Richard gave me the script that would help me make the sound sensor work.

Here is the script:

:loop $left=GetADC(adc0) $middle=GetADC(adc1) $right=GetADC(adc2)

if ($left>$middle)

if ($left>$right) servo(D0,1) // left is highest sleep(2000) goto(loop) endif

endif

if ($middle>$right) servo(D0,90) // middle is highest ELSE servo(D0,180 // right is the highest endif

sleep(2000) goto(loop)

I would like to understand this script.  Where can I go to understand the format of the loop script.  I have been looking on Synthiam to understand loop but to no avail.  I know it loops scripts but I do not understand all the loops and their inset protocol .  I really want to write my own scrips using the loop script but right now I do not understand it and don't know how to find how to use it.  Please Help.

#18  

Thanks for ideas and help.

I am still trying to use Richards script to make my robot Max turn his head toward who is talking.  Richards script helped me a lot.  I still cannot get it to work but I am working on it.

https://www.youtube.com/watch?v=r8qBdeMNlJA&feature=youtu.be

Above is a my YouTube video that will show you that the three sensors are not peak coordinated therefor I cannot compare voltages at the instance sound is made.  I also added a steady tone of 1141 Hz, from my Tone Generator which should show a steady tone on the three Read ADC gauges. If I could get a steady tone on my gauges,  I could balance the gauges using the sensitivity on each sound detector.  Sensors are Sound Detectors by RobotDyn.  I could then use the steady tone from my Tone Generator to balance them.

Here is a pictures of my setup.

User-inserted image

Thanks for all the help.  Please give me some direction to go.

Ellis