Source code of CDPLAY.CMD - part 1

 
/* ------------------------------------------------------------------ */
/* CDPLAY.CMD - simple text mode CD player                            */
/*                                                                    */
/* (c) Copyright Bernd Schemmer 2000                                  */
/*                                                                    */
/* Author:                                                            */
/*   Bernd Schemmer                                                   */
/*   Stalburgstr. 14                                                  */
/*   D-60318 Frankfurt am Main                                        */
/*   Germany                                                          */
/*   Bernd.Schemmer@gmx.de                                            */
/*                                                                    */
/* History:                                                           */
/*   30.01.2000 /bs v1.00                                             */
/*     - initial release                                              */
/*                                                                    */
/*                                                                    */
/*                                                                    */
/* Distribution:                                                      */
/*   This code may be distributed freely and used in other programs.  */
/*   Please give credit where credit is due.                          */
/*   If you need further help, feel free to contact me at the address */
/*   noted above.                                                     */
/*                                                                    */
/* Description:                                                       */
/*   CDPLAY.CMD is a very simple CD play program using the REXX       */
/*   extension for multimedia.                                        */
/*                                                                    */
/* Usage:                                                             */
/*   CDPLAY   {/L:logfile} {/H} {/Silent} {/NoSound} {/NoAnsi}        */
/*            {/Trace}                                                */
/*                                                                    */
/* where:                                                             */
/*                                                                    */
/*   /L:logFile - logfile is the name of the logfile :-)              */
/*                This parameter is case-sensitive!                   */
/*                Note: use /L:"logfile" if the name of the logfile   */
/*                      contains blanks or special chars              */
/*                def.: do not use a logfile                          */
/*                                                                    */
/*   /H         - show usage, you may also use                        */
/*                /h, /?, /HELP, -h, -H, -HELP or -?                  */
/*                (MAIN is not called!)                               */
/*                                                                    */
/*   /Silent    - suppress all messages (except error messages)       */
/*                You should also use the parameter /L:logfile if you */
/*                use this parameter!                                 */
/*                You may also set the environment variable SILENT to */
/*                "1" to suppress all messages.                       */
/*                                                                    */
/*   /NoSound   - suppress all sounds. You may also set the           */
/*                environment variable SOUND to "0" to suppress the   */
/*                sounds.                                             */
/*                                                                    */
/*   /NoAnsi    - do not use ANSI codes. You may also set the         */
/*                environment variable ANSI to "0" to suppress the    */
/*                use of ANSI codes.                                  */
/*                                                                    */
/*   /Trace     - turn TRACE on before calling MAIN. You may also     */
/*                set the environment variable RXTTRACE to ON to      */
/*                turn the TRACE mode for MAIN on.                    */
/*                                                                    */
/* NOTE:                                                              */
/*   You must use at least one blank to separate the parameter.       */
/*                                                                    */
/*                                                                    */
/* returncodes:                                                       */
/*      0 - execution okay                                            */
/*    240 ... 252                                                     */
/*          reserved for the runtime system                           */
/*    253 - syntax help called (parameter /h)                         */
/*    254 - user break (CTRL-C)                                       */
/*    255 - internal runtime system error                             */
/*   else - program specific errors                                   */
/*                                                                    */
/* Notes:                                                             */
/*                                                                    */
/*                                                                    */
/* Based on TEMPLATE.CMD v3.07, TEMPLATE is (c) 1997 Bernd Schemmer,  */
/* Stalburgstr. 14, 60318 Frankfurt, Germany, Bernd.Schemmer@gmx.de   */
/*                                                                    */
/* Read the documentation for my REXX template TEMPLATE.CMD           */
/* carefully before changing this program!                            */
/* ------------------------------------------------------------------ */

  call trace 'off'      /* turn interactive trace off                 */
                        /* use this statement as the first statement  */
                        /* in your program, to ignore the value of    */
                        /* the environment variable RXTRACE.          */

                  global. = ''  /* init the stem global. with ''      */

/*** change the following values to your need                       ***/

                        /* additional parameter                 v3.06 */
                        /* (string for the usage routine)       v3.06 */
  global.__userUsage  = ''                                   /* v3.06 */

         global.__Version = 1.0          /* Version of YOUR program   */

       global.__SignOnMsg = 1   /* set to 0 if you do not want the    */
                                /* program start and end messages     */

         global.__NeedCID = 0   /* set to 1 if you need CID support   */

      global.__NeedColors = 1   /* set to 1 if you want colored msgs  */

  global.__NeedPatchCheck = 1   /* set to 1 if you want the program   */
                                /* to search for a patched version of */
                                /* this program                       */

              /* set default values for EXPOSELIST if necessary       */
  exposeList = 'msgStem.'


                    /* base message number                            */
  Global.__BaseMsgNo = 1000

              /* name of the routine for the message handling         */
              /* Note: Use '' for hardcoded messages                  */
  global.__GetMsg = ''

             /* note: set the variable prog.__STDOUT to "STDERR:"     */
             /*       or "NUL" if your program is a filter program!   */

  prog.__STDOUT = 'STDOUT'        /* necessary for Object REXX        */
  prog.__STDERR = 'STDOUT'        /* necessary for Object REXX        */
                                                                   /*!*/
/***                End of variables to change                      ***/
/*      HINT: The further program code is in the function MAIN        */

/***        End of Part 1 of the source code of TEMPLATE.CMD        ***/


[Back: CDPLAY.CMD]
[Next: Source code of CDPLAY.CMD - part 4]