TWENEX MAGIC TOPS-20 magic and other know-how, mostly gleaned from the twenex.org BBOARD or the TOPS-20 mailing list. CONTENTS 1. HOW TO CREATE AND DESTROY SUBDIRECTORIES 2. HOW TO LOG A USER SESSION 3. WHY ARE .EXE FILE NAMES LIMITED TO SIX CHARACTERS? 4. HOW TO TELL HOW MUCH FILE SPACE IS IN USE 5. CONTROL CHARACTERS IN MIC SCRIPTS 6. MACRO SAMPLE PROGRAMS NOTES 1. HOW TO CREATE AND DESTROY SUBDIRECTORIES[1] @SYSTEM:PEXEC.EXE ! Start PANDA EXEC PANDA TOPS-20 Command processor 7.1(4453)-4 @BUILD @@PERMANENT blocks ! Must be less than permanent storage of parent @@WORKING blocks ! Must be less than working storage of parent @@ @POP ! Return to original EXEC The parent directories must each have MAXIMUM-SUBDIRECTORIES set to the total number of directories to be created in its subdirectory tree. Maximum is 20 directories per login. Must allocate blocks of permanent storage when creating a subdirectory. These blocks are automatically deducted from the free blocks for each parent directory, and may not exceed the current free blocks of any of the parent directories. PERMANENT, WORKING, MAXIMUM-SUBDIRECTORIES of existing directory can be altered with BUILD command (PEXEC not necessary). Existing directories can be deleted using the BUILD command KILL subcommand (PEXEC not necessary). Directory must be empty. 2. HOW TO LOG A USER SESSION[1] @PHOTO Log file: test.log [PHOTO: Recording initiated Thu 29-Dec-2011 6:31PM] @ ! Execute commands/programs to be logged. @POP [PHOTO: Recording terminated Thu 29-Dec-2011 6:33PM TEST.LOG.2] @ 3. WHY ARE .EXE FILE NAMES LIMITED TO SIX CHARACTERS?[1] The LINK program that generates .EXE files was inherited from TOPS-10, which limited all file names to six characters. 4. HOW TO TELL HOW MUCH FILE SPACE IS IN USE[1] @INFORMATION DISK-USAGE 5. CONTROL CHARACTERS IN MIC SCRIPTS[2] In a MIC script, a control character can be sent to a program with a string like "^C" (caret-C or any other letter corresponding to a control character) as a subcommand. 6. MACRO SAMPLE PROGRAMS For learning Macro assembly language, the TOPS-20 Monitor Calls User's Guide (DOC:JSYS_USERS.MEM) lists some sample programs that illustrate basic functions like displaying text on a terminal and copying files. => Assume these DON'T work on TOPS-10. NOTES [1] Thanks to Jon Solomon . [2] Thanks to Per Danielsson .