This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

TLV1805: Model for the TLV105.

Part Number: TLV1805

I work for Lockheed Martin and we can't load 3rd party software without getting permission from the IT mafia. Can you please send me the .txt of the model for the TLV1805. I want to add it to my LTspice simulation.

  • I feel your pain.  We have the same challenges here.

    Hope this works for you.

    Chuck

    TLV1805.txt
    * TLV1805
    *****************************************************************************
    * (C) Copyright 2018 Texas Instruments Incorporated. All rights reserved.
    *****************************************************************************
    ** This model is designed as an aid for customers of Texas Instruments.
    ** TI and its licensors and suppliers make no warranties, either expressed
    ** or implied, with respect to this model, including the warranties of 
    ** merchantability or fitness for a particular purpose.  The model is
    ** provided solely on an "as is" basis.  The entire risk as to its quality
    ** and performance is with the customer.
    *****************************************************************************
    *
    * This model is subject to change without notice. Texas Instruments
    * Incorporated is not responsible for updating this model
    *
    *****************************************************************************
    *
    ** Released by: Texas Instruments Inc.
    * Part: TLV1805Q1
    * Date: 06/06/2018 10:45:19
    * Model Type: All In One
    * Simulator: TINA
    * Simulator Version: 9
    * EVM Order Number: N/A 
    * EVM Users Guide:  N/A 
    * Datasheet: {ENTER THE DATASHEET DATE HERE}
    *
    * Model Version: 1.0
    *
    *****************************************************************************
    *
    * Updates:
    *
    * Version 1.0 : Release to Web
    *
    *****************************************************************************
    * Notes:
    * 1. The following parameters are modeled: 
    * 2. The following parameters are not modeled: 
    * 3. Such as such circuit is modeled as simplified representation
    *****************************************************************************
    
    
    
    .subckt TLV1805Q1 INP OUT VP VN SD INN
    XI0 INP OUT VP VN SD INN TLV1805Q1_HT1
    .ends
    
    
    
    
    
    
    
    .subckt BALUN V VCM VN VP
    R9 V NET023  1e-6
    R4 NET035 VCM  1e-6
    R5 NET023 NET016  1e-6
    R3 NET027 VN  1e-6
    R6 0 NET021  1e-6
    R7 NET023 NET019  1e-6
    R8 0 NET017  1e-6
    R1 NET022 VP  1e-6
    XTRANSFORMEREK0 NET016 NET021 NET022 NET035 TRANSFORMEREK0
    XTRANSFORMEREK1 NET019 NET017 NET035 NET027 TRANSFORMEREK1
    .ends BALUN
    
    
    .subckt TLV1805Q1_OUTPUTCIR_HT1 PD VCC VCCMAIN VEE VEEMAIN VIN VOUT
    XAHDLI29 NET060 NET038 NET035 VCC VEE HPA_OR2
    XAHDLI44 PD VIN NET033 VCC VEE HPA_AND2
    XAHDLI27 PD VIN NET038 VCC VEE HPA_AND2
    Q0 VOUT NET59 VCCMAIN PNP1
    Q1 VOUT NET63 VEEMAIN NPN1
    XAHDLI37 NET033 NET47 VCC VEE VCCMAIN NET51 DIGLEVSHIFT
    XAHDLI30 NET035 NET53 VCC VEE NET55 VEEMAIN DIGLEVSHIFT
    XAHDLI31 NET53 NET63 NET55 VEEMAIN HPA_INV
    XAHDLI28 PD NET060 VCC VEE HPA_INV
    XAHDLI36 NET47 NET59 VCCMAIN NET51 HPA_INV
    V0 NET55 VEEMAIN 910e-3
    V2 VCCMAIN NET51 910e-3
    C0 VOUT 0  1.5e-12
    I0 VOUT 0 1e-12
    .ends TLV1805Q1_OUTPUTCIR_HT1
    
    
    .subckt VINRANGE1 VCC VEE VIN VOUT PARAMS: VIL=100e-3 VIH=100e-3
    XIDVIH NET12 NET16 DiodeIdeal
    XIDVIL NET16 NET20 DiodeIdeal
    R0 VIN NET16  1e-3
    V0 NET16 VOUT 0
    VIL NET20 VEE {VIL} 
    VIH VCC NET12 {VIH} 
    .ends VINRANGE1
    
    
    .subckt ANALOG_BUFFER VOUT VIN
    R0 VIN 0  1e9
    R1 VOUT 0  1e9
    E0 VOUT 0 VIN 0 1
    .ends ANALOG_BUFFER
    
    
    .subckt TLV1805Q1_HT1 VINP VOUT VCC VEE PD VINM
    XAHDLI75 PD NET068 NET037 VCC_INT VEE_INT HPA_COMP
    XAHDLI73 NET076 VINM_INT NET31 VCC_INT VEE_INT NET073 HPA_COMPHYS
    XI72 POWER VCC_INT VCC_INT VEE_INT VEE_INT NET17 VOUT TLV1805Q1_OUTPUTCIR_HT1
    XI56 VCC_INT VEE_INT VINM VINM_INT VINRANGE1 PARAMS: VIL=-200e-3 VIH=-200e-3
    XI54 VCC_INT VEE_INT VINP VINP_INT VINRANGE1 PARAMS: VIL=-200e-3 VIH=-200e-3
    XAHDLINV1 NET037 POWER VCC_INT VEE_INT HPA_INV_IDEAL
    XI40 VCC VEE POWER VEE_INT VCC_INT Iq PARAMS: IOFF=10e-6 ION_X1=0 ION_Y1=150e-6
    + ION_X2=1.6 ION_Y2=150e-6 ION_X3=1.9 ION_Y3=150e-6 ION_X4=12 ION_Y4=150e-6
    
    V2 NET068 VEE_INT 450e-3
    V1 NET073 0 14e-3
    V3 VINP_INT NET076 7e-3
    XI60 VINP_INT VINM_INT Ibias PARAMS: Choice=1 Ibias=500e-12 Ioffset=25e-12 TA=27
    + IbiasDrift=0 IoffsetDrift=0 Ibiasp=0 Ibiasm=0
    
    R0 NET17 0  50
    R14 VEE_INT PD  10e6
    T0 NET31 0 NET17 0 Z0=50 TD=185e-9
    XI13 VEE_INT VEE ANALOG_BUFFER
    XI12 VCC_INT VCC ANALOG_BUFFER
    .ends TLV1805Q1_HT1
    
    
    
    
    .SUBCKT HPA_OR2 1 2 3 VDD VSS
    E1 4 0 VALUE = { IF( ((V(1)< (V(VDD)+V(VSS))/2 ) & (V(2)< (V(VDD)+V(VSS))/2 )), V(VSS), V(VDD) ) }
    R1 4 3 1
    C1 3 0 1e-12
    .ENDS
    
    
    .SUBCKT HPA_AND2 1 2 3 VDD VSS
    E1 4 0 VALUE = { IF( ((V(1)> (V(VDD)+V(VSS))/2 ) & (V(2)> (V(VDD)+V(VSS))/2 )), V(VDD), V(VSS) ) }
    R1 4 3 1
    C1 3 0 1e-12
    .ENDS
    
    
    .SUBCKT HPA_INV 1 2 VDD VSS
    E1 3 0 VALUE = { IF( V(1)> (V(VDD)+V(VSS))/2, V(VSS), V(VDD) ) }
    R1 3 2 1
    C1 2 0 1e-12
    .ENDS
    
    
    .SUBCKT HPA_INV_IDEAL 1 2 VDD VSS
    E1 2 0 VALUE = { IF( V(1)> (V(VDD)+V(VSS))/2, V(VSS), V(VDD) ) }
    .ENDS
    
    
    .SUBCKT DIGLEVSHIFT 1 2 VDD_OLD VSS_OLD VDD_NEW VSS_NEW
    E1 3 0 VALUE = { IF( V(1) < (V(VDD_OLD)+V(VSS_OLD))/2, V(VSS_NEW), V(VDD_NEW) ) }
    R1 3 2 1
    C1 2 0 1e-12
    .ENDS
    
    
    .SUBCKT HPA_COMP INP INN OUT VDD VSS
    E1 4 0 VALUE = { IF( (V(INP) > V(INN)), V(VDD), V(VSS) ) }
    R1 4 OUT 1
    C1 OUT 0 1e-12
    .ENDS
    
    
    .SUBCKT HPA_COMPHYS INP INN OUT_OUT VDD VSS VHYS
    EVMID VMID 0 VALUE = { ( V(VDD) + V(VSS) )/2 }
    EINPNEW INPNEW 0 VALUE = { IF( ( V(OUT) < V(VMID) ), V(INP),( V(INP) + V(VHYS) ) ) }
    EOUT OUT 0 VALUE = { IF( ( V(INPNEW) > V(INN) ), V(VDD), V(VSS) ) }
    R1 OUT OUT_OUT 1
    C1 OUT_OUT 0 1e-12
    .ENDS
    
    
    
    .SUBCKT TRANSFORMEREK0 1 2 3 4
    K1 L1 L2 0.5
    L1 1 2 10uH
    L2 3 4 10uH
    .ends
    
    
    
    .SUBCKT TRANSFORMEREK1 1 2 3 4
    K1 L1 L2 0.5
    L1 1 2 10uH
    L2 3 4 10uH
    .ends
    
    
    .SUBCKT AVG VIN1 VIN2 VOUT
    E1 VOUT 0 VALUE = { ( V(VIN1) + V(VIN2) ) / 2 }
    .ENDS
    
    
    
    
    
    
    .SUBCKT CMRR A B C PARAMS:
    
    + CMRR_DC 	        = -100
    + CMRR_f3dB             = 50e3
    + CMRR_f3dB_FudgeFactor = 3.4
    
    .PARAM CMRR       = {0-CMRR_DC}
    .PARAM FCMRR	  = {CMRR_f3dB * CMRR_f3dB_FudgeFactor}
    
    X1 A B C 0 CMRR_NEW PARAMS: CMRR = {CMRR} FCMRR = {FCMRR}
    .ENDS
    
    
    .SUBCKT DiodeIdeal NEG POS
    
    
    
    
    
    
    
    
    
    
    
    G1 POS NEG VALUE = { IF ( V(POS,NEG) <= 0 , 0, V(POS,NEG)*0.01G ) }
    R0 POS NEG 1000G
    
    
    
    .ENDS
    
    
    .SUBCKT DomPoleBias VIN1 VIN2 VOUT
    E1 VOUT 0 VALUE = { ( V(VIN1) + V(VIN2) ) / 2 * 1/2}
    R1 VOUT 0 1G
    
    
    .ENDS
    
    
    .SUBCKT GmItail  Vinp Vinm Ioutp Ioutm VEE VCC PD PARAMS:
    + Choice 	= 2
    
    + Gm 	        = 3.77e-2
    + SBF		= 1 
    
    + ITAILMAX_X1 	= { 3.0 }
    + ITAILMAX_Y1 	= { 10m }
    
    + ITAILMAX_X2 	= { 5.0 }
    + ITAILMAX_Y2 	= { 10m }
    
    + ITAILMIN_X1 	= { 3.0 }
    + ITAILMIN_Y1 	= { 10m }
    
    + ITAILMIN_X2 	= { 5.0 }
    + ITAILMIN_Y2 	= { 10m }
    
    
    
    
    .PARAM Choice1 		= { IF ( Choice == 1,  1, 0 ) }
    .PARAM Choice2 		= { IF ( Choice == 2,  1, 0 ) }
    .PARAM Choice3		= { IF ( Choice == 3,  1, 0 ) }
    .PARAM Choice11 	= { IF ( Choice == 11, 1, 0 ) }
    
    
    X1 PD PDINV VCC VEE LOGIC1 0 DLSINV
    VLOGIC1 LOGIC1 0 1
    
    
    
    
    .PARAM ITAILMAX_SLOPE = 
    + { ( ITAILMAX_Y2 - ITAILMAX_Y1 ) / ( ITAILMAX_X2 - ITAILMAX_X1 ) }
    .PARAM ITAILMAX_INTCP = 
    + { ITAILMAX_Y1 - ITAILMAX_SLOPE * ITAILMAX_X1 }
    
    EITAILMAX ITAILMAX 0 VALUE = 
    + { ITAILMAX_SLOPE * V(VCC,VEE) + ITAILMAX_INTCP  }
    
    
    
    
    .PARAM ITAILMIN_SLOPE = 
    + { ( ITAILMIN_Y2 - ITAILMIN_Y1 ) / ( ITAILMIN_X2 - ITAILMIN_X1 ) }
    .PARAM ITAILMIN_INTCP = 
    + { ITAILMIN_Y1 - ITAILMIN_SLOPE * ITAILMIN_X1 }
    
    EITAILMIN ITAILMIN 0 VALUE = 
    + { ITAILMIN_SLOPE * V(VCC,VEE) + ITAILMIN_INTCP  }
    
    
    
    
    
    
    G1 IOUTP IOUTM VALUE = { ( 1-V(PDINV) ) * (
    + Choice1  * ( LIMIT ( Gm * V(VINP,VINM) , -V(ITAILMIN), V(ITAILMAX) ) ) +
    + Choice2  * ( Gm * (V(ITAILMAX)/Gm) * TANH( V(VINP,VINM) / (V(ITAILMAX)/Gm) )   ) +	
    + Choice3  * ( Gm * V(VINP,VINM) / ( 1 + Gm/V(ITAILMAX) * ABS( V(VINP,VINM) ) ) ) +              		
    + Choice11 * ( LIMIT ( ( Gm * EXP ( LIMIT ( SBF * ABS(V(VINP,VINM)) , -LOG(1E100), LOG(1E100) ) ) ) 
    +                     * V(VINP,VINM) , -V(ITAILMIN), V(ITAILMAX) ) ) +
    
    + 0					   )	}
    
    .ENDS
    
    .SUBCKT Ibias VINP VINM PARAMS:
    + Choice       = 1
    
    + Ibias        = -10u
    + Ioffset      = 150n
    
    + TA           = 25
    + IbiasDrift   = 0
    + IoffsetDrift = 0
    
    + Ibiasp       =  -9.925u
    + Ibiasm       = -10.075u
    
    .PARAM Choice1 = { IF ( Choice == 1, 1, 0 ) }
    .PARAM Choice2 = { IF ( Choice == 2, 1, 0 ) }
    
    .PARAM Ib = { Choice1 * Ibias   + Choice2 * (Ibiasp + Ibiasm)/2  }
    .PARAM Io = { Choice1 * Ioffset + Choice2 * ABS(Ibiasp - Ibiasm) } 
    
    EIb Ib 0 VALUE = { IbiasDrift   * TEMP + ( Ib - IbiasDrift   * TA ) }
    EIo Io 0 VALUE = { IoffsetDrift * TEMP + ( Io - IoffsetDrift * TA ) }
    
    GIbp VINP 0 VALUE = { V(Ib) + V(Io)/2 }
    GIbm VINM 0 VALUE = { V(Ib) - V(Io)/2 }
    
    .ENDS
    
    
    .SUBCKT Inoise A B PARAMS:
    + X = { 1m  }
    + Y = { 100f }
    + Z = { 1f }
    X1 A B FEMT PARAMS: NLFF = { Y/1f }  FLWF = { X } NVRF = { Z/1f }
    .ENDS
    
    
    .subckt Iq VCCmain VEEmain PD VEE VCC PARAMS:
    + IOFF = { 1n }
    
    + ION_X1 = { 0.0 }
    + ION_Y1 = { 1m }
    
    + ION_X2 = { 1.6 }
    + ION_Y2 = { 1m }
    
    + ION_X3 = { 1.9 }
    + ION_Y3 = { 1m }
    
    + ION_X4 = { 12.0 }
    + ION_Y4 = { 1m }
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    
    EION_SEG1 ION_SEG1 0 VALUE = { IF ( 		          V(VCC,VEE) <= ION_X2, 1, 0 ) }
    EION_SEG2 ION_SEG2 0 VALUE = { IF ( V(VCC,VEE) > ION_X2 & V(VCC,VEE) <= ION_X3, 1, 0 ) }
    EION_SEG3 ION_SEG3 0 VALUE = { IF ( V(VCC,VEE) > ION_X3		              , 1, 0 ) }
    
    
    
    .PARAM ION_SEG1_SLOPE = { ( ION_Y2 - ION_Y1 ) / ( ION_X2 - ION_X1 ) }
    .PARAM ION_SEG1_INTCP = { ION_Y1 - ION_SEG1_SLOPE * ION_X1 }
    
    .PARAM ION_SEG2_SLOPE = { ( ION_Y3 - ION_Y2 ) / ( ION_X3 - ION_X2 ) }
    .PARAM ION_SEG2_INTCP = { ION_Y2 - ION_SEG2_SLOPE * ION_X2 }
    
    .PARAM ION_SEG3_SLOPE = { ( ION_Y4 - ION_Y3 ) / ( ION_X4 - ION_X3 ) }
    .PARAM ION_SEG3_INTCP = { ION_Y3 - ION_SEG3_SLOPE * ION_X3 }
    
    
    
    EION ION 0 VALUE = { 	V(ION_SEG1) * ( ION_SEG1_SLOPE * V(VCC,VEE) + ION_SEG1_INTCP ) +
    +			V(ION_SEG2) * ( ION_SEG2_SLOPE * V(VCC,VEE) + ION_SEG2_INTCP ) +
    + 			V(ION_SEG3) * ( ION_SEG3_SLOPE * V(VCC,VEE) + ION_SEG3_INTCP ) 	}
    
    
    
    X1 PD PDINV VCC VEE LOGIC1 0 DLSINV
    VLOGIC1 LOGIC1 0 1
    
    G1 VCCMAIN VEEMAIN VALUE = { V(ION) * ( 1-V(PDINV) ) + IOFF * V(PDINV) }  
    
    .ends
    
    
    .SUBCKT OutputCir_ILOAD  VDD VSS VIMON PD
    X1 PD PDINV VDD VSS LOGIC1 0 DLSINV
    VLOGIC1 LOGIC1 0 1
    
    G1 VDD 0 VALUE = {IF(V(VIMON) >= 0, V(VIMON)*( 1-V(PDINV) ), 0)}
    G2 VSS 0 VALUE = {IF(V(VIMON)  < 0, V(VIMON)*( 1-V(PDINV) ), 0)}
    
    .ENDS
    
    
    .SUBCKT OutputCir_IscDiodeIdeal NEG POS PARAMS: 
    + IS = 1E-14
    + N  = 50m
    
    
    
    G1 POS NEG_INT VALUE = { IF ( V(POS,NEG_INT) <= 0 , IS,  
    +                             IS * ( EXP ( V(POS,NEG_INT)/25m * 1/N ) - 0 )  ) }  
    
    
    V1 NEG_INT NEG {-N*0.8}
    
    
    
    
    
    
    
    
    
    
    
    .ENDS
    
    
    .SUBCKT OutputCir_IscVlimit A B VCC VEE PARAMS:
    +RIsc 		 = { 1 }
    
    +IscVsVsupply_X1 = { 3.0 }
    +IscVsVsupply_Y1 = { 75m }
    
    +IscVsVsupply_X2 = { 5.0 }
    +IscVsVsupply_Y2 = { 100m }
    
    .PARAM IscVsVsupply_SLOPE = 
    + { ( IscVsVsupply_Y2 - IscVsVsupply_Y1 ) / ( IscVsVsupply_X2 - IscVsVsupply_X1 ) }
    .PARAM IscVsVsupply_INTCP = 
    + { IscVsVsupply_Y1 - IscVsVsupply_SLOPE * IscVsVsupply_X1 }
    
    EIscVsVsupply IscVsVsupply 0 VALUE = 
    + { IscVsVsupply_SLOPE * V(VCC,VEE) + IscVsVsupply_INTCP  }
    
    E1 A B VALUE = { V(IscVsVsupply) * RIsc }
    
    .ENDS
    
    
    .SUBCKT OutputCir_RecoveryAssist  VINP VINM IOUTP IOUTM VCC VEE RecoverySignal
    
    
    
    X1 RecoverySignal RS VCC VEE LOGIC1 0 DLS
    VLOGIC1 LOGIC1 0 1
    
    G1 IOUTP IOUTM VALUE = { LIMIT ( 1m * V(VINP,VINM) *  V(RS) , -100m, 100m ) }
    
    .ENDS
    
    
    .SUBCKT OutputCir_Rout B A VIMON PARAMS:
    + Ro_Iout_0A = 100
    + RIsc = 1
    + Isc = 100m
    + Islope_const = 1/100
    
    .PARAM Islope = { Islope_const * Isc }
    
    
    
    
    
    
    
    
    
    
    G1 A B VALUE = { V(A,B) * 1 / ( (Ro_Iout_0A - RIsc) * Islope / ( Islope + ABS(V(VIMON)) ) )   }
    
    
    
    .ENDS
    
    
    .SUBCKT OutputCir_VOHVOLDiodeIdeal NEG POS
    
    G1 POS NEG VALUE = { IF ( V(POS,NEG) <= 0 , 0, V(POS,NEG)*0.01G ) }
    R0 POS NEG 1000G
    
    
    .ENDS
    
    
    .SUBCKT OutputCir_VOHVOL A B C  PARAMS:
    + VSUPPLYREF    = {2.5} 
    
    + VOUTvsIOUT_X1 = { ABS(0) }
    + VOUTvsIOUT_Y1 = { 2.4 }
    
    + VOUTvsIOUT_X2 = { ABS(100m) }
    + VOUTvsIOUT_Y2 = { 2.1 }
    
    
    .PARAM VDROPvsIOUT_X1 = { VOUTvsIOUT_X1 }
    .PARAM VDROPvsIOUT_Y1 = { ABS(VSUPPLYREF-VOUTvsIOUT_Y1) }
    
    .PARAM VDROPvsIOUT_X2 = { VOUTvsIOUT_X2 }
    .PARAM VDROPvsIOUT_Y2 = { ABS(VSUPPLYREF-VOUTvsIOUT_Y2) }
    
    
    .PARAM VDROPvsIOUT_SLOPE = 
    + { ( VDROPvsIOUT_Y2 - VDROPvsIOUT_Y1 ) / ( VDROPvsIOUT_X2 - VDROPvsIOUT_X1 ) }
    .PARAM VDROPvsIOUT_INTCP = 
    + { VDROPvsIOUT_Y1 - VDROPvsIOUT_SLOPE * VDROPvsIOUT_X1 }
    
    
    EVDROPvsIOUT VDROPvsIOUT 0 VALUE = 
    + { VDROPvsIOUT_SLOPE * V(C) + VDROPvsIOUT_INTCP  }
    
    E1 A B VALUE = { V(VDROPvsIOUT) }
    
    
    
    .ENDS
    
    
    
    
    
    
    
    .SUBCKT PSRR VDD VSS A B PARAMS:
    
    + PSRRP_DC    = -100
    + PSRRP_f3dB  = 100k
    
    + PSRRN_DC    = -90
    + PSRRN_f3dB  = 90k
    
    .PARAM PSRRP       = {0-PSRRP_DC}
    .PARAM PSRRN       = {0-PSRRN_DC}
    .PARAM FPSRRP      = {PSRRP_f3dB}
    .PARAM FPSRRN      = {PSRRN_f3dB}
    
    
    X1 VDD VSS A B 0 PSRR_DUAL_NEW PARAMS:
    + PSRRP = {PSRRP} FPSRRP = {FPSRRP}
    + PSRRN = {PSRRN} FPSRRN = {FPSRRN}
    .ENDS
    
    
    .SUBCKT RecoveryCircuit_DiodeIdeal NEG POS
    
    G1 POS NEG VALUE = { IF ( V(POS,NEG) <= 0 , 0, V(POS,NEG)*0.01G ) }
    R0 POS NEG 1000G
    
    
    .ENDS
    
    
    .SUBCKT Vinoffset POS NEG PARAMS: 
    + TA     = 25
    + VOS    = 500u
    + DRIFT  = 10u 
    
    
    
    
    E1 POS NEG VALUE = { DRIFT * TEMP + ( VOS - DRIFT * TA     ) }
    
    
    
    .ENDS
    
    
    .SUBCKT Vinrange_DiodeIdeal NEG POS
    
    G1 POS NEG VALUE = { IF ( V(POS,NEG) <= 0 , 0, V(POS,NEG)*100k ) }
    R0 POS NEG 1000G
    
    
    .ENDS
    
    
    .SUBCKT Vnoise A B PARAMS:
    + X = { 1m  }
    + Y = { 100n }
    + Z = { 5n  }
    X1 A B VNSE PARAMS: NLF = { Y/1n } FLW = { X }  NVR = { Z/1n }
    .ENDS
    
    
    
    
    
    
    
    
    
    
    
    
    .SUBCKT VNSE  1 2 PARAMS: NLF = 10 FLW = 4  NVR = 4.6
    .PARAM GLF={PWR(FLW,0.25)*NLF/1164}
    .PARAM RNV={1.184*PWR(NVR,2)}
    .MODEL DVN D KF={PWR(FLW,0.5)/1E11} IS=1.0E-16
    I1 0 7 10E-3
    I2 0 8 10E-3
    D1 7 0 DVN
    D2 8 0 DVN
    E1 3 6 7 8 {GLF}
    R1 3 0 1E9
    R2 3 0 1E9
    R3 3 6 1E9
    E2 6 4 5 0 10
    R4 5 0 {RNV}
    R5 5 0 {RNV}
    R6 3 4 1E9
    R7 4 0 1E9
    E3 1 2 3 4 1
    C1 1 0 1E-15
    C2 2 0 1E-15
    C3 1 2 1E-15
    .ENDS
    
    
    
    .SUBCKT FEMT  1 2 PARAMS: NLFF = 0.1 FLWF = 0.001 NVRF = 0.1
    .PARAM GLFF={PWR(FLWF,0.25)*NLFF/1164}
    .PARAM RNVF={1.184*PWR(NVRF,2)}
    .MODEL DVNF D KF={PWR(FLWF,0.5)/1E11} IS=1.0E-16
    I1 0 7 10E-3
    I2 0 8 10E-3
    D1 7 0 DVNF
    D2 8 0 DVNF
    E1 3 6 7 8 {GLFF}
    R1 3 0 1E9
    R2 3 0 1E9
    R3 3 6 1E9
    E2 6 4 5 0 10
    R4 5 0 {RNVF}
    R5 5 0 {RNVF}
    R6 3 4 1E9
    R7 4 0 1E9
    G1 1 2 3 4 1E-6
    C1 1 0 1E-15
    C2 2 0 1E-15
    C3 1 2 1E-15
    .ENDS
    
    
    
    
    
    
    .SUBCKT PSRR_SINGLE   VDD  VSS  VI  VO  GNDF PARAMS: PSRR = 130 FPSRR = 1.6
    .PARAM PI = 3.141592
    .PARAM RPSRR = 1
    .PARAM GPSRR = {PWR(10,-PSRR/20)/RPSRR}
    .PARAM LPSRR = {RPSRR/(2*PI*FPSRR)}
    G1  GNDF 1 VDD VSS {GPSRR}
    R1  1 2 {RPSRR}
    L1  2 GNDF {LPSRR}
    E1  VO VI 1 GNDF 1
    C2  VDD VSS 10P
    .ENDS
    
    .SUBCKT PSRR_SINGLE_NEW   VDD  VSS  VI  VO  GNDF PARAMS: PSRR = 130 FPSRR = 1.6
    .PARAM PI = 3.141592
    .PARAM RPSRR = 1
    .PARAM GPSRR = {PWR(10,-PSRR/20)/RPSRR}
    .PARAM LPSRR = {RPSRR/(2*PI*FPSRR)}
    G1  GNDF 1 VDD VSS {GPSRR}
    R1  1 2 {RPSRR}
    L1  2 GNDF {LPSRR}
    
    EA  101 GNDF 1 GNDF 1
    GRA  101 102 VALUE = { V(101,102)/1e6 }
    CA  102 GNDF 1e3
    EB  1 1a VALUE = {V(102,GNDF)}
    
    E1  VO VI 1a GNDF 1
    C2  VDD VSS 10P
    .ENDS
    
    .SUBCKT PSRR_DUAL   VDD  VSS  VI  VO  GNDF 
    + PARAMS: PSRRP = 130 FPSRRP = 1.6
    + PSRRN = 130 FPSRRN = 1.6
    .PARAM PI = 3.141592
    .PARAM RPSRRP = 1
    .PARAM GPSRRP = {PWR(10,-PSRRP/20)/RPSRRP}
    .PARAM LPSRRP = {RPSRRP/(2*PI*FPSRRP)}
    .PARAM RPSRRN = 1
    .PARAM GPSRRN = {PWR(10,-PSRRN/20)/RPSRRN}
    .PARAM LPSRRN = {RPSRRN/(2*PI*FPSRRN)}
    G1  GNDF 1 VDD GNDF {GPSRRP}
    R1  1 2 {RPSRRP}
    L1  2 GNDF {LPSRRP}
    
    G2  GNDF 3 VSS GNDF {GPSRRN}
    R2  3 4 {RPSRRN}
    L2  4 GNDF {LPSRRN}
    
    E1  VO VI VALUE = {V(1,GNDF) + V(3,GNDF)}
    C3  VDD VSS 10P
    .ENDS
    
    .SUBCKT PSRR_DUAL_NEW   VDD  VSS  VI  VO  GNDF 
    + PARAMS: PSRRP = 130 FPSRRP = 1.6
    + PSRRN = 130 FPSRRN = 1.6
    .PARAM PI = 3.141592
    .PARAM RPSRRP = 1
    .PARAM GPSRRP = {PWR(10,-PSRRP/20)/RPSRRP}
    .PARAM LPSRRP = {RPSRRP/(2*PI*FPSRRP)}
    .PARAM RPSRRN = 1
    .PARAM GPSRRN = {PWR(10,-PSRRN/20)/RPSRRN}
    .PARAM LPSRRN = {RPSRRN/(2*PI*FPSRRN)}
    
    G1  GNDF 1 VDD GNDF {GPSRRP}
    R1  1 2 {RPSRRP}
    L1  2 GNDF {LPSRRP}
    
    EA  101 GNDF 1 GNDF 1
    GRA  101 102 VALUE = { V(101,102)/1e6 }
    CA  102 GNDF 1e3
    EB  1 1a VALUE = {V(102,GNDF)}
    
    
    G2  GNDF 3 VSS GNDF {GPSRRN}
    R2  3 4 {RPSRRN}
    L2  4 GNDF {LPSRRN}
    
    EC  301 GNDF 3 GNDF 1
    GRC  301 302 VALUE = { V(301,302)/1e6 }
    CC  302 GNDF 1e3
    ED  3 3a VALUE = {V(302,GNDF)}
    
    
    E1  VO VI VALUE = {V(1a,GNDF) + V(3a,GNDF)}
    C3  VDD VSS 10P
    .ENDS
    
    
    
    .SUBCKT CMRR_OLD   VI  VO  VX GNDF PARAMS: CMRR = 130 FCMRR = 1.6K
    .PARAM PI = 3.141592
    .PARAM RCMRR = 1
    .PARAM GCMRR = {PWR(10,-CMRR/20)/RCMRR}
    .PARAM LCMRR = {RCMRR/(2*PI*FCMRR)}
    G1  GNDF 1 VX GNDF {GCMRR}
    R1  1 2 {RCMRR}
    L1  2 GNDF {LCMRR}
    E1  VI VO 1 GNDF 1
    .ENDS
    
    .SUBCKT CMRR_NEW   VI  VO VX GNDF PARAMS: CMRR = 130 FCMRR = 1.6K
    .PARAM PI = 3.141592
    .PARAM RCMRR = 1
    .PARAM GCMRR = {PWR(10,-CMRR/20)/RCMRR}
    .PARAM LCMRR = {RCMRR/(2*PI*FCMRR)}
    G1  GNDF 1 VX GNDF {GCMRR}
    R1  1 2 {RCMRR}
    L1  2 GNDF {LCMRR}
    
    EA  101 GNDF 1 GNDF 1
    GRA  101 102 VALUE = {V(101,102)/1e6}
    CA  102 GNDF 1e3
    EB  1 1a VALUE = {V(102,GNDF)}
    
    E1  VI VO 1a GNDF 1
    .ENDS
    
    
    
    .SUBCKT DLS 1 2 VDD_OLD VSS_OLD VDD_NEW VSS_NEW
    E1 3 0 VALUE = { IF( V(1) < (V(VDD_OLD)+V(VSS_OLD))/2, V(VSS_NEW), V(VDD_NEW) ) }
    R1 3 2 1
    C1 2 0 1p
    .ENDS
    
    
    .SUBCKT DLSINV 1 2 VDD_OLD VSS_OLD VDD_NEW VSS_NEW
    E1 3 0 VALUE = { IF( V(1) > (V(VDD_OLD)+V(VSS_OLD))/2, V(VSS_NEW), V(VDD_NEW) ) }
    R1 3 2 1
    C1 2 0 1p
    .ENDS
    
    
    .SUBCKT SWITCH_IDEAL A B C PARAMS:
    + Ron  = 100m
    + Roff = 0.1G
    
    
    
    
    
    G1 A B VALUE = { V(A,B) * 1 / ( Roff/2 * TANH( 0 - ( 20*V(C) - 5 ) ) + Roff/2 + Ron )  }
    
    R1 A 0 1000G
    R2 B 0 1000G
    
    .ENDS
    
    
    
    
    
    
    
    
    
    .MODEL VINRANGE_DIDEAL         D N=1m
    .MODEL RECOVERYCIRCUIT_DIDEAL  D N=1m 
    
    .MODEL OUTPUTCIR_ISC_DIDEAL    D N=0.1m
    .MODEL OUTPUTCIR_VOHVOL_DIDEAL D N=1m 
    .MODEL DBASIC D
    
    
    
    .MODEL NPN1 NPN LEVEL=1 IS=1E-16 RB=25 RC=35 TF=105n 
    .MODEL PNP1 PNP LEVEL=1 IS=1E-16 RB=25 RC=35 TF=105n