FILE UTILITY
Introduction
The
File Utility allows you to perform a wide
variety of data file tasks. You may list, print
, create, edit, and delete .CKT circuit files.
While this utility is quite adequate for its intended task, it's
not
a full featured word processor; it doesn't have features like "search
and replace," etc.
File Utility Menu
When you choose "
(2) File Utility" from the
Main
Menu, either by pressing "
2," or by using
the "
F2" function key, you'll enter the
File
Utility Menu. The screen display will look as follows:
File
Utility Menu
|
|
(1) List File
|
(2) Create File
|
(3) Edit File
|
(4) Delete File
|
(5) Directory
|
(6) Main Menu
|
|
| Choose (1 - 6) ? |
You may make a selection from the
File Utility Menu
by entering a number from 1 to 6. You
don't have to
press
<Enter>; these are
hot
keys and will immediately
do what you
want.
Listing, Deleting, & Printing Files
These two file operations are
identical in that you
are asked
one simple question:
Filename
[<Enter>=Quit] ? _
If you want to
list
the
FILTER demo file that exists in the \mwdata2
data sub-directory, simply type
FILTER, (no
extensions or paths are necessary), and press
<Enter>
to complete the entry.
You'll
then be asked:
"Print Logfile (Y/N) <Enter>=No ? _" Please press
<Enter> for now.
If you choose the option to 'Print Logfile,' the data will be directed
to 'Logfile.txt' within the \mwdata2 sub-directory,
and to the
screen. Right-click on 'Logfile.txt' to print it, and then DELETE the
file; it will re-create when next needed.
Creating a .CKT Data File
When you choose "(
2)
Create File,"
from the
File Utility Menu, either by pressing "
2,"
or by using the "
F2" function key, and then pressing
<Enter>, you'll see the following:
Enter line # 1 : ?_
For practice, lets re-create the file named
FILTER.
We will
need this file later, so
follow the instructions carefully. First, here is the schematic of
FILTER.
It's a 50 ohm 0.5 dB ripple Chebyshev low-pass filter with a 100 MHz
bandwidth.
When you create a
Sceptre .CKT file, its best to
start from the
left side. Each
element in the file is coded as shown in the
Element Library
(see
Appendix A). If
you visit this appendix, use your browser
BACK
button to return here.
If you look at
Appendix A,
you'll see that the code for a shunt C capacitor and a series L
inductor are, respectively,
CAP and
IND.
Here is what the first two lines of code in the .CKT file will look
like:
CAP AA PA 54.3
IND BB SE 97.88
The element
name, whether
it be a capacitor,
CAP, inductor,
IND,
series resistor-capacitor,
SRC, etc. is always
given
first. The
second
column specifies the element
location within the
circuit, AA is left of BB, etc. The third column tells
Sceptre
whether an element is parallel, PA, or series, SE, connected. Finally,
the last number, in the fourth column, specifies the element value in
ohms, nH, pF, degrees, or a combination.
Since our
FILTER circuit has
five
elements in it, the location code letters will start at AA and end at
EE.
In response to the query:
Enter line # 1 : ?_
Type the first two lines of the file as we did
above, and press
<Enter> after
each
entry. The first line will be:
CAP AA PA 54.3
The second line will be:
IND BB SE 97.88
Now enter the remaining three lines in the same
manner. Be
sure to press
<Enter>
after typing each line, and to use the
correct
element values.
After entering the elements in order, from left to right, the
next
step is to tell
Sceptre that we wish to
cascade
them. The
CAX command does this for three or more
elements. The
CAS command is used for two elements,
but its
special in that the
two
elements may be
anywhere in the
circuit.
Given that we have
five elements in this circuit,
type the following command in the next line down. Don't forget to press
<Enter> to
complete
the line entry.
CAX AA EE
All five two-port circuit elements will now be
combined
and the
new network named two-port
AA.
Here is what we have so far in the
FILTER .CKT
file:
CAP AA PA 54.3
IND BB SE 97.88
CAP AA PA 80.88
IND BB SE 97.88
CAP AA PA 54.3
CAX AA EE
Now that we have described the network to be
analyzed, we next must specify the output format.
Sceptre
has four different output formats:
S1,
S2,
IR, and
OR. They are discussed
in detail in
Appendix C.
For the
FILTER example, we'll use the
S1
output format. It gives the overall s-parameters of the network, plus
gain/loss, and stability data. As you
well know,
passive networks are
always "stable," only
active cirucits can be unstable, so the
printing of
this parameter will be automatically
suppressed.
Type the following line into the
FILTER .CKT file
and then press
<Enter>.
PRI AA S1 50
The
PRI is shorthand for
PRINT,
while the
AA tells
Sceptre
which two-port data to print.
S1 is the output
code, and
50 ohms is the system reference
impedance.
Finally, to
complete this .CKT
file, type
END, (and press
<Enter>),
and
then specify a list of analysis frequencies. If
this circuit had contained an
active device, a
TWO,
(short for two-port), we would enter
its s-data
just after the frequency line.
END
There are
two different ways to
enter frequency
data. First, we can enter individual analysis frequencies on one line,
or, second, we can use the
start,
stop,
step format. The latter is easier, so we'll use it
here. Type in the following line:
10 150 10
This tells
Sceptre to
analyze the circuit over the range of 10-150 MHz in 10 MHz steps.
All .CKT files have at
least
four lines. There must be at least one
element in
the file, a
PRI command, an
END,
and a
frequency line. If any file has less than
four lines, you'll get an error message.
O.K., here is the complete .CKT file for FILTER:
CAP AA PA 54.3
IND BB SE 97.88
CAP AA PA 80.88
IND BB SE 97.88
CAP AA PA 54.3
CAX
AA EE
PRI AA S1 50
END
10 150 10 |
At this point, lets
save the
FILTER
circuit file. To tell
Sceptre that you're done
entering data, just type an
extra
<Enter>.
You'll now be asked:
Filename
[<Enter>=Quit] ? _
Enter the following at the prompt:
FILTER
Press
<Enter> to complete the line
entry.
The file will be saved and you'll be returned to the
File
Utility Menu. As you see, it's
very
easy to create a circuit file!
As a
precaution, since this is your first time, you might want to list
the FILTER file to the screen, and make sure its
correct.
Editing
Files
When you choose "
(3) Edit File" from the
File
Utility Menu, either by pressing "
3" or by
using the "
F3" function key, you'll see the
following:
Filename
[<Enter>=Quit] ? _
Let's edit the
FILTER data file we've just created.
Type
FILTER to edit the file. Here is what you
should see on the screen:
Filename:
FILTER
# Lines : 9
(L) List
(D) Delete
(I ) Insert
(R) Replace
(S) Save
(Q) Quit
Choose (A-Z) ? _ |
You'll notice that the
Function Key
Menu at the bottom of the screen lists all
six
choices. It's always a
good idea to choose "
L
= List" first. So press "
L" and then
<Enter>
to list the file.
CAP AA PA 54.3
IND BB SE 97.88
CAP AA PA 80.88
IND BB SE 97.88
CAP AA PA 54.3
CAX
AA EE
PRI AA S1 50
END
10 150 10 |
Lets try out the "
Replace" command, by
changing
the analysis frequency range. Choose "
R" - you'll be
asked which line to
replace:
Line # to replace
[<Enter>=Quit] ? _
Type "
9," since its the
number
of the frequency line. After you press
<Enter>
to complete the entry,
Sceptre will print:
Old: 10 150 10
New: ? _
Type "
10 200 10" to change
the analysis frequency range to cover 10 to 200 MHz in 10 MHz steps.
Save
the changes to a new file,
FILTER2, by first typing
"
S," (the "
Save" command), and
then
entering the filename
FILTER2.
You now have a
good idea on how to use the List,
Replace, and Save commands in the
Edit Menu. There
are just
two commands, Delete and Insert, left to
cover.
The Delete command should be rather obvious. Just tell
Sceptre
the
line number, but be sure to
re-alphabetize
the remaining lines manually using "
Replace." The
Insert command involves a
bit more, but not much.
If you choose "
Insert" from the
Edit Menu,
the screen will
clear and you'll see the
following
message and question:
Caution:
If you INSERT a line of s-data you must also INSERT an additional
analysis frequency! If you
don't, an error will occur.
Insert line between (A,B)
[<Enter>=Quit] ? _
If you want to insert a line at the
top
of the file, enter "
0,1" to tell
Sceptre
that the line is to go just before the first line. If you want to add a
line at the
bottom, and there
were
nine lines in the file, (as is the case here), you would type "
9,10"
to add the new line at the end, in the
tenth
position. For now, just press
<Enter>
to return to the
Edit Menu.
If you now type "
Q" you'll return to the
File
Utility Menu. Try
listing the file
FILTER2
by using the "
F1" function key, and then, since we
don't
need it anymore, you can delete it with the "
F4"
key.
Directory Listings
If you would have chosen "
(5) Directory," you would
see a listing of all .CKT files in the c:\mwsoft\mwdata2 sub-directory on the screen.
Press "
F6" to return to the
Main Menu.
<
BACK 1 2
3 4 5
6 7 8
9 10 11 12 13 14 15 16 17 18 19 20 NEXT >
You are on Page 5