-2
\$\begingroup\$

As a part of a project I am producing a light gate incorporating a photo-transistor and an LED.

The design features feedback between the the LED and photo-transistor, so it would be useful to be able to test the behavior of the circuit in SPICE.

Is there a functionality in LT-SPICE simulation to use the output of the LED as the input for a photo transistor?

\$\endgroup\$
3
  • \$\begingroup\$ Have you done any research so far into this problem? \$\endgroup\$
    – Andy aka
    Sep 1, 2015 at 10:18
  • \$\begingroup\$ Did you have a look how optocoupler models do it? \$\endgroup\$
    – PlasmaHH
    Sep 1, 2015 at 10:53
  • \$\begingroup\$ Someone is asking how to make an optocouple in ltspice and they are being given down thumbs. You gotta love the intellectual pursuits and helpfulness of this "community". \$\endgroup\$ Jan 6, 2018 at 1:13

1 Answer 1

2
\$\begingroup\$

As you can see in, e.g., the 4N25 model that ships with LTSpice, the base-collector photodiode of the transistor is modelled with a voltage-controlled current source that measures the voltage drop over a resistor in series with the LED:

* Copyright © Linear Technology Corp. 1998, 1999, 2000.  All rights reserved.
*
.subckt 4N25 1 2 3 4 5
R1 N003 2 2
D1 1 N003 LD
G1 3 5 N003 2 .876m
C1 1 2 18p
Q1 3 5 4 [4] NP
.model LD D(Is=1e-20 Cjo=18p)
.model NP NPN(Bf=610 Vaf=140 Ikf=15m Rc=1 Cjc=19p Cje=7p Cjs=7p C2=1e-15)
.ends 4N25
\$\endgroup\$

Not the answer you're looking for? Browse other questions tagged or ask your own question.