home *** CD-ROM | disk | FTP | other *** search
- /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
- /* |_o_o|\\ Copyright (c) 1986 The Software Distillery. All Rights Reserved */
- /* |. o.| || This program may not be distributed without the permission of */
- /* | . | || the authors. */
- /* | o | || Dave Baker Ed Burnette Jay Denebeim John Mainwaring */
- /* | . |// Gordon Keener Jack Rouse John Toebes Doug Walker */
- /* ====== BBS:(919)-471-6436 */
- /* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * */
-
- POPCLI IV by Gordon Keener, John Toebes
- © 1987, 1988, 1989 The Software Distillery. All Rights Reserved
- 235 Trillingham Ln, Cary, NC 27513
-
- Contributions to continue development of this and other fine products for the
- Amiga should be sent to the Software Distillery at the above address.
-
- Other Products produced by the Software Distillery are:
- BLINK - the Turbo-charged Alink replacement
- HACK - The Amiga port of the famous UNIX game
- LARN - Another famous UNIX game
- MEMWATCH - Protects your machine from random trashes
- MAKE - A software development tool one shouldn't be without
- KERMIT - The World renown file transfer protocol brought to the Amiga
- ICONEXEC, SETALTERNATE, SETWINDOW - Icon manipulation tools
- TSIZE - A short utility for determining directory sizes.
- All of these are available on our BBS.
-
- Permission is hereby granted to distribute this program provided both this
- documentation accompanies the executable and that no charge is made for its
- distribution.
-
- POPCLI (pronounced POP-SEE-EL-EYE) is designed to solve two problems at once.
- First it provides a simple way of starting another CLI at any time without
- having to load workbench or exit whatever program you may be using. Second
- it has a builtin screen saver mode that automatically turns off the Amiga
- display when there has been no input for a given period of time.
-
- Once POPCLI is running, you can use it to get a new CLI from whatever program
- you are running by pressing Left Amiga and ESC at the same time. What this
- does is to bring the workbench screen to the front and then start up a new
- CLI window on the workbench screen. This is extremely handy when you start
- a program from CLI and then find you need to do a CLI command.
-
- The other function that POPCLI performs is to blank the screen for you. This
- saves on the wear of the monitor phospher. It will do this for you
- automatically any time that you have not pressed any key or moved the mouse
- for a given period of time regardless of what has been written to the screen.
- This is useful when you leave the Amiga on unattended so that you don't have
- to mess with the brightness control or, worse yet, turn the monitor off,
- putting wear and tear on its power supply. Furthermore it only takes a
- touch of the mouse or any key on the keyboard to bring it all back.
-
- The format of the POPCLI command is:
-
- POPCLI [[secs | ADD | REPL] [key]] [[cmdmods] [CMD] cmnd]
- POPCLI FREE [key]
- POPCLI EXEC [key]
- POPCLI BLANK
- POPCLI UNBLANK
- POPCLI QUIT
- POPCLI ?
-
- cmdmods:
- [NOWB] [MINMEM nnn] [MINCHIP nnn]
-
- From AREXX:
- ADDRESS 'POPCLI4' <popcli-arguments>
-
- POPCLI ? prints a summary of POPCLI options.
-
- <seconds> is any number of seconds after which the screen saver is to
- go into effect. If nothing is specified it defaults to turning off the
- screen after 300 seconds. (Five minutes) Note that it makes its decision to
- shut blank the screen solely upon the absence of any keyboard, gameport, or
- mouse input. Even if a program is printing to the screen it will shut down.
- This is not a problem, to unblank the screen merely move the mouse or touch any
- key (SHIFT or CTRL are excellent choices since they don't do anything).
-
- <key> is the scan code of the key that you wish to act as the command
- executer. By default this is the Escape key although you may set it to any
- other key if an application you use wants to conflict with PopCLI's choice.
- Scan codes may be entered in decimal, or in hex (0xnn or 0Xnn). Keys on the
- main part of the keyboard may also be specified as 'c', where c is one of
- the characters on the keycap; i.e. 's' and 'S' are equivalent to scan code
- 0x21. Also, F1-F10, DEL, and ESC are recognized as naming those keys.
-
- <command> is the command to be executed when the Left Amiga and <key> keys are
- pressed simaultaneously. By default the command is
- NEWCLI >NIL:
- to bring up a CLI window in the center of the screen. Note the >NIL: on the
- command to supress any output that the NEWCLI program may give. This is
- important because at the time the command is executed, the original window
- may be long gone. If you wish to have a CLI come up elsewhere on the screen
- you can put the window definition in the command such as:
- NEWCLI >NIL: CON:0/0/640/200/MYCLI
- Which will open a CLI to fill the entire (non-interlaced) screen. POPCLI
- does no parsing on the command, merely passing the ENTIRE string without any
- processing to AmigaDOS.
-
- The ADD (or REPL) keyword allows a new command key to be added to POPCLI without
- altering the timeout value. You can specify either a timeout or ADD, but not
- both. If the keycode cannot be read as a decimal digit, then you may leave
- off the ADD keyword, but I recommend using it for clarity. Whenever a key
- is redefined, the old command for that key is forgotten.
-
- The FREE keyword will cause POPCLI to free the specified key (default is ESC)
- and forget its command. If you wish to re-instate the key, you will have to
- specify the full command.
-
- The EXEC command will cause the specified key to be executed, just as if it
- had been typed at the keyboard.
-
- The BLANK keyword causes the screen to immediately blank.
-
- The UNBLANK keyword causes the screen to immediately unblank. Useful from
- command scripts.
-
- The TIME keyword allows you to reset the timeout value without clobbering any
- of the key definitions currently in effect.
-
- The NOWB keyword, placed in front of a command, will keep POPCLI from popping
- the Workbench screen to the front whenever the current key is hit. By default,
- POPCLI will pop the Workbench to the front, since the NEWCLI command will
- open a window on the Workbench screen. If, for example, you wanted to open
- a WShell on the topmost screen (using ConMan V1.3 or later), you could
- execute the following:
- POPCLI ADD 0x00 NOWB NEWWSH CON:s*0/0/640/150/topscreen/c
-
- The MINMEM and MINCHIP keywords are useful when your popped commands need a
- lot of memory. MINMEM suppresses command execution if less than the
- specified amount of memory is available; MINCHIP if there is not enough
- chip RAM. The numbers are rounded up to 1k increments, and are intended to be
- approximate. For instance, if you wish to define the Lamiga-1 key to be
- "RUN LSE", and you don't want to run LSE unless there is 50K of chip memory
- free, you can do the following:
- POPCLI ADD '1' MINCHIP 50000 CMD RUN LSE
-
- The CMD keyword allows commands with names which conflict with other POPCLI
- keywords or key codes to be specified. For example,
- POPCLI ADD 0x00 NowB aShell
- will cause Lamiga-` to execute the "aShell" command without popping the
- Workbench screen forward;
- POPCLI ADD 0x00 CMD NowB aShell
- will execute "NowB aShell" after popping the Workbench.
- NOTE: POPCLI keywords are NOT case sensitive.
-
- Terminating POPCLI:
- -------------------
- Once PopCLI has been installed, you can terminate it with the command:
- POPCLI QUIT
-
- You can change the default interval by giving a number:
- POPCLI 5 - sets the default timeout to 5 seconds.
- This is handy when you want to blank the screen immediately. Setting the
- interval to a very large number:
- POPCLI 99999
- Will keep PopCLI from blanking your screen.
-
- Setting the interval does not affect the command(s) to be executed.
-
- Controlling PopCLI from ARexx:
- ------------------------------
- PopCLI now has support for an ARexx port. Now, once PopCLI is up, you can
- send it commands from an ARexx script with the following ARexx command:
- ADDRESS POPCLI4 <popcli-arguments>
- where <popcli-arguments> are any valid PopCLI arguments. Possible uses (or
- abuses) of this feature include:
-
- * Defining lots of keys is faster using the ARexx port than it would be to
- run PopCLI multiple times in succession.
-
- * You can define a PopCLI key to run an ARexx script which re-defines other
- PopCLI keys. Of course, you could do that without the port, but with it,
- you don't have to have the PopCLI module lying around on disk.
-
- * Blanking and unblanking the screen around compiles.
-
- Installing PopCLI:
- ------------------
- To install a copy of POPCLI on your workbench, put a copy of POPCLI in your
- C directory and edit the Startup-Sequence file in the S directory to add
- POPCLI commands of your own taste.
-
- Notes:
- 1) POPCLI blanks the screen by creating a one bit-blane lo-res screen in front
- of all other screens and setting the background color to solid black. It
- then turns off the display freeing the cycles for any program that might
- be running.
- 2) Once the screen blanks, if the AMIGA is left undisturbed for 68.096 years
- the screen may briefly flash back on for the next 68.096 years. I have not
- taken the time to test this. If this turns out to be a problem, please
- let me know.
-
- Enhancements Provided under POPCLI II:
-
- * POPCLI now runs from WORKBENCH. An icon is provided for doing so. When
- run from workbench, the default command and default times will be used.
-
- * When run from CLI, the original window now goes away. In doing so, it
- also appears that incompatibilities with 1.2 have been removed. Please
- feel free to comment on potential future improvements.
-
- * The size of the screen used to blank the display has been reduced to reduce
- memory required to blank the screen.
-
- * POPCLI has been recompiled to take advantage of the latest features of 3.04
- Lattice and BLINK. Although source is being distributed, it is not likely
- that a version of POPCLI could be reconstructed without these products.
-
- Enhancements Provided under PopCLI III:
-
- * POPCLI has again been recompiled with Lattice 4.0 and Blink 6.9. The source
- provided will NOT compile with other than the latest version of Lattice.
-
- * POPCLI now self installs itself using the seglist splitting technique of
- CBack. Because of this, you may freely change the timeout interval or command
- without having to reboot your machine.
-
- Enhancements Provided under PopCLI IV:
-
- * PopCLI has been (aww, you guessed!) recompiled with Lattice 5.00 and Blink
- 7.3.
-
- * Multiple PopCLI keys with different commands are now supported. You may
- PopCLI ADD or PopCLI FREE keys at will. PopCLI QUIT will remove *all* keys.
-
- * Many new keywords and commands supported.
-
- * The code has been arranged such that the setup code and data resides
- in the first hunks of the PopCLI executable. This allows it to be freed when
- cback goes away.
-
- * Hex key names (0xnn) are supported; this makes it easier to assign PopCLI
- keys while looking at the scan code table in the AmigaDOS manual. F1-F10
- are also accepted, as well as ESC and DEL. Character keys may also be
- specified as 'c'.
-
- * Popped CLI's now retain the following information from the CLI from which
- PopCLI is run:
-
- Current Directory
- Current Directory Name (not quite equivalent to the current directory)
- Default Stack Size
- Prompt
- Fail Level
- Path
-
- Notice that these are copied when PopCLI is *first* run, not when the key is
- pressed or even when a new key is added to PopCLI.
-
- * Support for an ARexx port has been added.
-
-