Skip to content

Archive for May, 2013


Balancing Act….with air…

Experimenting with an Arduino usually ends with me travelling down, oh so many, bunny trails. I see a potential, or get a brain wave or just want to find out more about something associated with this intriguing piece of harnessed electrons.

I’m a bit of a weather station junkie so I was trying to figure out a way to get one of my wireless Arduino rigs to communicate with my Acu-Rite Weather Station. This proved to be fairly futile since there’s little published data about the Acu-Rite stations. However as I was learning all this, usually the hard way, I came across a number of people who’d built their own weather stations of bits and pieces. Which of course, lead me to “rain” detectors.

Of course, like all bunny trails, I stayed long enough to decide that rain detectors weren’t as foolproof as just looking out the window and saying, “Yep, raining”..but I then found myself migrating to “air”, another necessary component in a weather station.

Air is a whole different kettle of fish. So to speak. I’d have to build some weather vane thing, then an anemometer to check wind speed, a battery powered Arduino with wireless connections and and and and…well, you get the idea.

So how does one measure “wind”? I’m sure you’ve seen the hand held anemometers on eBay that advertise maximum accuracy, no doubt on some planet other than Earth. So I started to think (dangerous I know), hey I can build one of those. Turns out, it’s a little more difficult when dealing with low volumes of air. But I found one of these at Modern Device:

Wind Sensor

While not a Pitot tube, this is a hot wire anemometer and according to the specs, sensitive to low air flows. Like breathing. To which I can attest. It does pick up a breath from 12″ away.

Something I’ve always wanted to do was try to balance out the forced air from our ducts. Or at least see where the air is all going.

I’d picked up a GLCD from eBay:


It’s 3.1″, wired a little different than most of the GLCD’s and I’d originally wanted an I2C version of it. Actually I’m glad I didn’t get an I2C version because this one is FAST at updating. The I2C version is like watching grass grow.

I used a MEGA expansion board for connections to the GLCD:

IMG 3717

I hardwired the contrast POT (a 10 turn trimmer) right onto the GLCD board itself:

IMG 3716

Spent some time writing a sketch to read the “air flow” and then added a DHT11 temp sensor to it:

IMG 3715

Granted the “HVAC Air Balancer” is a bit of an over statement, in line with those eBay wind speed devices, it does allow you to see a comparative reading as I place the sensors over the various ducts. And really, for a budget project like this, it was all I had hoped for.

I still have to put the whole thing in an enclosure and then mount the “probes” but for all purposes it’s done. And darned if it doesn’t actually work pretty good.

It is true that I have no idea on the real air speed or CFM’s or anything else. I’ll wager that someplace someone has some way of calibrating these sensors, adding in a fudge factor and coming out with some fairly decent numbers in that respect.

As an offshoot of the project, because the sensor is very good at sensing minimal air movement, it actually finds draughts extremely well.

All in all, a fun project!


Logic Analyzer

I have a very good Rigol oscilloscope that I’ve used it many times for working on some of my Arduino projects, but there are times when I need to see what’s going on with an I2C or SPI signal. So I’ve been looking for a logic analyzer for a while.

And of course, I found one on eBay. Big surprise. The bigger surprise? The cost. Under $50. I bought it, the seller sent me a download link for the Mac software which I downloaded and then waited for the analyzer to show up. Which it did.

First thing was that the analyzer was small. As in smaller than a box of matches small. Connect it up and the thing flops around the work bench like a mackerel in a row boat. Some leads came with it, but I soldered some IC leads on the ends to make connections easier.

IMG 3656

I did a quick test of it to make sure it all worked and it worked just fine. But something didn’t sit right in my mind. You can see the label on the analyzer says CH1 to CH8. But the software refers to CH0 to CH7. I started to smell an Asian stinky fish. As in knock off.

It didn’t take too long to find the real Saleae in San Francisco. They make two versions of the logic analyzer, an 8 channel and a 16 channel. The 8 channel looks like this:


It doesn’t take a rocket scientist to see the two units are completely different. So if you see the ones on eBay that say Saleae but look like the first photo, it’s a cheap clone. Does it have all the input protection and specs of the real one? Oh of course it does. Probably. Not. Even. Close.

However, it did allow me to see if I’d even use an analyzer. And I discovered that it was quite useful for SPI and I2C.

I connected it up to an RF1100 board on the SPI pins:

IMG 3652

I selected the SPI buss analyzer in the software and let it capture some data:

IMG 3655

Right off, I could see that the RF1100 was receiving a lot more bytes than what I assumed the other RF1100 was sending. The other RF1100 is a UART driven one and I was sending it a serial packet once a second with the time, date and day of the week. Total of eight bytes.

But in decoding the SPI stream from my SPI RF100, I was getting WAY more data. I glanced at the doc’s for the UART driven RF1100 and it says that I could send a maximum of a 31 bytes. I assumed it was only sending out the bytes I sent. What I found was that it was sending all 31 and a length byte (for a total of 32 bytes).

I expanded the software display:

IMG 3654

I could actually read the “hex & ASCII” data in the stream. Now that’s cool. I could also see all the zero’s that were merely padding in the stream.

The RF1100 UART versions I have don’t say much about how they work, which doesn’t come as much of a surprise because they are from Asia and everyone knows how hit and miss that stuff is. Especially when it comes to anything Arduino.

The only part of the whole thing that frosts my socks is the eBay knock offs that are being sold as Saleae’s. That’s just plain wrong. I’m saving for a real Saleae so if the clone blows up, no loss.


USB to TTL – Done differently

I’ve purchased a number of RF transceiver modules from eBay and found that while the majority of them worked right from power up, it would be nice to be able to preconfigure them on the computer and then move them to the Arduino.

IMG 3619

I started off by downloading a Windows program that did a configuration but then decided to write my own Mac application to do it. So the first hurdle was that I needed a USB to TTL converter. I had a couple of these:

IMG 3625

Trouble was these “interfaces” and I use that term with some sarcasm, are RS232 but swing +5 not +12 like the old RS232 ones did. I decided to sacrifice one and see what made it tick and, if possible, hack it.

After ripping off the plastic/rubber cover from the DB9 I had this:

IMG 3626

A close up of the main control board:

IMG 3628

It’s easy to see these were made a LONG time ago now (2006) and some off shore warehouse is cleaning out their closet/basement. It don’t cost more than a Starbucks coffee for the USB to Serial converter so I decided to build my own TTL converter and connect it into that interface.

Amassing the two transistors, some resistors and a diode from my parts bin was pretty easy:

IMG 3629

The schematic I used:


I cross referenced the transistors and ended up using a 2N5401 and 2N5551. Both of those were lower gain than the usual 2N3904/06 switchers you find, but slightly higher gain than the BC557 and BC547.

IMG 3632

The final circuit board with the four lines tagged onto the serial portion, give me TTL switching and a 5V lead. Some of these RF modules require a 3.3V lead so I could have used a regulator to take the 5V down to 3.3 or maybe used three inline diodes in a pinch. Luckily my modules all require 5V.

Any the interface still works perfectly with my RS232 devices and now it also works with my RF modules for programming.


House Address Update…

After my recent tests with the RF1100 modules, I found they work rock solid. Unless, of course, I’m testing one and it happens to transmit some junk that the other slaves pick up. Yep. Then things go a little “south”.

I removed the GPS module from the house address control (this runs the house address LED’s outside from dusk to dawn). Then I plugged the RF1100 into the same leads as the GPS used. Easy fit. Took longer to drill the antenna hole in the case than change the wiring.

Here’s the old setup with the GPS module held in by double sided tape:

IMG 3617

No, the steel ruler isn’t doing anything under that box, it’s sitting on my tool rack..:-)

The LED board inside you can see is a buck converter to take the 12VDC for the LED’s and knock it down to about 6.8VDC for the Arduino power. I left a short USB cable connected to the UNO so I could easily reprogram it when need be. The power is running in the AC adapter jack.

After mounting the new RF1100 it looked like this:

IMG 3620

The whole job took about 10 minutes and it’s been running peachy ever since.

IMG 3622

Arduino’s…habit forming little things…