CraftBeerPi4 PT100/PT1000 Sensor Plugin
Project description
Craftbeerpi4 Plugin for PT100/PT1000 Sensor
PT100 / PT1000 probes using a max31865 chip. for wiring go to https://github.com/thegreathoe/cbpi-pt100-sensor/ updated 8/2/17
You can select the conversion mode and number of wires on your probe in software. You will need to select a setting to get the probe working after an update.
You will need to set the reference resistors on the craftbeerpi hardware page! My max31865 chip uses a 4,3 kohm resistor for the PT1000. It might be 430 ohm for a PT100 board
Using a max31865 board like: https://learn.adafruit.com/adafruit-max31865-rtd-pt100-amplifier/
Software installation:
- sudo pip3 install cbpi4-pt100x
- or install from repo: sudo pip3 install https://github.com/PiBrewing/cbpi4-pt100x/archive/main.zip
Hardware Installation:
- on your pi use the following GPIO pins:
- csPin = 8 this one can be any GPIO you want, if using multiple probes you change this on each one, but keep the other 3 pins the same
- misoPin = 9
- mosiPin = 10
- clkPin = 11
The code for the request to the max chip is from https://github.com/steve71/MAX31865 so all credit really goes there... i slightly modified the code from the craftbeerpi v3 plugin(https://github.com/thegreathoe/cbpi-pt100-sensor) to allow also the usage of tha PT1000 and added some other parameters.
Sensor Configuration
The sensor must be configured on the hardware page. The following parameters must be set and will affect your readings:
- csPin: The BCM number of the GPIO you max board cs pin is connected to.
- ResSens: Reistance in ohm of your sensor. Select 1000 for PT1000 or 100 for PT100.
- RefRest: Resistance in ohm of your reference resistor on your max board. Typically 4300 for a PT100 board and 430 for a PT100 board. The value is typically listed on the resistor of your board (Please have a look here for smd resistance codings.)
- offset: Defines a temperature offset for your temp probe.
- ignore_above: Ignores Temp readings above this value (0: deactivated)
- ignore_below: Ignores Temp readings below this value (0: deactivated)
- ignore_delta: If you experience issues with 'jumping' temp readings, you can define a threshold (only positive values are allowed) for the difference between two readings. If the difference between two subsequent readings is higher than the threshold, the value will be ignored. If the next reading is also higher (lower), this value is used / logged. (0: deactivated)
- alpha: calculates the average between 2 subsequent values. Must be between 0 and 1. (1: deactivated). 0.5 yields for instance in the average of two subsequent readings.
- ConfigText: You need to set this parameter to the configuration of your maxboard / sensor.
- Interval: defines the frequency of sensor readings in seconds.
- Kettle/Fermenter: You can select a Kettle OR Fermenter if you want to activate reduced sensor logging during inactivity of the Kettle / Fermenter
- Reducedlogging: Defines the logging interval for reduced logging in seconds (e.g. 300 would result in logging every 5 Minutes when the Kettle / Fermenter logic is not acitve) (0: no sensor logging during inactivity)
Please note that the max board delivers readings above 900C if no sensor is connected to the board.
Changelog:
- 25.06.23: (0.1.10) Better logging description on high delta value
- 09.06.23: (0.1.9) Updated descriptions for Sensor parameters on Hardware page. Updated README.
- 28.03.23: (0.1.8) No logging options in case of Kettle or Fermenter inactivity (set reducedlogging to 0)
- 25.03.23: (0.1.4) Reduced logging options in case of Kettle or Fermenter inactivity
- 10.05.22: (0.1.3) updated readme (removed cbpi add)
- 10.05.22: (0.1.2) Removed cbpi dependency
- 08.12.21: (0.1.1) Removed resampling as it caused issues with respect to long term stability (sensor unresponsivness)
- 01.12.21: (0.1.0) Improved handling of resampling in case of issues (test)
- 01.11.21: (0.0.11) Experimental update under development branch: Read another sample if delta between two values is too high
- 10.06.21: (0.0.10) Calculating average of 2 subsequent values.
- 29.05.21: (0.0.9) Added filter function to filter out outliers
- 14.04.21: (0.0.8) Adaption for properties (updated dataclass.py in cbpi)
- 09.04.21: (0.0.7) Fix in offset handling in case value is not None but empty
- 15.03.21: (0.0.6) Change to supprt cbpi >= 4.0.0.31
- 20.02.21: (0.0.4) Change to support cbpi >= 4.0.0.24. Added sensor log fucntionality
- 14.02.21: (0.0.3) Updated function to retrieve temperature unit. Units will be changed automatically for sensor when settigs saved properly. No need to update the sensor
- 09.02.21: (0.0.2) Added offset parameter and changed the GPIO.setmode. Currnetly, warnings are displayed during startup of CBPi. However, they cause typically no issues
- 05.02.21: (0.0.1) Adpated code to run under cbpi4
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
File details
Details for the file cbpi4-pt100x-0.1.10.tar.gz
.
File metadata
- Download URL: cbpi4-pt100x-0.1.10.tar.gz
- Upload date:
- Size: 23.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.0 CPython/3.9.13
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | d4b1048942ef68706f8fbe96847cb86f7eb75a3d268c64c928b21172fbc272ea |
|
MD5 | 48a650de1ac5d3b400f7ab057a5a3f07 |
|
BLAKE2b-256 | 495972a9153d3f126a70209263c3c0ab28e04fc7720c5e6337b2b060892ef04e |