100nF

MOSFET level shifter calculator

A level shifter connects two sections of a bus that run from different supplies. For an open-drain bus like I²C the shifter is one N-channel MOSFET per line: gate to the lower supply, source to the low-voltage bus, drain to the high-voltage bus, pull-ups on both sides. With nothing pulling, the FET is off and each side rests at its own rail; when either side pulls low, the FET conducts and the other side follows. For a 3.3 V to 5 V bus with 4.7 kΩ pull-ups and 100 pF each side, the FET has 2.9 V of gate drive, the pulling device sinks 1.6 mA, and each side rises in 398 ns — over Fast-mode's 300 ns, so 3.3 kΩ. Enter the two supplies, the pull-ups, the capacitances and the FET's threshold and on-resistance to check every state of the circuit against the I²C limits.

3.30 V5.00 V0FET off at 371 nslow side, τ = 470 nshigh side, τ = 470 nsmode rise limit 300 nstime after the low-side driver releases
Fig 1 — Release from the low side: the 3.30 V bus rises on its own pull-up, the FET turns off once the source is within 1.50 V of the gate (371 ns), and only then does the 5.00 V bus rise on its own pull-up. The bar is the mode's 30–70 % rise-time limit.
Gate drive V_DD1 − V_OL · margin over V_GS(th)
2.90 V · 1.40 V
State 3: V_DD1 needed to pull the low side through the body diode
2.60 V
Sink current for the pulling device · mode limit
1.60 mA · 3.00 mA
Low level on the far side: high side · low side
402 mV (V_IL 1.50 V) · 401 mV (V_IL 990 mV)
Rise time 30–70 %: low side · high side · limit
398 ns · 398 ns · 300 ns — over
FET turn-off delay after a low-side release
371 ns

398 ns of rise time is over the mode's 300 ns: a smaller pull-up on that side, less capacitance, or the slower mode. The high side also starts 371 ns late, which the mode's timing budget has to absorb.

How this is calculated

Standard: Nexperia AN10441; NXP UM10204 limits; TI SCEA030

VGS=VDD1−VOL>VGS(th)V_{GS} = V_{DD1} - V_{OL} > V_{GS(th)}
AN10441 state 2: a low-side pull-down turns the FET on.
VDD1>VOL+VF+VGS(th)V_{DD1} > V_{OL} + V_F + V_{GS(th)}
AN10441 state 3: the body diode drags the low side down until the FET takes over.
Isink=VDD1−VOLRp1+VDD2−VOLRp2≤IOLI_{sink} = \frac{V_{DD1} - V_{OL}}{R_{p1}} + \frac{V_{DD2} - V_{OL}}{R_{p2}} \leq I_{OL}
The pulling device carries both pull-ups; 3 mA in Standard and Fast mode, 20 mA in Fast-mode Plus (UM10204).
Vlow,far=VOL+VDD,far−VOLRp,farRDS(on)≤0.3 VDD,farV_{low,far} = V_{OL} + \frac{V_{DD,far} - V_{OL}}{R_{p,far}} R_{DS(on)} \leq 0.3\, V_{DD,far}
The far side's low level through the FET, against the I²C V_IL.
tr=0.8473 RpCb per sidet_r = 0.8473\, R_p C_b \text{ per side}
30–70 % rise time, UM10204 table 11; each side has its own R and C.
toff=Rp1C1ln⁡VDD1VGS(th)t_{off} = R_{p1} C_1 \ln \frac{V_{DD1}}{V_{GS(th)}}
After a low-side release, the high side is held until the source rises to V_DD1 − V_GS(th).

Assumptions

What sets whether a MOSFET level shifter works

A level shifter is needed when two devices with different supplies have to talk and the lower one is not tolerant of the higher rail — or, in the other direction, when a low swing "simply does not have enough logic swing to pass through the input VIH level of the receiving device" (TI SCEA030). For a bidirectional open-drain bus the shifter must work both ways with no direction pin, and Nexperia's AN10441 gives the circuit that does: one N-channel MOSFET per line, "the gates connected to the lowest supply voltage VDD1, the sources to the bus lines of the 'lower-voltage' section, and the drains to the bus lines of the 'higher-voltage' section", with pull-ups on both sides to their own rails.

The note walks its three states. Nobody pulling: gate and source both at VDD1, "VGS is below the threshold voltage and the MOSFET is not conducting", so each side sits at its own rail — that is the level shift. A low-side device pulls: the source drops, "VGSrises above the threshold and the MOSFET starts to conduct", dragging the high side down through it. A high-side device pulls: "the drain-substrate diode of the MOSFET" pulls the low side down "until VGS passes the threshold and the MOSFET starts to conduct", and the low side follows to the same low. States 2 and 3 are the wired-AND the I²C specification requires; state 1 is the shifting.

Every one of those states has a number in it, and the calculator checks each. The gate drive is only VDD1 − VOL, so the FET's threshold must be comfortably below that — the reason a 1.8 V low side needs a low-threshold part. State 3 has to get the low side to VOL + VF + VGS(th) through the body diode before the FET takes over, which is a second, stricter, condition on VDD1. Whichever device pulls low sinks both pull-ups through the conducting FET, against the mode's specified sink current. The far side's low level is VOL plus its own pull-up current through RDS(on). And each side rises on its own RC when released, with the high side unable to start until the low side has risen within VGS(th) of the gate and switched the FET off.

Worked example: 3.3 V to 5 V I²C, 4.7 kΩ each side, 100 pF each

The calculator's defaults: a 3.3 V controller section and a 5 V peripheral section, AN10441's own supplies, 4.7 kΩ pull-ups to each rail, 100 pF on each side, a FET with a 1.5 V maximum threshold and 2 Ω on at the available drive, checked as a Fast-mode bus.

gate drive     3.3 − 0.4                        = 2.9 V     margin 1.4 V over V_th 1.5 V
state 3        needs V_DD1 > 0.4 + 0.7 + 1.5     = 2.6 V     → 3.3 V is enough
sink           2.9 / 4.7k + 4.6 / 4.7k           = 1.60 mA   (limit 3 mA)
low on 5 V side  0.4 + 0.979 mA × 2 Ω            = 0.402 V   (V_IL 1.5 V)
rise, each side  0.8473 × 4.7 kΩ × 100 pF        = 398 ns    Fast-mode limit 300 ns — over
FET turn-off   4.7 kΩ × 100 pF × ln(3.3/1.5)     = 371 ns after the low side releases

for Fast-mode: R ≤ 300 ns / (0.8473 × 100 pF) = 3.54 kΩ → 3.3 kΩ: 280 ns, sink 2.27 mA

The levels and the sink current are fine; the rise time is the problem, and it would be the same problem without the shifter — 4.7 kΩ into 100 pF is a Standard-mode number. The shifter adds something the plain bus does not have: the high side's edge starts 371 ns after the low side's, because the FET holds it down until the low side has climbed to VDD1 − VGS(th). At 100 kHz that is invisible; at 400 kHz it is a third of the low period, and a lower-threshold FET shortens it as much as a smaller pull-up does.

Where the level shifter model stops being valid

Common level shifter mistakes

Further reading