API Reference¶
qwiic_tmp102¶
Python module for the [SparkFun Qwiic TMP102 Sensor](https://www.sparkfun.com/products/16304)
This python package is a port of the existing [SparkFun Qwiic TMP102 Sensor Arduino Examples](https://github.com/sparkfun/SparkFun_TMP102_Arduino_Library/tree/master/examples)
This package can be used in conjunction with the overall [SparkFun qwiic Python Package](https://github.com/sparkfun/Qwiic_Py)
New to qwiic? Take a look at the entire [SparkFun qwiic ecosystem](https://www.sparkfun.com/qwiic).
- class qwiic_tmp102.QwiicTmp102Sensor(address=None, i2c_driver=None)[source]¶
- Parameters
address – The I2C address to use for the device. If not provided, the default address is used.
i2c_driver – An existing i2c driver object. If not provided a driver object is created.
- Returns
The TMP102 Sensor device object.
- Return type
Object
- begin()[source]¶
Initialize the operation of the Soil Moisture Sensor module :return: Returns true of the initialization was successful, otherwise False. :rtype: bool
- property connected¶
Determine if a Soil MoistureSensor device is conntected to the system.. :return: True if the device is connected, otherwise False. :rtype: bool
- is_connected()[source]¶
Determine if a Soil MoistureSensor device is conntected to the system.. :return: True if the device is connected, otherwise False. :rtype: bool
- one_shot(setOneShot=0)[source]¶
Sets the SingleShot Register. Returns 1 after the conversion is complete
- set_alert_mode(mode)[source]¶
// Set Alert type // 0 - Comparator Mode: Active from temp > T_HIGH until temp < T_LOW // 1 - Thermostat Mode: Active when temp > T_HIGH until any read operation occurs
- set_conversion_rate(rate)[source]¶
// Set the conversion rate (0-3) // 0 - 0.25 Hz // 1 - 1 Hz // 2 - 4 Hz (default) // 3 - 8 Hz
- set_extended_mode(mode)[source]¶
Enable or disable extended mode 0 - disabled (-55C to +128C) 1 - enabled (-55C to +150C)