Gates as Electrical Parts: Levels, Fan-Out and Logic Families

Read a logic data sheet: levels, noise margins and fan-out. Then decide when two logic families can be connected.

You Will Be Able To

  • Compute both noise margins between a driver and a receiver from their data sheets.
  • Compute DC fan-out from output and input currents, and say why AC fan-out is often smaller.
  • Say what to do with unused CMOS and TTL inputs.
  • Decide whether one logic family can drive another, and which family to put between them.
Lesson
G9.14
Time
30 min
Runs on
Your browser
Check
5 questions

A board mixed old LS TTL parts with new HC parts on one 5 V supply. Every signal from LS to HC worked on the bench. In the cold chamber some of them read 0 when they should read 1. The data sheets had predicted it.

An Output Window Must Sit Inside an Input WindowGuaranteed output levels of the driver against the input thresholds of the receiver.
  • I/O
  • Constraint
  • Structure
An output window must sit inside an input windowGuaranteed output levels of the driver against the input thresholds of the receiver. io LS output high at least 2.50 V io HC input reads 1 above 3.15 V io HCT input reads 1 above 2.00 V constraint Undefined band 2.50 to 3.15 V forHC may land herenot a valid 1margin 500 mV
  1. io LS output highat least 2.50 V
    • may land here → Undefined band
    • margin 500 mV → HCT input
  2. constraint Undefined band2.50 to 3.15 V for HC
    • not a valid 1 → HC input
  3. io HC inputreads 1 above 3.15 V
  4. io HCT inputreads 1 above 2.00 V
  1. LS into HC

    A guaranteed LS 1 can be as low as 2.50 V. The HC input only promises to read 1 above 3.15 V. Between them the result is not defined.

  2. LS into HCT

    HCT inputs switch at TTL levels: 1 above 2.00 V. The LS output clears that by 500 mV.

Read the diagram as text
  • LS output high: at least 2.50 V
  • HC input: reads 1 above 3.15 V
  • HCT input: reads 1 above 2.00 V
  • Undefined band: 2.50 to 3.15 V for HC
  • LS output high → Undefined band: may land here
  • Undefined band → HC input: not a valid 1
  • LS output high → HCT input: margin 500 mV

Data sheet values: SN74LS00 at 4.75 V, SN74HC00 and SN74HCT00 at 4.5 V.

Four Levels and Two Margins

A data sheet promises four voltages. An output gives at least V_OH when high and at most V_OL when low, at a stated current. An input reads 1 above V_IH and 0 below V_IL.

FamilySupplyV_OH minV_OL maxV_IH minV_IL maxOutput test current
74LS (TTL)5 V2.50 V0.50 V2.00 V0.80 VIOH −0.4 mA, IOL 8 mA
74HC (CMOS)4.5 V3.84 V0.33 V3.15 V1.35 VIOH −4 mA, IOL 4 mA
74HCT (CMOS, TTL inputs)4.5 V3.84 V0.33 V2.00 V0.80 VIOH −4 mA, IOL 4 mA
74LVC (3.3 V CMOS)3 V2.40 V0.40 V2.00 V0.80 VIOH −12 mA, IOL 12 mA
10EP (LVPECL)3.3 V2.23 V1.68 V2.15 V1.75 Vinto 50 Ω to VCC − 2 V

From the TI data sheets of the SN74LS00, SN74HC00, SN74HCT00 and SN74LVC00A, worst case. The 10EP row is the onsemi MC10EP16 at 25 °C. TI prints 2.5 V for LS V_OH; some vendors print 2.7 V.

The high noise margin is V_OH(driver) − V_IH(receiver). The low noise margin is V_IL(receiver) − V_OL(driver). Both must be positive, or some legal output is not a legal input.

DC Fan-Out from the Currents

Each input draws a current: I_IH when high and I_IL when low. An output can supply at most I_OH while keeping V_OH, and sink at most I_OL while keeping V_OL.

For LS TTL the low state is the expensive one: an LS input sources 400 µA into the driver when low. One LS output, rated for 8 mA, can hold 20 of them low.

A CMOS input draws almost nothing, at most 1 µA of leakage. By currents alone one HC output could drive thousands. The real limit is capacitance: each HCT input has up to 10 pF. The delay of the driver grows with the load, as in lesson G9.6. So the AC fan-out is set by the delay you can accept.

An HC output driving LS inputs is limited the other way: it sinks only 4 mA at its rated V_OL. The HC data sheet itself says it supports a fan-out of up to 10 LS loads.

Unused Inputs and Families

An open TTL input usually reads as 1, but it picks up noise. An open CMOS input floats near the middle of the supply, where both transistors conduct and the gate may oscillate. Tie every unused input to a rail.

DriverReceiverHigh marginLow marginWorks?
74LS (TTL)74HC (CMOS)-650 mV850 mVno
74LS (TTL)74HCT (CMOS, TTL inputs)500 mV300 mVyes
74HC (CMOS)74LS (TTL)1840 mV470 mVyes
74LVC (3.3 V CMOS)74HC (CMOS)-750 mV950 mVno
74HC (CMOS)74LVC (3.3 V CMOS)1840 mV470 mVyes: LVC inputs tolerate 5.5 V
10EP (LVPECL)74LVC (3.3 V CMOS)230 mV-880 mVno

Computed from the table above. Margins in millivolts; a negative margin means some legal output is not a legal input.

HCT is the classic bridge: CMOS outputs that swing to the rails, with inputs at TTL thresholds. 3.3 V LVC parts can take 5 V signals because their inputs tolerate 5.5 V. Their 1 is too low for an HC input, though.

ECL, emitter-coupled logic, is a separate world. Its transistors never saturate and draw a constant current, so it is fast and quiet on the supply. The levels sit near the top of the supply, less than a volt apart. For the 3.3 V form, LVPECL, they are 2.23 V and 1.68 V. An LVPECL 0 is far above a CMOS input's V_IL, so a translator is needed.

Asked in interviews
  1. What is a noise margin?

    The gap between what a driver guarantees and what a receiver needs. High margin = V_OH(min) − V_IH(min); low margin = V_IL(max) − V_OL(max). Both must be positive.

  2. How do you compute fan-out?

    DC fan-out is the smaller of I_OH / I_IH and I_OL / I_IL. For CMOS loads the input current is tiny. Fan-out is then limited by the capacitance the driver can switch in time.

  3. Why can a TTL output not drive an HC input reliably?

    An LS high level is only guaranteed above 2.5 V, while an HC input at 4.5 V needs 3.15 V. HCT inputs with TTL thresholds, or a level shifter, fix it.

Try It

The first line is LS driving LS: both margins are positive and the fan-out is 20.

HC driving HC has large margins, and the DC fan-out of 4000 only says that the input currents do not matter.

Add a line check("LS->HC", LS, HC); and run it. The high margin turns negative.

RUNIcarus Verilog · in your browser
Edit the code, then run it
Expected: LS->LS NMH=500 NML=300 fanout=20 HC->HC NMH=690 NML=1020 fanout=4000 LS->HCT NMH=500 NML=300 fanout=400

Check Yourself

Predict the outputThe same program for LS driving HCT. Predict the exact line.
module tb;
  // datasheet values in mV and uA (currents as magnitudes)
  typedef struct packed { int voh, vol, vih, vil, ioh, iol, iih, iil; } family_t;
  family_t LS = {32'd2500, 32'd500, 32'd2000, 32'd800, 32'd400, 32'd8000, 32'd20, 32'd400};
  family_t HC = {32'd3840, 32'd330, 32'd3150, 32'd1350, 32'd4000, 32'd4000, 32'd1, 32'd1};
  family_t HCT = {32'd3840, 32'd330, 32'd2000, 32'd800, 32'd4000, 32'd4000, 32'd1, 32'd1};
  family_t LVC = {32'd2400, 32'd400, 32'd2000, 32'd800, 32'd12000, 32'd12000, 32'd5, 32'd5};
  function automatic void check(string name, family_t d, family_t r);
    int nmh = d.voh - r.vih;            // high noise margin, mV
    int nml = r.vil - d.vol;            // low noise margin, mV
    int fan_h = d.ioh / r.iih;          // inputs the output can hold high
    int fan_l = d.iol / r.iil;          // inputs the output can hold low
    int fan = fan_h < fan_l ? fan_h : fan_l;
    $display("%s NMH=%0d NML=%0d fanout=%0d", name, nmh, nml, fan);
  endfunction
  initial begin
    check("LS->HCT", LS, HCT);
  end
endmodule
ConceptWhich pair of numbers sets the low-state fan-out?
ConceptWhy is the fan-out of a CMOS output into CMOS inputs set by capacitance in practice?
ConceptAn LVC part at 3 V must drive a 5 V HC input. What does the margin table say?
ConceptWhat should be done with an unused input of a CMOS gate?

Common Mistakes

Wrong Connect a 5 V TTL output to a 5 V HC input because both are "5 V logic".

An LS output is only guaranteed 2.50 V when high. An HC input at 4.5 V needs 3.15 V. The high margin is -650 mV: negative.

Fix Use an HCT part, whose inputs have TTL thresholds, or a level shifter.

Wrong Compute fan-out from the high state only.

An LS output can hold 20 LS inputs high and 20 low here. With other families the two numbers differ, and the smaller one counts.

Fix Compute both IOH / IIH and IOL / IIL, and take the smaller.

Wrong Leave unused CMOS inputs open.

A floating CMOS input drifts to the middle of the supply, where both transistors conduct. The HCT data sheet says every unused input must be held at VCC or GND.

Fix Tie unused inputs to a rail, directly or through a resistor, or to a used input of the same gate.

Wrong Treat a CMOS input that sits at a TTL high level as free.

At 2.4 V the input transistors are both partly on. The HCT data sheet allows 2.9 mA of extra supply current for each such input.

Fix Drive CMOS inputs close to the rails where power matters, or accept the extra current in the budget.

Remember

  • Noise margins: V_OH − V_IH and V_IL − V_OL, both from worst-case data sheet values. Both must be positive.
  • DC fan-out: the smaller of I_OH / I_IH and I_OL / I_IL.
  • CMOS loads draw almost no current; their capacitance limits fan-out through delay.
  • Never leave CMOS inputs open.
  • TTL into HC fails on the high level; HCT bridges TTL and CMOS. LVC tolerates 5 V inputs.

Practice

Report a problem with this page