Accelerometers, motion-sensors, distance-sensors, and compasses. What do these sensors have in common? They compose the Introduction to Sensors Kit that the Parallax Corporation sells for $79.99. Purchase this kit, a programmable microcontroller like the Parallax BS2, a kit board, and a serial cable and you’re ready to explore the Sensor platform for Windows 7.
Below is a screenshot of the Passive Infrared (PIR) or motion sensor running on a Parallax HomeWork board:
The Parallax BS2 (BasicStamp 2) is a programmable microcontroller that you code with Parallax PBASIC. This microcontroller has the following features:
· 20MHz processor
· 32 bytes RAM
· 2KB EEPROM (able to hold ~500 PBASIC instructions)
· 16 I/O pins
· 5 VDC with 3mA draw while running
Sensor Applications in .NET
With very little code, you’ll begin to see the rich power of the Sensor platform. For example, the below screenshot was taken from a simple C# .NET application that graphs the output for the Memsic 2-axis accelerometer:
This application was written with just 100 lines of code. And, below is a screenshot of another application that renders compass output in real-time:
This application contained a little more code (closer to 200 lines); however, even 200 lines is a remarkably small footprint for an application that renders real-time data from a remote device.
How do I get started ?
That depends: If you’re a hardware type, building the circuit will be a piece of cake. But, creating the driver (the interface between the sensor hardware and Windows) might be a challenge. Same goes for application developer: If you know your way around .Net, you might find it a challenge to write the driver or build the hardware. Driver developers will probably have the least difficulty of all.
But, we’ve tried to simplify the process for everyone. We’ve provided a sample driver that supports all four sensors in the kit. And, we’ve provided sample firmware for the four devices as well as a simple .Net application that demonstrates the use of the Sensor platform for the Passive Infrared (PIR) sensor.
You’ll find the sample driver, firmware, PIR application, and a descriptive whitepaper on the MSDN Code Gallery here.
You’ll find a sample application that demonstrates real-time graphing of accelerometer data on the MSDN Code Gallery here.
Where can I find out more ?
· To learn more about the programmable microcontrollers and sensors offered by Parallax, see the Parallax Web site.
· For information about the Sensor API, see Sensor API in the Win32 and COM Development section MSDN.
· For information about Sensor Drivers, see Sensor Devices in the Windows Driver Kit (WDK) section of MSDN.
· To download a free version of Visual C# 2008 Express, see this Downloads page on the Microsoft site.
-- Sensor & Location Platform Team
This posting is provided "AS IS" with no warranties and confers no rights.