Misc Projects : 1-Wire Sensors
Using the Maxim/Dallas Semiconductor 1-wire sensors for systems and environmental monitoring.
I've found the Maxim/Dallas 1-Wire products to be extremely useful for systems and environmental monitoring. A variety of devices are available to digitally measure temperature, voltage, counts, and current, as well as to control switches. They are particularly convenient in that a 1-wire bus generally requires only a single twisted-pair, providing both data and power. Devices are connected in parallel and are uniquely addressable. For disconnected temperature measurement, the iButton Thermocron devices are programmable, self-powered loggers in a durable stainless steel package.
Serial, parallel, and USB computer interface adapters are available. I currently use the serial DS9097U. A few other third-party products such as The Link are also available. I use cat-5 cable with RJ45 ends for physical connections to a few patch panels. To avoid a variety of bus errors, branch lengths should be kept to a minimum, though relatively small(<30m, ~50 devices) star networks work well for me.
On the software side, the OWFS project implements a hierarchical filesystem using the Linux FUSE kernel interface. In simple terms, this facilitates simple browsing of the network structure and device access with standard command-line tools. Perhaps most importantly, this general interface handles concurrent access and writing by a variety of scripts. Logging and graphing page generation such as my Machine Status is accomplished with regular logging to postgres database backend and periodic page generation. I'm happy to share this infrastructure. Drop me an email... Everything is written in Python.
For dry measurements, I solder a small 2mm molex plug to the end of a cat-5 cable. See Mouser parts 538-51110-0450. The sensor may then be trimmed and inserted, to be held with heat shrink. This avoids the need for any additional electrical insulation. Note that for non-parasitic devices, it is generally necessary to connect the ground and power chip leads. I solder a short bridge to the base of the chip package. See the Water Cooling Gallery for further installation examples.
The DS2423 is a two-channel counter. I use this to count pulses from a paddlewheel flow meter, further described on my Water Cooling page. I use a small transistor circuit to amplify the meter pulses sufficiently for measurement. I use a diode and small capacitor for parasitic power from the 1-Wire bus. Other flowmeters integrate such a transistor to generate a square wave which could be counted directly.
PIO Communication with MicroChip PICs
The DS2408 is an 8-channel switch. I use this chip for PIO communication of color data to a 16F88 PIC for my LED Water Lamp With the DS9097U (not in overdrive), I am able to achieve approximately 30 bytes/sec. I currently use four bytes to transmit 24-bit RGB colors, resulting in somewhere around 7 colors/sec. With interpolation on the PIC to smooth color changes, this interface is fast enough for smooth, rapid color changes. See the LED Water Lamp page for further details.
Last Modified: 17 Nov 2009