LTSPICE making a spice model

Thread Starter

Ddunham5

Joined Nov 9, 2018
6
I don't know necessarily what I'm doing here.
So Here is where I'm at:
I'm trying to work with the TI TPA3126D2 Datasheet is here:
http://www.ti.com/lit/ds/symlink/tp...l-wwe&DCM=yes&ref_url=https://www.mouser.com/

Trying to setup a spice model for this in LTspice
TI has the .lib .tld & .tsm files for download on the site. The .lib is attached below
I've looked up online how LTspice says to do this. Apparently I need a .sub file or .SUBCKT file.
Now I don't know exactly what those files do, I get the feeling that they are net list descriptions that allow LTspice to build a component drawing from, but I fully expect I'm wrong with that.

Ok I'm rambling, The ultimate question is can I build a new component drawing and then assign the .lib file to it to utilize it in spice sims in LTspice?
 

Attachments

Thread Starter

Ddunham5

Joined Nov 9, 2018
6
Okay I think I'm a little closer now.
I have the .lib in ltspice
Here it is copied.


**$ENCRYPTED_LIB
**$INTERFACE
* TPA3116D2
*****************************************************************************
* (C) Copyright 2012 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.
*****************************************************************************
*
** Released by: WEBENCH(R) Design Center, Texas Instruments Inc.
* Part: TPA3116D2
* Date: 04/27/2012
* Model Type: All In One
* Simulator: Pspice
* Simulator Version: 16.2
* EVM Order Number: N/A
* EVM Users Guide: N/A
* Datasheet: September 2011 (v1.10)
*
* Model Version: 1.0
*
*****************************************************************************
*
* Updates:
*
* Version 1.0 : Release to Web
*
*****************************************************************************
* Notes:
* 1. The following parameters/functionalities are modeled:
* Icc, Isd, RDSon, Gain Setting, Oscillator Frequency, Input Impendance,
* Mute, Plimit, PBTL, MODSEL, Efficiency.
*
* 2. The following parameters/functionalities are not modeled:
* The slave function
*
*****************************************************************************
.subckt TPA3116D2 AM0 AM1 AM2 AVCC GAINSLV GND GVDD INNL INNR INPL INPR MODSEL
+ MUTE OUTNL OUTNR OUTPL OUTPR PLIMIT PVCC SDZ


$CDNENCSTART
eee8c5c7a2bc4b01f045f303678664e7916da0bae22e8cb0bba041dd67c69ce448ea70148a9ac1670c8926c1ac5057c8ccfcd77bf87ca9dcd7c452bda3259f13
7599c7b09b0d5eb3fc109395b04c6806fba57768f81561fd498759111478f366ba6a82c3325d3bff972064cb5f8b42e769e38211dcc95180a623d75ccd483cee
4d74ef47ecfd78bc2b43f3d4707d0c0780f7ca8922ece6ba7d7e948c13a0ea18b2ba69306953f5c4e5387ec1fcfa76a7b9673b74921e15b9a609f806799e5e04
da59aefedc2cc4565cd20a0565ab1fe121fb7de9b72094284d06ed514ae35f1f641977a5e95ddf078f265351b889c99739859341766fc92cddede366a551a6e7


$CDNENCFINISH
.ends

Set up my spice directive: .include C:\Program Files\LTC\LTspiceXVII\lib\sub\TPA3116D2.LIB

And now I get this error:
Port{pin} count mismatch between the definition of subcircuit 'tpa3116d2' and instance 'xu2'.
The instance has more connection terminals than the definition.

Now I get that it is saying that I have more pins on the component I drew up (The actual component has 32 pins so that's what I drew up)
I'm just wondering when I redraw this component what order do I draw the pins? Meaning does should the netlist pin out be in the order that the pin shows up in the list, or the way it is actually laid out on the circuit? And what about all of those pins that are after the "+" (IE: + MUTE OUTNL OUTNR OUTPL OUTPR PLIMIT PVCC SDZ) I know most of these pins are the outputs of the circuit except for mute plmit pvcc and sdz. But even those are used as well.
I'll keep working at it on my end.
Any one who decides to help, thank you.
 

Bordodynov

Joined May 20, 2015
3,179
You see abracadabra in the text file. This means that it is encrypted for ORCAD. And this is very bad news for you - it is not suitable for LTspice. TI encrypts its models. True, he recently began to "correct" and in addition to encrypted models, he also supplies unencrypted models. Search the site. Maybe you are lucky. Good luck!
 
Top