Thursday, February 23, 2006

NXT Room Positioning System

It is often very useful for a robot to position itself in its environment. Animals and we use advanced vision and processing to accomplish this. These options are currently not open for Lego Mindstorms NXT robots.

However, GPS shows us that cars can position themselves with high accuracy without complex vision, by triangulating their position against known fixed positions (in the sky). But GPS doesn't have the accuracy needed for our robots, and it doesn't work indoors.

How could we create a Room Positioning System? In a past project, my team and I created something similar: a absolute tracking system. The robot shown in the image had to follow the person by tracking the position of the transmitter. The transmitter was worn by a person, and the project's objective was to drive a golf caddy over a golf court.

The robot used a sonar transmitter, and two sonar receivers. Sonar is based on ultrasound, which is sound. The speed of sound is a lot slower than the speed of light, and can be measured even at short distances. To calculate how long sound traveled, you need to know when it started flying, and when it arrived. That is why the black sending box sent out a radio signal and sonar signal at the same time. The radio wave (at the speed of light) was near the robot immediately, while the sonar reached it slightly later. That time difference provides a very good measure of the distance between the robot and the beacon.

Building on the previous concept, we could build an indoor position system by creating some sort of light house. The lighthouse is controlled by an NXT brick. The lighthouse sends out a sonar bliep, and a Bluetooth message at the same time. Since the NXT brick will not send them exactly at the same time, we need to measure the time it takes between sending the sonar signal and the Bluetooth, as corrective measure. Like a real lighthouse, a motor would rotate the sonar continuously. The Bluetooth message would contain the current rotational angle of the lighthouse. Because of this rotational information, the receiving robot needs only one sonar receiver instead of two.

The receiving robot would receive this information. By calculating the flight time of the sonar signal, it can measure the distance to the lighthouse. By using the angle encoded in the Bluetooth signal, also knows the direction it is currently on relative to the Lighthouse. Using polar coordinates, it has an absolute position where it is in the room.

To calculate the flight time, the robot must listen for both the Bluetooth message, and the sonar bliep. The robot will have to compensate for calculation times. Because the Bluetooth protocol is a multilayered protocol that takes time to calculate, the approach can gain a crucial amount of precision by timing to the low level interrupt that signals the arrival of the radio message, and using that timing if the message turns out to come from the lighthouse.

There are a number of complications, the main one being that sound (including sonar) bounces of walls, creating shadow reflections. Therefore, the Lighthouse must not signal to fast, for the reflection to die out. The robot must also take into account deadreckoning measurements to understand the likeliness of the signal. That implies that the lighthouse is used as a continuous callibration of deadreckoning. Instead of deadreckoning, a digital compass sensor could also be used.


At September 27, 2006 4:11 PM , Anonymous Anonymous said...

Is it not possible to make a bluetooth GPS talk to the NXT and then get the position from this GPS? Would be much easier and the time lost will be reduced considerably

At May 10, 2007 5:14 PM , Anonymous Anonymous said...

using GPS is possible, but:

- you cannot use a GPS sensor in rooms. (The sensor must have a direct connection to 3 satellites.)

- GPS has an accuracy of about 0.5 m for "normal" users.


Post a Comment

Subscribe to Post Comments [Atom]

Links to this post:

Create a Link

<< Home