pyupm_max44000 module¶
-
class
pyupm_max44000.
MAX44000
(bus, devAddr=74)[source]¶ Bases:
object
API for the MAX44000 Ambient and Infrared Proximity Sensor.
ID: max44000
Name: Ambient and Infrared Proximity Sensor
Category: light
Manufacturer: maxim
Connection: i2c
Link:https://www.maximintegrated.com/en/products/analog/sensors-and- sensor- interface/MAX44000.html Maxim Integrated*MAX44000 is an ambient and infrared proximity sensor. This module was tested on the Maxim IntegratedMAX44000PMB1 PMOD module from the analog PMOD kit.
C++ includes: max44000.hpp
-
getAmbient
()[source]¶ uint16_t getAmbient()
Reads the ambient value from the sensor (based on ambient data).
-
getProximity
()[source]¶ uint16_t getProximity()
MAX44000 object destructor; basically, it closes the I2C connection. ~MAX44000 (); no need for the destructor - the I2c connection will be closed when m_i2cMaxControlCtx variable will be out of context Reads the proximity value from the sensor (based on ambient data).
-
i2cReadReg_16
(reg)[source]¶ uint16_t i2cReadReg_16(int reg)
Reads a two-byte register
reg: Address of the register
-
i2cReadReg_8
(reg)[source]¶ uint8_t i2cReadReg_8(int reg)
Reads a one-byte register
reg: Address of the register
-