08-14-2018 10:28 AM
I'm glad it worked for you! I noticed I left in some extra code you probably don't need. That was for another switch I was using. I don't think you need this code (Red X).
03-27-2020 07:19 AM
Hi Arteitle / Hazmat
It would be helpful, if you can briefly sequence your code sequence. I'm trying to establish i2c communication b/w ftdi and tps65400. I face the same issue mentioned i.e. I could select particular mux channel of tca9548 but not able to access the slave since SCx not toggling.
Rough python code is here
from i2c import *
from pyftdi.i2c import *
import time
i2c = I2cController()
i2c.configure('ftdi://ftdi:2232h/1', clockstretching=False) ### ftdi://ftdi:2232:FT2Y4V6J/1
results = i2c.poll(address = 0x70, write=False, relax=True)
print(results)
slave = i2c.get_port(0x70)
print(slave)
slave_2 = i2c.get_port(0x69) #Based on the resistor value used and the address mentioned in the datasheet
print(slave_2)
print(slave_2.address)
time.sleep(0.00001)
print(slave.frequency)
print(slave.address)
slave.write(out=b'\x80', relax=False, start=True) # channel 4 of mux --> this could be read back
slave_2.write_to(regaddr=0x00, out = b'\x00', relax = False, start = True) #PAGE 0 slave2 tps65400 doesn't ack