Alok, Have your team put the ultrasonic sensor block within a time loop and also use a switch.  That way you can make it either detect the object/wall correctly or have it quit the loop after specified time, whichever happens first.

Sachin Aradhey
#3629 Nanobots
Harrisonburg, VA.

On Fri, Nov 19, 2010 at 9:10 AM, Alok Jain <[log in to unmask]> wrote:
Hi!
My team realized that ultrasonic sensor is not consistent when used with the wait block. Sometimes it seemed to be not stopping at all. I am talking about big objects and the side wall. I did a little experiment and there seems to be a difference of 15 cm (at power level 60). i.e. if I want the robot to stop at 30 cm, it actually stops when distance is 15 cm.
I tried changing the sensor and also putting the sensor lower, but still the same result. The reading in the sensor, when robot is stopped, shows up correctly. It is only while stopping it is acting up. At power level 75 and higher it totally misses the stop point. Did anyone else face this problem in the past? Am I doing something wrong ?
Here are my questions:

1) how high should the Ultrasonic sensor be placed from the ground?
2) Is there something I need to caliberate or change in the program ?

My team is competing on Sunday, so any help is highly appreciated.

Thanks,
Alok


To UNSUBSCRIBE or CHANGE your settings, please visit https://listserv.jmu.edu/archives/vadcfll-l.html and select "Join or leave the list".
VADCFLL administrative announcements are sent via VADCFLL-ADMIN-L. Visit https://listserv.jmu.edu/archives/vadcfll-admin-l.html to subscribe.


To UNSUBSCRIBE or CHANGE your settings, please visit https://listserv.jmu.edu/archives/vadcfll-l.html and select "Join or leave the list".
VADCFLL administrative announcements are sent via VADCFLL-ADMIN-L. Visit https://listserv.jmu.edu/archives/vadcfll-admin-l.html to subscribe.