To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.nxtOpen lugnet.robotics.nxt in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / NXT / 826
825  |  827
Subject: 
Re: stop task
Newsgroups: 
lugnet.robotics.nxt
Date: 
Wed, 25 Jul 2007 12:55:16 GMT
Viewed: 
22171 times
  
In lugnet.robotics.nxt, Elizabeth Mabrey wrote:

I hope my question does not start anything unpleasant.

It hasn't, Elizabeth - I'm not upset at John, and he knows *far* more about
programming than I do. I just wanted to point out that there are process where
abruptly "killing" a thread was one of the best solutions I ever found, due to
the speed with which things had to be done, and the fact that even under the RCX
standard firmware, there were times when some small multiple of 3 ms (about how
long a bytecode took) was far too long. When you are playing with 1 m/s line
followers on 3/4" width electrical tape, you can cross a line in about 20 ms, or
only 6 bytecodes worth of execution time. That's not much to deal with, and
requires either some remarkably tight loops, or an even faster system "under the
hood" that you can take advantage of. The other place I find it very helpful is
in rapid responses like Sumo - at the speeds current LEGO sumo robots operate
(again, in the m/s range), you need to respond to a ring edge detection
*immediately*... not just once a loop, even if the loop is processing a small
set of instructions.

It's just a pet peeve of mine, Elizabeth, because while it might not be the most
standard way of doing things, it is sometimes the fastest and most efficient.
And one I've really grownn to take advantage of and like on the RCX. The new FW
has taken away one of my most powerful toys :-).

As to the terminology thing, well... I use words to communicate, and I'm a
little bit looser with language perhaps than John is. Both styles have their
place, but I come from an environment where all too often people can so loose
themselves in terminology that they mis-communicate, because they expect the
word definitions to do it for them. The folks in my field who tend to be the
most successful are the ones who know the terminology, but also know that if
they subscribe to it as laws, they hobble both their understanding and their
communication. However, that's why you have a physics figure things out, *NOT*
(in many cases) design the resulting application. Perhaps it's a physicist vs.
engineer thing.

--
Brian Davis
(who really does type too much)



Message is in Reply To:
  RE: stop task
 
Everyone, Being fair in the judgement in using a global watchdog flag to terminate a task. Honestly, when I have a multi-threaded process, I have always used a watchdog type of flag, mutex, semaphore, etc. to signal a thread to terminate. I hardly (...) (17 years ago, 25-Jul-07, to lugnet.robotics.nxt)

6 Messages in This Thread:

Entire Thread on One Page:
Nested:  All | Brief | Compact | Dots
Linear:  All | Brief | Compact
    

Custom Search

©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR