Subject:
|
NXT Program: How to avoid stop-and-go?
|
Newsgroups:
|
lugnet.robotics
|
Date:
|
Thu, 20 Dec 2007 22:22:12 GMT
|
Original-From:
|
bigboss97 <BIGBOSS97.GEO@stopspammersYAHOO.COM>
|
Viewed:
|
5154 times
|
| |
| |
I've just started with my very first vehicle according to the instruction.
Then I added the distance sensor. So, my car will turn when it come too
close to an obstacle. I use a loop with distance as exit condition, i.e. the
loop repeats the forward block bit by bit. Therefore I'm getting a
stop-and-go effect.
My question: How can I move in a constant speed and check the distance at
the same time?
thanks
Phuoc
--
View this message in context: http://www.nabble.com/NXT-Program%3A-How-to-avoid-stop-and-go--tp14446433p14446433.html
Sent from the LEGO Robotics mailing list archive at Nabble.com.
|
|
Message has 1 Reply: | | Re: NXT Program: How to avoid stop-and-go?
|
| (...) Try a Move block set to "unlimited": that will turn the motors on and let them run. Then have a Wait block to wait for the US sensor to report an object, or something similar inside a Loop. When an object (like a wall) is detected, the next (...) (17 years ago, 21-Dec-07, to lugnet.robotics)
|
10 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|