home *** CD-ROM | disk | FTP | other *** search
/ HAM Radio 1 / HamRadio.cdr / math / cktdraw / cktdraw2.doc < prev    next >
Encoding:
Text File  |  1988-09-11  |  9.5 KB  |  199 lines

  1.                                  CKT Draw!
  2.                                                     by Scott Walton
  3.  
  4.     Version 1.0
  5.     December 9, 1987
  6.     Written in TURBO PASCAL
  7.  
  8.     Version 1.1
  9.     February 20, 1988
  10.     Updated to Turbo Pascal 4.0.
  11.  
  12.     Version 2.0
  13.     August 20, 1988
  14.     Additional Elements and Functions added.
  15.  
  16.          CKT Draw! is a graphical circuit editor for the IBM PC and
  17.     compatibles with CGA (or compatible).  My original idea for this
  18.     program was to make a circuit editor that was:
  19.  
  20.           1) Graphically oriented
  21.           2) Keyboard interactive
  22.           3) Very fast and easy to use.
  23.  
  24.      I think I have accomplished this with CKT Draw!  The elements look
  25.      like their symbols, and the keyboard commands allow one to create
  26.      circuits quickly.
  27.  
  28.     FEATURES_____________________________________________________________
  29.  
  30.          CKT Draw! can be started by typing the name of the .EXE file
  31.     CKT.EXE.  Upon loading, the helpscreen is displayed.  This is a quick
  32.     reminder of all the commands, elements, and special keys that can be
  33.     called up in the program as a reference.  Press a key and you are in
  34.     the main display mode.  The display mode has two parts.  The bottom
  35.     two text lines are reserved for the commandbar which displays a list
  36.     of elements and commands that are available.  The rest of the screen
  37.     is the main drawing screen.  An X-shaped cursor appears on the screen.
  38.     This is the graphics cursor.  It is moved around with the arrow keys.
  39.     Most commands are single key presses where the key to be pressed is
  40.     the capital letter of the command listed on the commandbar.  For
  41.     example, to draw a resistor, press R (the capitalized letter of the
  42.     command) and select a direction with the arrow keys.  The main features
  43.     of CKT Draw! are summarized below.
  44.  
  45.  
  46.     MESSAGES: Messages sometimes appear on the command bar at the bottom
  47.     of the screen such as "File not found", "Are you sure you want to
  48.     quit", etc.  Also, keyboard input for the filenames is done here.
  49.  
  50.  
  51.     CURSOR: The X-shaped graphics cursor is moved about the screen with the
  52.     arrow keys to draw and connect elements.  The function keys F1 through
  53.     F4 are used to control the distance the cursor moves when an arrow key
  54.     is pressed.  F2 gives half (1/2) jumps, F3 gives one third (1/3) jumps
  55.     and so on. This is necessary to get to the terminals of an op amp.
  56.     However, only wires can be drawn in the small jump modes, so F1 must
  57.     be pressed to draw elements.
  58.  
  59.     ELEMENTS: All elements are obtained by pressing the single capitalized
  60.     letter of the name and selecting a direction with the arrow keys.  If
  61.     an incorrect key is pressed (not a direction) no element is obtained.
  62.     The elements are:
  63.  
  64.     Resistor - Resistor symbol (zig-zag line)
  65.     Capacitor - Capacitor symbol (two parallel lines)
  66.     Coil - Inductor symbol (coiled line)
  67.     Wire - Wire (straight line)
  68.     Amp - Triangular amplifier symbol (may be used as an op amp or finite
  69.           gain amplifier)
  70.     Voltage source - AC voltage source symbol (circle)
  71.     Current source - AC current source symbol (circle with arrow)
  72.     Box - Unidentified box (can be given any name)
  73.     Node - Circular node symbol (open terminal)
  74.     Cross - Dot showing two wires are connected
  75.     Arrow - Multi-directional Arrow
  76.     Dependent Source - Multi-Directional that is available as Current source
  77.                        or Null Source
  78.     Ground - Multi-directional Ground
  79.     Jfet - Left or Right-Facing Jfet that is available as n-channel or
  80.            p-channel.
  81.     Model - pn Junction Diode model
  82.     Diode - Multi-directional diode that is available as Ideal or Non-ideal
  83.     BJT - Left or RIght-Facing BJT that is available as pnp or npn.
  84.     Zdiode - Multi-directional Zener Diode
  85.     Mosfet - Left or Right-Facing Mosfet that is available as Enhanced
  86.              p-channel, Depletion p-channel, Enhanced n-channel or
  87.              depletion n-channel.
  88.  
  89.  
  90.     COMMANDS: All commands are obtained by pressing  *  followed by the
  91.     capitalized letter of the name.  The commands are:
  92.  
  93.     Blank - Clears the main graphics screen
  94.  
  95.     Delete - Deletes an element.  Use an arrow key to choose which element
  96.              is deleted.  To delete a node element (node or cross) hit
  97.              the HOME key after pressing D.  To delete an op amp hit the
  98.              END key, then choose a direction with the arrow keys.
  99.  
  100.     Hold - Erases the cursor and command bar and waits until a key is
  101.            pressed.  This lets you look at how your final circuit will
  102.            look or print with ^printscreen.
  103.  
  104.     ?(Help) - Displays the help screen, that appears when the program is
  105.               first started, for reference.  The current circuit is saved.
  106.  
  107.     Text - Engages text mode to allow text entry. (See below for details)
  108.  
  109.     Print - Prints out the current circuit in high res.  This printout
  110.             is right-side up (not sideways down the page).  However, it
  111.             may not work on printers that do not support 120 dots per
  112.             inch graphics mode.
  113.  
  114.     Save - Saves a file to disk.  The user is prompted for a file name.
  115.            The extension is always .CKT (this lets you look at your disk
  116.            directory and immediately see which files belong to CKT Draw!).
  117.            Certain characters are illegal as input to the file name, such
  118.            as <space>, !, @, etc., and these characters are not allowed.
  119.  
  120.     Get - Loads a file from disk.  This works in the same manner as save.
  121.  
  122.     Quit - Exit from the program to DOS.
  123.  
  124.  
  125.     TEXT MODE: This allows text to be added to circuits.  Pressing T enters
  126.     text mode.  The commandbar displays a message on how to exit.  The
  127.     text cursor (a square) appears in the upper left hand corner.  This can
  128.     be moved with arrow keys also.  The cursor will wrap around at the edge
  129.     of the screen.  The function keys F1 through F10 change the amount by
  130.     which the cursor moves.  F1 gives a single pixel jump, F2 gives a two
  131.     pixel jump an so on.  The default distance is 8 pixels (F8).  Note that
  132.     these distances apply both for the arrow keys AND WHEN TYPING TEXT.
  133.     Thus to get proper spacing in text, you must press F8.  If you make a
  134.     mistake, backspace will erase the text.  It will also replace any
  135.     graphics that you have typed over AS LONG AS YOU HAVE NOT PRESSED ENTER
  136.     OR AN ARROW KEY.  After this, backspace will erase a character and any
  137.     graphics in the same space.
  138.  
  139.  
  140.     HINTS AND TIPS________________________________________________________
  141.  
  142.          When using amplifiers, it is sometimes hard to get wires and elements
  143.     lined up.  One good way to go is to draw the amp first, then start from
  144.     the amp terminals drawing other elements.  Liberal use of the function keys
  145.     (F1 - F4) will also help. This is also true for Mosfets, BJT's and Jfet's.
  146.          In text mode, good titles can be obtained by double striking.  To
  147.     do this, put your cursor at the first letter in the word then move off by
  148.     one pixel (using F1 and an arrow key).  Then retype the words to get a
  149.     "bold" print.  Also, it is possible to underline text by simpling backing
  150.     up to the beggining of the text and typing the underline key.
  151.  
  152.  
  153.     THE PROGRAM___________________________________________________________
  154.  
  155.          CKT Draw! was written in TURBO PASCAL on an IBM clone.  The code
  156.     is about 800 lines long.  The program is probably IBM/CGA/TURBO
  157.     specific because it uses many routines that are specific to
  158.     TURBO and CGA.  The program, while not being very large, is quite a
  159.     memory hog and might not run on a 64k machine.  (I don't know, though,
  160.     if you find out let me know).  Also, since this is a version 1.1
  161.     program, it is bound to have lots of bugs that I cannot find all by
  162.     myself.  I would also appreciate notice of any of these and any
  163.     comments or suggestions you might have.  I live in Tucson, Arizona,
  164.     and can be contacted through any of my bulletin boards such as:
  165.  
  166.     University of Arizona (U of A) MAP BBS
  167.     U of A College of Agriculture (CAG BBS)
  168.     Davis - Monthan Air Force Base (DMAFB BBS)
  169.     NEC Home Electronics BBS (Nationwide)
  170.     Any other that you find my name on.
  171.  
  172.     or you may write to me:
  173.  
  174.     Scott Walton
  175.     3041 S. Eastview Ave.
  176.     Tucson, AZ 85730
  177.  
  178.  
  179.     REVISIONS AND UPDATES_________________________________________________
  180.  
  181.          I hope to make improvements on this program such as fixing bugs,
  182.     adding new elements and commands.  I would also like to try and make
  183.     the code smaller (if possible) and faster.  Any suggestions for
  184.     improvement will be greatly appreciated.  Keep an eye out for future
  185.     revisions of CKT Draw!
  186.  
  187.     Version 1.1 - For version 1.1, the code was recompiled using Turbo
  188.        Pascal 4.0.  This makes the code smaller as was desired above.
  189.  
  190.    Version 2.0 - Additional Elements were added:Arrow, dependent source
  191.                  (Current and Null), Ground, Jfet, Pn Junction diode model,
  192.                  Diode, BJT, Zener Diode, and Mosfet.  A problem with the
  193.                  Print function was fixed.  In order to have growth space,
  194.                  Vars,Const and type sections were separated into a
  195.                  separate unit (function of Turbo 4.0).  An addtional
  196.                  draw function (Drawe2) was created to handle the
  197.                  multi-directional elements.
  198.  
  199.