O'Reilly logo

GNU/Linux Rapid Embedded Programming by Rodolfo Giometti

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Getting access to 1-Wire devices

In the next section, we will manage a 1-Wire device using both an emulated 1-Wire controller and a real one connected by I2C to the main CPU.

Using the GPIO interface

To show you how the 1-Wire bus works, we can use a really simple chip: the temperature sensor DS18B20. There are two possible ways or modes by which the chip can be powered: a parasite version (that is, the one that works in the parasite mode) with two wires only and a normal version with a dedicated power pin, which uses three wires instead. In our example, we will use the three wires and a waterproof version of this chip. There is a special packaging of the chip so that it can be used in hostile environments (look at the following image to see the ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required