![]() |
Qwiic_VEML6030_Py
2.0.0
Python for SFE Qwiic VEML6030
|
Public Member Functions | |
def | __init__ (self, address=None, i2c_driver=None) |
Constructor. More... | |
def | is_connected (self) |
Determines if this device is connected. More... | |
def | begin (self) |
Initializes this device with default parameters. More... | |
def | set_gain (self, gain_val) |
Sets the gain. More... | |
def | read_gain (self) |
Gets the gain. More... | |
def | set_integ_time (self, time) |
Sets the integration time. More... | |
def | read_integ_time (self) |
Gets the integration time. More... | |
def | set_protect (self, prot_val) |
Sets the persistence protect number. More... | |
def | read_protect (self) |
Gets the persistence protect number. More... | |
def | enable_int (self) |
Enables interrupts. More... | |
def | disable_int (self) |
Disables interrupts. More... | |
def | read_int_setting (self) |
Gets whether interrupts are enabled. More... | |
def | shut_down (self) |
Shuts down the device. More... | |
def | power_on (self) |
Powers on the device. More... | |
def | enable_pow_save (self) |
Enables power saving mode. More... | |
def | disable_pow_save (self) |
Disables power saving mode. More... | |
def | read_pow_sav_enabled (self) |
Gets whether power saving is enabled. More... | |
def | set_pow_sav_mode (self, mode_val) |
Sets the power saving mode. More... | |
def | read_pow_sav_mode (self) |
Gets the power saving mode. More... | |
def | read_interrupt (self) |
Gets whether an interrupt has triggered. More... | |
def | set_int_low_thresh (self, lux_val) |
Sets the low threshold for interrupts. More... | |
def | read_low_thresh (self) |
Gets the low threshold for interrupts. More... | |
def | set_int_high_thresh (self, lux_val) |
Sets the high threshold for interrupts. More... | |
def | read_high_thresh (self) |
Gets the high threshold for interrupts. More... | |
def | read_light (self) |
Gets the measured ambient light in lux. More... | |
def | read_white_light (self) |
Gets the measured white light in lux. More... | |
Public Attributes | |
address | |
Properties | |
connected = property(is_connected) | |
def qwiic_veml6030.QwiicVEML6030.__init__ | ( | self, | |
address = None , |
|||
i2c_driver = None |
|||
) |
Constructor.
int,optional | address: The I2C address to use for the device If not provided, the default address is used |
I2CDriver,optional | i2c_driver: An existing i2c driver object If not provided, a driver object is created |
def qwiic_veml6030.QwiicVEML6030.begin | ( | self | ) |
Initializes this device with default parameters.
True
if successful, otherwise False
def qwiic_veml6030.QwiicVEML6030.disable_int | ( | self | ) |
Disables interrupts.
def qwiic_veml6030.QwiicVEML6030.disable_pow_save | ( | self | ) |
Disables power saving mode.
def qwiic_veml6030.QwiicVEML6030.enable_int | ( | self | ) |
Enables interrupts.
def qwiic_veml6030.QwiicVEML6030.enable_pow_save | ( | self | ) |
Enables power saving mode.
def qwiic_veml6030.QwiicVEML6030.is_connected | ( | self | ) |
Determines if this device is connected.
True
if connected, otherwise False
def qwiic_veml6030.QwiicVEML6030.power_on | ( | self | ) |
Powers on the device.
def qwiic_veml6030.QwiicVEML6030.read_gain | ( | self | ) |
Gets the gain.
def qwiic_veml6030.QwiicVEML6030.read_high_thresh | ( | self | ) |
Gets the high threshold for interrupts.
def qwiic_veml6030.QwiicVEML6030.read_int_setting | ( | self | ) |
Gets whether interrupts are enabled.
True
if interrupts are enabled, otherwise False
def qwiic_veml6030.QwiicVEML6030.read_integ_time | ( | self | ) |
Gets the integration time.
def qwiic_veml6030.QwiicVEML6030.read_interrupt | ( | self | ) |
Gets whether an interrupt has triggered.
def qwiic_veml6030.QwiicVEML6030.read_light | ( | self | ) |
Gets the measured ambient light in lux.
def qwiic_veml6030.QwiicVEML6030.read_low_thresh | ( | self | ) |
Gets the low threshold for interrupts.
def qwiic_veml6030.QwiicVEML6030.read_pow_sav_enabled | ( | self | ) |
Gets whether power saving is enabled.
True
if power saving is enabled, otherwise False
def qwiic_veml6030.QwiicVEML6030.read_pow_sav_mode | ( | self | ) |
Gets the power saving mode.
See datasheet for the effects of each value
def qwiic_veml6030.QwiicVEML6030.read_protect | ( | self | ) |
Gets the persistence protect number.
def qwiic_veml6030.QwiicVEML6030.read_white_light | ( | self | ) |
Gets the measured white light in lux.
def qwiic_veml6030.QwiicVEML6030.set_gain | ( | self, | |
gain_val | |||
) |
Sets the gain.
gain_val | Gain, possible values: 1/8, 1/4, 1, and 2 :type: float |
def qwiic_veml6030.QwiicVEML6030.set_int_high_thresh | ( | self, | |
lux_val | |||
) |
Sets the high threshold for interrupts.
float | lux_val: High threshold in lux |
def qwiic_veml6030.QwiicVEML6030.set_int_low_thresh | ( | self, | |
lux_val | |||
) |
Sets the low threshold for interrupts.
float | lux_val: Low threshold in lux |
def qwiic_veml6030.QwiicVEML6030.set_integ_time | ( | self, | |
time | |||
) |
Sets the integration time.
int | time: Integration time in ms, possible values: 25, 50, 100, 200, 400, and 800 |
def qwiic_veml6030.QwiicVEML6030.set_pow_sav_mode | ( | self, | |
mode_val | |||
) |
Sets the power saving mode.
See datasheet for the effects of each value
int | mode_val: Power saving mode number, can be 1-4 |
def qwiic_veml6030.QwiicVEML6030.set_protect | ( | self, | |
prot_val | |||
) |
Sets the persistence protect number.
int | prot_val: Protect number |
def qwiic_veml6030.QwiicVEML6030.shut_down | ( | self | ) |
Shuts down the device.
qwiic_veml6030.QwiicVEML6030.address |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |
|
static |