Repository navigation
Plugin air temp humi
Monitors DHT temperature and humidity and optional DS18B20 sensors through an external I2C board.
| Item | Value |
|---|---|
| Version | 1.0.7 |
| Category | Weather, climate and environmental sensors |
| Author | Martin Pihrt |
| License | GPL-3.0 |
| OSPy |
3.0.211 or newer |
| Python |
3.8 or newer |
| Permissions |
files, gpio, i2c, system
|
| Hardware | platforms: raspberry_pi; interfaces: gpio
|
| Dependencies | Database Connector (optional) |
| Python/OS packages |
RPi.GPIO / python3-rpi.gpio (required), smbus / python3-smbus (optional) |
| Interfaces | Mobile API v1 |
| Source | Open the plug-in directory |
Monitors DHT temperature and humidity and optional DS18B20 sensors through an external I2C board.
Tested in Python 3+
Version 1.0.3 treats Database Connector as an optional runtime dependency. When it is stopped, sensor sampling and local logging continue and SQL logging is skipped without repeated error tracebacks.
This plugin needs DHT11 (22) probe connected to GPIO 10 (pin 19 MOSI). This plugin allows you to connect 1-6 DS18B20 sensors connected to the external hardware board via an I2C bus (address 0x03). Visit Martin Pihrt's blog. for more information for HW.
The plug-in includes an OSPy plugin.json manifest, registers its sensor worker with the shared plug-in runtime, uses the common stop signal, and implements health(). Diagnostics evaluates only the configured DHT and DS18B20 sensor types and reports worker state, enabled probes, latest successful sample, and the latest sensor error.
-
Check Enabled: If checked enabled plugin is enabled.
-
Check Enable local logging and show graph: If checked enabled logging save measure value to logfile (format .csv for Excel) and logfile for graph.
-
Check Enable SQL logging: If checked enabled logging save measure value to SQL database. This option requires the Database Connector extension to be installed and configured. The button will delete the airtemp table from the database, thus deleting all saved data from this extension! This promotion is non-refundable!
-
Maximum number of log records: Type maximum records in log file. 0 is unlimited.
-
Interval for logging: Type interval for logging in minutes (minimum is 1).
-
Label for sensor: Type label for Your probe.
-
Check Allow regulation: If checked "Allow regulation", now is output regulation enabled.
-
Hysteresis: Number value for hysteresis in regulation loop.
-
Humidity for output ON: Humidity value for output switched to on.
-
Maximum run time in activate: Maximum duration when activating the output (in minutes and seconds). After this time, the output will turn off regardless of other events (conditions).
-
Humidity for output OFF: Humidity value for output switched to off.
-
Select Output: Select station for output.
-
Check Enable DS18B20: If checked enabled DS18B20, I2C bus is in plugin enabled.
-
DS18B20 error timeout: Time in seconds for keeping the last valid DS18B20 value when an I2C read returns an error value such as -127. During this time the plugin does not overwrite the displayed/logged value with the error value. Use 0 to keep the last valid value without timeout.
-
DS18B20 sensors: Enable only the connected DS18B20 sensors (DS1-DS6) and set a label for each used sensor. Disabled sensors are hidden from the graph and log view.
-
Label for sensor DS 1-6: Type label for Your probe Dallas DS18B20.
-
Status: Status window from the plugin.
-
Graph To use the graph it is necessary to enable saving of measured data (from temperature sensors). When using for the first time, name the sensors first and then delete all records (using the button).
-
Select filter for graph history Without limits Day filter Month filter Year filter
Visit Martin Pihrt's blog. for more information HW board with DS18B20 probe.
The following notes are generated from the help page shipped with this plug-in. Field names are also explained directly in the OSPy settings page.
This plugin needs DHT11 (22) sensor connected to GPIO 10 (pin 19 MOSI). Sensor DHT11 (22) is placed on main OSPy board by developer pihrt.com
This plugin allows the control of some stations (eg Fan) depending on the humidity of the sensor
This plug-in allows you to connect 1-6 DS18B20 sensors connected to the external hardware board via an bus (address 0x03)
If logging is enabled, a graph with measured data will be displayed at the bottom of the screen
Visit for more information
The PCB board for 6 probe DS18B20 (board by pihrt.com)
Humidity sensor DHT is connected to Raspberry Pi header
On the main OSPy board by pihrt.com is already installed.
DHT11 vs DHT22
We have two versions of the DHT sensor, they look a bit similar and have the same pinout, but have different characteristics. Here are the specs:
- DHT11
Ultra low cost, 3 to 5V power and I/O, 2.5mA max current use during conversion (while requesting data).
Good for 20-80% humidity readings with 5% accuracy.
Good for 0-50C temperature readings +-2C accuracy.
No more than 1 Hz sampling rate (once every second).
Body size 15.5mm x 12mm x 5.5mm.
4 pins with 0.1 inch spacing.
- DHT22/AM2302 (Wired version)
Low cost, 3 to 5V power and I/O, 2.5mA max current use during conversion (while requesting data).
Good for 0-100% humidity readings with 2-5% accuracy.
Good for -40 to 80C temperature readings +-0.5C accuracy.
No more than 0.5 Hz sampling rate (once every 2 seconds).
Body size 15.1mm x 25mm x 7.7mm.
Check OSPy → Diagnostics first and remove passwords, tokens, private addresses and other secrets before sharing logs. Report reproducible plug-in problems in the OSPy-plugins issue tracker.
Start
Reference
Catalog sections






