fredag den 2. januar 2009

Construction of the autonomus bat

Present: Thomas, Lars and Morten.

Goal:
To determine the basic design of the autonomus(in other words the computer player bat) . Subgoals include gaining knowledge about the effective range of the sensors in play, thus helping us to determine the length and width of our playing field.

Plan:
  • To construct a simple robot, similar to one of the Braitenberg vehicles, equipped with two lightsensors.
  • To experiment with the robot, to determine wether we can construct it in a way that it is able to center itself relative to a lightsource.
  • To experiment with the robot to determine the range at which it is able to center itself.
Activities:

Construction of the robot:
While brainstorming about the physical construction of the bat robots, we opted for a two engine, four wheels design due to the natural stability of this platform. To ensure directional stability we fixed the shafts between the two engines. At the one side of the vehicle we mounted a bat-like construction and on top of the bat we mounted 2x2 lightsensors in a 40 degree angel. To complete the design we added to ultrasonic sensors, one at each end of the vehicle.



After the initial construction, we wrote a simple test program, much like the code used in the Braitenberg vehicles. Using a table lamp as light source, we concluded that our vehichle was able position itself relative to this lightsource. But this simple test also showed us the importance of mounting the weels the same way all the way around and making sure that the tires are properly fitted on the rims, neglecting this will cause the bat to change direction inspite of the locked shafts.

Knowing that our ball would hardly be able to carry the tablelamp, we realised the need for a smaller lightsource and thus carried out the following experiment, to determine wether the light sensors we fitted would be able to recognize the small lego-lights at a distance.

Experiment with the lego-lights and the RCX light sensors:
The setup for this experiment consists of two RCX light sensors and one lego-light. We then marked distances from 0 to 150 cm with a 15 cm interval on the wall and lined the light up with the wall at the 0-marker. The next step was to measure the raw values produced by the lightsensors at the different distance markers. For this purpose we used a simple program for the NXT. We repeated the experiment with one light sensor, two light sensors and with one light sensor with minimal light in the room.



The following table shows the data obtained during the experiment:


Distance1 sensor2 sensors1 sensor, dark
15377270
30305957
45275249
60244946
75234541
90224438
105214135
120213934
135203834
150203833

The raw values of the background lighting was measured to 17 with one sensor and 32 with two sensors. From the collected data we conclude that we will be able to recognize the light at distances of up to 150 cm, which is more than we expected and actually makes the lego-light a possible light source for our game. Using two sensors instead of one more or less just doubled the values, but we chose to use two because this gives us a clearer distinction between our lightsource and the background lighting. The experiment also shows us that there is no reason to darken the playingfield to better recognize the lightsource.

One thing we noticed during the experiment is that the light seem to be concentrated in a rather narrow cone shape. This suggest that we will need multiple lightsources on the ball to make sure that our bat will be able to detect it when approaching in different angles.

Ingen kommentarer:

tagtagtag