#
# OTA-A
# 31 - cintA
-# 30 - zeroA
+# 30 - zeroA
# 29 - seA
# 28 - fastA
# 27..16 - tuneA
if ret < 0:
raise FTDI_Error(self.ftdi.get_error_string(self.context))
-
def _clear_scl(self):
self.io[self.scl] = 1
self.ftdi.set_bitmode(self.context, int(self.io), self.ftdi.BITMODE_BITBANG)
class AD524x(object):
+ """Digitally-controlled potentiometer."""
ADDR_BASE = intbv(0b0101100, max=2**7)
SEL_POS = 7
RS_POS = 6
return s
class DAC8568(object):
+ """8-channel DAC."""
CTL_WIDTH = 32
DAC_WIDTH = 16
#POR_VALUE = 2**(DAC_WIDTH - 1)
def _feature(self, value):
#self._word[4:0] = value #intbv(value, max=2**4)
self._word += ((value & 0xf) << 0)#intbv(value, max=2**4)
-
+
class ADS8201_Error(Exception):
pass
class ADS8201(object):
- """Configures and operates an ADS8201 over the given SPI bus."""
+ """Configures and operates an 8-channel ADC system, ADS8201 over the given
+ SPI bus."""
# register addresses
CH01_CCR = 0
CH23_CCR = 1