diff --git a/adafruit_tca9548a.py b/adafruit_tca9548a.py index 5e709b1..dc3d7a1 100644 --- a/adafruit_tca9548a.py +++ b/adafruit_tca9548a.py @@ -81,6 +81,12 @@ def writeto(self, address, buffer, **kwargs): raise ValueError("Device address must be different than TCA9548A address.") return self.tca.i2c.writeto(address, buffer, **kwargs) + def writeto_then_readfrom(self, address, buffer_out, buffer_in, **kwargs): + """Pass thru for writeto_then_readfrom.""" + #In linux, at least, this is a special kernel function call + if address == self.tca.address: + raise ValueError("Device address must be different than TCA9548A address.") + return self.tca.i2c.writeto_then_readfrom(address, buffer_out, buffer_in, **kwargs) class TCA9548A(): """Class which provides interface to TCA9548A I2C multiplexer."""