官术网_书友最值得收藏!

Connectting digital input - sensor DS18B20

The Raspberry Pi has digital pins, so in this section, we will look at how to connect a digital sensor to the board. We will use the digital sensor DS18B20, which has a digital output and can be perfectly connected to a digital input in our Raspberry Pi sensor. The main idea is to take temperature readings from the sensor and display them on the screen.

Hardware requirements

We will require the following hardware to take the temperature reading:

  • Temperature sensor DS18B20 (waterproof)
  • One resistor of 4.7 kilo-ohms
  • Some jumper wires
  • A breadboard

We will use a waterproof sensor DS18B20 and a 4.7 kilo-ohm resistor:

Hardware requirements

This is the waterproof sensor that we are using in this project.

Hardware connections

The following diagram shows the circuit on the breadboard, with the sensor and the resistor:

Hardware connections

In the following image, we can see the circuit with the sensor:

Hardware connections
主站蜘蛛池模板: 偏关县| 屏山县| 威远县| 会理县| 六枝特区| 玉山县| 长兴县| 广德县| 东兴市| 突泉县| 哈尔滨市| 电白县| 广水市| 响水县| 兴宁市| 钟祥市| 扶风县| 芒康县| 新龙县| 洛扎县| 亳州市| 白山市| 阜新| 镇原县| 禹州市| 林西县| 子长县| 通渭县| 根河市| 新宁县| 无为县| 宁晋县| 嘉黎县| 三都| 怀柔区| 淮北市| 青州市| 璧山县| 泸溪县| 古丈县| 竹山县|