LPS22HB absolute pressure and temperature sensor
Constructor to create LPS22HB sensor
arObj - the arduino parent object
propertyname, propertyvalue - optional property name, value pairs. Current known properties are: Current properties are:
I2C address of the sensor (default 0x5C)
I2C bus - 0 or 1 (default 0)
obj - created object
a = arduino()
sensor = lps22hb(a)
Read the temperature
obj - the sensor object
C - read temperature in deg C.
timestamp - timestamp when read
a = arduino()
s = lps22hb(a)
# get temp
temp = s.readTemperature
See also: lps22hb.
Read the pressure
obj - the sensor object
P - pressure reading from sensor.
timestamp - timestamp when read
Read the sensor data
obj - the sensor object
P - pressure reading from sensor.
C - temperature reading from sensor.
timestamp - timestamp when read
overrun - overrun flag.
readings - table structure with fields for Timestamp, Pressure, Temperature and Humidity.
Read the sensor info
obj - the sensor object
inf - structure containing the sensor information.
Structure fields are:
Chip firmware version
sensor id value
sensor type ’lps22hb’
Status value read from sensor
Flush sensor data
obj - the sensor object
None
Release the resources of the sensor
obj - the sensor object
None
Package: arduino