Selecting the right sensor is not a strict process. This is about eliminating all the wrong choices based on a series of question aiming to eliminate first the technology that underlying the sensor and then the product that it doesn’t fit to the robot requirements.
When we use the word target, we refer in the same time at a small ball, at an object like a chair, or even at a human that stay in front of the robot.
To select the best sensor from a variety of products and manufacturers is a hard work especially when you’re a beginner and try to build a simple robot. In few words the sensor has to be selected in concordance with your targets size, shape and range. All of these three features have to be on the same line with the specification of the robot. But even so, it is hard to define the best sensor since the performance and precision of this depend on many factors.
A sensor is a sophisticated device that measures a physical quantity like speed or pressure and converts it into a signal that can be measured electrically. Sensors are based on several working principals and types of measurements. In our case almost all types of sensors emit signals and measure the reflection to make measurements.
There are many sensors that can be used for a simple application like line following (IR LED and a Photodiode, LED and LDR, etc.), but this is a simple case when a simple sensor can be selected. A complicated case is when you have to track an object and the budget is limited to purchase a mini computer like Raspberry Pi. In this case it can be used an ultrasonic sensor to scan from side to side till the sensor detect a drop in distance (at this stage it detects the edge of the object and from now on the sensor see only the background). The scanning process continues back to the point where the object is with left and right scanning.
This is one of the cases when expensive products can be replaced with cheap sensors.
In the following, you can explore the features of sensors that can be used for detecting and tracking a target.
Criteria to choose the right sensor
With so many models available on the market from various vendors would be very useful to know from where you can start. A good starting point is to know certain features, and some of them are given below:
- Type of Sensor – the presence of an object can be detected with proximity sensors, and there are several kinds of sensor technologies including here ultrasonic sensors, capacitive, photoelectric, inductive, or magnetic. Tracking objects can works using proximity sensors (ex. : ultrasonic sensors), or for advanced applications generally it is used image sensors (ex.: webcams) and vision software like OpenCV;
- Accuracy – the accuracy is very important in detecting and tracking objects, and it is useful to choose sensors with accuracy values between desired measurement margins;
- Resolution – a high resolution can detect smallest changes in the position of the target;
- Range – involves choosing the sensors based on measurement limits and compared with the desired detection range of the robot;
- Control Interface – to interface the sensor you have to know the types of the sensors. A wide range of sensors are 3-wire DC types, but there are many more types including 2-wire DC or 2-wire AC/DC;
- Environmental Condition – any sensor has its operational limits usually these are the temperature and humidity;
- Calibration – calibrating the sensors is an essential step in to ensure efficiency and more accurate measurement;
- Cost – depending on the budget allocated to a project, you can select the sensor or the sensors that can be used to build the robot;
Sensor classification based on property
- Proximity sensors – several sensor technologies are used to build proximity sensors: ultrasonic sensors, capacitive, photoelectric, inductive, or magnetic;
- Motion detectors – these sensors are based on infrared light, ultrasound, or microwave/radar technology;
- Image sensors – these are digital cameras, camera modules and other imaging devices based on CCD or CMOS technology;
Starting from the above information and combining with the below features for each type of sensor separately, you are now able to find the appropriate sensor and start building any robotic application.
Each sensor type has its characteristics that make from this little device better for a certain task or replaceable from other tasks. For example, an ultrasonic sensor works fine for solid objects and becomes lazy for soft or fuzzy objects. Also, some sensors are unable to make the difference between a static object and a human. All of these characteristics have to be clear before to choose the right sensor/sensors for your robot.
A light sensor can be included in the proximity sensor category, and it is a simple sensor that changes the voltage of Photoresistor or Photovoltaic cells in concordance with the amount of light detected. A light sensor is used in very popular applications for autonomous robots that track a line-marked path.
Different colors are reflected with different intensity, for example the orange color reflects red light in an amount greater than the green color, and this is the color sensor. This simple sensor is in the same range with light sensor, but with a few extra features that can be useful for applications where the robot has to detect the presence of an object with a certain color, or to detect the types of objects or the surfaces.
The touch sensor can be included in the proximity sensors category and are designed to sense objects at a small distance with or without direct contact. This sensor is designed to detect the changes in the capacitance between the on-board electrodes and the object making contact.
These sensors are designed to generate high frequency sound waves and receive the echo reflected by the target. These sensors are used in a wide range of applications and are very useful when it is not important the detection of colors, surface texture, or transparency.
Advantages of Ultrasonic sensors
- the output value is linear with the distance between the sensor and the target;
- sensor response is not dependent on the colors, transparency of objects, optical reflection properties, or by the surface texture of the object;
- these sensors are designed for contact-free detection;
- sensors with digital (ON/OFF) outputs have excellent repeat sensing accuracy;
- accurate detection even of small objects;
- ultrasonic sensors can work in critical conditions such as dirt and dust;
- they are available in cuboid or cylinder forms, which is better for a freedom design;
Disadvantages of Ultrasonic sensors
- ultrasonic sensors must view a high density surface for good results. A soft surface like foam and cloth has low density and absorb the sound waves emitted by the sensor;
- could have false responds for some loud noises such as air hoses;
- the ultrasonic sensors have a response time with a fraction less than other types of sensors;
- an ultrasonic sensor has a minimum sensing distance, which should be taken into consideration when you choose the sensor;
- some changes in the environment can affect the response of the sensor (temperature, humidity, pressure, etc.);
An infrared sensor measure the IR light that is transmitted in the environment to find objects by an IR LED. This type of sensor is very popular in navigation for object avoidance, distance measured or line following applications. This sensor is very sensitive to IR lights and sunlight, and this is the main reason that an IR sensor is used with great precision in spaces with low light.
Advantages of Ultrasonic sensors
- infrared sensors can detect infrared light over a large area;
- they can operate in real-time;
- the IR sensor uses non-visible light for detection;
- they are cheap sensors;
Disadvantages of Ultrasonic sensors
- this sensor is very sensitive to IR lights and sunlight;
- it has a weakness to darker colors such as black;
The sonar sensor can be used primarily in navigation for object detection, even for small objects, and generally are used in projects with a big budget because this type of sensor is very expensive. This sensor has high performances on the ground and in water where it can be used for submersed robotics projects.
A laser light is very useful for tracking and detection a target located at a long distance. The distance between sensor and target is measured by calculating the speed of light and the time since light is emitted and until it is returned to the receiver.
A laser sensor is very precise in measurement and in the same time is very expensive.
Most popular combination for detection and tracking an object or detecting a human face is a webcam and the OpenCV vision software. This combination may be the best in detection and tracking applications, but it is necessary to have advanced programming skills and a mini computer like a Raspberry Pi.
Using an image sensor can be built a wide range of applications, and some of these are listed below:
- face detection and tracking;
- tracking and detecting objects in colors;
- detect specific shapes in images;
- detect corners of triangles from an image;
- detect the position of an object on 2D surfaces;
- it can acquires and prioritizes targets;