This Input will execute a command in the shell and store the output as a float value. Perform any unit conversions within your script or command. A measurement/unit is required to be selected.
Option
Type
Description
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Command Timeout
Integer - Default Value: 60
How long to wait for the command to finish before killing the process.
User
Text - Default Value: mycodo
The user to execute the command
Current Working Directory
Text - Default Value: /home/pi
The current working directory of the shell environment.
All channels require a Measurement Unit to be selected and saved in order to store values to the database. Your code is executed from the same Python virtual environment that Mycodo runs from. Therefore, you must install Python libraries to this environment if you want them to be available to your code. This virtualenv is located at ~/Mycodo/env and if you wanted to install a library, for example "my_library" using pip, you would execute "sudo ~/Mycodo/env/bin/pip install my_library".
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Mycodo: Test Input: Save your own measurement value~
Manufacturer: Mycodo
Measurements: Variable measurements
This is a simple test Input that allows you to save any value as a measurement, that will be stored in the measurement database. It can be useful for testing other parts of Mycodo, such as PIDs, Bang-Bang, and Conditional Functions, since you can be completely in control of what values the input provides to the Functions. Note 1: Select and save the Name and Measurement Unit for each channel. Once the unit has been saved, you can convert to other units in the Convert Measurement section. Note 2: Activate the Input before storing measurements.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Channel Options
Name
Text
A name to distinguish this from others
Commands
Enter the Value you want to store as a measurement, then press Store Measurement.
Channel
Integer
This is the channel to save the measurement value to
Value
Decimal - Default Value: 10.0
This is the measurement value to save for this Input
This calculates RPM from pulses on a pin using pigpio, but has been found to be less accurate than the method #2 module. This is typically used to measure the speed of a fan from a tachometer pin, however this can be used to measure any 3.3-volt pulses from a wire. Use a resistor to pull the measurement pin to 3.3 volts, set pigpio to the lowest latency (1 ms) on the Configure -> Raspberry Pi page. Note 1: Not setting pigpio to the lowest latency will hinder accuracy. Note 2: accuracy decreases as RPM increases.
Option
Type
Description
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Raspberry Pi: Signal (Revolutions) (pigpio method #2)~
This is an alternate method to calculate RPM from pulses on a pin using pigpio, and has been found to be more accurate than the method #1 module. This is typically used to measure the speed of a fan from a tachometer pin, however this can be used to measure any 3.3-volt pulses from a wire. Use a resistor to pull the measurement pin to 3.3 volts, set pigpio to the lowest latency (1 ms) on the Configure -> Raspberry Pi page. Note 1: Not setting pigpio to the lowest latency will hinder accuracy. Note 2: accuracy decreases as RPM increases.
Option
Type
Description
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Pin: GPIO (BCM)
Integer
The pin to measure pulses from
Sample Time (Seconds)
Decimal - Default Value: 5.0
The duration of time to sample
Pulses Per Rev
Decimal - Default Value: 15.8
The number of pulses per revolution to calculate revolutions per minute (RPM)
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
A one- or two-point calibration can be performed. After exposing the probe to a concentration of CO2 between 3,000 and 5,000 ppmv until readings stabilize, press Calibrate (High). You can place the probe in a 0 CO2 environment until readings stabilize, then press Calibrate (Zero). You can also clear the currently-saved calibration by pressing Clear Calibration, returning to the factory-set calibration. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
High Point CO2
Integer - Default Value: 3000
The high CO2 calibration point (3000 - 5000 ppmv)
Calibrate (High)
Button
Calibrate (Zero)
Button
Clear Calibration
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
LED Only For Measure
Boolean - Default Value: True
Turn the LED on only during the measurement
LED Percentage
Integer - Default Value: 30
What percentage of power to supply to the LEDs during measurement
Gamma Correction
Decimal - Default Value: 1.0
Gamma correction between 0.01 and 4.99 (default is 1.0)
Commands
The EZO-RGB color sensor is designed to be calibrated to a white object at the maximum brightness the object will be viewed under. In order to get the best results, Atlas Scientific strongly recommends that the sensor is mounted into a fixed location. Holding the sensor in your hand during calibration will decrease performance. 1. Embed the EZO-RGB color sensor into its intended use location. 2. Set LED brightness to the desired level. 3. Place a white object in front of the target object and press the Calibration button. 4. A single color reading will be taken and the device will be fully calibrated.
Calibrate
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Compensation: Measurement
Select Measurement (Input, Function)
Select a measurement for temperature compensation
Temperature Compensation: Max Age (Seconds)
Integer - Default Value: 120
The maximum age of the measurement to use
Commands
A one- or two-point calibration can be performed. After exposing the probe to air for 30 seconds until readings stabilize, press Calibrate (Air). If you require accuracy below 1.0 mg/L, you can place the probe in a 0 mg/L solution for 30 to 90 seconds until readings stabilize, then press Calibrate (0 mg/L). You can also clear the currently-saved calibration by pressing Clear Calibration. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
Calibrate (Air)
Button
Calibrate (0 mg/L)
Button
Clear Calibration
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Compensation: Measurement
Select Measurement (Input, Function)
Select a measurement for temperature compensation
Temperature Compensation: Max Age (Seconds)
Integer - Default Value: 120
The maximum age of the measurement to use
Commands
Calibration: a one- or two-point calibration can be performed. It's a good idea to clear the calibration before calibrating. Always perform a dry calibration with the probe in the air (not in any fluid). Then perform either a one- or two-point calibration with calibrated solutions. If performing a one-point calibration, use the Single Point Calibration field and button. If performing a two-point calibration, use the Low and High Point Calibration fields and buttons. Allow a minute or two after submerging your probe in a calibration solution for the measurements to equilibrate before calibrating to that solution. The EZO EC circuit default temperature compensation is set to 25 °C. If the temperature of the calibration solution is +/- 2 °C from 25 °C, consider setting the temperature compensation first. Note that at no point should you change the temperature compensation value during calibration. Therefore, if you have previously enabled temperature compensation, allow at least one measurement to occur (to set the compensation value), then disable the temperature compensation measurement while you calibrate. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
Clear Calibration
Button
Calibrate Dry
Button
Single Point EC (µS)
Integer - Default Value: 84
The EC (µS) of the single point calibration solution
Calibrate Single Point
Button
Low Point EC (µS)
Integer - Default Value: 12880
The EC (µS) of the low point calibration solution
Calibrate Low Point
Button
High Point EC (µS)
Integer - Default Value: 80000
The EC (µS) of the high point calibration solution
Calibrate High Point
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
Set the Measurement Time Base to a value most appropriate for your anticipated flow (it will affect accuracy). This flow rate time base that is set and returned from the sensor will be converted to liters per minute, which is the default unit for this input module. If you desire a different rate to be stored in the database (such as liters per second or hour), then use the Convert to Unit option.
Option
Type
Description
I2C Address
Text
The address of the I2C device.
I2C Bus
Integer
The Bus the I2C device is connected.
FTDI Device
Text
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Flow Meter Type
Select(Options: [Atlas Scientific 3/8" Flow Meter | Atlas Scientific 1/4" Flow Meter | Atlas Scientific 1/2" Flow Meter | Atlas Scientific 3/4" Flow Meter | Non-Atlas Scientific Flow Meter] (Default in bold)
Set the type of flow meter used
Atlas Meter Time Base
Select(Options: [Liters per Second | Liters per Minute | Liters per Hour] (Default in bold)
If using an Atlas Scientific flow meter, set the flow rate/time base
Internal Resistor
Select(Options: [Use Atlas Scientific Flow Meter | Disable Internal Resistor | 1 K Ω Pull-Up | 1 K Ω Pull-Down | 10 K Ω Pull-Up | 10 K Ω Pull-Down | 100 K Ω Pull-Up | 100 K Ω Pull-Down] (Default in bold)
Set an internal resistor for the flow meter
Custom K Value(s)
Text
If using a non-Atlas Scientific flow meter, enter the meter's K value(s). For a single K value, enter '[volume per pulse],[number of pulses]'. For multiple K values (up to 16), enter '[volume at frequency],[frequency in Hz];[volume at frequency],[frequency in Hz];...'. Leave blank to disable.
K Value Time Base
Select(Options: [Use Atlas Scientific Flow Meter | Liters per Second | Liters per Minute | Liters per Hour] (Default in bold)
If using a non-Atlas Scientific flow meter, set the flow rate/time base for the custom K values entered.
Commands
The total volume can be cleared with the following button or with the Clear Total Volume Function Action.
Clear Total: Volume
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Compensation: Measurement
Select Measurement (Input, Function)
Select a measurement for temperature compensation
Temperature Compensation: Max Age (Seconds)
Integer - Default Value: 120
The maximum age of the measurement to use
Temperature Compensation: Manual
Decimal - Default Value: 20.0
If not using a measurement, set the temperature to compensate
LED Mode
Select(Options: [Always On | Always Off | Only On During Measure] (Default in bold)
When to turn the LED on
Commands
A one- or two-point calibration can be performed. After exposing the probe to a specific concentration of O2 until readings stabilize, press Calibrate (High). You can place the probe in a 0% O2 environment until readings stabilize, then press Calibrate (Zero). You can also clear the currently-saved calibration by pressing Clear Calibration, returning to the factory-set calibration. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
High Point O2
Decimal - Default Value: 20.95
The high O2 calibration point (percent)
Calibrate (High)
Button
Calibrate (Zero)
Button
Clear Calibration
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Compensation: Measurement
Select Measurement (Input, Function)
Select a measurement for temperature compensation
Temperature Compensation: Max Age (Seconds)
Integer - Default Value: 120
The maximum age of the measurement to use
Commands
A one-point calibration can be performed. Enter the solution's mV, set the probe in the solution, then press Calibrate. You can also clear the currently-saved calibration by pressing Clear Calibration. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
Calibration Solution mV
Integer - Default Value: 225
The value of the calibration solution, in mV
Calibrate
Button
Clear Calibration
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
Calibration Measurement is an optional setting that provides a temperature measurement (in Celsius) of the water that the pH is being measured from.
Option
Type
Description
I2C Address
Text
The address of the I2C device.
I2C Bus
Integer
The Bus the I2C device is connected.
FTDI Device
Text
The FTDI device connected to the input/output/etc.
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Compensation: Measurement
Select Measurement (Input, Function)
Select a measurement for temperature compensation
Temperature Compensation: Max Age (Seconds)
Integer - Default Value: 120
The maximum age of the measurement to use
Commands
Calibration: a one-, two- or three-point calibration can be performed. It's a good idea to clear the calibration before calibrating. The first calibration must be the Mid point. The second must be the Low point. And the third must be the High point. You can perform a one-, two- or three-point calibration, but they must be performed in this order. Allow a minute or two after submerging your probe in a calibration solution for the measurements to equilibrate before calibrating to that solution. The EZO pH circuit default temperature compensation is set to 25 °C. If the temperature of the calibration solution is +/- 2 °C from 25 °C, consider setting the temperature compensation first. Note that if you have a Temperature Compensation Measurement selected from the Options, this will overwrite the manual Temperature Compensation set here, so be sure to disable this option if you would like to specify the temperature to compensate with. Status messages will be sent to the Daemon Log, accessible from Config -> Mycodo Logs -> Daemon Log.
Compensation Temperature (°C)
Decimal - Default Value: 25.0
The temperature of the calibration solutions
Set Temperature Compensation
Button
Clear Calibration
Button
Mid Point pH
Decimal - Default Value: 7.0
The pH of the mid point calibration solution
Calibrate Mid
Button
Low Point pH
Decimal - Default Value: 4.0
The pH of the low point calibration solution
Calibrate Low
Button
High Point pH
Decimal - Default Value: 10.0
The pH of the high point calibration solution
Calibrate High
Button
Calibration Export/Import: Export calibration to a series of strings. These can later be imported to restore the calibration. Watch the Daemon Log for the output.
Export Calibration
Button
Calibration String
Text
The calibration string to import
Import Calibration
Button
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
A higher oversampling value means more stable readings with less noise and jitter. However each step of oversampling adds ~2 ms latency, causing a slower response time to fast transients.
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
The I2C address can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate and change the I2C address option after setting the new address.
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Warning: Counterfeit DS18B20 sensors are common and can cause a host of issues. Review the Additional URL for more information about how to determine if your sensor is authentic.
Option
Type
Description
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Warning: Counterfeit DS18B20 sensors are common and can cause a host of issues. Review the Additional URL for more information about how to determine if your sensor is authentic.
Option
Type
Description
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Offset
Decimal
The temperature offset (degrees Celsius) to apply
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Commands
Set the resolution, precision, and response time for the sensor. This setting will be written to the EEPROM to allow persistence after power loss. The EEPROM has a limited amount of writes (>50k).
Note: This module does not allow for multiple sensors to be connected at the same time. For multi-sensor support, use the MAX31865 CircuitPython Input.
Option
Type
Description
Pin: Cable Select
Integer
GPIO (using BCM numbering): Pin: Cable Select
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
A single topic is subscribed to and the returned JSON payload contains one or more key/value pairs. The given JSON Key is used as a JMESPATH expression to find the corresponding value that will be stored for that channel. Be sure you select and save the Measurement Unit for each channel. Once the unit has been saved, you can convert to other units in the Convert Measurement section. Example expressions for jmespath (https://jmespath.org) include temperature, sensors[0].temperature, and bathroom.temperature which refer to the temperature as a direct key within the first entry of sensors or as a subkey of bathroom, respectively. Jmespath elements and keys that contain special characters have to be enclosed in double quotes, e.g. "sensor-1".temperature. Warning: If using multiple MQTT Inputs or Functions, ensure the Client IDs are unique.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Host
Text - Default Value: localhost
Host or IP address
Port
Integer - Default Value: 1883
Host port number
Topic
Text - Default Value: mqtt/test/input
The topic to subscribe to
Keep Alive
Integer - Default Value: 60
Maximum amount of time between received signals. Set to 0 to disable.
Client ID
Text - Default Value: client_xwGF2wFt
Unique client ID for connecting to the server
Use Login
Boolean
Send login credentials
Use TLS
Boolean
Send login credentials using TLS
Username
Text - Default Value: user
Username for connecting to the server
Password
Text
Password for connecting to the server. Leave blank to disable.
Use Websockets
Boolean
Use websockets to connect to the server.
Channel Options
Name
Text
A name to distinguish this from others
JSON Key
Text
JMES Path expression to find value in JSON response
A topic is subscribed to for each channel Subscription Topic and the returned payload value will be stored for that channel. Be sure you select and save the Measurement Unit for each of the channels. Once the unit has been saved, you can convert to other units in the Convert Measurement section. Warning: If using multiple MQTT Inputs or Functions, ensure the Client IDs are unique.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Host
Text - Default Value: localhost
Host or IP address
Port
Integer - Default Value: 1883
Host port number
Keep Alive
Integer - Default Value: 60
Maximum amount of time between received signals. Set to 0 to disable.
Client ID
Text - Default Value: client_t3h9zD1a
Unique client ID for connecting to the server
Use Login
Boolean
Send login credentials
Use TLS
Boolean
Send login credentials using TLS
Username
Text - Default Value: user
Username for connecting to the server
Password
Text
Password for connecting to the server. Leave blank to disable.
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Accuracy
Select(Options: [Good Accuracy (33 ms, 1.2 m range) | Better Accuracy (66 ms, 1.2 m range) | Best Accuracy (200 ms, 1.2 m range) | Long Range (33 ms, 2 m) | High Speed, Low Accuracy (20 ms, 1.2 m)] (Default in bold)
Set the accuracy. A longer measurement duration yields a more accurate measurement
Notes when setting a custom timing budget: A higher timing budget results in greater measurement accuracy, but also a higher power consumption. The inter measurement period must be >= the timing budget, otherwise it will be double the expected value.
Option
Type
Description
I2C Address
Text
The address of the I2C device.
I2C Bus
Integer
The Bus the I2C device is connected.
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Range
Select(Options: [Short Range | Medium Range | Long Range | Custom Timing Budget] (Default in bold)
Select a range or select to set a custom Timing Budget and Inter Measurement Period.
Timing Budget (microseconds)
Integer - Default Value: 66000
Set the timing budget. Must be less than or equal to the Inter Measurement Period.
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Timing Budget (ms)
Integer - Default Value: 50
Set the timing budget between 10 to 200 ms. A longer duration yields a more accurate measurement.
Inter-Measurement Period (ms)
Integer
Valid range between Timing Budget and 5000 ms (0 to disable)
Commands
The I2C address of the sensor can be changed. Enter a new address in the 0xYY format (e.g. 0x22, 0x50), then press Set I2C Address. Remember to deactivate the Input and change the I2C address option after setting the new address.
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Temperature Offset
Decimal - Default Value: 4.0
Set the sensor temperature offset
Altitude (m)
Integer
Set the sensor altitude (meters)
Automatic Self-Calibration
Boolean
Set the sensor automatic self-calibration
Persist Settings
Boolean - Default Value: True
Settings will persist after powering off
Commands
You can force the CO2 calibration for a specific CO2 concentration value (in ppmv). The sensor needs to be active for at least 3 minutes prior to calibration.
CO2 Concentration (ppmv)
Decimal - Default Value: 400.0
Calibrate to this CO2 concentration that the sensor is being exposed to (in ppmv)
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
I2C Frequency: The SCD-30 has temperamental I2C with clock stretching. The datasheet recommends starting at 50,000 Hz.
I2C Frequency (Hz)
Integer - Default Value: 50000
Automatic Self Ccalibration (ASC): To work correctly, the sensor must be on and active for 7 days after enabling ASC, and exposed to fresh air for at least 1 hour per day. Consult the manufacturer’s documentation for more information.
Enable Automatic Self Calibration
Boolean
Temperature Offset: Specifies the offset to be added to the reported measurements to account for a bias in the measured signal. Must be a positive value, and will reduce the recorded temperature by that amount. Give the sensor adequate time to acclimate after setting this value. Value is in degrees Celsius with a resolution of 0.01 degrees and a maximum value of 655.35 C.
Temperature Offset
Decimal
Ambient Air Pressure (mBar): Specify the ambient air pressure at the measurement location in mBar. Setting this value adjusts the CO2 measurement calculations to account for the air pressure’s effect on readings. Values must be in mBar, from 700 to 1200 mBar.
Ambient Air Pressure (mBar)
Integer - Default Value: 1200
Altitude: Specifies the altitude at the measurement location in meters above sea level. Setting this value adjusts the CO2 measurement calculations to account for the air pressure’s effect on readings.
Altitude (m)
Integer - Default Value: 100
Commands
A soft reset restores factory default values.
Soft Reset
Button
Forced Re-Calibration: The SCD-30 is placed in an environment with a known CO2 concentration, this concentration value is entered in the CO2 Concentration (ppmv) field, then the Foce Calibration button is pressed. But how do you come up with that known value? That is a caveat of this approach and Sensirion suggests three approaches: 1. Using a separate secondary calibrated CO2 sensor to provide the value. 2. Exposing the SCD-30 to a controlled environment with a known value. 3. Exposing the SCD-30 to fresh outside air and using a value of 400 ppm.
CO2 Concentration (ppmv)
Integer - Default Value: 800
The CO2 concentration of the sensor environment when forcing calibration
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Automatic Self Ccalibration (ASC): To work correctly, the sensor must be on and active for 7 days after enabling ASC, and exposed to fresh air for at least 1 hour per day. Consult the manufacturer’s documentation for more information.
This Input module allows the use of any temperature/humidity sensor with the TH10/TH16. Changing the Sensor Name option changes the key that's queried from the returned dictionary of measurements. If you would like to use this module with a version of this device that uses the AM2301, change Sensor Name to AM2301.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
IP Address
Text - Default Value: 192.168.0.100
The IP address of the device
Sensor Name
Text - Default Value: SI7021
The name of the sensor connected to the device (specific key name in the returned dictionary)
This measures from several Kasa power devices (plugs/strips) capable of measuring energy consumption. These include, but are not limited to the KP115 and HS600.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Device Type
Select
The type of Kasa device
Host
Text - Default Value: 0.0.0.0
Host or IP address
Asyncio RPC Port
Integer - Default Value: 18846
The port to start the asyncio RPC server. Must be unique from other Kasa Outputs.
Commands
The total kWh can be cleared with the following button or with the Clear Total kWh Function Action. This will also clear all energy stats on the device, not just the total kWh.
This input queries the energy usage information from a WiFi outlet that is running the tasmota firmware. There are many WiFi outlets that support tasmota, and many of of those have energy monitoring capabilities. When used with an MQTT Output, you can both control your tasmota outlets as well as mionitor their energy usage.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
This input relies on an ADS1115 analog-to-digital converter (ADC) to measure pH and/or electrical conductivity (EC) from analog sensors. You can enable or disable either measurement if you want to only connect a pH sensor or an EC sensor by selecting which measurements you want to under Measurements Enabled. Select which channel each sensor is connected to on the ADC. There are default calibration values initially set for the Input. There are also functions to allow you to easily calibrate your sensors with calibration solutions. If you use the Calibrate Slot actions, these values will be calculated and will replace the currently-set values. You can use the Clear Calibration action to delete the database values and return to using the default values. If you delete the Input or create a new Input to use your ADC/sensors with, you will need to recalibrate in order to store new calibration data.
Option
Type
Description
I2C Address
Text
The address of the I2C device.
I2C Bus
Integer
The Bus the I2C device is connected.
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
pH Calibration Actions: Place your probe in a solution of known pH. Set the known pH value in the "Calibration buffer pH" field, and press "Calibrate pH, slot 1". Repeat with a second buffer, and press "Calibrate pH, slot 2". You don't need to change the values under "Custom Options".
Calibration buffer pH
Decimal - Default Value: 7.0
This is the nominal pH of the calibration buffer, usually labelled on the bottle.
Calibrate pH, slot 1
Button
Calibrate pH, slot 2
Button
Clear pH Calibration Slots
Button
EC Calibration Actions: Place your probe in a solution of known EC. Set the known EC value in the "Calibration standard EC" field, and press "Calibrate EC, slot 1". Repeat with a second standard, and press "Calibrate EC, slot 2". You don't need to change the values under "Custom Options".
Calibration standard EC
Decimal - Default Value: 1413.0
This is the nominal EC of the calibration standard, usually labelled on the bottle.
This input relies on an ADS1256 analog-to-digital converter (ADC) to measure pH and/or electrical conductivity (EC) from analog sensors. You can enable or disable either measurement if you want to only connect a pH sensor or an EC sensor by selecting which measurements you want to under Measurements Enabled. Select which channel each sensor is connected to on the ADC. There are default calibration values initially set for the Input. There are also functions to allow you to easily calibrate your sensors with calibration solutions. If you use the Calibrate Slot actions, these values will be calculated and will replace the currently-set values. You can use the Clear Calibration action to delete the database values and return to using the default values. If you delete the Input or create a new Input to use your ADC/sensors with, you will need to recalibrate in order to store new calibration data.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Set the calibration method to perform during Input activation
Commands
pH Calibration Actions: Place your probe in a solution of known pH. Set the known pH value in the `Calibration buffer pH` field, and press `Calibrate pH, slot 1`. Repeat with a second buffer, and press `Calibrate pH, slot 2`. You don't need to change the values under `Custom Options`.
Calibration buffer pH
Decimal - Default Value: 7.0
This is the nominal pH of the calibration buffer, usually labelled on the bottle.
Calibrate pH, slot 1
Button
Calibrate pH, slot 2
Button
Clear pH Calibration Slots
Button
EC Calibration Actions: Place your probe in a solution of known EC. Set the known EC value in the `Calibration standard EC` field, and press `Calibrate EC, slot 1`. Repeat with a second standard, and press `Calibrate EC, slot 2`. You don't need to change the values under `Custom Options`.
Calibration standard EC
Decimal - Default Value: 1413.0
This is the nominal EC of the calibration standard, usually labelled on the bottle.
This Input receives and stores measurements from the Data Storage Integration on The Things Network. If you have key/value pairs as your payload, enter the key name in Variable Name and the corresponding value for that key will be stored in the measurement database.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Start Offset (Seconds)
Integer
The duration to wait before the first operation
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Application ID
Text
The Things Network Application ID
App API Key
Text
The Things Network Application API Key
Device ID
Text
The Things Network Device ID
Channel Options
Name
Text
A name to distinguish this from others
Variable Name
Text
The TTN variable name
The Things Network: The Things Network: Data Storage (TTN v3, Payload jmespath Expression)~
This Input receives and stores measurements from the Data Storage Integration on The Things Network. The given Payload jmespath Expression is used as a JMESPATH expression to find the corresponding value that will be stored for that channel. Be sure you select and save the Measurement Unit for each channel. Once the unit has been saved, you can convert to other units in the Convert Measurement section. Example expressions for jmespath (https://jmespath.org) include temperature, sensors[0].temperature, and bathroom.temperature which refer to the temperature as a direct key within the first entry of sensors or as a subkey of bathroom, respectively. Jmespath elements and keys that contain special characters have to be enclosed in double quotes, e.g. "sensor-1".temperature.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Start Offset (Seconds)
Integer
The duration to wait before the first operation
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Application ID
Text
The Things Network Application ID
App API Key
Text
The Things Network Application API Key
Device ID
Text
The Things Network Device ID
Channel Options
Name
Text
A name to distinguish this from others
Payload jmespath Expression
Text
The TTN jmespath expression to return the value to store
Obtain a free API key at openweathermap.org. If the city you enter does not return measurements, try another city. Note: the free API subscription is limited to 60 calls per minute
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
Obtain a free API key at openweathermap.org. Notes: The free API subscription is limited to 60 calls per minute. If a Day (Future) time is selected, Minimum and Maximum temperatures are available as measurements.
Option
Type
Description
Measurements Enabled
Multi-Select
The measurements to record
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete
The CO2 measurement can also be obtained using PWM via a GPIO pin. Enter the pin number below or leave blank to disable this option. This also makes it possible to obtain measurements even if the UART interface is not available (note that the sensor can't be configured / calibrated without a working UART interface).
GPIO Override
Text
Obtain readings using PWM on this GPIO pin instead of via UART
Commands
Calibrate Zero Point
Button
Span Point (ppmv)
Integer - Default Value: 2000
The ppmv concentration for a span point calibration
This is the version of the sensor that does not include the ability to conduct automatic baseline correction (ABC). See the B version of the sensor if you wish to use ABC.
Option
Type
Description
UART Device
Text
The UART device location (e.g. /dev/ttyUSB1)
Period (Seconds)
Decimal
The duration between measurements or actions
Pre Output
Select
Turn the selected output on before taking every measurement
Pre Out Duration (Seconds)
Decimal
If a Pre Output is selected, set the duration to turn the Pre Output on for before every measurement is acquired.
Pre During Measure
Boolean
Check to turn the output off after (opposed to before) the measurement is complete