FlauschBert / bpi_dht11

Read humidity and temperature from the DHT11 sensor on the Banana Pi.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

DHT11 on the Banana Pi

Humidity and temperate sensor DHT11 on the Banana Pi or Raspberry Pi (not tested).

Motivation

Read out the values from the sensor and print to the console.

Results

The approach of polling the values is improvable unfortunately. Because we are running on a system with many concurrent processes the results vary with every run. With an heuristic approach it works very good however.
It would be perfect if we could rely on interrupts but this is not possible in user-space.

Compile and install wiringBP library and tools

Clone the repository and run ./build.
This installs includes and library in /usr/local/include and /usr/local/lib. Binaries in the /usr/local/bin folder.

Compile and install

Go to the source directory and use the mighty force of shining CMake :D to compile the pico project.
The wiringPi sub folder contains the internal interface library for the installed wiringBP library.
Do make install to install the library in /usr/local.

(I used Armbian stretch but also more recent versions should work).

References

About

Read humidity and temperature from the DHT11 sensor on the Banana Pi.

License:BSD 2-Clause "Simplified" License


Languages

Language:C++ 83.5%Language:CMake 16.5%