home *** CD-ROM | disk | FTP | other *** search
/ Computer Club Elmshorn Atari PD / CCE_PD.iso / pc / 0500 / CCE_0544.ZIP / CCE_0544 / MX2 / MX2.TXT < prev    next >
Text File  |  1988-06-11  |  29KB  |  1,585 lines

  1.  
  2. - 1 -                          MX2 Multitasking Kernel
  3.  
  4.  
  5.  
  6.  
  7. **************************************************************************
  8. *       Due to my now being a multimillionaire I am forever giving away  *
  9. *       the complete source and the complete program is now              *
  10. *                  !!!       PUBLIC DOMAIN     !!!                       *
  11. *                                                                        *
  12. *                  !!!            FREE         !!!                       *
  13. *       As a service to help down and out C programmers around the       *
  14. *       world you can still send a donation to                           *
  15. *                                                                        *
  16. *               Fred Brooks                                              *
  17. *               4145 44ST #5                                             *
  18. *               San Diego CA 92105                                       *
  19. *                                                                        *
  20. *               You will receive a thank you and can continue            *
  21. *               to live with a clear conscience.                         *
  22. *                                                                        *
  23. *               MX2 V2.3.0    A multitasking and multiuser               *     
  24. *               environment for ATARI ST.                                *
  25. *               Written using TDI Modula-2 3.01a Compiler                *
  26. *               For TOS Versions 11/20 1985 and 04/22 1987               *
  27. *               Other Versions may not run correctly.                    *
  28. *                                                                        *
  29. *               This set of programs are NOT for sale by anyone and I    *
  30. *               reserve all rights to it's ownership.                    *
  31. **************************************************************************
  32.  
  33.  
  34.  Intro: MX2 is a multitasking environment to aid in program development
  35.         for the ATARI ST. It was developed in Modula-2 but can be used
  36.         with any language such as C, BASIC, or PASCAL. Suggested system
  37.         minimum requirements are 1 MEG of memory with a double-sided
  38.         disk drive. A hard disk drive will greatly improve system
  39.         performance.
  40.  
  41.  
  42.  
  43.  
  44.  
  45.  
  46.  
  47.  
  48.  
  49.  
  50.  
  51.  
  52.  
  53.  
  54.  
  55.  
  56.  
  57.  
  58.  
  59.  
  60.  
  61.  
  62.  
  63.  
  64.  
  65.                                MX2 Multitasking Kernel
  66.  
  67.  
  68. - 2 -                          MX2 Multitasking Kernel
  69.  
  70.  
  71.  NOTES:
  72.  
  73.         I have tuned this kernel for use with the GULAM shell. I have 
  74.         had no problems using it exempt with the TE communications command.
  75.         It locks up my background xmodem routines if used.                           
  76.  
  77.  
  78.  
  79.  
  80.  
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.                                MX2 Multitasking Kernel
  132.  
  133.  
  134. - 3 -                          MX2 Multitasking Kernel
  135.  
  136.  
  137. SYSTEM GENERATION:
  138.  
  139.         The MX2.INF file contains the system generation parameters.
  140.         It is an ASCII files that can be edited with the UE editor in
  141.         GULAM or any ASCII editor This files allows you to change the
  142.         default system boot parameters
  143.         If this file does not exist the default values are:
  144.                 numeric values are in decimal
  145.  
  146.         Init Command              : IP CLI.PRG
  147.         System Memory             : 32000
  148.         Alt Program HOTKEY        : 3276800
  149.         Normal Mouse HOTKEY       : 3211264
  150.         Cursor Mouse HOTKEY       : 3014656
  151.         Reboot HOTKEY             : 1245184
  152.         Reserved Memory           : 32000
  153.  
  154.         The initialisation command is normally used to load the SHELL
  155.         program. The CLI.PRG enables GULAM.PRG to multitask then loads
  156.         the program. If the program is exited the kernel will respawn
  157.         the SHELL. To load a program other than the SHELL edit the line to
  158.         to IP "name of program".
  159.  
  160.         System memory is the size of the memory reserved by MX2 to
  161.         allocate for it's internal data structures. The default size
  162.         should be adequate for 7 MX2 processes with a workspace of 2K
  163.         each.
  164.  
  165.         Reserved memory is the size of the memory block that will be split
  166.         off of the main memory heap.  This memory should still be available
  167.         with GEM programs that allocate all available memory with a malloc(-1).
  168.  
  169.  
  170.  
  171.  
  172.  
  173.  
  174.  
  175.  
  176.  
  177.  
  178.  
  179.  
  180.  
  181.  
  182.  
  183.  
  184.  
  185.  
  186.  
  187.  
  188.  
  189.  
  190.  
  191.  
  192.  
  193.  
  194.  
  195.  
  196.  
  197.                                MX2 Multitasking Kernel
  198.  
  199.  
  200. - 4 -                          MX2 Multitasking Kernel
  201.  
  202.  
  203. MX2.ACC:
  204.  
  205. The MX2.ACC will not work correctly if you try to run two or more GULAM
  206. shells. Because both would be GEM programs and the AES would hang or get lost
  207. . If you want to have a remote or wish to run two shells from the desk to
  208. please select the OFF option from the desk ACC before starting up the second
  209. shell with the go.g script file or by typing the commands. I am trying to
  210. work around this problem.
  211.  
  212.  
  213.  
  214.  
  215.  
  216.  
  217.  
  218.  
  219.  
  220.  
  221.  
  222.  
  223.  
  224.  
  225.  
  226.  
  227.  
  228.  
  229.  
  230.  
  231.  
  232.  
  233.  
  234.  
  235.  
  236.  
  237.  
  238.  
  239.  
  240.  
  241.  
  242.  
  243.  
  244.  
  245.  
  246.  
  247.  
  248.  
  249.  
  250.  
  251.  
  252.  
  253.  
  254.  
  255.  
  256.  
  257.  
  258.  
  259.  
  260.  
  261.  
  262.  
  263.                                MX2 Multitasking Kernel
  264.  
  265.  
  266. - 5 -                          MX2 Multitasking Kernel
  267.  
  268.  
  269. LOGIN and PASSWD file:
  270.  
  271. The MX2 password system uses five fields separated by a colon.
  272.  
  273. The file 'passwd' contains all password records.
  274.  
  275. field 1         userid
  276. field 2         password
  277. field 3         path
  278. field 4         program
  279. field 5         comment
  280.  
  281. Example         mx2::::
  282.  
  283. Is the minimum password record. It contains only the userid field with the
  284. other fields set to null. This would login user 'mx2' with no password to
  285. the default path 'current path' and run the default program 'gulam.prg'.
  286.  
  287. Example         fred:AXKHRWQ:c\mx2:gulam.prg: login as me using my work id
  288.  
  289. Would login user 'fred' using encrypted password 'AXKHRWQ' to drive 'c' 
  290. path '/mx2' "note if a drive is specified DO NOT use a colon between the drive
  291. character and the path" and run program 'gulam.prg'. The comment is not used 
  292. by the program and is there to inform the user. The program field could have 
  293. been a null entry or any other valid program. The program field 
  294. may include subdirectories. ie ':\mx2\gulam.prg:'
  295.  
  296. The 'passwd.prg' is used to set and change user passwords. New users must
  297. have a null field 2 when it is created. Passwords MUST be set with the
  298. passwd.prg.
  299.  
  300. USAGE:   passwd fred
  301.                 ^
  302.                 user
  303.  
  304. Where fred is a system username in field 1 of a password record.
  305. If there is no password the program will ask for a new password.
  306. If a password already exists you will be asked for the old password
  307. first, then if it is correct you can change the password. Passwords must be
  308. at least 4 characters long.
  309.  
  310. Examine the supplied passwd file for more examples.
  311.  
  312.  
  313.  
  314.  
  315.  
  316.  
  317.  
  318.  
  319.  
  320.  
  321.  
  322.  
  323.  
  324.  
  325.  
  326.  
  327.  
  328.  
  329.                                MX2 Multitasking Kernel
  330.  
  331.  
  332. - 6 -                          MX2 Multitasking Kernel
  333.  
  334.  
  335. INTERFACE LIBRARIES:
  336.  
  337.         The SYSCALL module is the standard interface for user programs
  338.         to the MX2 Multitasking system. It includes functions to starting
  339.         ending and controlling concurrent processes. The TDILIB contains
  340.         the TDI MODULA-2 3.01a libraries. I will include a portable C
  341.         library as soon as I can translate the code over.
  342.  
  343.  
  344.  
  345.  
  346.  
  347.  
  348.  
  349.  
  350.  
  351.  
  352.  
  353.  
  354.  
  355.  
  356.  
  357.  
  358.  
  359.  
  360.  
  361.  
  362.  
  363.  
  364.  
  365.  
  366.  
  367.  
  368.  
  369.  
  370.  
  371.  
  372.  
  373.  
  374.  
  375.  
  376.  
  377.  
  378.  
  379.  
  380.  
  381.  
  382.  
  383.  
  384.  
  385.  
  386.  
  387.  
  388.  
  389.  
  390.  
  391.  
  392.  
  393.  
  394.  
  395.                                MX2 Multitasking Kernel
  396.  
  397.  
  398. - 7 -                          MX2 Multitasking Kernel
  399.  
  400.  
  401. COMMUNICATIONS:
  402.  
  403.         Also included is a no frills communications program.  
  404.         COM.TOS without options sets the AUX port to 1200BPS. 
  405.         COM.TOS # "where # is a number" will set the AUX port to 
  406.         the speed according to the table.
  407.                0      =    300BPS
  408.                1      =    1200BPS
  409.                2      =    2400BPS
  410.                4      =    4800BPS
  411.                9      =    9600BPS
  412.                H      =    19200BPS
  413.         Use the [Undo] key to exit back to the CLI.
  414.  
  415.  
  416.  
  417.  
  418.  
  419.  
  420.  
  421.  
  422.  
  423.  
  424.  
  425.  
  426.  
  427.  
  428.  
  429.  
  430.  
  431.  
  432.  
  433.  
  434.  
  435.  
  436.  
  437.  
  438.  
  439.  
  440.  
  441.  
  442.  
  443.  
  444.  
  445.  
  446.  
  447.  
  448.  
  449.  
  450.  
  451.  
  452.  
  453.  
  454.  
  455.  
  456.  
  457.  
  458.  
  459.  
  460.  
  461.                                MX2 Multitasking Kernel
  462.  
  463.  
  464. - 8 -                          MX2 Multitasking Kernel
  465.  
  466.  
  467. MX2 HOTKEYS:
  468.  
  469.         Hotkeys for several functions are included. These are the default
  470.         keys they can be changed in the MX2.INF file.
  471.  
  472.         ALT m   = Load and switch to second CLI or program, the screen and status
  473.                   of the first cli are saved. If used after the second
  474.                   CLI was loaded this command will switch back and
  475.                   forth between the two. It is recommended that this
  476.                   command only be used in TOS programs. If a you only press
  477.                   RETURN after the program name prompt the CLI.PRG will
  478.                   automatically be loaded.
  479.  
  480.         ALT r   = Will REBOOT the computer. This is the same as pressing the
  481.                   reset button on the ST.
  482.  
  483.  
  484.  
  485.  
  486.  
  487.  
  488.  
  489.  
  490.  
  491.  
  492.  
  493.  
  494.  
  495.  
  496.  
  497.  
  498.  
  499.  
  500.  
  501.  
  502.  
  503.  
  504.  
  505.  
  506.  
  507.  
  508.  
  509.  
  510.  
  511.  
  512.  
  513.  
  514.  
  515.  
  516.  
  517.  
  518.  
  519.  
  520.  
  521.  
  522.  
  523.  
  524.  
  525.  
  526.  
  527.                                MX2 Multitasking Kernel
  528.  
  529.  
  530. - 9 -                          MX2 Multitasking Kernel
  531.  
  532.  
  533. BACKGROUND TIMER:
  534.  
  535.         CRON is the background program timer. When MX2 starts the file 
  536.         CRONTAB is read into memory. CRONTAB lists the start time and 
  537.         frequency of the MX2 command on that line to be executed. To 
  538.         stop the CRON from running the entries in the CRONTAB file you 
  539.         can rename it or after the CLI is running issue the "SYS CRON OFF" 
  540.         command to stop.
  541.  
  542.         All times are in minutes. You may have up to 16 entries in the
  543.         CRONTAB file. The format of the CRONTAB file is.
  544.  
  545.         Start Time      Frequency       Command
  546.         0               60              SYS BP DUMMY.PRG
  547.  
  548.         midnight        every hour      run the DUMMY.PRG in background
  549.  
  550.  
  551.  
  552.  
  553.  
  554.  
  555.  
  556.  
  557.  
  558.  
  559.  
  560.  
  561.  
  562.  
  563.  
  564.  
  565.  
  566.  
  567.  
  568.  
  569.  
  570.  
  571.  
  572.  
  573.  
  574.  
  575.  
  576.  
  577.  
  578.  
  579.  
  580.  
  581.  
  582.  
  583.  
  584.  
  585.  
  586.  
  587.  
  588.  
  589.  
  590.  
  591.  
  592.  
  593.                                MX2 Multitasking Kernel
  594.  
  595.  
  596. - 10 -                         MX2 Multitasking Kernel
  597.  
  598.  
  599. NETWORKING:
  600.  
  601.         netaux.prg      networking program that uses the aux port.
  602.         netmidi.prg     networking program that uses the midi port.
  603.         neta.g          Gulam script file to start the netaux.prg in background.
  604.         netm.g          Gulam script file to start the netmidi.prg in
  605.                         background.
  606.  
  607.         The network uses the MIDI or AUX port to allow a second ST that
  608.         is also running MX2 to use the remote ST's drives. The remote
  609.         drives can be used just like your local drives but they will of
  610.         course be slower because of the transfer of the data through the
  611.         MIDI or AUX ports. The remote drives will start as the second drive ID
  612.         after the last drive that you have on the local ST. For example
  613.         if you have drives A,B,C,D,E,F then the remote drives will be
  614.                            | | | | | |
  615.                            H,I,J,K,L,M  To use the C drive on the remote
  616.         system simply use the J: drive on the CLI. Be sure to cross connect
  617.         the midi cables ie... the MIDI out to the MIDI in on the other ST
  618.         and vice verse.
  619.                             midi in ___  ___ midi in
  620.                   ST 1                 \/                 ST 2
  621.                            midi out ___/\___ midi out
  622.  
  623.         If the AUX port is selected for the network a NULL modem
  624.         cable should  be used for direct connect or a normal
  625.         modem cable for use through remote lines. The BAUD rate
  626.         can be set by the CLI or a DESK ACC.
  627.  
  628.         The MX2NET.PRG is a standalone network driver that runs from
  629.         the DESKTOP or another GEM program. It may be installed in an
  630.         AUTO folder or run from the DESKTOP. It will allow disk sharing
  631.         between ST's that are not both using the MX2 environment.
  632.  
  633.  
  634.  
  635.  
  636.  
  637.  
  638.  
  639.  
  640.  
  641.  
  642.  
  643.  
  644.  
  645.  
  646.  
  647.  
  648.  
  649.  
  650.  
  651.  
  652.  
  653.  
  654.  
  655.  
  656.  
  657.  
  658.  
  659.                                MX2 Multitasking Kernel
  660.  
  661.  
  662. - 11 -                         MX2 Multitasking Kernel
  663.  
  664.  
  665. MISC:
  666.  
  667.         The condition of the CapsLock is shown by an asterisk in
  668.         the upper right corner.
  669.  
  670.  
  671.  
  672.  
  673.  
  674.  
  675.  
  676.  
  677.  
  678.  
  679.  
  680.  
  681.  
  682.  
  683.  
  684.  
  685.  
  686.  
  687.  
  688.  
  689.  
  690.  
  691.  
  692.  
  693.  
  694.  
  695.  
  696.  
  697.  
  698.  
  699.  
  700.  
  701.  
  702.  
  703.  
  704.  
  705.  
  706.  
  707.  
  708.  
  709.  
  710.  
  711.  
  712.  
  713.  
  714.  
  715.  
  716.  
  717.  
  718.  
  719.  
  720.  
  721.  
  722.  
  723.  
  724.  
  725.                                MX2 Multitasking Kernel
  726.  
  727.  
  728. - 12 -                         MX2 Multitasking Kernel
  729.  
  730.  
  731. Known Bugs, Fixes and Improvements:
  732.  
  733.         V1.1.0  Process priorities are now fixed.
  734.  
  735.         V1.0.0  The spooler will not work with networked files.
  736.  
  737.         V1.0.0  MX2.ACC accessory will allow MX2 to multitask in some GEM
  738.                 programs. The TDI editor will allow MX2 to switch when running
  739.                 this accessory.
  740.         V1.1.0  Improved the MX2.ACC to multitask with more gem programs.
  741.                 I have used a vector to read the Super stack of the ACC
  742.                 and passed it to the scheduler to help it know when it's
  743.                 safe to context switch.
  744.         V2.1.0  Added code so the MX2.ACC does not soak up cpu time until
  745.                 MX2 has started. The desk accessory check every 10 seconds
  746.                 for the MX2 running flag then it starts a zero time event
  747.                 timer call.
  748.  
  749.         V1.0.0  Some programs will start up ok but on exit cause the system to
  750.                 crash.
  751.         V2.0.0  I hope I have solved this problem. Most programs should run
  752.                 correctly now without problems. Some programs won't run with
  753.                 the GULAM shell even without MX2.
  754.  
  755.         V1.0.2  Added KILL command to terminate processes and their
  756.                 children. This command will not work with programs
  757.                 run as background processes.
  758.  
  759.         V1.1.0  Added support for use of AUX port for network along
  760.                 with MIDI.
  761.  
  762.         V1.1.0  Added I/O options for selecting ports on background
  763.                 programs. Example a 'sys bp -a -p cli.prg' would start
  764.                 command shell that uses the aux port for input and uses
  765.                 the printer port for output. You could send input from
  766.                 the main CLI by using the 'submita.prg'
  767.                 Example: 'submita ls' would send the the ls command into
  768.                 the aux buffer which the cli would read and send the
  769.                 directory output to the printer.
  770.  
  771.  
  772.         V1.1.0  Changed usage of reserved memory.
  773.  
  774.         V2.2.0  Fix bug in PS command that displayed incorrect start time
  775.                 and date for processes.
  776.  
  777.         V2.2.1  Remove PS command code from kernel. All code is now is the PS
  778.                 Program.
  779.  
  780.         V2.3.0  I have deleted the trap 15 interface because of problems
  781.                 with a few programs. There is now a vector to all the MX2
  782.                 system routines.
  783.  
  784.  
  785.  
  786.  
  787.  
  788.  
  789.  
  790.  
  791.                                MX2 Multitasking Kernel
  792.  
  793.  
  794. - 13 -                         MX2 Multitasking Kernel
  795.  
  796.  
  797. Known Bugs, Fixes and Improvements:
  798.  
  799.         V2.3.0  Added user device drivers. When a background program is
  800.                 started one of the drivers in the range of 0 to 3 may be
  801.                 selected. The device driver routines types are defined in
  802.                 the ATOMIC.DEF file. All bios calls to the keyboard and
  803.                 screen will be redirected the these routines. Of course
  804.                 user will have to load the address of his routines into
  805.                 the correct entry in the DeviceTable. A call to get the
  806.                 system variables will allow you to get the correct address
  807.                 of the DeviceTable. Look at the file device.mod for an
  808.                 example to how to load and use the device drivers.
  809.  
  810.  
  811.  
  812.  
  813.  
  814.  
  815.  
  816.  
  817.  
  818.  
  819.  
  820.  
  821.  
  822.  
  823.  
  824.  
  825.  
  826.  
  827.  
  828.  
  829.  
  830.  
  831.  
  832.  
  833.  
  834.  
  835.  
  836.  
  837.  
  838.  
  839.  
  840.  
  841.  
  842.  
  843.  
  844.  
  845.  
  846.  
  847.  
  848.  
  849.  
  850.  
  851.  
  852.  
  853.  
  854.  
  855.  
  856.  
  857.                                MX2 Multitasking Kernel
  858.  
  859.  
  860. - 14 -                         MX2 Multitasking Kernel
  861.  
  862.  
  863. MX2 Commands:
  864.                 () mandatory parameter, [] optional parameter
  865.                 priories range from 1 to 10 were 10 get the most CPU time.
  866.                 Always use SYS before all commands if run from
  867.                 the CLI.
  868.  
  869.  
  870.  
  871.  
  872.  
  873.  
  874.  
  875.  
  876.  
  877.  
  878.  
  879.  
  880.  
  881.  
  882.  
  883.  
  884.  
  885.  
  886.  
  887.  
  888.  
  889.  
  890.  
  891.  
  892.  
  893.  
  894.  
  895.  
  896.  
  897.  
  898.  
  899.  
  900.  
  901.  
  902.  
  903.  
  904.  
  905.  
  906.  
  907.  
  908.  
  909.  
  910.  
  911.  
  912.  
  913.  
  914.  
  915.  
  916.  
  917.  
  918.  
  919.  
  920.  
  921.  
  922.  
  923.                                MX2 Multitasking Kernel
  924.  
  925.  
  926. - 15 -                         MX2 Multitasking Kernel
  927.  
  928.  
  929. Program Commands:
  930.  
  931.         IP      : Run Interactive Program. This is normally only used to
  932.                   run the mx2 CLI when the kernel first boots. The kernel
  933.                   will respawn the program if it terminates or exits.
  934.                   USAGE : IP [priority] (filename) [command], 
  935.                           SYS IP [priority] (filename) [command]
  936.  
  937.         BP      : Run Background Program.
  938.                   Background programs use the same I/O vectors as the process
  939.                   that started it.
  940.                   USAGE : BP [-pacmn0123] [-pacmn0123] [priority] (filename) [command], 
  941.                           SYS BP [-pacmn0123] [-pacmn0123] [priority] (filename) [command]
  942.                           The -pacmn0123 argument allows for controlling the port
  943.                           that the program STDIO will use for INPUT and OUTPUT.
  944.                           The first argument is for INPUT, the second for OUTPUT.
  945.                           parameters are       p : printer port
  946.                                                a : rs232 port
  947.                                                c : console 'keyboard or screen'
  948.                                                m : midi port
  949.                                                n : null device
  950.                                              0-3 : userdefinable I/O drivers  
  951.                           The NULL device always returns a ready status for
  952.                           input and output. If the port options are missing
  953.                           CON I/O will use the console and screen.
  954.  
  955.               Example:    'sys bp -a -p doit.prg' will cause the doit program to
  956.                           use the rs232 port for INPUT and will print OUTPUT
  957.                           through the printer port.
  958.  
  959.         FP      : Run Foreground Program.
  960.                   Foreground programs always use the normal ST I/O vectors.
  961.                   Use it to run programs that use the ST screen and
  962.                   keyboard from processes that are redirected to the
  963.                   RS232 or other ports.
  964.                   USAGE : FP [-pacmn0123] [-pacmn0123] [priority] (filename) [command], 
  965.                           SYS FP [-pacmn0123] [-pacmn0123] [priority] (filename) [command]
  966.                           The -pacmn0123 argument allows for controlling the port
  967.                           that the program STDIO will use for INPUT and OUTPUT.
  968.                           The first argument is for INPUT, the second for OUTPUT.
  969.                           parameters are       p : printer port
  970.                                                a : rs232 port
  971.                                                c : console 'keyboard or screen'
  972.                                                m : midi port
  973.                                                n : null device
  974.                                              0-3 : userdefineable driver
  975.                           The NULL device always returns a ready status for
  976.                           input and output. If the port options are missing
  977.                           CON I/O will use the console and screen.
  978.  
  979.               Example:    'sys fp -a -a cli.prg' will cause the cli program to
  980.                           use the rs232 port for INPUT and OUTPUT.
  981.  
  982.         PORT    : Select stdio ports.
  983.                   USAGE : PORT (pid) [-pacmn0123] [-pacmn0123], 
  984.                           SYS PORT (pid) [-pacmn0123] [-pacmn0123]
  985.                           The -pacmn0123 argument allows for controlling the port
  986.                           that the process STDIO will use. This command will not
  987.  
  988.  
  989.                                MX2 Multitasking Kernel
  990.  
  991.  
  992. - 16 -                         MX2 Multitasking Kernel
  993.  
  994.  
  995.                           affect the main CLI.
  996.  
  997.  
  998.  
  999.  
  1000.  
  1001.  
  1002.  
  1003.  
  1004.  
  1005.  
  1006.  
  1007.  
  1008.  
  1009.  
  1010.  
  1011.  
  1012.  
  1013.  
  1014.  
  1015.  
  1016.  
  1017.  
  1018.  
  1019.  
  1020.  
  1021.  
  1022.  
  1023.  
  1024.  
  1025.  
  1026.  
  1027.  
  1028.  
  1029.  
  1030.  
  1031.  
  1032.  
  1033.  
  1034.  
  1035.  
  1036.  
  1037.  
  1038.  
  1039.  
  1040.  
  1041.  
  1042.  
  1043.  
  1044.  
  1045.  
  1046.  
  1047.  
  1048.  
  1049.  
  1050.  
  1051.  
  1052.  
  1053.  
  1054.  
  1055.                                MX2 Multitasking Kernel
  1056.  
  1057.  
  1058. - 17 -                         MX2 Multitasking Kernel
  1059.  
  1060.  
  1061. XMODEM COMMANDS:
  1062.  
  1063.         XR      : Receive a XMODEM file from remote computer.
  1064.                   USAGE : XR ([-]filename)
  1065.                         This command will start a background process to
  1066.                         download a file. If the download is complete a single
  1067.                         bell will sound at the console. If the download
  1068.                         aborted for some reason four bells will sound.
  1069.                         Transfers default to CRC, a - in front of the filename
  1070.                         will cause a switch to checksum error-checking.
  1071.  
  1072.         XT      : Send a XMODEM file to a remote computer.
  1073.                   USAGE : XT ([-]filename)
  1074.                         This command will start a background process to
  1075.                         upload a file. If the upload is complete a single
  1076.                         bell will sound at the console. If the upload
  1077.                         aborted for some reason four bells will sound.
  1078.                         Transfers default to CRC, a - in front of the filename
  1079.                         will cause a switch to checksum error-checking.
  1080.  
  1081.         XA      : Abort XMODEM transfers.
  1082.                   USAGE : XA
  1083.                         This command will abort all xmodem background
  1084.                         processes.
  1085.  
  1086.         XS      : XMODEM Status.
  1087.                   USAGE : XS
  1088.                         This command will display the status of a
  1089.                         xmodem up or download.
  1090.  
  1091.  
  1092.  
  1093.  
  1094.  
  1095.  
  1096.  
  1097.  
  1098.  
  1099.  
  1100.  
  1101.  
  1102.  
  1103.  
  1104.  
  1105.  
  1106.  
  1107.  
  1108.  
  1109.  
  1110.  
  1111.  
  1112.  
  1113.  
  1114.  
  1115.  
  1116.  
  1117.  
  1118.  
  1119.  
  1120.  
  1121.                                MX2 Multitasking Kernel
  1122.  
  1123.  
  1124. - 18 -                         MX2 Multitasking Kernel
  1125.  
  1126.  
  1127. PROCESS PRIORITY:
  1128.  
  1129.         NICE    : Change Process Priority.
  1130.                   USAGE : NICE (priority) [pid], SYS NICE (priority) [pid]
  1131.                         If NICE is called without a pid the current process
  1132.                         will be used.
  1133.  
  1134.  
  1135.  
  1136.  
  1137.  
  1138.  
  1139.  
  1140.  
  1141.  
  1142.  
  1143.  
  1144.  
  1145.  
  1146.  
  1147.  
  1148.  
  1149.  
  1150.  
  1151.  
  1152.  
  1153.  
  1154.  
  1155.  
  1156.  
  1157.  
  1158.  
  1159.  
  1160.  
  1161.  
  1162.  
  1163.  
  1164.  
  1165.  
  1166.  
  1167.  
  1168.  
  1169.  
  1170.  
  1171.  
  1172.  
  1173.  
  1174.  
  1175.  
  1176.  
  1177.  
  1178.  
  1179.  
  1180.  
  1181.  
  1182.  
  1183.  
  1184.  
  1185.  
  1186.  
  1187.                                MX2 Multitasking Kernel
  1188.  
  1189.  
  1190. - 19 -                         MX2 Multitasking Kernel
  1191.  
  1192.  
  1193. PROCESS COMMANDS:
  1194.  
  1195.         HP      : Halt Process.
  1196.                   USAGE : HP (pid), SYS HP (pid)
  1197.                         Pid is the process id number of the process you
  1198.                         wish to Halt. To start up a halted process use
  1199.                         the WP command. The HP command takes a process out
  1200.                         of the ready list and removes it from the CPU but
  1201.                         NOT from memory.
  1202.  
  1203.         WP      : Wakeup Process.
  1204.                   USAGE : WP (pid), SYS WP (pid)
  1205.                         Pid is the process id number of the halted process
  1206.                         you wish to Wakeup. The WP command puts the process
  1207.                         back into the ready list to be run in it's time
  1208.                         slot.
  1209.  
  1210.         KILL    : KILL Process.
  1211.                   USAGE : KILL (pid), SYS KILL (pid)
  1212.                         Pid is the process id number of the process you
  1213.                         wish to terminate. The KILL command removes the process
  1214.                         from the ready list and releases it's workspace back to
  1215.                         the system process memory.
  1216.  
  1217.  
  1218.  
  1219.  
  1220.  
  1221.  
  1222.  
  1223.  
  1224.  
  1225.  
  1226.  
  1227.  
  1228.  
  1229.  
  1230.  
  1231.  
  1232.  
  1233.  
  1234.  
  1235.  
  1236.  
  1237.  
  1238.  
  1239.  
  1240.  
  1241.  
  1242.  
  1243.  
  1244.  
  1245.  
  1246.  
  1247.  
  1248.  
  1249.  
  1250.  
  1251.  
  1252.  
  1253.                                MX2 Multitasking Kernel
  1254.  
  1255.  
  1256. - 20 -                         MX2 Multitasking Kernel
  1257.  
  1258.  
  1259. BACKGROUND TIMER COMMANDS:
  1260.  
  1261.         CRON    : Background Scheduler Timer.
  1262.                   USAGE : SYS CRON [ON OFF]
  1263.                         CRON with no options will display the current
  1264.                         timer table entries. CRON OFF disables the timer.
  1265.                         CRON ON read the CRONTAB file, reloads the timer
  1266.                         table then enables the timer.
  1267.  
  1268.  
  1269.  
  1270.  
  1271.  
  1272.  
  1273.  
  1274.  
  1275.  
  1276.  
  1277.  
  1278.  
  1279.  
  1280.  
  1281.  
  1282.  
  1283.  
  1284.  
  1285.  
  1286.  
  1287.  
  1288.  
  1289.  
  1290.  
  1291.  
  1292.  
  1293.  
  1294.  
  1295.  
  1296.  
  1297.  
  1298.  
  1299.  
  1300.  
  1301.  
  1302.  
  1303.  
  1304.  
  1305.  
  1306.  
  1307.  
  1308.  
  1309.  
  1310.  
  1311.  
  1312.  
  1313.  
  1314.  
  1315.  
  1316.  
  1317.  
  1318.  
  1319.                                MX2 Multitasking Kernel
  1320.  
  1321.  
  1322. - 21 -                         MX2 Multitasking Kernel
  1323.  
  1324.  
  1325. MX2 UTILITY PROGRAMS:
  1326.  
  1327. PROCESS STATUS COMMANDS:
  1328.  
  1329.         PS.PRG  : Process Status.
  1330.                   USAGE : PS
  1331.                         Display description of all system processes.
  1332.  
  1333.         PS.PRG -z : Zombie Process Status.
  1334.                   USAGE : PS -z
  1335.                         Display description of all inactive system 
  1336.                         processes.
  1337.  
  1338.         PID.PRG   : Process Identifier.
  1339.                   USAGE : PID
  1340.                         Returns the Process Identifier of the current
  1341.                         process.
  1342.  
  1343.         REDIR.PRG       Program to redirect screen and keyboard I/O to
  1344.                         the RS232 port. 
  1345.  
  1346.         COM.PRG         Program to communicate thru the RS232.
  1347.  
  1348.       SUBMIT.PRG [cmd]  Program to send string on the command line to the
  1349.                         keyboard buffer.
  1350.       SUBMITA.PRG [cmd] send string to RS232 buffer.
  1351.       SUBMITM.PRG [cmd] send string to MIDI buffer.
  1352.  
  1353.       MX2.ACC           Desk accessory to allow MX2 to multitask in
  1354.                         some GEM programs. You can disable GEM Multitasking
  1355.                         if you click on the Desk menu bar for MX2 and select
  1356.                         the OFF button.
  1357.  
  1358. SYS.PRG  USAGE:
  1359.  
  1360.         The SYS.PRG reads it's command line and submits the command the
  1361.         the MX2 kernel. It's use to give MX2 commands from another
  1362.         program such at GULAM. Example "SYS BP LOOP.PRG" will load
  1363.         and run LOOP.PRG as a background process. All MX2 commands
  1364.         can be used. To get a process status enter "SYS PS" 
  1365.        
  1366.  
  1367.  
  1368.  
  1369.  
  1370.  
  1371.  
  1372.  
  1373.  
  1374.  
  1375.  
  1376.  
  1377.  
  1378.  
  1379.  
  1380.  
  1381.  
  1382.  
  1383.  
  1384.  
  1385.                                MX2 Multitasking Kernel
  1386.  
  1387.  
  1388. - 22 -                         MX2 Multitasking Kernel
  1389.  
  1390.  
  1391. USEFUL  SCRIPT FILES:
  1392.  
  1393.         startlp.g       Gulam script file to start the background spooler.
  1394.                         This runs the SPOOLER.PRG as a background process.
  1395.  
  1396.         pr.g            This Gulam script file will copy the file(s) on it's
  1397.                         command line to the MX2 spool directory than start the
  1398.                         SPOOLER.PRG if it has already been run as a background
  1399.                         process.
  1400.  
  1401.         go.g            Gulam script file will start a background shell that
  1402.                         uses the AUX port for I/O.
  1403.  
  1404.  
  1405.  
  1406.  
  1407.  
  1408.  
  1409.  
  1410.  
  1411.  
  1412.  
  1413.  
  1414.  
  1415.  
  1416.  
  1417.  
  1418.  
  1419.  
  1420.  
  1421.  
  1422.  
  1423.  
  1424.  
  1425.  
  1426.  
  1427.  
  1428.  
  1429.  
  1430.  
  1431.  
  1432.  
  1433.  
  1434.  
  1435.  
  1436.  
  1437.  
  1438.  
  1439.  
  1440.  
  1441.  
  1442.  
  1443.  
  1444.  
  1445.  
  1446.  
  1447.  
  1448.  
  1449.  
  1450.  
  1451.                                MX2 Multitasking Kernel
  1452.  
  1453.  
  1454. - 23 -                         MX2 Multitasking Kernel
  1455.  
  1456.  
  1457. DESIGN and IMPLEMENTATION:
  1458.  
  1459.         MX2 is not a CLI shell. It provides a platform for system
  1460.         services for a CLI or programs. When MX2 boots it looks for 
  1461.         CLI.PRG in its directory. If it exists it will be run as an 
  1462.         Interactive Process as the command shell. 
  1463.  
  1464.  
  1465.  
  1466.  
  1467.  
  1468.  
  1469.  
  1470.  
  1471.  
  1472.  
  1473.  
  1474.  
  1475.  
  1476.  
  1477.  
  1478.  
  1479.  
  1480.  
  1481.  
  1482.  
  1483.  
  1484.  
  1485.  
  1486.  
  1487.  
  1488.  
  1489.  
  1490.  
  1491.  
  1492.  
  1493.  
  1494.  
  1495.  
  1496.  
  1497.  
  1498.  
  1499.  
  1500.  
  1501.  
  1502.  
  1503.  
  1504.  
  1505.  
  1506.  
  1507.  
  1508.  
  1509.  
  1510.  
  1511.  
  1512.  
  1513.  
  1514.  
  1515.  
  1516.  
  1517.                                MX2 Multitasking Kernel
  1518.  
  1519.  
  1520. - 24 -                         MX2 Multitasking Kernel
  1521.  
  1522.  
  1523. SETUP:
  1524.         
  1525.         First create a directory \MX2, Move the MX2VX.X.X archive into this
  1526.         directory. Unarchive the main archive. The source.arc and tdilib.arc 
  1527.         file may be placed into separate directories and unarchived.
  1528.         You MUST have a copy of GULAM.PRG for the SHELL. It is included with
  1529.         the main archive. Start the MX2.PRG causing the CLI.PRG will load 
  1530.         and be ready for user login into the system.
  1531.  
  1532.         I have included a few batch files to set up and to help run a
  1533.         CLI in background to the RS232 port.
  1534.  
  1535.         Please let me know of any fixes that you come up with or
  1536.         improvements.
  1537.  
  1538.         HOME PHONE 619-584-0281 San Diego CA.   5PM-10PM Please.
  1539.  
  1540.  
  1541.  
  1542.  
  1543.  
  1544.  
  1545.  
  1546.  
  1547.  
  1548.  
  1549.  
  1550.  
  1551.  
  1552.  
  1553.  
  1554.  
  1555.  
  1556.  
  1557.  
  1558.  
  1559.  
  1560.  
  1561.  
  1562.  
  1563.  
  1564.  
  1565.  
  1566.  
  1567.  
  1568.  
  1569.  
  1570.  
  1571.  
  1572.  
  1573.  
  1574.  
  1575.  
  1576.  
  1577.  
  1578.  
  1579.  
  1580.  
  1581.  
  1582.  
  1583.                                MX2 Multitasking Kernel
  1584.  
  1585.