Subject:
|
Re: 3T
|
Newsgroups:
|
lugnet.org.us.laflrc
|
Date:
|
Fri, 3 Mar 2006 16:11:24 GMT
|
Viewed:
|
1863 times
|
| |
| |
In lugnet.org.us.laflrc, John Brost wrote:
> Well, I've had some time on my hands, and being totally unhappy
> with my 3T robot I decided a re-build was in order.
I ran mine last night at a "family science night" for a school. Big hit,
although I *absolutely* need error checking in my code (playing against a robot
is easy - playing against a 5-year-old, with a couple of 4-year-olds constantly
hitting the "move completed" button, now that's hard...). Ironicly, two people
beat it - time to tune up the code to deal with really stupid,
nobody-would-ever-do-THAT type moves. Sigh...
> Taking a cue from the rest of you, and having rescued my touch
> sensors from my NEIRG robot, I decided to ditch the rotation sensors
> and go with touch sensors for both X & Y movements. Much, much
> better.
Ironicly, I had been thinking about switching to rotation sensors, before the
mass exodus in the other direction. I think at the first meeting mine was the
only one using touch sensors this way.
> I have noticed an interesting thing in Mindscript,
Warning: I don't know Minscript. Still, since when has that stopped me :) ?
The first thing I don't understand is why you seem to be watching the event
("scancomplete") in a tight wait loop ("wait until scancomplete"). In NQC (and
the basic firmware), there's a special way of monitoring an event that gives
very prompt (immediate) response. I'm not sure if you are invoking this ability.
> Here's my workaround... insert a 1/2 second wait command just
> before the if B = 0 statement.
But that means for every cell scanned, you've added a 1/2 sec pause. I wish I
knew the answer to your original question, but at least put the 1/2 sec wait
after the "set scandone = 1" within the "If A = 1" statement. That way it only
executes the (time-wasting) pause if it has found a block.
> when it returns home, the CurX and CurY values have
> already been reassigned to the location of B (1,2)
Now I'm really confused. In the code fragment you posted, CurX & CurY are
*immediately* both set to zero if a block is found. Are you talking about some
other variables?
--
Brian Davis
|
|
Message has 1 Reply: | | Re: 3T
|
| In lugnet.org.us.laflrc, Brian Davis wrote: <snip> (...) I don't know if I'm using the most efficient method either, but from what I have found... Tasks are run in parallel. If I start a task (the scan task) my main code will continue to run at the (...) (19 years ago, 3-Mar-06, to lugnet.org.us.laflrc)
|
Message is in Reply To:
| | 3T
|
| Well, I've had some time on my hands, and being totally unhappy with my 3T robot I decided a re-build was in order. Probably an 85% - 90% rebuild. About the only thing that wasn't touched was my cube magazine & the dropper mechanism. Everything else (...) (19 years ago, 3-Mar-06, to lugnet.org.us.laflrc)
|
9 Messages in This Thread:
- Entire Thread on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
This Message and its Replies on One Page:
- Nested:
All | Brief | Compact | Dots
Linear:
All | Brief | Compact
|
|
|
|