Tuesday, 21 September 2010

1 Wire Networks Part 1

Recently I have been looking at 1 Wire networks.
There are plenty of resources out there so a bit of googling is sure to whet your appetite.
The photo in the Blitzortung post shows 2 Cat5 cables coming out of the antenna housing, the blue is the pre-amplifier cable, the green is for a 1 wire temperature and humidity sensor. The sensor was bought from Hobby Boards.
I have been using Digitemp on the T1010 to monitor the temperature and humidity within the antenna enclosure.
This gives a display in text format:

Sep 21 16:00:58 Sensor 2 C: 26.41 F: 79.53 H: 22%

The next step is to implement OWFS and get the data on this page, hopefully a few other things like rainfall and wind speed/direction, a complete weather station in fact.

To interface to the 1 Wire network I built a DS9097U compatible I/F based on this post and added a Maxim MAX232 on the serial side to convert from RS232 to TTL levels.

More to follow on this subject later.

Sunday, 15 August 2010

Quick MIDI Thru box

After my last post I thought I would chuck this out as well.
I first made one of these a few years ago and it works very well. I found some information on a website that appears to have vanished so, I can't include a link here. This is a pretty standard way of doing this so I don't think I am stepping on anyone's toes here.
The inverter chip can be a 7404 or 7407, I personally use the 7407 as I have loads in my junk box. I have also used an AND gate with the inputs joined to make a non-inverting buffer. It depends on the Optoisolator as to whether the output is inverted or not. If it doesn't work try a different buffer chip. Breadboarding is the best way to find a configuration that works for you.
The MIDI IN must not have a ground connected, the MIDI OUTs do have a ground on pin 2 even though this is not shown on the schematic. If you are in doubt about the way to connect a MIDI socket there is loads of information on the web, just ask Google. I would add it here but I can't remember off the top of my head.
As many outs can be added as you want, just add more inverters etc.

Embedding USB sticks

The Compaq T1010 used in my Blitzortung setup has a 1GB USB stick as the hard disk. OK it's not a new idea but it does have one drawback. How do you know if the stick is being accessed when it's inside of the machine?

To start with I soldered an additional LED across the one on the stick (take the stick out the case first). The first 1 worked for months with this arrangement but eventually something broke and the LED stopped working.

So after a bit of thought (and some inspiration from messing with a MIDI Thru box) I came up with the following circuit:
The PNP transistor can be any thing suitable e.g. BC212 for a single LED or a BD680 for loads of LEDs. R3 is the appropriate current limiting resistor for your choice of LED, 560R in my case. R1 acts as a current limiting resistor for both the 6N137 input and the USB stick's LED driver.
The circuit works fine with the stick's own LED in circuit or when it is removed, I left it in.

Please note: I will NOT be held responsible in any way for the use or misuse of the information presented here.

Sunday, 8 August 2010

Blitzortung Time Of Arrival project

I have recently joined the Blitzortung network, mine is the first TOA station in the UK. Check out the Blitzortung.org page for details. I stumbled across this site a few years ago and it has always interested me so I thought it was time to make my contribution.

Weather, as we all know, is a very British obsession and I am probably more obsessed than most. Lightning scared the **** out of me when I was a kid which probably explains my fascination with it now. There are other posts to follow concerning lightning detection.

The setup here consists of a hacked Compaq T1010 thin client running DamnSmallLinux (see winterm.gaast.net for details, I will add a post here later) and the PCBs, Ferrite rod antennas and GPS available by special request from Blitzortung.org.

Generally I am not one for building electronic kits, I prefer to do things the hard way and mess with chemicals to make my own PCBs, but this build was a complete breeze, the PCBs are made to a very high standard. Everything worked right away (a first for me).

The Ferrite rod antennas  proved to be a little more fragile than I expected, I managed to break one of them rendering it completely useless. This has meant a delay in becoming fully operational (waiting on a replacement at the moment).

Another problem was caused by the source code for the Linux Tracker. All credit to the author Egon Wanke, this code works perfectly with Linux kernels newer than 2.6.0 but for my Linux it caused unending Zombie processes. I should state that anything higher level than assembler language is voodoo to me so I had a bit of a time sorting the problem. Linux comes in many flavours and things change with its development. C++ is used for the source code and it would build with no errors or warnings. After much searching google I found the answer, SA_NOCLDWAIT is only available after Linux 2.6 so by using signal(SIGCHLD, SIG_IGN); before fork() the Zombies disappeared for good. Phew!

I will post a few photos when I find the motivation. In the interim, why not check out the Blitzortung site and maybe join up? It's not difficult and we need more participants in the UK.

Here is the "business end" of the set-up, yes that is a bit of Wickes own brand down pipe!
The large box is made from PVC sheet and is glued together with normal PVC plumbing cement.
Antenna housing with the GPS receiver in the lower right of the picture