Maker Faire Surprise

On the drive to Maker Faire on Friday, I had a few dark moments wondering if anyone would really care about the work I’ve been doing on wireless sensor networks.  I imagine that there are all these sensors struggling to be heard and I’ve been constructing a platform to help facilitate that.  But would anyone share that vision?   On I drove…

My friend, Terence, helped get us set up with the booth and finally with no hope of getting any internet access (seems it was over-taxed most of the time), we retired to the Friday evening’s beer and paella dinner.  We met a lot of wonderfully creative Makers.  The Maker Faire is such a wonderful collection of creativity in all it’s myriad forms.  It is inspirational and gives me hope.  Terence made a good point that Obama should have come to the Maker Faire to see an example of what makes America great.

Well I have to say I was very surprised to see how many people came to our booth to learn about wireless sensor networks.  I’m exhausted and my voice is shot but I feel very satisfied to see so much interest in what we have built.  Thanks to all who came by the booth.  I hope that this experience can be the beginning of an exchange of ideas to make more robust sensor networks that can provide meaning to those who seek to extend what we can know about the world around us.  I heard so many great ideas and I hope we can keep the them coming.

Now that the Maker Faire is over, I plan to focus on this web site for the next couple of weeks and get the tutorials in order.  I’ve started some of them and have not yet published some others.  I promised everyone who I spoke with at the Maker Faire to get these completed and that’s where I’ll be focused.  If anyone wants info about any particular part of the platform, sooner than later, please let me know and I’ll be happy to move that to the front of the line.

Thanks to all who came by the booth, to Terence, to my friends who’ve been supporting my efforts to Make my vision, to Aurora for putting up with my project clutter, and thanks to the folks at Maker Faire for putting on a great show.

(the original post about Maker Faire)


OSHW – Open Source Hardware

I support the Open Source Hardware Definition v1.0

A cool new logo has been defined for Open Source Hardware (OSHW).

Here are the principles of what is being attempted in open source hardware (from the site):

Open source hardware is hardware whose design is made publicly available so that anyone can study, modify, distribute, make, and sell the design or hardware based on that design. The hardware’s source, the design from which it is made, is available in the preferred format for making modifications to it.  Ideally, open source hardware uses readily-available components and materials, standard processes, open infrastructure, unrestricted content, and open-source design tools to maximize the ability of individuals to make and use hardware. Open source hardware gives people the freedom to control their technology while sharing knowledge and encouraging commerce through the open exchange of designs.

Read more here…

Netgear GS605 v2 fix

NetGear GS606 v2 with new capacitors

NetGear GS606 v2 with new capacitors

A few weeks ago we had a serious storm here in the SF Bay area and the power went out for about 5 hours.  It took a few days for me to realize that the internet connection was running pretty slow, so I started trying to trace it.

I’m using Comcast IP service and right out of the cable modem I was getting 21Mbps (using the Speakeasy speed test).  After the first Netgear gigabit switch the bandwidth dropped to about 3.g Mbps and after the second, it dropped less than 1.0 Mbps.  Killin’ me!

So after some Google searching I found that the Netgear GS605 v2 was susceptible to power surges which often happen during or after power outages.  The problem is apparently in the poor quality capacitors used.  Once replaced, they are back to full force with less than $10 worth of parts and about 20 minutes.  Here’s how I replaced the capacitors.

Tools, parts:

  • Soldering Iron
  • Solder Sucker
  • Torx Screwdriver (T8)
  • 2 x 1000 uF 10V, 1 x 470 uF 25V capacitors

Open it up:

On the bottom there are some rubber feet that can be peeled back to reveal tiny torx head screws (from my set I used a T8).  Unscrew the 4 screws.  The PC board is not secured further, so when you remove the back, you can jiggle the PCB and it will come out as a single unit.

Removing the capacitors:

On the PCB you can see 4 capacitors:

  • 2 x 1000 uF, 10V
  • 1 x 470 uF, 25V
  • 1 x 100uF, 16V (looks like part of the power regulator, I did not replace)

To remove the capacitors, I first tried using one of those solder sucker tools but I think my soldering iron it not getting hot enough.  I basically put some side pressure on the exposed post oposite the capacitor side of the PCB and when the solder melted, the capacitor slipped out at an angle.  Doing the same on the other post released the capacitor.  I removed the 2 1000 uF caps and the 470 uF cap.


I went to Radio Shack and purchased:

  • 2 x 1000 uF, 35V – $1.79 ea.
  • 1 x 470 uF, 35V – $1.49 ea

The replacements from Radio Shack were their generic versions, bigger in size and higher in rated voltage but I wanted to get it done and not wait a few days for an online order.

Because the new capacitors were so large, I had to mount them sideways. on the PCB.  This is generally straight forward if you pre-bend the leads.  Put the cap in place and with needle nose pliers, pre-bend at the appropriate lengths.  The 1000 uF cap closest to the edge needed to be bent with the leads in a slightly overlapping form, but once you get in there it should be obvious.  Here’s what it looked like.

NetGear GS606 v2 with new capacitors, close up

NetGear GS606 v2 with new capacitors, close up

Maker Faire! May 21, 22

There was a call for Makers, I applied and got accepted. So this year, instead of being in the stands, I’ll be out on the field having fun. My booth will be called The Sense of Things, as a play on the concept of The Internet of Things.

I will be showing what I’ve learned in the last year regarding wireless sensor networks.

Short Description: Wireless sensor networks, data acquisition and analysis; a discussion about building wireless sensor networks based on open source software and hardware (OSHW) for use in things like home energy, air quality, and elder care.

Long Description: Exploring sensor networks, data acquisition and displaying data.

This project will demonstrate what I have learned in the last year from others on the internet. Open source software has lead to open source hardware (OSHW) and makes it possible to build wireless sensors, open source wireless gateways, data logging data services and charting applications.

With this kind of system we can monitor things like energy used in a home, indoor/outdoor temperatures, wind speed, dangerous gases, the presence of a person in a room, etc.

We will discuss how various online tutorials and technologies (Tweetawatt, xBee, Asus wifi with OpenWRT, data logger, web services, Pachube, Adafruit, MightyOhm, etc) were used to develop the test system.

Web site:

Please come by for a visit.

Saturday, May 21st – SHOWTIME :  10 a.m. – 8 p.m.
Sunday, May 22nd – SHOWTIME:  10 a.m. – 6 p.m.


Physical dashboard devices – Eh!

According to this article by Katie Fehrenbacher at Gigaom, the developers of home energy management systems have figured it out that there’s no future in dedicated dashboard devices when you have a marketplace full of iPhones, Android phones, iPads and other tablet devices.

The dedicated dashboard devices would be able to display various conditions of your home energy system, your local weather, etc., and to control devices in the home.   But now that we have Android phones and iPads, these new devices can access the web and use either native web pages or specialized apps.

It’s a no brainer.   Have a web based system as the default UI and provide specialized apps for hand held controls.

Joint Center for Artificial Photosynthesis (JCAP)

It will be interesting to watch the progress on artificial photosynthesis.

“The Joint Center for Artificial Photosynthesis (JCAP), to be led by the California Institute of Technology (Caltech) in partnership with the U.S. Department of Energy’s Lawrence Berkeley National Laboratory (Berkeley Lab), will bring together leading researchers in an ambitious effort aimed at simulating nature’s photosynthetic apparatus for practical energy production. The goal of the Hub is to develop an integrated solar energy-to-chemical fuel conversion system and move this system from the bench-top discovery phase to a scale where it can be commercialized.”

WSN: Gas Sensor

Hooking up a gas sensor is more or less the same as with the voltage divider model but it has an extra twist.  The MQ Series sensors which I used for gas sensing (average cost= $5) have a heating element to react with the gases they detect.  I’ve played with the MQ-2 – General combustible gas, MQ-3 – Alcohol, MQ-4 – Natural gas & Methane, MQ-5 – LPG or Propane, and the MQ-7 – Carbon Monoxide (CO).

For the analog sensing it is the same as the classic voltage divider model (see the notes on the main sensor post).  Because I use an XBee analog input to read the sensor output value, the V+ is at 3.3V (which is what the XBee runs on) and the V- is at Gnd.

Here’s the schematic I set up (click to see a larger view):

It might seem more complicated than it needs to be, but basically we have a 5V regulator supply (w/ 7805) for the heater element, a 3.3V regulator supply (MCP1700-3302E/TO; same as the Adafruit XBee Adapter PCB) to power the XBee module, then the MQ series device.  I’ve connected the gas sensor output to pin 20 of the XBee module, so we’ll be reading the gas sensor voltage on analog input 0.

Here are my Eagle CAD files for this setup (Schematic, Board)

One thing to note about these sensors is that they are not calibrated to detect specific parts per million, etc.  They can also be affected by the ambient temperature and humidity.  I’ve used them primarily to know when the gas concentrations are high or low, trending up or down.

Here’s a live sample graph of the data tracked at

The spikes you might see on the chart are, I am pretty sure, generated by some problem of collection downstream of the sensor and the xbee radio. Hopefully, I’ll get this resolved soon.

Next Post: FSR Sensor
Next Group: Radio:XBee

WSN: Temperature Sensor

The temperature sensor is based on the TMP36 Low Voltage Temperature Sensors.

My first attempt at creating a wireless temperature sensor was using a TMP36 device from Analog.  The TMP36 looks like a transistor because it is in a TO-92 package.

I soldered together an XBee Adapter board from Adafruit then I soldered the TMP36 directly to the adapter board.  Using the layout above. I soldered the voltage input pin to the closest VCC trace, the ground to ground (obviouisly) and the Analog Voltage output pin to the AD0 pin.

TMP36 on the XBee adapter

TMP36 on the XBee adapter

This seems to work fairly well if you only have one input.  If you plan to use multiple sensors on the XBee ADC inputs, you’ll need to set up a rail to rail op amp buffer.  But that’s for another post.








Here’s a live sample of a TMP36 data stream from my back porch as derived from a chart on

Large spikes are a known problem with the data collection downstream of the TMP36 and the XBee module.  To be fixed soon, I hope.


Next Post: Gas Sensor
Next Group: Radio:XBee

WSN: Tweet-a-Watt

The Tweet-a-Watt is a wireless power meter based on a commercial device called the Kill A Watt which is hacked to include a wireless XBee radio.  It was designed by Limor Fried of Adafruit Industries and she has written up one of the best online tutorials for a kit based project.  It collects data from the Kill A Watt from P3 International and with an added XBee radio sends data to a PC and then on to a twitter feed.  Hence the name, Tweet-a-Watt, a combination of Twitter’s Tweet and the Kill A Watt power meter.

You can build a Tweet-a-Watt by following the tutorial here.

The basic components:

Kill A Watt Power Meter (P4400)


Everyone should own at least one Kill A Watt.  It can tell you the cumulated kilowatt hours (KWh) at the plug load of an appliance, along with the volts, amps, and watts.

With pencil and paper and a little time you can hook this up to the various appliances in your home and look at the meter and simply “do the math”.  With the math, and perhaps a spreadsheet program, you can analyse what your appliances draw in watts and learn what to turn off or use less.  You can get them online for as little as $17 and at your local hardware store for about $25.
XBee Radio
The Kill-a-Watt starts to become a Tweet-a-Watt with the introduction of an XBee radio.  The radio can be hooked up inside the Kill-a-watt and that makes it possible to transmit the readings from the Kill A Watt and send them to a computer for logging and analysis.

The original design of the Tweet-a-Watt project had an XBee radio receiver hooked up to a PC through what is known as an FTDI USB cable; essentially a serial input.  There was a python script that would run on the PC and collect the serial input and  package the data for delivery to a twitter feed.

During my investigations I saw Limor Fried’s short video about using an Asus Wifi Router instead of a PC to collect and send the sensor data to the internet.  If you’re trying to reduce your energy consumption it seems a shame to have to run a PC; even a laptop will draw perhaps 60-90 watts.  The Asus wifi router setup can be configured to run the python script and do the same basic job as the PC but it only draws about 4 watts.  Much better.   See the post about setting up the ASUS WL-520gU.

Next Post: Temperature Sensor
Next Group: Radio XBee

WSN: Sensors

Sensors are the front line components in a wireless sensor network.  They move a response from the physical realm into the electrical realm.  Each sensor responds to some environmental events and generates a voltage or a digital signal or something that can be measured.  There’s a great list of sensors on Wikipedia (hours o’ fun).  I am constantly surprised by the seemingly endless list of sensors.

To list some things that can be sensed:

  • Temperature
  • Gas, Smoke
  • Light
  • Tilt, Acceleration
  • Proximity
  • Sound
  • Distance
  • Air pressure

Most sensors are what are defined as Passive.  Passive sensors react to some environmental stimulus and put out a signal.  Active sensors inject something into the environment and then respond to the effects created by the active aspect.  Radar is a classic example of an Active Sensor.

Because we’re talking about “wireless” sensors, it’s hard to talk about wiring up the sensors without talking about the radios that make them wireless.  We’ll focus on XBee radios but there are others that I’ll describe on the Radios post.  On many sites on the internet sensors are shown as hooked up to a microprocessor (which then connects to a radio).  I have found that for the sensors I have built so far, none have needed to use a microprocessor.  Instead, I’ve connected the sensors directly to an analog input of an XBee.  It seems you would need a microprocessor when you need to apply some kind of up front logic to a sensor’s readings.

Voltage Divider

When trying to figure out how to wire up sensors, it helps to have a basic knowledge of electronics.  The most prevalent setup in sensor networks seems to be what is called the voltage divider (see the diagram below).  There’s a lot of theory about voltage dividers but the basic idea is that you have a voltage at the top (Yin), you have 2 resisters connected inline (R1, R2) to a ground, and you have a voltage out (Vout) where the 2 resisters are joined.  The output voltage (Vout) is some value relative to the ratio of R1 and R2.

voltage divider

voltage divider

As an example, you can imagine that R1 is a sensor that varies its resistance with temperature.  If Vin is 5VDC then the Vout is going to vary dependent on the variable resistance of R1.  Vout would be connected to an input on an XBee (to send wirelessly over a radio) or connected to a microprocessor (like an Arduino) for special handling.

There’s a cool page that shows lots of different circuit layouts for various sensors on the Wiring site (Wiring is kind of like Arduino).  On this page you can select circuit types from a popup and some of the selections with display circuits.

Another great resource to get started is on Adafruit Industries’ Tutorial on Sensors which gives an overview of various sensors and how to wire them up.

The Sensors:

  • Tweet-a-Watt: The Tweet-a-Watt, originally created by Limor Fried (aka: Adafruit) is a modified Kill A Watt with an embedded XBee radio.
  • Temperature Sensor: It is relatively easy to hook up a temperature sensor to an XBee radio.
  • Gas Sensor: Hooking up a gas sensor to an XBee radio.
  • FSR Sensor (Force Sensitive Resistor): Very easy to hook up even if a bit challenging to hook up physically.  The FSR responds to pressure applied to its disk and simply changes the resistance based on the amount of pressure.

Next Tutorial Post: Tweet-a-Watt
Next Group Post: Radio XBee