Microcontroller Shop has a variety of useful electronic and microcontroller parts. What they have that’s exciting are the XBee boards from droids.it. They sell the XBee Simple board, the XBee Serial board, and the XBee USB board.
XBee Library graphing and logging application
Here’s a program that uses Rob Faludi and Dan Shiffman’s XBee library for processing to read three analog sensors from multiple remote XBee radios and graph them. It also saves the data to a comma-delimited file. It also makes sounds when the value exceeds a given threshold. For this application, you need two or more XBee series 1 radios. One is attached to the serial port of the computer, and the other is remote, broadcasting three analog values.
This also uses the ControlP5 library by Andreas Schlegel and the Ess library by Krister Olsson.
Continue reading “XBee Library graphing and logging application”
XBee Library graphing application
Here’s a simple program that uses Rob Faludi and Dan Shiffman’s XBee library for processing to read three analog sensors from a remote XBee radio and graph it. For this application, you need two XBee series 1 radios. One is attached to the serial port of the computer, and the other is remote, broadcasting three analog values.
XBee to USB modules
Droids.it has a breakout board for XBee radios, and a USB-to-Xbee board available.
The USB board is nice, because in addition to having a built-in 5V-to-3.3V regulator and indicator LEDs, it’s got all the pins of the XBee broken out on the side of the board. Makes development of XBee projects easier.
The breakout board also has its own regulator on board, making it easy to interface with a 5V project. It’s also got the serial pins broken out to a single row, making it easy to mount on the side of a breadboard.
The prices on both are reasonable for the European market. As the US dollar continues to sink, they’re a bit pricier for US customers, but still reasonable, for now.
Thanks to Rob Faludi and Jeff LeBlanc for testing help, and to Luigi Carnevale for supplying sample boards.
Technorati Tags: electronics, networked objects, networks
XBee Radio Received Signal Strength Graphing Program
This Processing program takes a string of values in the serial port. It assumes the string is the API string from a Maxstream XBee radio. It parses the string and graphs the signal strength. See the XBee product manual for more info on the protocol.
The XBee radio in this program is attached to the computer’s serial port using an FTDI USB-to-serial module like this one from Spark Fun.
Technorati Tags: networked objects, networks, XBee
Continue reading “XBee Radio Received Signal Strength Graphing Program”
Xbee Radio Received Signal Strength and Data Graphing Program
This Processing program takes a string of values in the serial port. It assumes the string is the API string from a Maxstream XBee radio. It parses the string and graphs the signal strength and the analog values represented in the string. See the XBee product manual for more info on the protocol.
The XBee radio in this program is attached to the computer’s serial port using an FTDI USB-to-serial module like this one from Spark Fun.
Technorati Tags: networked objects, networks, XBee
Continue reading “Xbee Radio Received Signal Strength and Data Graphing Program”
Xbee Radio terminal program
Working with the Maxstream Xbee radios on OSX can be annoying because the screen program doesn’t print a linefeed automatically when it receives a carriage return. This Processing program works as a serial terminal program, but inserts a linefeed when it gets a carriage return.
Technorati Tags: networked objects, networks, XBee
Random Numbers and Physical Computing
Most microcontrollers don’t have a random function. Random functions are not truly random, they’re actually a complex mathematical formula that results in a number that “seems” random. That can take up lots of processing time, so it’s usually the first function to go when writing a microprocessor language.
In fact, most of what you do in programming physical computing projects is to figure out how to deal with the world’s natural randomness and make it look smooth. A photoresistor read through an analog-to-digital converter, for example, will never give you a nice steady number, it always fluctuates with tiny changes in lighting that your eye can’t see. Your consciousness is a great leveller for the sensors that are your eyes, ears, skin, nose, and taste buds When you move a photoresistor from one room to another, your readings will be totally different, and all of a sudden, you have to re-calculate what is “average” and what constitutes the lighting change that you want. And that’s just one of many examples. The fact is, data from sensors is filled with the noise of the real world. Plan for it in advance.
Technorati Tags: pcomp, physical computing, programming