GDSX Manual

DEVICE^HANDLER Example, Running and
Managing
Extended General Device Support (GDSX) Manual134303
4-2
Compiling the Requester
Compiling the Requester
The application source file, APPLS, is included in the GDSX installed subvolume. The
terminal to be used for compilation is called the TACL terminal. At the TACL terminal,
log on and, if necessary, use the VOLUME command to change the default subvolume
to the subvolume where you wish to work.
Then compile the application program APPLS, assigning an object file name of APPL:
> TAL /IN $vol.subvol.APPLS, OUT $S.#APPLS/ APPL
When compiling APPLS, you do not set the HIGHPIN object-file attribute on, because
this requester is unconverted and cannot run at a high PIN. A listing of the source file is
included in Appendix A.
Running the Application
The first application terminal is used for input to and output from the requester
application. At this terminal, log on and enter a WHO command to identify the
terminal’s device name. Suppose for this example that it is $TC1. Pause the TACL
process with the PAUSE command. Pausing the TACL process allows the application
process to control the terminal.
At the TACL terminal, start an application process, named $A1 in this example:
> RUN APPL /NAME $A1, OUT $TC1, NOWAIT/
$A1 is designed to open the specified OUT file and send a WRITEREAD to the file.
The application terminal should now show a prompt sent by the application. The prompt
contains the CPU number and PIN of the process. Verify this by entering the following
at the TACL terminal:
> STATUS *, TERM
At the application terminal, type a short text string followed by a carriage return. The
string of characters returned should be exactly those entered, displayed in reverse order.
Enter another text string.
After reading the startup message and opening the OUT file, this simple application
performs the following instructions in a loop:
1. Issue a waited WRITEREAD “CPU, PIN” prompt to the file.
2. Reverse the text string that was input at the prompt.
3. Issue a waited WRITE of the reversed string to the file and delay two seconds.
Later in this section the APPLS application is used similarly to communicate with a
terminal, but with an intermediate GDSX process doing datastream conversion,
changing all lowercase text sent to the terminal to uppercase text. Although this
conversion is trivial, it serves to demonstrate how GDSX can be used to do datastream
conversion.