pub enum Command {
Show 22 variants
StartContinuousMeasurement = 33,
StopMeasurement = 260,
GetDataReady = 514,
ReadMeasurement = 768,
ReadRawMeasurement = 1_029,
ReadNumberConcentrationValues = 790,
SetTemperatureOffsetParameters = 24_754,
SetTemperatureAccelerationParameters = 24_832,
GetProductName = 53_268,
GetSerialNumber = 53_299,
GetDeviceStatus = 53_766,
ReadAndClearDeviceStatus = 53_776,
ResetDevice = 54_020,
StartFanCleaning = 22_023,
ActivateShtHeater = 14_128,
SetReadVocTuningParameters = 24_784,
SetReadVocAlgorithmState = 24_961,
SetReadNoxTuningParameters = 24_801,
ForcedRecalibration = 26_375,
SetReadCo2AutomaticSelfCalibration = 26_385,
SetReadAmbientPreassure = 26_400,
SetReadSensorAltitude = 26_422,
}Expand description
I2C Commands for the SEN66 according to its interface description.
Variants§
StartContinuousMeasurement = 33
Starts a continuous measurement and moves chip to measuring state. After the sending the command it might take some time until the first measurement is ready. Exec. Time: 50ms
StopMeasurement = 260
Stops measurements and returns to idle state. Wait at least 1000ms until starting a new measurement. Exec. Time: 1000ms
GetDataReady = 514
Queries whether a measurement can be read from the sensor’s buffer. The answer is 1 if a
measurement is available 0 otherwise.
Exec. Time: 20ms
ReadMeasurement = 768
If a measurement is available reads out the measurement. If no new data is available the
previous measurement is returned. If no data is available all data is set to the maximum
value (0xFFFF for u16, 0x7FFF for i16). The measurement contains the mass
concentration for PM1.0, PM2.5, PM4.0 and PM10.0 in ug/m³, the relative humidity in %, the temperature
in °C, the volatile organic compounds (VOC)
index,
the NOx
index and
CO2 concentration in ppm.
Exec. Time: 20ms
ReadRawMeasurement = 1_029
If a measurement is available reads out the measured raw values. If no new data is available
the previous measurement is returned. If no data is available all data is set to the maximum
value (0xFFFF for u16, 0x7FFF for i16). The measurement contains the raw relative
humidity in %, the raw temperature in °C, the VOC ticks, the NOx ticks and the CO2
concentration in ppm. For the first 10-11s after power-on or device reset the CO2 value will
be 0xFFFF.
Exec. Time: 20ms
ReadNumberConcentrationValues = 790
If a measurement is available reads out the measured number concentration values. If no
new data is available the previous values will be returned. If no data is available at all,
the data is set to the maximum value (0xFFFF for u16). The values contain the mass
concentration for PM0.5, PM1.0, PM2.5, PM4.0 and PM10.0 in p/cm³
Exec. Time: 20ms
SetTemperatureOffsetParameters = 24_754
Configures the temperature compensation via a slope and one of five offsets in °C. Exec. Time: 20ms
SetTemperatureAccelerationParameters = 24_832
Configures the temperature acceleration parameters for the RH/T engine. Thes parameters are volatile and reverted after a device reset. Exec. Time: 20ms
GetProductName = 53_268
Reads out the product name as a null-terminated ASCII string with up to 32 characters. Exec. Time: 20ms
GetSerialNumber = 53_299
Reads out the device’s serial number as a null-terminated ASCII string with up to 32 characters. Exec. Time: 20ms
GetDeviceStatus = 53_766
Read out the device’s status register as a 32-bit bitfield. Exec. Time: 20ms
ReadAndClearDeviceStatus = 53_776
Read the current device status as a 32-bit bitfield and clear all flags. Exec. Time: 20ms
ResetDevice = 54_020
Executes a device reset, the same as a power cycle. Exec. Time: 1200ms
StartFanCleaning = 22_023
Starts fan cleaning, where fan speed is set to a maximum for 10s. Wait at least 10s after this command until the next measurement. Exec. Time: 1ms
ActivateShtHeater = 14_128
Start the SHT’s inbuilt heater for 1s with 200mW. Wait at least 20s after this command until the next measurement. Exec. Time: 1300ms
SetReadVocTuningParameters = 24_784
Sets or reads the parameters that customize the VOC algorithm. Contains the index offset,
the learning time offset hours, the learning time gain hours, the max duration minutes, the
initial standard deviation and the gain factor (all i16).
Exec. Time: 20ms
SetReadVocAlgorithmState = 24_961
Sets or reads the state of the VOC algorithm to skip the initial learning phase. The state is encoded in a byte array of length 8. Exec. Time: 20ms
SetReadNoxTuningParameters = 24_801
Sets or reads the parameters that customize the VOC algorithm. Contains the index offset,
the learning time offset hours, the learning time gain hours, the max duration minutes, the
initial standard deviation and the gain factor (all i16).
Exec. Time: 20ms
ForcedRecalibration = 26_375
Executes a forced recalibration (FRC) of the CO2 signal. Send the target CO2 concentation
(as u16) and receive the correction factor as FRC - 0x8000 (as u16). Wait at least 1000ms after power-on
and 600ms after stopping measurement to send this command.
§Errors
If recalibration failes 0xFFFF is returned. Exec. Time: 500ms
SetReadCo2AutomaticSelfCalibration = 26_385
Enables/Disables or reads the status of the automatic self calibration (ASC) for the CO2
sensor via a bool value. Sending a 0x01 activates ASC, sending a 0x00 disables ASC.
Receiving a 0x01 indicates that ASC is enabled, a 0x00 indicates that ASC is disabled.
Exec. Time: 20ms
SetReadAmbientPreassure = 26_400
Sets or reads the ambient pressure value in hPA (as u16) which is used for the CO2
sensor’s pressure compensation.
Exec. Time: 20ms
SetReadSensorAltitude = 26_422
Sets or reads the sensors current altitude in m (as u16) which is used for the CO2
sensor’s pressure compensation.
Exec. Time: 20ms