TINA pro lab manual
TINA pro lab manual
Adapted from
This work is freely redistributable for non-commercial use, share-alike with attribution.
or via www.dissidents.com
TINA™ is a trademark of DesignSoft. Neither the author, nor any software programs or other goods or services offered by
the author, are affiliated with, endorsed by, or sponsored by DesignSoft.
“Without deviation, progress is not possible”
- Frank Zappa
1 Introduction to TINA
Objective
The objective of this exercise is to become familiar with the TINA™ electrical circuit simulation
package in order to create simple schematics and perform basic simulations. TINA stands for Toolkit for
Interactive Network Analysis and is produced by DesignSoft. The differences between US (ANSI) and
Euro (DIN) schematic symbols, and 3D components will be examined along with the use of virtual
instruments to make simulated measurements. Please note that the precise look of the windows, menus
and dialog boxes may be slightly different from that pictured depending on the version of TINA that is
being used. Regardless of appearance, the functionality remains. A free version of TINA, known as
TINA-TI, is available from the Texas Instruments web site at https://www.ti.com/tool/TINA-TI
Procedure
After logging into the computer, open TINA. If a desktop shortcut is not available TINA may be
accessed via the Programs menu under the TINA menu item. You will be greeted with something
similar to the screen shown in Figure 1-1. Depending on the version, the precise look of the program
may be a little different from that shown (TINA-TI). There are two toolbar strips immediately below the
menus. The topmost toolbar contains the usual File Open, Save, and similar commands, along with
buttons for text insertion, zoom level and the like. At the extreme right end of this strip is search box
for electronic components. The lower strip is made up of a set of tabbed toolbars for electronic
components, measurement instruments and other devices. Selecting a given tab (e.g., Basic, Meters,
Semiconductors, etc.) shows the toolbar for that set of items.
TINA’s schematic capture facility is object based, that is, you “draw” a circuit by selecting predefined
objects such as resistors and transistors, and drag them onto the workspace. They are then wired
together using the mouse. You can zoom into or out of the workspace using the mouse or the zoom
toolbar button.
Figure 1-1
TINA will draw schematics using one of three formats. The first style uses the ANSI (North American)
standard for schematic symbols. The second style uses the DIN (Euro) standard. The final style is called
"3D" where components look more like photographs of the actual component. Examples are shown in
Figure 1-2 using ANSI, DIN and 3D. You can set the preferred format via the View->Options menu
item. More on this in a moment.
Figure 1-2
Generally, we do not use the 3D style for most work. It is, however, useful for newcomers as a way of
reinforcing and practicing use of the resistor color code, and for general package identification (such as
the TO-92 transistor case pictured in Figure 1-2). TINA will show the proper color sequence for
resistors using either two or three significant digits along with a proper tolerance band (i.e., four or five
bands). A comparison is shown in Figure 1-3.
Figure 1-3
Along with the appropriate electronic parameters of a device, physical data regarding shape and pinout
are required if a printed circuit board (PCB) will be created. For example, a particular device such as an
operational amplifier may be available in several different package styles including through-hole or
surface mount variants. Our goal here is to become familiar with capturing the schematic and
performing simulations, such as verifying a laboratory exercise. Consequently, we shall not concern
ourselves with the needs of PCB layout at this point.
To illustrate the use and editing of components, select the Basic tab and drag a DC voltage source (third
item) onto the workspace. It will show up with a default voltage value and label. Double click the
symbol. A dialog box will pop up next to it as shown in Figure 1-4.
Figure 1-4
From this dialog you can change a variety of attributes, the most important of which are the voltage
value and the label. Double clicking any component will bring up a settings dialog box although the
precise items contained within it will vary from component to component. For example, for a resistor
there will be a resistance setting instead of a voltage setting. If you need to remove a component,
simply select it and hit the Delete key.
Electronic components can be placed into two broad categories; generic parts and more accurate "real
world" models typically generated by the manufacturer of that part. This is particularly true with
complex components or devices. For example, Figure 1-5 shows a pair of NPN transistors. The one
labeled "!NPN" is a simple generic model. The lower, highlighted transistor references a specific part
number, in this case the 2N3904, a popular general purpose device.
Figure 1-5
Double clicking the generic transistor opens up its settings dialog box. Initially, under Type, it will say
"NPN", referring to the generic. Next to this is a small box labeled with an ellipsis (...). Clicking on the
ellipsis will open a second settings box, the Catalog Editor. From here, a specific manufacturer's part
can be selected from the scrolling list on the left. If need be, specific parameters can be altered in the
list on the right.
Remember, whenever you see the small ellipsis box, clicking on it will open another settings box so
that you can specify further details.
Editing the position and orientation of a component is straightforward. Once the item is selected
(highlighted in red by default) it may be moved using either the mouse or the cursor keys. If you need
to move a group of components, the mouse may be used to select several items by clicking and then
dragging the mouse over them. Every component within the selection box will be highlighted and will
move as a group. Components may also be rotated and flipped. These commands can be accessed from
the main menu, however, it is handy to remember certain keyboard shortcuts (such as Ctrl-R for rotate
right, or clockwise). Also note that it is possible to select the text labels of components and move or
rotate them independently of the component. This can be handy if a label becomes obscured by a wire.
To do so, make sure the component is not selected (unhighlighted) and then click directly on the label.
It can now be moved or rotated.
Along with editing the components, you may also customize the look of the work space. From the file
menu, select Page Setup. This opens the dialog box shown in Figure 1-6 and allows you to specify the
sheet size for the schematic and related properties.
Figure 1-6
Other attributes, such as whether or not to show the grid, component values, labels, and the like can be
selected from the View menu. This is shown in Figure 1-7. Of particular importance is the final item in
this list, Options, which was mentioned earlier. Selecting Options brings up the Editor settings box
shown in Figure 1-8.
Figure 1-7
The Editor options include the aforementioned ANSI, DIN and 3D styles. It also includes the base
function for AC (it is recommended this be set to sine). Further, you can adjust the color scheme for
your workspace and a few other global parameters.
Figure 1-8
OK, let’s create a circuit and perform a simulation. If you have been experimenting, remove any
components on your workspace (select with the mouse and then press the Delete key). From the Basic
components tab, select a DC voltage source, two resistors and an earth ground symbol. We shall make a
series loop of the three elements with the negative end of the power supply at ground. One resistor will
need to be rotated 90 degrees (one horizontal and one vertical). In order to wire the items together,
move the mouse to the end of one component you wish to wire. The connection ends are denoted with a
small red x. When the mouse cursor is close, it will turn into a pen shape. Simply click on the lead of
the component and move the mouse to the desired lead of another component. While moving, TINA
will draw a red line. Clicking on the second component will create a proper wire (by default, colored
black). Wires are always drawn along the horizontal and vertical with 90 degree bends, not directly
from point to point. This is the proper way to draw a schematic in the vast majority of cases.
To delete a wire, click on it to select it. You will see a set of small “handles” on it. To remove the wire,
simply hit the Delete key. Note that you can also move the wire with those handles if desired.
Note that if you move a component, TINA will automatically move the wires along with it. You do not
have to rewire it. If a component is later deleted, this will result in "dangling wires" which also should
be deleted.
Figure 1-9
Once the components are in place and wired, double-click each component to set their values as shown
in Figure 1-9. We shall then add two the two voltmeters (fifth item in the Basic tab). Please note that it
is perfectly acceptable to change the component values immediately after dragging them onto the work
space; you don’t have to wait until they are wired together. It is suggested, though, that you decide
upon a particular workflow and stick to it otherwise the chances of forgetting to change components
from their default values increases.
The circuit is now ready to perform a simulation.
From the Analysis menu, select DC Analysis->Calculate nodal voltages. In a moment, the values of the
voltages will be printed next to the voltmeters. Also, a small window will pop up. With this window,
you can investigate particular node voltages or component voltages and currents. You will notice that
the mouse cursor will have changed shape into a measurement probe. You can click on a node to see a
voltage with respect to ground (a node is denoted with a small, solid black circle on the wire where
items connect, such as where a meter connects to a wire). Further, if you click on a component, the
voltage across it and the current through it will be displayed in the little pop up window. This is a nice
interactive feature.
TINA also has a wide variety of virtual instruments. These can be accessed via the T&M (Test and
Measurement) menu. For example, Figure 1-10 illustrates a virtual oscilloscope. This has the advantage
of immediacy (assuming you’ve used an oscilloscope before), however, it is not the ultimate way to
perform a simulation. We will look at even more powerful and flexible ways of creating simulations in
the next exercise.
Figure 1-10
For now, you may wish to delete this new instrument from the work space and then save the existing
schematic. Remember to always save to either your student account or to a USB drive. Never save
directly to the hard drive in lab.
There are three very good “every day” uses for TINA during your studies: First, it is a very handy tool
for verifying lab results. That is, you can recreate a lab circuit, simulate it, and compare the simulation
to both your theoretical calculations and lab measurements. Second, it is a handy tool for checking
homework if you get stuck on a problem. Third, it is convenient for the creation of schematics, for
example, for a lab report. An easy way to do this is to draw the circuit, capture the screen image
(Windows key+Print Screen key copies it into the clipboard) and then paste the image into your
favorite image manipulation program. From there you can crop it, change contrast, etc. as needed and
then paste the modified image into your lab report.
At this point you may wish to experiment a bit by rewiring the circuit or to try building new circuits. As
with any tool, continued practice will hone your skill. Once you are done and have saved the file (the
extension should be .TSC), close TINA and then shut down the computer.
2 TINA Extensions
Objective
The objective of this exercise is to become more familiar with the TINA electrical circuit simulation
package in order to use more generalized simulations via the Output Windows.
Procedure
In previous work we have examined the basic functionality of TINA, namely basic schematic capture
functions such as component selection, placement, and parameter editing, along with simple
simulations using voltmeters and the nodal voltages probe to measure DC voltage. While this method is
relatively quick and easy to use, it is limited in other aspects. Some of the issues include:
1. Limited measurements per unit, for example a single measurement for a voltmeter, requiring
multiple units for multiple measurements.
2. The need to rewire the instruments (and hence the schematic) in order to take different readings.
3. Excessive amount of work space area obscured by the instrument(s) with accompanying clutter.
To address these issues TINA allows for an all-in-one analysis using a Table of Results and also a
graphing window. Large amounts of data may be displayed simultaneously. These data may also be
saved as a text file for later examination or for input into other programs.
Nothing “extra” needs to be added to the circuit. Instead of choosing the DC Analysis->Calculate nodal
voltages menu item, instead, select the DC Analysis->Table of DC results menu item. To illustrate,
begin by building the circuit shown in Figure 2-1. Drag a DC voltage source, an earth ground and two
resistors onto the work space. Connect them in a series loop and edit the component values to 20 volts
for the source, and 4000 and 6000 ohms for the two resistors.
Figure 2-1
Notice that no voltmeters are required. From the Analysis menu, select DC Analysis->Table of DC
results, as shown in Figure 2-2.
Figure 2-2
In a moment, the Table of Results window will open as shown in Figure 2-3. You may need to enlarge
the window in order to see all of the values.
Figure 2-3
This window lists all of the component voltages and currents in the circuit. Essentially, it's like using
the probe on everything and then collecting all of the data in one place. This list can be saved as a text
file by selecting the small “finger point” button in the lower right. All values are identified by the
component's name. You will also notice that every connection point in the circuit has been given a
number. Ground is always 0 and the remaining points are sequentially numbered as the circuit is wired
together. Note that voltage points 1 and 2 (VP_1 and VP_2) are included in the list and that each
component's current or voltage is also identified by these numbers. For example, the voltage across
resistor R1 is identified as V_R1[2,1]. The [2,1] indicates that the component is connected from node 2
to node 1. The first number is the connection for the positive lead of the meter while the second is the
connection for the negative lead. Thus, this indicates the polarity and direction of the voltage and
current.
It is worth noting that although TINA also has an ammeter similar to its voltmeter, this method tends to
be much more efficient for current measurement because ammeters must be inserted in series with the
component of interest. That is, the circuit must be rewired to accommodate the ammeter, unlike a
voltmeter which is simply placed across the component(s) of interest.
At this point, you might be wondering why you would ever not use this method, abandoning the
original method and voltmeters entirely. There are two cases where using the original method and/or
voltmeters may be preferred. First, in very large circuits the table of values can be overwhelming.
Second, as is, there is no obvious way of determining a voltage that appears across several components,
short of adding up the individual voltages manually. In this case, a voltmeter can still be used, its value
will show up in the table alongside the other component voltages.
Finally, you may prefer to give the connection points names, such as Vin or node A, instead of the
default numbering scheme. This can be achieved by adding Voltage Pins to the schematic. This is the
first item in the Meters tab and looks like the letter C with a tail. These items can be placed anywhere
on a schematic, and once added, the names can be changed. This is illustrated in Figure 2-4. Two
voltage pins have been added to the locations formerly known as nodes 1 and 2. The names have been
changed to “b” and “a”, respectively. Note that the table of voltages and currents now uses these letters
instead of the numbers.
Figure 2-4
Finally, the table still makes use of the mouse probe. If you click on a Voltage Pin, its entry will be
highlighted in the table. If you click on a component, the entries for both its current and voltage will be
highlighted.
There are times when graphical data is preferred over simple numeric data. To illustrate this, we will
shift our attention to time domain waveform analysis using an AC source. To do this, first delete the DC
source in your existing circuit. Replace it with an AC voltage generator. This is the fourth item in the
Sources tab. Your circuit should like similar to the one shown in Figure 2-5.
Figure 2-5
The AC generator is very flexible. We would like to create a 20 volt peak sine wave at a frequency of 1
kHz. To do this, double click on the generator to open its settings dialog box. Click on the Signal row to
reveal a small ellipsis button (…). Clicking on the ellipsis brings up the Signal Editor. Select the sine
shape (third item) and set the Amplitude to 20 and the frequency to 1000 Hz (1k, for short). Select OK
for both of these windows.
From the Analysis menu, select Transient. The Transient Analysis dialog opens, as shown in Figure 2-6.
Figure 2-6
We would like to see the first two milliseconds of our waveform. At 1 kHz, we should see two full
cycles. Enter a start time of 0 and and end time of 2m (0.002 seconds). After selecting OK, a graphing
window opens as shown in Figure 2B-7. Notice that the time scale runs from 0 to 2 milliseconds and
the amplitude spans from -20 to +20 volts. Two waveforms are drawn, node voltages a and b, as
requested by our Voltage Pins.
Figure 2-7
There are several useful tools and variations you can utilize with this graphing window. They are
accessed either through the menus or the toolbar. For example, you can zoom into any part of the wave
for closer inspection by using the zoom tool (magnifying glass). For precise measurements of the
waveforms, you can make use of the cursors. There are two cursors labeled a and b (red and blue
crosses in the toolbar). To use a cursor, select the cursor button and then hover the mouse over the
waveform of interest. The mouse pointer will change shape into a cross. Click on the waveform. This
will produce a pair of horizontal and vertical lines that track the waveform. You can move the cursor by
grabbing the associated letter tab at the top of the graph with the mouse. The values at the intersection
are displayed in a small output window. If both cursors are active, the output window will also include
the differences between the two sets of cursor values. This is illustrated in Figure 2-8 where the the
bottom line displays the difference in the horizontal X values (here, that's time), and the vertical Y
values (in this case, voltage).
Figure 2-8
You may wish to separate the curves instead of displaying them together. This can be achieved through
the View menu options Separate/Collect curves, as shown in Figure 2-9.
Figure 2-9
Some other graph attributes can be modified through the View menu such as the color of the grid and
the visibility of the axes. Double clicking on a curve will allow you to set the color of the curve, its
thickness and other characteristics. Unique labels can be applied using the Text tool (capital T on the
toolbar and essentially the same as the one found in the main program toolbar). A pointer can be added
to the text with the use of the Text Pointer button (a small T with an arrow). The horizontal and vertical
axes can be formatted by double clicking on them. This will bring up the Set Axis dialog box. Here you
can change the label, set the numeric format and precision, and also set the scale range and type. This is
illustrated in Figure 2-10.
Figure 2-10
One particularly interesting toolbar button is the one immediately to the right of the cursors. This is the
Post Processor. Selecting this will allow you to create complex expressions that can then be plotted. For
example, you might wish to find the difference between two voltages or the current through a section of
a circuit by dividing its voltage curve by the associated resistance.
The process is fairly straightforward. The Post Processor dialog is illustrated in Figure 2-11. On the left
is a list of available signals. In this example we have the voltages from node a to ground and from node
b to ground. Suppose we would like to plot the voltage seen across R1. This is voltage a minus voltage
b. Select a from the list and copy it to the Line Editor by clicking on the large downward arrow. Now,
select the minus sign from the drop down list of built-in functions and copy this down to the Line
Editor. Finally, select b from the curves list and copy it down. We now have an expression to plot. It
can be previewed with the Preview button before selecting OK. This curve is shown in bright blue in
the graphing window.
Figure 2-11
Assignment
Recreate the transistor amplifier schematic shown in Figure 2-12. Try to make it as close to this
drawing as possible. All parameters must be the same. Device designators must also be the same (after
all, these will be cross referenced to the PCB layout and bill of materials). The only items to change are
the date (use today’s date) and the designer's name entry (insert your name).
Figure 2-12