TXB0108 Bi-Directional Voltage Translator Not Working For SPI [RESOLVED]

I set up a circuit that logs data from an Analog Devices ADXL362 accelerometer to a SD card over SPI. The Texas Instruments TXB0108 is to translate between the ATmega328p 5V and sensor/SD 3v3.

Running a simple blink program (1Hz), the level shifter behaves as expected. However, with SPI signals the results are confusing. The CS signal simply outputs high (3v3) the whole time no matter what the input is doing. The faster clock and MOSI signals result in a noisy DC signal at 1.2-1.5V. There seems to be much trouble with this bi-directional IC having a weak driver, but there are no pull up/down resistors or anything apart from the SD card and ADXL362 connected. As of right now, only the accelerometer is connected.

My PCB currently only has the translator and accelerometer and is being used as the breakout board for a clone Uno. However, the exact same symptoms were there with another version where the PCB was built and bypass capacitors were immediately present. I've also tried only enabling the translator a few seconds after the MCU boots, right now OE is tied to high with a 10k resistor.

The strangest part is that the same design worked with the SD card at an earlier stage. As I was trying to solder the accelerometer, a real time clock battery exploded and that PCB was ruined (in addition to my day thanks to a resulting trip to the hospital :P). I've also tried a couple of different TXB0108 chips in case one was faulty.

I realise that SPI doesn't require bi-directional translation and perhaps I should have gone with a tried chip and saved myself the hassle. However, as the board is already made I'd prefer to get it working. I really am out of things to try so would love any suggestions!

Thanks,
Abdullah

This won't help much and not what you want to hear but I used to think those chips were the answer to all my prayers, but when I used one in a design for SPI it just would not work. I didn't personally do the hardware debug but spent ages on Skype with the guys that did, all to no avail.

It's been a while now but the symptoms you describes sound awfully familiar.

Eventually we gave up and changed the design.

One thing about those chips is that they have a 4k series resistor on the IO, that means they are a very weak driver and of course you can't really use pullup/down resistors but you don't appear to have any.


Rob

Thanks for your quick reply Rob! I'm glad to know I'm not the only one, I guess I'll keep debugging as it worked for an instant.

If you at all have the time for a quick look, what do you think of this device? http://www.ti.com/lit/ds/symlink/txs0108e.pdf http://www.ti.com/lit/an/scea044/scea044.pdf

It has a different architecture designed for open-drain applications and not what I'm looking for on paper, but since it has the same land pattern I might give it a try.

Thanks,
Abdullah

The TXS versions may be better as they don't seem to have the series resistors I mentioned.

Have you tried one yet?


Rob

Hi Rob,

I've ordered one in and will update once I've given it a try.

Thanks!
Abdullah

This problem has been resolved (somewhat) by using the stronger TXS0108 chip. The passive configuration is a 10k pull-up on the OE pin and 100nF capacitors between VCCa/VCCb and ground.

It's not quite pulling up to VCCa and ground but apart from that the signal is very clear and should be sufficient for SPI.

Thanks for the update.


Rob

I used TXB010x in a design with MAX31865s. Signals from uC to the MAX31865 were okay for 1:1 connections. SCK & MOSI might even have been fine. Issue I ran into was MISO coming back - MAX31865 did not have nuch drive capability and the TXB010x needed 2mA drivers to make the IO switch. I ended up lifting MISO pins on the TXB010x and connecting the MAX31865 directly.
I won't be using those chips any more, opting for part like 74HC4050 for 5V to 3.3V and 74HC125 (or one of it's single driver variants) with SS controlling OE to let MISO out onto the SPI bus instead.

I just looked back at the design I mentioned above and we used '125s as well. I too will not be using the TXB chips again, I might consider the TXS ones as Abdullah seems to have had some success with them, but OTOH if 125s work why bother.

It's funny how a common chip from a huge vendor can give so much grief.


Rob

Just to confirm, I haven't tried it in circuit yet and these are only observations from probing with a scope. I don't see why it wouldn't behave but we know that's not how electronic components work :stuck_out_tongue:

I'm quite disappointed with this series, especially coming from someone like TI. If I could afford the wait for a new PCB or in the future, I'd definitely go with a 74* chip.

Abdullah

I'm afraid I have to take issue with some of "anti" TXB comments.
My application was for using an Arduino 5-V digout to go into a 3.3-V XBee digin.
I spent a considerable amount of time messing about with 74HC125's to achieve this.
Feeding the 125 with 3.3-V Vcc and 5-V on the input (only one used, all others grounded), a la Nick Gammon Gammon Forum : Electronics : Microprocessors : Connecting 512 Kbyte EEPROM (flash memory) to your processor using SPI example, only to find that the 125 output was about 4.0-V, no good for XBee.
On the contrary, the TXB0101, behaved flawlessly, spot on 3.3-V output and worked just as well the other direction.
Personally, I'm not going to spend anymore time with 125's and will stick with TXB's even if they are SOT-23.
I'm aware of the 54/74 differences and the HCT/HC differences and may spend another day on it, but doesn't look promising.

Hello,
Just an update on this.
TXB0101 works fine (for my application at least, 5-V from Arduino, 3.3-V to XBee)
74HC4050 works fine.
74HC125 put out 4-V, so no good.
74AHC125 (note the "A" for advanced) worked fine.
So spoiled for choice - the 4050 is easiest to implement so will be first choice - another application calls for 1.5 to 1.3-V in and 5-V out so TXB0101 will be used.
Also tried 74HC14 Schmitt which was also OK, but feeding it 3.3-V Vcc and 5-V on one input (all others grounded) 1-second high, 10-seconds low and scoping the ouput inverted pin, produced a strange and very reproducable "overshoot" on the 12th and 13th pulses - no idea why, but won't be using the Schmitt just in case of XBee damage.