how to build macro-models in tina spice part 1: text macro-model creation text subcircuit creation...

80
How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic Macro-Model Creation Schematic SubCircuit Creation Symbol Creation Macro-Model Creation Tim Green May 4, 2006

Upload: liliana-singleton

Post on 17-Jan-2016

243 views

Category:

Documents


1 download

TRANSCRIPT

Page 1: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

How to Build Macro-Models in Tina SPICE

Part 1: Text Macro-Model CreationText SubCircuit Creation

Symbol CreationMacro-Model Creation

Part 2: Schematic Macro-Model CreationSchematic SubCircuit Creation

Symbol CreationMacro-Model Creation

Tim Green May 4, 2006

Page 2: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationText SubCircuit Creation

Symbol CreationMacro-Model Creation

Page 3: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationText SubCircuit Creation

* TG Simple 159Hz LPF*Connections..... VIN VOUT GND.SUBCKT LPF 1 2 3R1 1 2 1kC1 2 3 1u.ENDS LPF

Equivalent Schematic of Text SubCircuitCircled numbers are Node numbers

* Indicates Comment

.SUBCKT statement w/subcircuit name (LPF)All external Nodes to connect subcircuit (1,2,3)

Component types/names and Node connections

End subcircuit statement w/subcircuit name (.ENDS LPF)

R1

C1

VOUTVIN

GND

1 2

3

1k

1F

Page 4: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationNetlist Creation

Open “Netlist Editor” in Tina Schematic Editor

Page 5: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationNetlist Creation

Enter Text SubCircuit into “Netlist Editor”

Page 6: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationText SubCircuit Creation

“Save File As” either “.cir” or “.mod” in any file folder convenient

Page 7: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationText SubCircuit Creation

Close “Netlist Editor”

Page 8: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation

Open “Schematic Symbol Editor”

Page 9: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation

“File”, “Open”, “Devices.DDB”This is the Device Database file which hold all schematic symbols for Tina.

Page 10: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

Select a device form the list at the right and then select “Edit Device”, If you want to use an existing symbol and modify it

Page 11: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

After existing symbol edits are completed, select “Edit”, “Pin Order…”

Page 12: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

1 2

3

Hidden Pin Numbers

* TG Simple 159Hz LPF*Connections..... VIN VOUT GND.SUBCKT LPF 1 2 3R1 1 2 1kC1 2 3 1u.ENDS LPF

Ensure “Pin Order” matches the order in the Text SubCircuit. If not re-arrange the pin order using the up and down arrows until the pin order is correct.

Page 13: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

After existing symbol edits are completed, select “Device Properties”

Page 14: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

Give the edited symbol a new, unique name and click “OK”

Page 15: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

“Add Device”, Add the new symbol to the list at the right.Use + button or drop down menu.

Page 16: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - Modify

Save the updated Device Database as “DEVICES.DDB”

Warning: Backup the original “DEVICES.DDB” File in case there is a problem.

Page 17: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

“Device”, “New Device”, If you want to create your own unique symbol for the Macro-Model

Page 18: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

Create desired outline for symbol.Keep grey “crosshair arrows” and “+ circle” geometrically centered inside of symbol outline.

“Label” will be where “Ref Designator” appears as default on schematic when symbol is placed.

Page 19: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

“Drop down menu allows for pin rotation during pin placement

Place pins by drag and drop where desired. Red x is electrical connection point. Grey box can move pin number anywhere desired.

Page 20: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

Double click on each pin to select the “Pin Properties”. If you want a name on your pin unselect “Show”. For your Symbol to be available to build your Macro-Model form the Text SubCircuit it must be built with the EXACT same number of pins and use the same pin numbers on the pins as your Text SubCircuit

Page 21: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

Click on “T” to create a text label for your symbol pin. A crosshair will appear in the window. Click the mouse once and a Text Entry Box will pop up.

Enter desired pin name here

After text entry click “OK” and name will appear. Move pin name where desired.

Page 22: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

After existing symbol edits are completed, select “Edit”, “Pin Order…”

Page 23: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

1 2

3

Hidden Pin Numbers

* TG Simple 159Hz LPF*Connections..... VIN VOUT GND.SUBCKT LPF 1 2 3R1 1 2 1kC1 2 3 1u.ENDS LPF

Ensure “Pin Order” matches the order in the Text SubCircuit. If not re-arrange the pin order using the up and down arrows until the pin order is correct.

Page 24: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

After existing symbol edits are completed, select “Device Properties”

Page 25: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

Give the edited symbol a new, unique name and click “OK”

Page 26: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

“Add Device”, Add the new symbol to the list at the right.Use + button or drop down menu.

Page 27: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationSymbol Creation - New

Save the updated Device Database as “DEVICES.DDB”

Warning: Backup the original “DEVICES.DDB” File in case there is a problem.

Page 28: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Either “Exit” or minimize the “Schematic Symbol Editor”

Page 29: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Select “Re-read symbol database”

Page 30: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Start the Tina “New Macro Wizard”

Page 31: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Enter “Name” for the new Macro-Model.

Click on “Content” and select the desired Text SubCircuit File. Then click “Open”

Page 32: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Unselect all boxes since we want to use our own symbol for the Macro-Model.

Click on “Shape”. The ONLY symbol choices that will appear at the right are ones that contain pin numbers and quantities that EXACTLY match the Text SubCircuit. (i.e., 3 pins and pins numbered 1, 2, 3 corresponding to the Nodes in the Text Subcircuit of 1, 2, 3)

Page 33: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Highlight desired “Shape” at the right and click “OK” to enter it into the “Shape” dialog box.

Page 34: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

VIN VOUTGND

U2 159Hz

If you want a label to appear next to the Ref Designator when you place the Macro-Model on a schematic enter it here under “Label”

Page 35: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Creation

Finish Macro-Model creation and Save the results. Click “OK” and popup window on right will appear. Tina uses “.TSM” as Macro Schematics file extension. After creating or using default File name and choosing the folder to store the Macro-Model in click “Save”

Page 36: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Use

Select “Re-read symbol database”

Page 37: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Use

In the Tina “Schematic Editor” choose “Insert”, “Macro”.

From the desired folder select the Macro for insertion into the Schematic Editor and click “Open”

Page 38: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 1: Text Macro-Model CreationMacro-Model Use

Now the Macro-Model may be connected and used in the Schematic Editor as a normal Macro-Model.

Page 39: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model Creation

Schematic SubCircuit CreationSymbol Creation

Macro-Model Creation

Page 40: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSchematic SubCircuit Creation

Create a schematic for the SubCircuit in the “Schematic Editor”. Add “Macro pin” connections for the desired Macro-Model pins.

Page 41: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSchematic SubCircuit Creation

Double click on each “Macro pin” and type a desired pin number in the “Label” box. When completed click on “OK”.

Page 42: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSchematic SubCircuit Creation

When Schematic SubCircuit is complete use “File”, “Save As” in desired folder as a Tina schematic “.TSC”

Page 43: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation

Open “Schematic Symbol Editor”

Page 44: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation

“File”, “Open”, “Devices.DDB”This is the Device Database file which hold all schematic symbols for Tina.

Page 45: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - Modify

Select a device form the list at the right and then select “Edit Device”, If you want to use an existing symbol and modify it

Page 46: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - Modify

After existing symbol edits are completed, select “Device Properties”

Page 47: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - Modify

Give the edited symbol a new, unique name and click “OK”

Page 48: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - Modify

“Add Device”, Add the new symbol to the list at the right.Use + button or drop down menu.

Page 49: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - Modify

Save the updated Device Database as “DEVICES.DDB”

Warning: Backup the original “DEVICES.DDB” File in case there is a problem.

Page 50: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

“Device”, “New Device”, If you want to create your own unique symbol for the Macro-Model

Page 51: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

Create desired outline for symbol.Keep grey “crosshair arrows” and “+ circle” geometrically centered inside of symbol outline.

“Label” will be where “Ref Designator” appears as default on schematic when symbol is placed.

Page 52: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

“Drop down menu allows for pin rotation during pin placement

Place pins by drag and drop where desired. Red x is electrical connection point. Grey box can move pin number anywhere desired.

Page 53: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

Double click on each pin to select the “Pin Properties”. If you want a name on your pin unselect “Show”. For your Symbol to be available to build your Macro-Model form the Text SubCircuit it must be built with the EXACT same number of pins and use the same pin numbers on the pins as your Text SubCircuit

Page 54: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

Click on “T” to create a text label for your symbol pin. A crosshair will appear in the window. Click the mouse once and a Text Entry Box will pop up.

Enter desired pin name here

After text entry click “OK” and name will appear. Move pin name where desired.

Page 55: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

After existing symbol edits are completed, select “Device Properties”

Page 56: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

Give the edited symbol a new, unique name and click “OK”

Page 57: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

“Add Device”, Add the new symbol to the list at the right.Use + button or drop down menu.

Page 58: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationSymbol Creation - New

Save the updated Device Database as “DEVICES.DDB”

Warning: Backup the original “DEVICES.DDB” File in case there is a problem.

Page 59: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Either “Exit” or minimize the “Schematic Symbol Editor”

Page 60: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Select “Re-read symbol database”

Page 61: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Start the Tina “New Macro Wizard”

Page 62: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Open the schematic where the Schematic SubCircuit is created.

Enter a name for the Macro-Model under “Name”.

Check “Current circuit”.

Page 63: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Click on “Shape”. The ONLY symbol choices that will appear at the right are ones that contain pin numbers and quantities that EXACTLY match the Text SubCircuit. (i.e., 3 pins and pins numbered 1, 2, 3 corresponding to the Nodes in the Schematic Subcircuit of 1, 2, 3)

Page 64: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Highlight desired “Shape” at the right and click “OK” to enter it into the “Shape” dialog box.

Page 65: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

If you want a label to appear next to the Ref Designator when you place the Macro-Model on a schematic enter it here under “Label”

VIN VOUTGND

U2 159Hz

Page 66: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Creation

Finish Macro-Model creation and Save the results. Click “OK” and popup window on right will appear. Tina uses “.TSM” as Macro Schematics file extension. After creating or using default File name and choosing the folder to store the Macro-Model in click “Save”

Page 67: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Use

Select “Re-read symbol database”

Page 68: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Use

In the Tina “Schematic Editor” choose “Insert”, “Macro”.

From the desired folder select the Macro for insertion into the Schematic Editor and click “Open”

Page 69: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationMacro-Model Use

Now the Macro-Model may be connected and used in the Schematic Editor as a normal Macro-Model.

Page 70: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape

Create subcircuit in the Schematic Editor. Connect a “Macro Pin” to each I/O of the subcircuit.

Double-Click on each “Macro Pin” and assign it a desired name in the “Label” dialog box. Click “OK” to save the pin name.

Page 71: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape

Start the Tina “New Macro Wizard”

Page 72: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape

Check the box next to the “Content” dialog as “Current circuit” since we are turning the current schematic into a Macro-Model. Check the box next to the “Shape” dialog as “Auto-generated” to have Tina create a Macro-Model symbol automatically for you. Then click “OK”.

If you want a label to appear next to the Ref Designator when you place the Macro-Model on a schematic enter it here under “Label”

VIN VOUTGND

U2 159Hz

Page 73: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape

Finish Macro-Model creation and Save the results. Click “OK” and popup window on right will appear. Tina uses “.TSM” as Macro Schematics file extension. After creating or using default File name and choosing the folder to store the Macro-Model in click “Save”

Page 74: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

Select “Re-read symbol database”

Page 75: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

In the Tina “Schematic Editor” choose “Insert”, “Macro”.

From the desired folder select the Macro for insertion into the Schematic Editor and click “Open”

Page 76: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

Now the Macro-Model may be connected and used in the Schematic Editor as a normal Macro-Model.

Notice how Tina created the box shape for the Macro-Model and automatically assigned the pins the names we used for each “Macro Pin” name when we created the Schematic SubCircuit

Page 77: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

Double-click on the Macro-Model Shape and the popup Properties window will appear. Click on “Enter Macro”

Page 78: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

The Schematic SubCircuit that was used to create the Macro-Model will appear in a separate window. Values in the SubCircuit may be modified as in the normal Schematic Editor.

Page 79: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

When the edits to the component values inside of the Schematic SubCircuit are completed close the window by selecting “File”, “Close”.

Page 80: How to Build Macro-Models in Tina SPICE Part 1: Text Macro-Model Creation Text SubCircuit Creation Symbol Creation Macro-Model Creation Part 2: Schematic

Part 2: Schematic Macro-Model CreationAuto-Generated Shape: Macro-Model Use

The modified Schematic SubCircuit used for the Macro-Model was modified and the changes are now included in the Macro-Model. These changes stay wherever this instance of the Macro-Model are copied and placed in this or another schematic.