You're currently on: Catalog » Guides » SN74AHCT08PWR: an AND gate that lifts 3.3 V to 5 V logic
A 3.3 V microcontroller output looks like a high to a human reading a meter. To a 5 V CMOS input it can look like nothing at all. This guide explains why, and how one quad AND gate solves it.
A plain CMOS input decides between high and low by comparing the input to a fraction of its own supply. For 74HC logic the data sheet guarantees a high only from 3.15 V when the chip runs on 4.5 V – roughly 0.7 × VCC. Run the same chip on 5 V and it wants about 3.5 V before a high is guaranteed.
A 3.3 V output cannot reach that. It often appears to work on the bench at room temperature, and then fails on a cold morning, on a different batch, or when the supply drifts up. “It worked once” is not the same as “the data sheet guarantees it”.
Old TTL logic used fixed thresholds instead: anything at or above 2 V is a high, anything at or below 0.8 V is a low, regardless of supply. 3.3 V clears a 2 V threshold with 1.3 V to spare.
The SN74AHCT08 is CMOS inside – fast, almost no static current – but its inputs are deliberately given TTL thresholds: VIH 2 V minimum, VIL 0.8 V maximum over the whole 4.5 V to 5.5 V supply range. The outputs are ordinary CMOS outputs that swing to the 5 V rail.
That combination is the level shift. Feed 3.3 V logic into the input, take 5 V logic out. TI states it plainly in the data sheet: the TTL inputs accept voltages down to 3.3 V and translate up to 5 V.
This works in one direction only. The outputs swing all the way to VCC, so you must not point them at a 3.3 V input that is not 5 V tolerant. For 5 V → 3.3 V you need a different arrangement, such as the open-drain SN74LVC07A with a pull-up to the lower rail.
The inputs themselves are rated to 5.5 V at any valid supply, so a 5 V source driving an AHCT input is fine.
Use gate 1. VCC is pin 14, GND is pin 7, and the 3.3 V board and the 5 V board must share that ground. Put a 100 nF capacitor between pin 14 and pin 7, close to the chip.
The chip has four identical gates, so one package translates four signals – for example a 3.3 V SPI master’s clock, chip-select and data lines into a 5 V peripheral.
Instead of tying 1B permanently high, drive it from a control line. The gate then becomes a switch: while 1B is high the signal passes, while 1B is low the output is held low. That is the clean way to start and stop a clock without generating a runt pulse on a chip-select line.
If the enable has to come from an address or a device number, a decoder produces exactly one active line at a time – see the 74HC138 address-decoding guide. Note that a ’138 output is active low, so it must be inverted before it can enable an AND gate.
Specified at VCC = 4.5 V (dc levels) and 5 V ± 0.5 V (switching), 25 °C unless stated.
The supply current is not zero when you hold a TTL level. Every input parked at around 3.4 V instead of at a rail adds up to 1.5 mA. Four gates with both inputs at 3.3 V can therefore draw several milliamps even when nothing is switching. That is normal for an HCT-type part, not a fault.
Never leave an input floating. Unused inputs must be tied to VCC or GND. A floating CMOS input drifts around the threshold and makes the gate oscillate and heat up.
Mind the output current limits. The recommended working current is 8 mA per output; 25 mA per output and 50 mA through VCC or GND are absolute maximum ratings, not design targets. Do not use the gate as an LED driver at full brightness.
A slow or noisy signal needs conditioning first. An AND gate has no hysteresis. If the incoming edge is slower than 20 ns per volt, clean it up with a Schmitt-trigger input such as the 74AC14 hex Schmitt-trigger inverter before it reaches the translator.
iMania stocks Texas Instruments SN74AHCT08PWR. In TI’s part numbering, PW is the 14-pin TSSOP package (5.00 mm × 4.40 mm body) and R is the 2000-piece tape-and-reel carrier. It is a surface-mount part on a 0.65 mm pitch, so for breadboard work you will want a TSSOP-14 to DIP adapter board.
If you want the same function in through-hole and do not need level translation, the MC74HC08AN in PDIP-14 is the plain-HC equivalent – but remember that its inputs use the 0.7 × VCC rule described above and will not reliably accept 3.3 V signals at a 5 V supply.
The same TTL-threshold trick scaled up to eight bits is exactly what the SN74HCT541 octal bus buffer does, and when several sources must take turns on one wire you want 3-state outputs instead – see the SN74LS126A 3-state buffer guide.
View the SN74AHCT08PWR product page and availability.
Original data sheets: Texas Instruments SN54AHCT08, SN74AHCT08 (SCLS237P, October 2023). PDF. Threshold figures for plain HC logic from SN74HC08 (SCLS081J). PDF.
We use cookies to provide you with the best possible experience. They also allow us to analyze user behavior in order to constantly improve the website for you.