Create OP AMP Symbol with text file in PSPICE

Discussion in 'Electronics Resources' started by Mick84, Jun 6, 2015.

  1. Mick84

    Thread Starter New Member

    Feb 8, 2015
    12
    0
    I cant find a PSPICE model for a LM386 Op Amp IC that will work with PSPICE.

    I just need a basic step by step how to use the sub circuit model text file to create the component with the correct behaviour!

    I have found the text file online but haven't a clue how to create the LM386 from the text file.
    It is an 8 Pin IC.

    Here is the text file I found posted online:

    Code (Text):
    1.  
    2. *lm386 subcircuit model follows:
    3.  
    4. * IC pins: 2 3 7 1 8 5 6 4
    5. * | | | | | | | |
    6. ..subckt lm386 inn inp byp g1 g8 out vs gnd
    7.  
    8. * input emitter-follower buffers:
    9.  
    10. q1 gnd inn 10011 ddpnp
    11. r1 inn gnd 50k
    12. q2 gnd inp 10012 ddpnp
    13. r2 inp gnd 50k
    14.  
    15. * differential input stage, gain-setting
    16. * resistors, and internal feedback resistor:
    17.  
    18. q3 10013 10011 10008 ddpnp
    19. q4 10014 10012 g1 ddpnp
    20. r3 vs byp 15k
    21. r4 byp 10008 15k
    22. r5 10008 g8 150
    23. r6 g8 g1 1.35k
    24. r7 g1 out 15k
    25.  
    26. * input stage current mirror:
    27.  
    28. q5 10013 10013 gnd ddnpn
    29. q6 10014 10013 gnd ddnpn
    30.  
    31. * voltage gain stage & rolloff cap:
    32.  
    33. q7 10017 10014 gnd ddnpn
    34. c1 10014 10017 15pf
    35.  
    36. * current mirror source for gain stage:
    37.  
    38. i1 10002 vs dc 5m
    39. q8 10004 10002 vs ddpnp
    40. q9 10002 10002 vs ddpnp
    41.  
    42. * Sziklai-connected push-pull output stage:
    43.  
    44. q10 10018 10017 out ddpnp
    45. q11 10004 10004 10009 ddnpn 100
    46. q12 10009 10009 10017 ddnpn 100
    47. q13 vs 10004 out ddnpn 100
    48. q14 out 10018 gnd ddnpn 100
    49.  
    50. * generic transistor models generated
    51. * with MicroSim's PARTs utility, using
    52. * default parameters except Bf:
    53.  
    54. ..model ddnpn NPN(Is=10f Xti=3 Eg=1.11 Vaf=100
    55. + Bf=400 Ise=0 Ne=1.5 Ikf=0 Nk=.5 Xtb=1.5 Var=100
    56. + Br=1 Isc=0 Nc=2 Ikr=0 Rc=0 Cjc=2p Mjc=.3333
    57. + Vjc=.75 Fc=.5 Cje=5p Mje=.3333 Vje=.75 Tr=10n
    58. + Tf=1n Itf=1 Xtf=0 Vtf=10)
    59.  
    60. ..model ddpnp PNP(Is=10f Xti=3 Eg=1.11 Vaf=100
    61. + Bf=200 Ise=0 Ne=1.5 Ikf=0 Nk=.5 Xtb=1.5 Var=100
    62. + Br=1 Isc=0 Nc=2 Ikr=0 Rc=0 Cjc=2p Mjc=.3333
    63. + Vjc=.75 Fc=.5 Cje=5p Mje=.3333 Vje=.75 Tr=10n
    64. + Tf=1n Itf=1 Xtf=0 Vtf=10)
    65.  
    66. ..ends
    67. *----------end of subcircuit model-----------
    68.  
    Moderators note : Please use code tags for pieces of code
     
    Last edited by a moderator: Jun 6, 2015
  2. crutschow

    Expert

    Mar 14, 2008
    13,050
    3,244
    That is the model file. It is a text file that you give a .lib extension.
    You need to mate that with the schematic graphic for an op amp so you can add it to a schematic.

    This should help you with the details.
     
    Last edited: Jun 7, 2015
Loading...