To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.robotics.rcx.nqcOpen lugnet.robotics.rcx.nqc in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 Robotics / RCX / NQC / 963
962  |  964
Subject: 
Re: advice for game of tag?
Newsgroups: 
lugnet.robotics.rcx.nqc
Date: 
Mon, 5 Feb 2001 15:01:27 GMT
Viewed: 
1971 times
  
In lugnet.robotics.rcx.nqc, Rik Blok writes:
Hi, I've got 2 bots that I want to play tag with each other.  The
challenge is that I want them to see each other at a distance.

Hi Rik,

I am familiar with the idea of "Tag" but I don't understand what this means "to
see each other". Normally, it would be enough that a bot sends a message as
soon as it has hit the other.

Another problem: why do you use random numbers in the message?
If both bots are trasmitting and listening, the transmitter will most probably
receive his own message. How does he know it was his signal?

In general, it is not quite trivial, if you have 2 bots that are establishing
a continuous IR communication. What happens is that - depending on the geometry
of your working space - a "field" of IR messages due to different times of
travelling. This also happens if you send a message only once (this technique
is used in IR proximity detection).

The result is, that the bots are really receiving a lot of "spam" and you have
to "filter" for getting the true message by using the message number (e.g. bot
1 sends a 1, bot 2 send a 2). You will also loose some of the messages (the
real ones and some with early or late reflections).

I did some experiments (sorry, I don't have the code anymore)like this:
after both bots were started, they sent messages: bot 1 from 1 to 100, bot 2
from 101 to 200. Each message was sent once and 20 messages were sent in a
second. After having sent a message, the bot was listening until he detected a
valid message (i.e. bot 1 was looking for 101 to 200, bot 2 for 1 to 100). The
valid message was stored in the datalog. I downloaded the datalog and was
surprised how few "hits" they had. I think that I reduced the message per
second to 10 after this ...

If you should do such an experiment, please let me know the results.
Unfortunately, I don't have the time to do something with Mindstorms  :-((

Best regards
Bernd



Message has 1 Reply:
  Re: advice for game of tag?
 
(...) The firmware knows what (and when) it has just sent, so it can distinguish between incoming and outcoming messages. (...) That's not exactly true. Infrared light travels at the speed of light (300000 km/s), so you can safely ignore delays. (...) (24 years ago, 5-Feb-01, to lugnet.robotics.rcx.nqc)

Message is in Reply To:
  advice for game of tag?
 
Hi, I've got 2 bots that I want to play tag with each other. The challenge is that I want them to see each other at a distance. I'm working on some code to combine the IR ports with the light sensors (which can detect IR) as follows: 1) each sends (...) (24 years ago, 3-Feb-01, to lugnet.robotics.rcx.nqc)

3 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
    

Custom Search

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