question about writing a CLI under RSX - VMS

This is a discussion on question about writing a CLI under RSX - VMS ; I have a legacy RSX (11M+ V4.1) application (no source) which installs and uses its own command line interpreter (called PMC). The command set is peculiar to the application and standard MCR commands aren't readily accessible except through a shell ...

+ Reply to Thread
Results 1 to 7 of 7

Thread: question about writing a CLI under RSX

  1. question about writing a CLI under RSX

    I have a legacy RSX (11M+ V4.1) application (no source) which installs and
    uses its own command line interpreter (called PMC). The command set is
    peculiar to the application and standard MCR commands aren't readily
    accessible except through a shell entered by typing 'RSX' at the user
    prompt.

    I would like to extend the instruction set of this CLI. I can (I think)
    write a task that accepts a command line and checks for my new commands. If
    found, I'd execute a TSK under MCR, otherwise I'd just pass the command line
    on to PMC. Is this possible? Is it straightforward? Is there anything
    peculiar about writing a task to act like a CLI? It looks like both ...MCR
    and ...PMC (and ...DCL?) are installed so how do I execute a task under MCR
    from within my new CLI? Of course I have no RSX documents handy and have
    never written a CLI for RSX so is this going to be way more trouble than
    it's worth? Thanks in advance for any illumination.

    Best regards,

    P. Scott Harris, P.Eng.
    H&L Associates



  2. Re: question about writing a CLI under RSX

    Hi

    Your CLI (Command Line Interperter) PMC is just a task similar to MCR or
    DCL. Tasks are declared as CLI's when installed with the install command
    (installed as ...PMC or ...DCL. Any CLI parses commands and passes them to
    MCR...

    Custom CLI's make excellent user/operator interfaces. A terminal at login
    can be set to use a particular CLI. I suspect the your "shell MCR" is
    actually coded into the CLI allowing all or some MCR commands to execute.


    Possible soloutions would be to:

    - modify the existing PMC cli, the lack of source makes this difficult

    - write a new PMC that mimics the original and adds your current
    requirements

    - use an indirect command file (.cmd) to add your new requirements


    Look at the help files on your system and also look for an example CLI. The
    manual set contains an example CLI in macro and fortran. The example makes
    an excellent start if you are to write new code.

    Hope this helps. I have (or had) a fair bit of RSX experience, the above is
    from memory. If you are desperate I may be able to provide an example CLI.

    Cheers Bill D.

    "P. Scott Harris" wrote in message
    news:xNydnZ4rI65qWETcRVn-qg@magma.ca...
    > I have a legacy RSX (11M+ V4.1) application (no source) which installs and
    > uses its own command line interpreter (called PMC). The command set is
    > peculiar to the application and standard MCR commands aren't readily
    > accessible except through a shell entered by typing 'RSX' at the user
    > prompt.
    >
    > I would like to extend the instruction set of this CLI. I can (I think)
    > write a task that accepts a command line and checks for my new commands.
    > If found, I'd execute a TSK under MCR, otherwise I'd just pass the command
    > line on to PMC. Is this possible? Is it straightforward? Is there anything
    > peculiar about writing a task to act like a CLI? It looks like both ...MCR
    > and ...PMC (and ...DCL?) are installed so how do I execute a task under
    > MCR from within my new CLI? Of course I have no RSX documents handy and
    > have never written a CLI for RSX so is this going to be way more trouble
    > than it's worth? Thanks in advance for any illumination.
    >
    > Best regards,
    >
    > P. Scott Harris, P.Eng.
    > H&L Associates
    >
    >




  3. Re: question about writing a CLI under RSX

    Thanks. I appreciate the feedback.

    "Billy" wrote

    > - modify the existing PMC cli, the lack of source makes this difficult

    Unfortunately true.

    > - write a new PMC that mimics the original and adds your current
    > requirements

    The current CL:I is quite comprehensive and customised for machine control
    so this would be a major pain.

    > - use an indirect command file (.cmd) to add your new requirements

    The PMC CLI takes over the indirect operator '@' and access to MCR commands
    through the
    'RSX' command is a bit limited i.e. indirect cmd files run like '>rsx
    @cmdfile' always lock up. I basically
    have to do '>rsx set cli=mcr' to get an indirect cmd file to work, and then
    restore the CLI as '>set cli=pmc'

    > Look at the help files on your system and also look for an example CLI.
    > The manual set contains an example CLI in macro and fortran. The example
    > makes an excellent start if you are to write new code.

    The installed RSX operating system is stripped down and without help files.
    Any pointers to the mentioned
    example (or any examples) would be appreciated. The tools are limited to
    DECUS languages (Pascal for example)
    in addition to MAC so the interface would have to be constructed from
    whatever libraries come with RSX-11M.

    Regards

    P. Scott Harris, P.Eng.
    H&L Associates



  4. Re: question about writing a CLI under RSX

    On Mon, 3 Jan 2005, P. Scott Harris wrote:

    > Thanks. I appreciate the feedback.
    >
    > "Billy" wrote
    >
    >> - modify the existing PMC cli, the lack of source makes this
    >> difficult

    > Unfortunately true.
    >
    >> - write a new PMC that mimics the original and adds your current
    >> requirements

    > The current CL:I is quite comprehensive and customised for machine
    > control so this would be a major pain.
    >
    >> - use an indirect command file (.cmd) to add your new requirements

    ....

    I looked at the sample CLI files that Billy mentioned, and skimmed the
    documentation about writing a CLI. The solution that suggests itself
    to me is:

    - write a new CLI (PSH?) to implement your new commands. Your new
    CLI will pass all unrecognized commands on to PMC.

    It should be OK to send you the sample CLI source files for you to
    examine. Let me know how I can get them to you.

    - Rob


    --

    Rob Brown b r o w n a t g m c l d o t c o m
    G. Michaels Consulting Ltd. (866)438-2101 (voice) toll free!
    Edmonton (780)438-9343 (voice)
    (780)437-3367 (FAX)
    http://gmcl.com/


  5. Re: question about writing a CLI under RSX

    Thanks, much appreciated. Assuming e-mail is acceptable, just remove the
    ..MAPS from my e-mail address and send whatever examples you can find.

    Regards,

    P. Scott Harris, P.Eng.
    H&L Associates

    "Rob Brown" wrote in message
    news:Pine.LNX.4.61.0501032032450.18515@localhost.l ocaldomain...
    > On Mon, 3 Jan 2005, P. Scott Harris wrote:
    > - write a new CLI (PSH?) to implement your new commands. Your new
    > CLI will pass all unrecognized commands on to PMC.
    >
    > It should be OK to send you the sample CLI source files for you to
    > examine. Let me know how I can get them to you.
    >
    > - Rob




  6. Re: question about writing a CLI under RSX

    If you can wait a few days, I can e-mail you a CLI I wrote about 15 years
    ago. I think it is fairly well documented. It allowed command line editing
    and substitution, before passing the result on to MCR.

    Ed Tottenham




    "P. Scott Harris" wrote in message
    news:zPGdnXGSKPl_YETcRVn-2Q@magma.ca...
    > Thanks. I appreciate the feedback.
    >
    > "Billy" wrote
    >
    > > - modify the existing PMC cli, the lack of source makes this difficult

    > Unfortunately true.
    >
    > > - write a new PMC that mimics the original and adds your current
    > > requirements

    > The current CL:I is quite comprehensive and customised for machine control
    > so this would be a major pain.
    >
    > > - use an indirect command file (.cmd) to add your new requirements

    > The PMC CLI takes over the indirect operator '@' and access to MCR

    commands
    > through the
    > 'RSX' command is a bit limited i.e. indirect cmd files run like '>rsx
    > @cmdfile' always lock up. I basically
    > have to do '>rsx set cli=mcr' to get an indirect cmd file to work, and

    then
    > restore the CLI as '>set cli=pmc'
    >
    > > Look at the help files on your system and also look for an example CLI.
    > > The manual set contains an example CLI in macro and fortran. The example
    > > makes an excellent start if you are to write new code.

    > The installed RSX operating system is stripped down and without help

    files.
    > Any pointers to the mentioned
    > example (or any examples) would be appreciated. The tools are limited to
    > DECUS languages (Pascal for example)
    > in addition to MAC so the interface would have to be constructed from
    > whatever libraries come with RSX-11M.
    >
    > Regards
    >
    > P. Scott Harris, P.Eng.
    > H&L Associates
    >
    >




  7. Re: question about writing a CLI under RSX

    Thanks. Any help much appreciated.

    P. Scott Harris
    remove the obvious MAPS from the e-mail address to respond directly

    Edward Tottenham wrote:
    > If you can wait a few days, I can e-mail you a CLI I wrote about 15 years
    > ago. I think it is fairly well documented. It allowed command line editing
    > and substitution, before passing the result on to MCR.
    >
    > Ed Tottenham
    >


+ Reply to Thread