April 08, 2013: As I've shown previousl, the purpose of this robot is to follow its user, and I imagined two instruments for implementing that:
1) a global localization method, using GPS. The PROs are that we can place a GPS module on the robot, and the user can have a mobile phone with its own GPS module. The phone can establish a connection to the robot using Bluetooth, and send the user coordinates periodically. Then the robot can calculate the path it needs to run, to get in close proximity of the user, and follow him/her. Sounds good, but the CONs are bad: first, the GPS errors are too big to allow us to make the robot follow the user; it would rather jump like a crazy monkey all around the user, and this is the best scenario. Another issue is also the GPS signal which is poor or unavailable indoors.
If we place a stationary GPS receiver, here's how the GPS coordinates look like:
As you can see, despite the fact our GPS receiver is stationary, the localization data we receive has a tolerance of a few meters or even tens of meters, placing us on a disc surrounding the real position. This is inappropriate for the purpose of this work, so I have decided to find different means of robot positioning and orientation; this number -2- below:2) The local method will use a closed system for localization, formed of only the robot itself, the user, and a signaling beacon. Normally the user will carry a signaling beacon (ultrasonic, infrared, radio, etc), which the robot will "see" and follow. Easy to say, doing it is of course much harder, as we need a smooth robot movement, so a lot of error compensation and fuzzy logic must be involved.Recently I made some excellent progress using ultrasounds as a transmission method, to create a simple beacon detector. You can read more on it here.
The user needs to carry this tiny, low power ultrasonic beacon which the robot should be able to "hear" and use the signal to navigate to the target, and follow it.
These wonderful modules will not only return a signal when ultrasounds are detected, but the output amplitude is directly proportional with the actual distance to the beacon. So we'll know both where the beacon is, and how far.
Given these tools, there are several ways of implementing the working mechanism:
a) using a single ultrasonic receiver, placed in front of the robot: the rover will need to rotate until it detects a maximum level of signal. Then it should move forward until the detected signal reaches a given threshold (so it will not hit the user, but stop right before him/her). It doesn't really work well, as the software gets overcomplicated and the results are not as good as expected.
b) similar to a), but use a servo motor to rotate the ultrasonic sensor instead of rotating the entire robot. When the maximum signal is detected, the robot should turn towards the source, and begin moving forward . It still doesn't solve many of the issues found with a)
c) using two ultrasonic receivers, placed some space apart, in the frontal part of the rover. Now we can make differential measurements, so it's easy to know from which part is the signal coming from, as the corresponding sensor will have higher readings. The robot can now directly turn towards the beacon, and follow the forward direction while the two sensors give approximately similar readings. If the right sensor output increases, then it means the robot needs to turn right, to face the beacon and continue moving forward. Same case for left. A similar approach has been used in a project by Andrew Wiens .
The ultrasonic sensors already return an output signal which is a function of the distance to the beacon / user. This can be used to measure the distance. If greater accuracy is required, we can involve infrared light in the process:
- the beacon sends a set of 38KHz modulated Infrared pulses marking moment of time t0
- the beacon immediately sends out the ultrasonic pulses
- the receiver which is a few meters from the beacon, receives the infrared pulses practically instantaneously and knows the time is t0 (using a TSOPXX38)
- the receiver registers the incoming ultrasonic pulses at the time t1, where t1>t0. By using the speed of sound in air, we can get the exact distance to the beacon.
All in one we use light to signal the start for counting, and we stop when the ultrasonic waves reach the destination. More on this here, here or here.