We define complex sensors as those that provide their information in a way that can’t be read with digitalRead() or analogRead() alone. These sensors usually have a whole circuit inside them, possibly with their own microcontroller. Some examples of complex sensors are digital temperature sensors, ultrasonic rangers, infrared rangers, and accelerometers. One reason for this complexity might be to provide more information or more accuracy; for example, some sensors have unique addresses, so you can connect many sensors to the same wires and yet ask each one individually to report its data.

Fortunately, Arduino provides a variety of mechanisms for reading these complex sensors. You’ll see some of them, in “Testing the Real Time Clock (RTC)” to read a Real Time Clock, and in “Testing the Temperature and Humidity Sensor”, to read a Temperature and Humidity Sensor.

You can find more examples on the Arduino website by searching for “tutorials” and under Community->Project Hub.

Tom Igoe’s Making Things Talk, 3rd edition has extensive coverage of complex sensors.

figure 5 8 gs

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *