Schematic Designs for DIY Infrared Receivers and Transmitters

Build a high-sensitivity photodetector circuit using a TSOP38238 module–its carrier frequency of 38 kHz ensures rejection of ambient light interference. Pair it with a 100 Ω resistor in series to limit current, then connect a 10 µF electrolytic capacitor across the power rails to filter noise. For precise signal decoding, route the output through a Schmitt-trigger inverter (e.g., 74HC14) to clean up pulse edges before microcontroller input.
For emission circuits, use a 940 nm LED driven by a 2N3904 transistor in switch mode. A 47 Ω resistor in series with the LED prevents thermal runaway while maintaining sufficient radiant intensity. Modulate the signal with a 555 timer IC in astable mode, configured via 10 kΩ resistors and a 1 µF capacitor to generate stable 38 kHz pulses. Ensure ground planes are separate for detector and emitter to avoid cross-talk.
Power both sections from a regulated 5V supply with 0.1 µF bypass capacitors near each IC. Test emission strength by sweeping a photodiode (BPW34) across the range: peak response at 10 cm confirms optimal alignment. For extended reach, replace the single LED with an array of four 940 nm LEDs, each with its own 220 Ω resistor, arranged in a circular pattern.
Avoid placing the detector near switching regulators or fluorescent lighting–both emit harmonics that degrade performance. If interference persists, shield the circuit with a Faraday cage fashioned from copper tape. For bidirectional setups, use dual TSOP modules with orthogonal polarization filters to prevent signal collisions. Calibrate modulation depth by oscilloscope: target 30–50% duty cycle for reliable reception.
Building Optical Signal Circuits: Key Designs

Use a 38 kHz modulation frequency for optimal noise rejection in near-field optical communication systems. Pair a TSOP1738 sensor with a 555 timer IC in astable mode to generate carrier waves. This configuration achieves reliable signal detection within 10 meters under controlled ambient light.
For power-constrained applications, replace discrete transistor-based emission drivers with an IRLML6401 MOSFET. This component reduces current draw by 40% while maintaining consistent pulse strength. Implement a 220 µF smoothing capacitor across the power supply to eliminate voltage dips during transmission bursts.
Critical Component Selection

- Emission sources: SFH 4230 (940 nm) or OSRAM SFH 4545 (850 nm) for balanced range/efficiency
- Detection modules: VS1838B (supports 36-40 kHz) or TSSP4P38 (extended range)
- Logic gates: 74HC00 quad NAND for basic encoding/decoding tasks
- Resistors: 1% tolerance metal film for precise timing circuits
Design biasing networks with temperature compensation in mind. Use a 15 kΩ thermistor in series with a 10 kΩ fixed resistor for the SFH 4230 emitter to maintain consistent output across 0-60°C. For receivers, add a 330 Ω series resistor to limit input current during false signal spikes from fluorescent lighting interference.
Common Pitfalls to Avoid
- Omitting pull-up resistors on open-collector outputs causes erratic behavior
- Incorrect timing capacitor selection (use polyester film for ≤5% drift)
- Exposing unshielded traces to ambient light degrades SNR by 18-22 dB
- Paralleling emitters without individual current-limiting resistors creates thermal runaway
- Ignoring PCB ground plane pour sacrifices noise immunity in long-distance links
Optimize point-to-point links by placing the detection module at a 7° angle from the emitter’s optical axis. Use baffles or IR-absorbing paint to prevent sidewall reflections in multi-node networks. For battery-powered designs, implement a sleep-mode circuit using a CD4013 flip-flop to reduce standby current to 2 µA.
Test emission patterns with an oscilloscope and photodiode probe. Verify signal integrity by checking for
Core Elements of Optical Link Setups

Select a photodiode with a spectral response matching 850–950 nm wavelengths for optimal signal capture. PIN diodes like the Vishay BPV10NF offer fast recovery (
Emitters should be driven with constant-current circuits to prevent thermal runaway; an NPN transistor (e.g., 2N3904) paired with a 150 Ω resistor delivers stable 30–50 mA pulses. Use 38 kHz modulation for interference rejection–encode data via pulse-width or Manchester coding to distinguish valid packets from ambient light. Add a 100 nF bypass capacitor near the emitter’s anode to suppress voltage spikes during switching.
Key Circuit Parameters
| Component | Spec | Purpose |
|---|---|---|
| Photodiode | 25–100 µA/mW sensitivity | Signal detection |
| Current-limiting resistor | 150 Ω (adjust for 30–50 mA) | Emitter protection |
| Bypass capacitor | 100 nF | Noise filtering |
| Modulation frequency | 38 kHz | Interference avoidance |
For detection circuitry, a transimpedance amplifier (TIA) built around an op-amp (e.g., LM358) converts photocurrent into usable voltage levels. Place a 10 kΩ feedback resistor to achieve a 1 V/mA gain; higher values increase sensitivity but risk saturation from ambient light. AC-couple the input with a 1 µF capacitor to block DC offsets, and add a 10 kΩ pull-down resistor to define the baseline voltage.
Synchronize timing with hardware or software interrupts–an AVR microcontroller can sample the TIA output every 26 µs (38 kHz cycle) using its internal timer. Calibrate threshold voltages empirically: target 20–30% above ambient noise floor for robust packet validation. Shield sensitive traces with a grounded copper pour to reduce capacitive coupling from adjacent digital lines.
Common Pitfalls
Avoid pairing dissimilar wavelengths–emit at 940 nm yet detect at 880 nm, and signal integrity degrades by 40%. Exceeding 50 mA emitter current shortens lifespan; replace standard 5 mm LEDs with high-output variants (e.g., Osram SFH 409) to maintain range without stressing components. Verify power rails: a sag below 4.5 V during 30 mA pulses distorts modulation, so regulate with an LDO or switch-mode converter for consistent performance.
Step-by-Step IR Emitter Circuit Assembly
Select a 940nm wavelength LED for optimal signal propagation in most consumer applications. Solder the anode to a 220Ω current-limiting resistor to prevent thermal damage–this value ensures stable operation at 5V DC while maintaining a forward current of ~20mA. Position the LED at a 15° emission angle for targeted transmission; wider angles dilute signal strength disproportionately. Use flux-core solder for clean joints and verify polarity with a multimeter before powering the circuit.
Component Layout and Wiring

Place the NPN transistor (2N2222 or equivalent) with the collector connected to the LED’s cathode via a 1kΩ base resistor to modulate signal pulses. Route the emitter to ground and the base to the microcontroller’s output pin–ensure to minimize parasitic capacitance, which degrades high-frequency pulses. Add a 10µF electrolytic capacitor across the power rails to suppress voltage spikes during switching; ceramic capacitors lack sufficient energy storage for transient loads.
Encode signals using 38kHz carrier frequency for compatibility with standard protocols. Configure the microcontroller to generate 50% duty cycle pulses–longer pulses reduce range, while shorter pulses degrade receiver sensitivity. Test viability by transmitting 20-bit NEC codes and measuring signal integrity at 5 meters with an oscilloscope; expect >2V peak-to-peak at the photodiode if assembly is correct. Replace malfunctioning LEDs immediately–>70°C junction temperatures irreversibly degrade output power.
Building a Photo-Sensing Module with Signal Decoding

Select a TSOP38238 or VS1838B sensor for 38 kHz demodulation–these components reject ambient noise while capturing pulsed signals. Power the sensor with a clean 3-5V supply, bypassed with a 47 µF electrolytic and 0.1 µF ceramic capacitor to filter high-frequency ripple. Connect the output directly to a microcontroller’s interrupt-capable pin, such as Arduino’s D2 or ESP32’s GPIO4, to trigger real-time processing without polling delays.
Implement a 56 kΩ pull-up resistor on the sensor’s output pin to prevent floating states; this ensures rapid transition between logic levels. For robust decoding, sample the incoming signal at twice the carrier frequency (76 kHz) to satisfy the Nyquist criterion. Store raw pulses in a circular buffer to handle bursts–16 to 32 entries suffice for most protocols like NEC or RC5. Apply a Schmitt trigger (e.g., 74HC14) if signal integrity degrades due to long cable runs or reflective interference.
Pair the sensor with an OP-amp preamplifier (e.g., MCP6002) when detecting weak sources, such as 5-meter distant LEDs. Configure the op-amp in non-inverting mode with a gain of 10-50x, using a 1 kΩ input resistor and a 10-50 kΩ feedback resistor. AC-couple the sensor output with a 1 µF capacitor to block DC drift, then clamp the amplified signal to 3.3V with a BAT54 Schottky diode to protect downstream logic.
Decode pulses using bit-banging or hardware peripherals like ESP32’s RMT/Arduino’s PulseIn. For NEC protocol, measure pulse durations: 9 ms lead-in, 4.5 ms for logic 1, 560 µs for logic 0, and 2.25 ms gap. Validate checksums by summing address and command bytes, discarding frames with mismatches. For Sony SIRC, account for 600 µs bit period variations (±10%); implement hysteresis in code to tolerate timing drift.
Shield the module from interference with a grounded copper foil enclosure or position it away from SMPS coils (minimum 10 cm). For multi-protocol support, prioritize decoding routines: NEC → RC5 → Sony SIRC. Store decoded data in volatile memory for immediate use; avoid flash writes unless logging is critical. Test range by transmitting 10 ms bursts at varying distances–expect reliable performance up to 8 meters with a 940 nm LED at 100 mA.