Need Help Using Braswell I2C With Level Shifter

Discussion in 'UDOO X86' started by MacDH, Jul 10, 2018.

  1. MacDH

    MacDH New Member

    Joined:
    Jan 23, 2018
    Messages:
    8
    Likes Received:
    5
    Hello, I have been playing with I2C on the Arduino side for quite some time now. I would like to be able to use the Braswell I2C pins with my 3.3v PIC. I bought a PCA9306 Level Shifter and wired it the following liking:
    https://cdn.sparkfun.com/assets/0/8/4/e/9/5294eb19ce395f223a8b4567.jpg

    I'm using the current version of Arch Linux. I have i2ctools installed, I have loaded the i2c-dev module and can see the following i2c buses using i2cdetect -l:
    Code:
    i2c-0    Synopsys DesignWare I2C adapter
    i2c-1    Synopsys DesignWare I2C adapter
    i2c-2    SMBus I801 adapter at 2040
    i2c-3    i915 gmbus ssc
    i2c-4    i915 gmbus vgs
    i2c-5    i915 gmbus panel
    i2c-6    i915 gmbus dpc
    i2c-7    i915 gmbus dpb
    i2c-8    i915 gmbus dpd
    i2c-9    DPDDC-B
    i2c-10   DPDDC-C
    i2c-11   DPDDC-D
    I know the majority of these are hardware resources and that i2c-0 and i2c-1 are most likely the buses I'm looking for. However when i try to find an address I don't get the address I'm looking for (This includes every bus).

    Am I missing something here? I have searched all the forums for further information but have found none. Any help at all would be greatly appreciated.
     
  2. MacDH

    MacDH New Member

    Joined:
    Jan 23, 2018
    Messages:
    8
    Likes Received:
    5
    Update: Started using an oscilloscope. The correct bus channel is i2c-0 for the pins I am using. The problem is with how I am setting up the level shifter. Will update further when I get answers.
     
  3. waltervl

    waltervl UDOOer

    Joined:
    Dec 12, 2015
    Messages:
    2,314
    Likes Received:
    580
  4. MacDH

    MacDH New Member

    Joined:
    Jan 23, 2018
    Messages:
    8
    Likes Received:
    5
    That is the same forum thread I got advise from to buy a PCA9306 level shifter. Its specifically tailored for I2C and SMBus level translation. Except, the one I bought comes with built in pull-up resistors. This makes me wonder if this is why its not working since the UDOO already has built in pull-up resistors as well.

    The wiki page for the PCA9306 Level Translator I bought:
    http://www.geeetech.com/wiki/index.php/PCA9306_Level_Translator_Breakout
     
  5. Araceli

    Araceli New Member

    Joined:
    Jul 31, 2018
    Messages:
    2
    Likes Received:
    0
    Hi, did you find any solution?
     
  6. MacDH

    MacDH New Member

    Joined:
    Jan 23, 2018
    Messages:
    8
    Likes Received:
    5
    I could not get I2C working with the the PCA9306 Level Translator I bought. I believe this is because it had pull up resistors built into the PCB. Since the UDOO already has pull-up resistors, I think doubling the resistance is ruining the communication. So I bought two 8 Channel Logic Level Bi-directional Converter Modules (TXS0108E). I have yet to try them but they look like there isn't any pull-up resistors. I will test it for you today and get back with you to see if I can get it to work.
     
    Araceli likes this.
  7. MacDH

    MacDH New Member

    Joined:
    Jan 23, 2018
    Messages:
    8
    Likes Received:
    5
    Okay! So, I got the TXS0108E to work. The clock and data are successfully translating from 1.8v to 3.3v. I confirmed this with an oscilloscope. However I still wasn't able to detect my microchip, but that is because its in a battery with its own power source and its a little funky. Despite that, the correct way to connect to the TXS0108E is as follows:

    (BRASWELL) Pin 33 1.8v to (TXS0108E) VA
    (BRASWELL) Pin 34 SCL to (TXS0108E) A4
    (BRASWELL) Pin 35 SDA to (TXS0108E) A5
    Low Power Source (In this case 1.8v) to (TXS0108E) OE <--- This is mandatory for the TXS0108E to function. I put a direct wire from VA to OE.
    (ARDUINO) 3.3v Source to (TXS0108E) VB
    (ARDUINO) Ground to (TXS0108E) GND
    (TXS0108E) VB to your I2C device voltage connection if needed
    (TXS0108E) B4 to your I2C device SCL
    (TXS0108E) B5 to your I2C device SDA
    (TXS0108E) GND to your I2C device ground

    Imgur - Reference Photos:
    https://imgur.com/a/oqvALFD
     
  8. Araceli

    Araceli New Member

    Joined:
    Jul 31, 2018
    Messages:
    2
    Likes Received:
    0
    Thank you very much for your answer!! I bought PCA9306 :( i will try doing the connection in the datasheet
     
  9. ccs_hello

    ccs_hello UDOOer

    Joined:
    Apr 15, 2017
    Messages:
    536
    Likes Received:
    194
    Probably just clip out the pull up resistors on the PCA9306 breakout board (the 1.8V side.)
    1 minute job.
     

Share This Page