Specifications

Operat ion Page
67
In the cases of the Read-identity, Read-counters, and Send-console-
command functions, the Requester sends the appropriate message as a
Must-transact.' The higher level must abort the request
if
it
determines that it has taken too long.
Receipt number is initialized to a random, non-zero value at system
startup and incremented by one each time one
is
used. It is used to
identify the request between the Console Requester and user.
The Console Requester is the "master" of the console carrier
mechanism. It initiates a console carrier connection by opening a
port to the target system. The Port-id parameter
is
used to insure
that only one Console Requester user can have access to the console
carrier connection at one time. It establishes the connection by
transmitting a reserve console message to the target system and
verifies the connection by sending a Request ID and checking the
returned System
ID
from the target system.
The Console Requester accepts commands from the user and transmits
them using the console command and poll message. It waits for
acknowledgement of the command by receiving a console response and
acknowledge message from the target system before accepting another
command from the user.
If
there is data in the response message, it
makes that data available to the user through the Console-response-
poll function.
The algorithms for the console carrier functions in the Console
Requester are:
ROUTINE Reserve-remote-console (channel-id, destination-address)
:
ON
not successful,
EXIT
with appropriate return-code.
port-id
:=
Open (channel-id, pad, id-list).
receipt-number
:=
Next-receipt-number (channel-id).
system-id
:=
Transact, Request ID message.
IF system-id <function [console carrier]>
is
on AND system-id
<function [console carrier reservation]>
is
off THEN
command-buffer
:=
Allocate-buffer (command-buffer-size).
response-buffer
:=
Allocate-buffer (response-buffer-size).
transmit, Reserve Console message.
receipt-number
:=
Next-receipt-number (channel-id).
system-id
:=
Transact, Request ID message.
IF system-id <console-user>
=
source-address THEN
message number
:=
0.
CLEAR command-pending.
return-code
:=
success.
ELSE
return-code
:=
channel in wrong state.
ENDIF.
ELSE
return-code
:=
channel in wrong state.
ENDIF.
RETURN Reserve-remote-console.
ROUTINE Release-remote-console (port-id)
:
IF port is open
THEN