ADS1115 16-bit analog to digital converter instance.
|
__init__(self,
*args,
**kwargs)
x.__init__(...) initializes x; see help(type(x)) for signature |
source code
|
|
|
|
|
_data_rate_config(self,
data_rate)
Subclasses should override this function and return a 16-bit value
that can be OR'ed with the config register to set the specified data
rate. |
source code
|
|
|
_conversion_value(self,
low,
high)
Subclasses should override this function that takes the low and high
byte of a conversion result and returns a signed integer value. |
source code
|
|
Inherited from object :
__delattr__ ,
__format__ ,
__getattribute__ ,
__hash__ ,
__new__ ,
__reduce__ ,
__reduce_ex__ ,
__repr__ ,
__setattr__ ,
__sizeof__ ,
__str__ ,
__subclasshook__
|
|
_read(self,
mux,
gain,
data_rate,
mode)
Perform an ADC read with the provided mux, gain, data_rate, and mode
values. |
source code
|
|
|
_read_comparator(self,
mux,
gain,
data_rate,
mode,
high_threshold,
low_threshold,
active_low,
traditional,
latching,
num_readings)
Perform an ADC read with the provided mux, gain, data_rate, and mode
values and with the comparator enabled as specified. |
source code
|
|
|
|
|
readList(self,
register,
length)
Read a length number of bytes from the specified register. |
source code
|
|
|
read_adc(self,
channel,
gain=1,
data_rate=None)
Read a single ADC channel and return the ADC value as a signed
integer result. |
source code
|
|
|
read_adc_difference(self,
differential,
gain=1,
data_rate=None)
Read the difference between two ADC channels and return the ADC value
as a signed integer result. |
source code
|
|
|
start_adc(self,
channel,
gain=1,
data_rate=None)
Start continuous ADC conversions on the specified channel (0-3). |
source code
|
|
|
start_adc_comparator(self,
channel,
high_threshold,
low_threshold,
gain=1,
data_rate=None,
active_low=True,
traditional=True,
latching=False,
num_readings=1)
Start continuous ADC conversions on the specified channel (0-3) with
the comparator enabled. |
source code
|
|
|
|
|
start_adc_difference_comparator(self,
differential,
high_threshold,
low_threshold,
gain=1,
data_rate=None,
active_low=True,
traditional=True,
latching=False,
num_readings=1)
Start continuous ADC conversions between two channels with the
comparator enabled. |
source code
|
|
|
stop_adc(self)
Stop all continuous ADC conversions (either normal or difference
mode). |
source code
|
|
|
writeList(self,
register,
data)
Write bytes to the specified register. |
source code
|
|