Global Sources
EE Times-Asia
Stay in touch with EE Times Asia
?
EE Times-Asia > Sensors/MEMS
?
?
Sensors/MEMS??

DiY IoT: Digging deep on sensors

Posted: 02 May 2016 ?? ?Print Version ?Bookmark and Share

Keywords:sensors? CC3200? LaunchPad? accelerometer? thermopile?

I am back with another instalment for the CC3200 series!

If you haven't read three of the previous posts on the TI LaunchPad hardware and the Energia development environment, I suggest you do so now. We also talked about WiFi and made a small program that allows you to connect your board to home network, including a few adjustments to core WiFi library. Today we will make a small break from connectivity and talk about sensors in general, and those that come bundled with CC3200 LaunchPad in particular. I can easily admit that sensors and data acquisition and processing are two of my favorite subjects, so this post is extra fun for me to write.

Sensors come in many shapes and flavors. Some can be extremely simple!nothing more than two wires that can detect submersion in water (since any but distilled water is conductive), and some can be extremely complicated!like image sensors that can capture photons in quantum wells and create digital pictures. The most common sensors I seem to encounter over and over in hobbyist world are members of three big families: image sensors, inertial sensors, and environmental sensors.

Image sensors are quite self-explanatory!as their name suggests they capture stills or video. From the other two: inertial sensors include accelerometers, gyroscopes, tilt sensors, and magnetic flux sensors (aka compasses). Environmental sensors include temperature, humidity, barometric pressure, HAL effect, and various gas sensors.

I suppose it is therefore not surprising that our LaunchPad includes one representative of each from inertial and environmental families (including an image sensor would tremendously affect the cost!these are very expensive). To be precise!LaunchPad contains a tri-axial accelerometer and a thermopile temperature sensor. (After reading the datasheet for the accelerometer, you will discover that it contains a temperature sensor of its own as well!)

To communicate with a sensor, you must first figure out the way it is connected to your board. Some sensors can be connected in more than one way, so be careful! Here are the most common ways a sensor can be connected (I will try to write them in decreasing order of likelihood, although first few ways are fairly equivalent).

1. I2C (pronounced "eye-squared-see"), is also known as two-wire connection!so called because it only requires two extra wires to connect a device. Sensors connected this way require total of four pins!VCC, GND, SDA, SCL. These are, respectively, power line, ground line, data line, and clock line. The advantage of this type of connection is that it allows multiple devices connected to a bus, each device (sensor!in our case) having its own address by which it can be reached.

2. ADC direct!this means our sensor is giving out straightforward analog values which we can easily pick up and read via analog-to-digital converter pin (ADC, for short). This kind of sensor would present VCC, GND, DATA pins. Readout is very easy technically, but can be tricky in terms of timing!not all the analog sensors have their data ready at all times. It is (as always) important to pay attention to the datasheet.

3. 1-Wire (pronounced "one-wire") connection C is an interesting variation somewhat similar to I2C, but with a twist. It only requires two pins to operate, GND and DATA. A sensor that communicates via 1-wire needs to have a small capacitor inside to store enough power to keep it alive when no data is transmitted over the bus.

4. SPI!As this is the most advanced serial protocol of all the above, it is rarely found in small sensors and more commonly found in more complicated components like WiFi, BT, memory modules, etc. The connection requires six pins altogether!VCC,GND,MOSI,MISO,SCLK,CS.

1???2???3?Next Page?Last Page



Article Comments - DiY IoT: Digging deep on sensors
Comments:??
*? You can enter [0] more charecters.
*Verify code:
?
?
Webinars

Seminars

Visit Asia Webinars to learn about the latest in technology and get practical design tips.

?
?
Back to Top