The trend of science and technology is changing rapidly.

What Is a Phototransistor? Circuits, Operation and Selection

Insights 7

A phototransistor is a light-sensitive transistor that converts incident light into a change in collector current. Internal transistor gain amplifies the light-generated signal, allowing relatively simple detection circuits. Its useful sensitivity and speed depend on wavelength, illumination, bias, load resistance and whether the device operates in its active region or saturation.

How does a phototransistor detect light?

In a common bipolar phototransistor, light reaches a photosensitive junction and generates carriers. Transistor action increases the resulting collector current. Many devices expose only collector and emitter connections; others provide a base connection that permits additional control of gain or leakage behavior.

Light changes current rather than providing a ready-made logic level. A load resistor or another signal-conditioning circuit converts that current into voltage. The following circuitry interprets the voltage as an analog value or a switching state.

The Phototransistors category includes detector components with different packages and optical characteristics. A clear lens, a dark filter and a side-looking package can have different spectral or viewing behavior. Identify the exact part rather than choosing by appearance.

Side-view phototransistor package with an optical encoder background

Phototransistor vs photodiode vs photoresistor

DetectorElectrical behaviorCommon reason to choose itMain tradeoff
PhototransistorLight-controlled current with internal gainSimple presence or interruption detectionGain variation, speed and linearity
PhotodiodePhotocurrent often used with an amplifierFast or controlled analog measurementAmplifier and noise design may be required
PhotoresistorLight-dependent resistanceSlow light-level response where appropriateResponse time and material characteristics

Internal gain can make a phototransistor convenient for a threshold circuit. It does not mean the device is universally more accurate or detects a lower signal in every measurement system. Compare the whole circuit’s noise, gain and bandwidth at the intended operating point.

An optocoupler combines an emitter and receiver in an isolation package; a discrete phototransistor does not provide isolation on its own. Check whether the requirement is free-space light detection or an electrically isolated signal path before sourcing a replacement.

How does a basic phototransistor circuit work?

For a common NPN circuit, connect the emitter to ground and the collector to the supply through a pull-up resistor, taking the output at the collector. Increasing illumination increases collector current and lowers the output voltage until the circuit reaches its limiting region. Confirm the real device pinout before connecting it.

In the active region, a simplified relationship is Vout ≈ VCC − IC × RL. With an assumed 3.3 V supply, 10 kΩ resistor and 100 µA collector current, the calculated output is about 2.3 V. This is an illustrative calculation; actual photocurrent must come from the selected device’s specified conditions or measurement.

An emitter-load arrangement gives a rising voltage with increasing current, within its compliance range. Both arrangements need checks for the receiving circuit’s input range. TT Electronics’ application note describes active and switching configurations. [1]

Phototransistor component with an emitter and encoder interruption arrangement

How should you choose the load resistor?

Choose the resistor using the weakest useful light signal, the strongest background signal and the required response time. A larger resistance can create a larger voltage change from a small current. It can also reduce the available current range before clipping and interact with capacitance to slow the response.

For a digital threshold, ensure the illuminated state crosses the input’s low-level threshold with margin while the dark or background condition remains above the high-level threshold. Include device variation and temperature effects. For an analog measurement, preserve headroom across the expected light range instead of driving the transistor deeply into saturation.

Vishay’s ambient-light sensor note shows that resistor choice depends on illumination and output-current variation. Its specific resistor values apply to the devices and circuit in that note; they are not universal phototransistor design values. [2]

Why do saturation, dark current and ambient light matter?

Saturation can make a switching state easy to detect, but stored charge can delay turn-off. A detector that meets a timing requirement under one resistor and illumination condition may respond differently in a deeply saturated circuit. Use the datasheet’s test conditions when interpreting rise and fall times.

Dark current is the current that flows without the intended illumination. It generally changes with temperature. Ambient light adds another background contribution and may leave little headroom for the wanted signal. Optical shielding, wavelength selection and emitter modulation can help when supported by the system.

The sensing path also changes with alignment, distance and contamination. Test the minimum expected light current and the maximum unwanted current rather than adjusting a prototype around one convenient sample. Keep electrical and optical tolerances in the same assessment. [3]

Phototransistor package beside an optical test board and measurement probe

Which phototransistor specifications belong in a selection checklist?

Check peak sensitivity and spectral bandwidth against the light source. Record viewing angle, package orientation and any optical filter. Then compare photocurrent at specified illumination, dark current, voltage limits and switching conditions. Photocurrent figures measured at different irradiance or wavelength are not directly comparable.

ChipApex lists XZRNI56W-1 as a side-view SMD phototransistor associated with a 940 nm sensing description. Use the exact manufacturer documentation to confirm the spectral response, mechanical orientation and electrical ratings. A catalog wavelength label alone does not establish compatibility with every infrared emitter.

For a larger detection assembly, Optical Sensors may provide other device types. A bare detector and a complete threshold-output sensor require different supporting electronics.

How do you test a phototransistor circuit?

First verify supply polarity, the package pinout and the load connection. Measure the output with the intended emitter off and on, then repeat at the maximum distance and least favorable alignment. Test background light from the directions likely in service.

Use an oscilloscope for a moving or pulsed target. Observe both transitions; a correct steady-state voltage does not prove that the circuit resolves short events. If a brighter emitter makes turn-off worse, check saturation before increasing gain or resistance again.

Phototransistor FAQ

Can a phototransistor detect visible light and infrared?

Some devices respond over both regions, while filters and semiconductor material restrict others. Match the full spectral response to the intended source. The package’s appearance is insufficient to identify its useful wavelength range.

Why do many phototransistors have only two pins?

The base can be left without an external terminal because light provides the control signal. Two-pin parts still contain transistor action internally. Three-terminal devices allow additional base circuitry when their design supports it.

Can a phototransistor connect directly to a microcontroller?

It usually needs a load or signal-conditioning circuit. Verify the output range and input thresholds, including the microcontroller’s supply state. A comparator with hysteresis may be appropriate when the optical signal crosses a threshold slowly or noisily.

Does a bigger load resistor always improve detection?

No. It increases voltage response to a given current within the valid region, but it can reduce bandwidth or drive the circuit into saturation. Choose it with the light range, background current and timing requirement together.

What information helps with a sourcing inquiry?

Provide the exact part number or required wavelength, package, viewing direction, photocurrent test conditions and response time. Include the emitter and circuit conditions where possible. ChipApex inquiries can also specify quantity and acceptable mechanical alternatives without assuming electrical equivalence.

References

  1. TT Electronics: Application Circuits for the Phototransistor Switch
  2. Vishay: Ambient Light Sensors—Circuit and Window Design
  3. Renesas: Phototransistor dark current, saturation and switching specifications
The prev:

Related recommendations

Expand more!