1-wire is a electronic bus protocol invented by Dallas Semiconductor (now owned by Maxim). One of the most popular uses of 1-wire is for temperature sensors. The DS18B20 temperature sensor is most commonly available in a TO-92 package that makes it look like a transistor.
To make this project, you will need:
- DS18B20 1-wire temperate sensor (I got mine from Sheepwalk)
- RJ45 Break-out board (for example from SparkFun or Proto-Pic)
- RJ45 socket (I used a low-profile Molex 95501-2881 so it fits in my wall enclosure)
- Soldering Iron
- Wire cutters
Teachers! Did you use this instructable in your classroom?
Add a Teacher Note to share how you incorporated it into your lesson.
Step 1: Solder the RJ45 Socket to the PCB
The first step is to solder the RJ45 socket to the PCB. This isn't too difficult, thanks to the socket being quite chunky and sitting flat on a table.
Place the PCB on top of the socket and then solder the opposite corners to hold it in place. Finally solder all the other pins. Check that there are no short circuits between any of the pins.
Step 2: Solder the Sensor to the PCB
Next insert the 1-wire temperature sensor into the PCB, with the markings facing outwards, away from the RJ45 socket.
1-wire Pin 1 → GND → RJ45 Socket Pin 5
1-wire Pin 2 → DATA → RJ45 Socket Pin 4
1-wire Pin 3 → 5v → RJ45 Socket Pin 2
Pins 1 and 2 of the DS18B20 1-wire sensor are right next to each other in the middle. Pin 3 has to be bent slightly to reach over slightly. I made the legs of the DS18B20 long enough that the top of the package is level with the top of the RJ45 socket.
Solder the three legs and then trim them off close to the PCB.
Step 3: Connecting It Up
The Maxim USB to 1-wire adaptor (DS9490R) has a RJ11 socket on it (6 positions, 6 pins).
You can either connect it up using a proper RJ11 to RJ45 cable or a RJ11 cable will actually fit in a RJ45 socket - albeit slightly wobbly. The advantage of using an RJ45 socket is that you can than connect it to a remote location using standard RJ45 / Cat5 wiring.
As simple as that, you are done!
The software is out of scope of this tutorial, but I personally use OWFS on Linux.