home *** CD-ROM | disk | FTP | other *** search
/ Crawly Crypt Collection 1 / crawlyvol1.bin / program / compiler / pbug1_21 / pbugconf / english / readme < prev   
Encoding:
Text File  |  1994-03-30  |  15.4 KB  |  346 lines

  1.      **********************************************************************
  2.      *                                                                    *
  3.      *                 PEACEBUG, Config                                   *
  4.      *                 ----------------                                   *
  5.      *                                                                    *
  6.      * written by:     Emanuel Möcklin                                    *
  7.      *                 Zschokkestrasse 7                                  *
  8.      *                 CH-8037 Zürich                                     *
  9.      *                 FREDDY@ezrz1.vmsmail.ethz.ch                       *
  10.      *                                                                    *
  11.      * written with:   Turboassembler 1.xx                                *
  12.      *                                                                    *
  13.      **********************************************************************
  14.  
  15.  
  16.      0. Introduction
  17.      ---------------
  18.  
  19.      General:
  20.        With PEACEBUG-Config, you can easily configure PEACEBUG via its cookie
  21.        interface. You can either configure a residently installed debugger or
  22.        PEACEBUG.PRG (on disk).
  23.  
  24.        For more details on the parameters mentioned in the following chapters,
  25.        consult the PEACEBUG readme, under the chapter "Interface".
  26.  
  27.        PBUGCONF works as an accessory or program, on all known and unknown
  28.        TOS versions, ST(E)/TT/F030 and all possible and impossible config-
  29.        urations.
  30.        The resource file is included in the program.
  31.  
  32.      Dialogs:
  33.        All dialogs are in a window and are non modal.
  34.        "Cancel" discards all changes.
  35.        "OK" accepts all changes.
  36.        Some dialogs additionally have a "Set" button, which has the same
  37.        effect as "OK" but does not close the dialog. You cannot undo chan-
  38.        ges with "Cancel" that have been "Set".
  39.        UNDO has the same effect as "Cancel".
  40.        RETURN has the same effect as "OK".
  41.        Control q closes all windows and terminates the program. The changes
  42.        of all opened windows are discarded.
  43.        Control w or the closer of the window closes the top window and
  44.        accept the changes.
  45.        When the program is started or the accessory is called, the main
  46.        menu appears, which allows you to call the other dialogs.
  47.  
  48.      Modes:
  49.        Basically there are two different working modes, the patch mode and
  50.        the config mode:
  51.        - config mode: every time a dialog is opened, the parameters which
  52.          can be manipulated in this dialog will be copied from the resident
  53.          debugger, and if the dialog is exited by "OK", copied back. The con-
  54.          fig mode is the default mode of operation if a debugger is installed
  55.          when PBUGCONF is started.
  56.          Since PBUGCONF version 1.16 it has been possible to configure
  57.          several resident installed debuggers with the same PBUGCONF.
  58.        - patch mode: the parameters are neither taken from a resident
  59.          debugger nor copied back. This allows you to manipulate and save
  60.          the parameters afterwards in PEACEBUG.PRG or PBUGCONF.PRG/ACC.
  61.        As not all of the parameters have the state p(=patch) (PEACEBUG readme,
  62.        chapter "Interface"), some of them can't be manipulated in
  63.        the patch mode.
  64.  
  65.      If you are interested in the source code, please send me a formatted
  66.      disk or an e-mail. You will then receive the newest version in the
  67.      same way. Bug reports and suggestions are also welcome.
  68.  
  69.      The following chapters describe every single dialog which can be
  70.      called from the main menu.
  71.  
  72.  
  73.      1. Information
  74.      --------------
  75.  
  76.      This dialog doesn't need any explanations, does it?
  77.  
  78.  
  79.      2. Vectors
  80.      ----------
  81.  
  82.      This dialog allows you to configure two things:
  83.      1. How PEACEBUG reacts if a certain exception occurs.
  84.      2. How the routine VEKTOR (PEACEBUG readme, chapter "Vectors")
  85.         reacts (VEKTOR is called if PEACEBUG is called and if a F1-F20 or
  86.         RETURN/ENTER is pressed within the debugger).
  87.  
  88.      Here is the standard way to proceed:
  89.      1. First you choose the vector you want to configure on the left side
  90.         "Exceptions".
  91.      2. Then you choose on the right side ("Action"), how the debugger
  92.         should react if the choosen exception occurs. There are three
  93.         possibilities:
  94.         - Debugger: the debugger is called and the occurance of the
  95.           exception is reported.
  96.         - Original: the debugger ignores the exception and just calls the
  97.           routine following the debugger's one (normally the OS).
  98.         - Ignore: the exception is corrected, that means it jumps to the
  99.           opcode following the one that caused the exception.
  100.         On all MC680x0 with x>0, a privilege violation exception occurs if
  101.         a move sr,<ea> is executed, as this addressing mode is only allowed
  102.         in supervisor mode. For this reason, two additional buttons appear
  103.         if you configure the "Privileg"(=Privilege Violation) exception:
  104.         - SR,<ea>: the command is executed in supervisor mode and the
  105.           program doesn't realize it. In contrast to the TOS routine, the
  106.           debugger's routine works with any opcodes e.g.:
  107.           move sr,([-1,A7,D0.l*8],-1).
  108.         - CCR,<ea>: the SR in the opcode is modified directly to a CCR,
  109.           that means e.g. a move sr,d0 is modified to a move ccr,d0 (in the
  110.           program code).
  111.         If vector "Reset" is selected, two more buttons will appear:
  112.         - Always: means that a reset within the debugger is always caught.
  113.         - Once a Sec: means that a reset within the debugger is caught
  114.           only once a second. This means that if you reset twice within one
  115.           second, the reset is actually executed.
  116.         If both buttons are disabled, a reset within the debugger is never
  117.         caught.
  118.         If the reset occurs outside the debugger:
  119.         - Debugger: The debugger catches the reset, but since the PC gets
  120.           lost, the program can't be continued.
  121.         - Original: Just a normal reset.
  122.         - Ignore: All programs hanging in the reset vector are ignored,
  123.           that means a normal reset is performed without calling any pro-
  124.           grams in the reset vector.
  125.      3. Finally, you set how the routine VEKTOR should work (the values in
  126.         brackets are equal to the ones described in the PEACEBUG readme,
  127.         chapter "The More Significant Byte":
  128.        - Untrap (0): the routine is untrapped if possible (if it can be
  129.          found by the xbra links).
  130.        - none (this means all three buttons are disabled) (2): the
  131.          status quo remains untouched.
  132.        - 1st Position (-2): the routine is untrapped if possible, and install
  133.          the vector again.
  134.        - Setup (1): the routine is searched and if not found, installed in
  135.          the vector. If it's found, nothing happens.
  136.        - 1st Position+Setup (-1): the routine is searched and if not found,
  137.          installed in the vector. If it's found, it will be untrapped
  138.          and installed again (so its position is always the first).
  139.  
  140.      ATTENTION: if you leave the dialog with "OK", the routine VEKTOR is
  141.      called afterwards.
  142.  
  143.  
  144.      3. Cache
  145.      --------
  146.  
  147.      This dialog allows you to set the length of the cache and the history-
  148.      buffer.
  149.  
  150.      - Cache:
  151.         - Length each Entry: informs how many bytes one cache entry needs.
  152.           This can vary from PEACEBUG version to PEACEBUG version.
  153.         - Length Cache 1: number of entries of cache 1.
  154.         - Length Cache 2: number of entries of cache 2.
  155.         - Expand Cache 1 to: here you set how many entries cache 1 should
  156.           contain.
  157.         - Expand Cache 2 to: here you set how many entries cache 2 should
  158.           contain.
  159.      You can also choose values smaller than the actual ones. In this case
  160.      entries are deleted, which means untrapped from the chain. If you
  161.      add entries, only the new ones will be allocated, as it is organized
  162.      as a ring.
  163.  
  164.      - History:
  165.         - Length: this is the amount of bytes the historybuffer contains.
  166.         - Actual Number: informs you how many entries are possible with
  167.           the actual length of the buffer (Length/Length of one line).
  168.         - New Length: here you choose the new length of the history buffer.
  169.  
  170.  
  171.      4. Keyboard
  172.      -----------
  173.  
  174.      Here you set the key combination to call the debugger.
  175.  
  176.      Any combination of shift keys (shift left/right, control, alternate,
  177.      left/right mousebutton left) and one of the other keys is used. CapsLock
  178.      is always ignored.
  179.      The two mousebuttons are the ones under the cursor block, named with
  180.      "l" and "r".
  181.  
  182.      - Call 1: key combination, which does not work if flock ($43E) is set.
  183.        Default: alternate F10.
  184.  
  185.      - Call 2: key combination, which always works (hopefully).
  186.        Default: alternate+control F10.
  187.  
  188.  
  189.      5. Miscellanous
  190.      ---------------
  191.  
  192.      - Cursor: insert- or overwrite mode, that's the question.
  193.  
  194.      - Symbols:
  195.        1. All: PEACEBUG uses all symbols for disassembly, this means
  196.           PEACEBUG's own ones and the ones the Resident Symbol Driver
  197.           offers (PEACEBUG readme, Chapter "Symbols, "Resident Symbol
  198.           Driver").
  199.        2. Debugger: PEACEBUG only uses its own symbols for disassembly.
  200.        3. None: PEACEBUG uses no symbols for disassembly.
  201.        If RSD is installed, the program name is also printed. If you choose
  202.        "None", this will be supressed.
  203.  
  204.      - Keyboard+Mouse: here you set the keyrepeat/delay and the same for
  205.        the mouse.
  206.  
  207.      - Timeout: gives you the ability to set the timeouts for the different
  208.        ports, that means the time the debugger waits until it can send data
  209.        to a port (or cannot send).
  210.  
  211.  
  212.      6. Screen
  213.      ---------
  214.  
  215.      The many parameters of the screen interface can be configured in this
  216.      dialog. Detailed explanations to each parameter are to be found in the
  217.      PEACEBUG readme, chapter "Interface, Screen Interface".
  218.  
  219.      - Configure: this box will not appear in the patch mode, as the para-
  220.        meters in it don't have the "p" state. It contains the current
  221.        PEACEBUG screen parameters .
  222.  
  223.      - Prefer: in contrary to the parameters of "Configure", these are the
  224.        parameters the debugger evaluates when it's loaded or if NEW_FORMAT
  225.        is called.
  226.  
  227.      - Active Font: tells the debugger which font to use.
  228.  
  229.      - Load Font: you can load another font in tempus format (8*16 = 4096
  230.        Bytes, 8*8 = 2048 Bytes).
  231.        Sample fonts are in \PEACEBUG\PBUGCONF\FONTS.
  232.  
  233.  
  234.      7. Precedence
  235.      -------------
  236.  
  237.      In this dialog you can set the precedences of arithmetic operations.
  238.      Higher values have greater priority than lower ones, e.g. a+b*c is equal
  239.      to a+(b*c) but unequal to (a+b)*c, as the multiplication has higher priority.
  240.      This function does not seem very useful to me, except to change the precedence
  241.      of the pointer operation (p).
  242.  
  243.  
  244.      8. User Routines
  245.      ----------------
  246.  
  247.      This dialog gives you the ability to install the six routines
  248.      USERTRACE, USERENTER, USERQUIT, USERSWITCH_ENTER, USERSWITCH_QUIT and 
  249.      USERRESET (PEACEBUG readme, chapter "Interface, User Routines").
  250.      Instead of writting a whole program which has to search PEACEBUG and
  251.      has to install itself, you can use this function. The program must
  252.      have a special format, with the following structure at the beginning:
  253.  
  254.      typedef struct {
  255.              int null;           /* Dummy */
  256.              long *us_message;   /* Pointer to the message */
  257.              char xb_magic[4];   /* "XBRA" */
  258.              char xb_id[4];      /* XBRA-ID */
  259.              long *xb_oldvec;    /* old value of the vector */
  260.      } USER;
  261.  
  262.      or in assembler:
  263.  
  264.      > dc.w 0
  265.      > dc.l MESSAGE
  266.      > dc.b 'XBRA'
  267.      > dc.b 'PBUG'               ; e.g.
  268.      > dc.l $XXXXXXXX
  269.  
  270.      After this structure the program follows.
  271.      When loaded it will be relocated, memory will be released, the structure
  272.      above will be initialized and last but not least it will be installed
  273.      into the vector.
  274.      Examples are in the folder PEACEBUG\PBUGCONF\USER. These are not really
  275.      useful, but are mainly to illustrate the use of user routines.
  276.      By the way, the dummy word at the beginning is necessary because
  277.      otherwise *us_message would not be relocated as it would have the
  278.      offset 0 to the text segment.
  279.  
  280.  
  281.      9. Accelerator
  282.      --------------
  283.  
  284.      This dialog allows you to configure the debugger's mouse accelerator.
  285.      Single click on the arrow buttons to increment or decrement the coeffi-
  286.      cients of the polynomial by 1/128, double click to increase by 10/128.
  287.  
  288.  
  289.      10. Load Parameters
  290.      -------------------
  291.  
  292.      This function loads parameters from the files PBUGCONF.ACC/PRG or
  293.      PEACEBUG.PRG. The program recognizes if it's the debugger or the
  294.      config program. If it loads from the config program then there are
  295.      some additional parameters which are not part of the debugger.
  296.  
  297.  
  298.      11. Save Parameters
  299.      -------------------
  300.  
  301.      This function saves parameters into the files PBUGCONF.ACC/PRG or
  302.      PEACEBUG.PRG. The program recognizes if it's the debugger or the
  303.      config program. If it saves into the config program then there are
  304.      some additional parameters which are not part of the debugger.
  305.  
  306.  
  307.      12. Configure
  308.      -------------
  309.  
  310.      This dialog offers you the utilities of \PEACEBUG\PEACEBUG\UTILLITY\.
  311.      The functions are executed in two cases:
  312.      1. If you select "OK" or "Set".
  313.      2. If the program/accessory is loaded and the debugger is installed
  314.         at that moment. Before you have to save the configuration in PBUG-
  315.         CONF naturally.
  316.      The functions which set certain values ("Cache" and "History") take
  317.      these from the config program itself, this means Cache sets the number
  318.      of entries to the value that you set in the dialog "Cache".
  319.  
  320.      - Cache: adds a certain number of entries to the two caches.
  321.      - History: adds certain number of entries to the history buffer. It is
  322.        bytes=entries*length of one line.
  323.      - Invert: inverts the color palette of the debugger
  324.      - Getrez: sets the resolution of the debugger according to Getrez
  325.        (XBIOS 4). This is useful if you are working with virtual
  326.        resolutions (e.g. with protos or bigscreen). As the debugger has its
  327.        own screen, the screenexpander cannot come into action and the
  328.        screen will be messed up. This can be fixed with this function, as
  329.        it urges the debugger to use the real (physical) resolution.
  330.      - Newfont: installs a new screen font.
  331.      - NewFormat: adapts the debugger to the actual resolution, a practical
  332.        function with gfx board driver, which are installed after the auto
  333.        folder programs.
  334.      - NewScreen: if a gfx board driver installs after the debugger, the
  335.        debugger won't recognize it. With this function, PEACEBUG allocates
  336.        a new screen.
  337.  
  338.  
  339.  
  340.      13. Config-/Patchmode
  341.      ---------------------
  342.  
  343.      Until version 1.15 you could only switch between config- and patchmode.
  344.      Now it's possible to configure several debuggers with only one
  345.      config program. This function now switches from patchmode to PEACEBUG
  346.      0 through 9 and back to patchmode.