Envoy ACP/XF Application Programming Manual

EnvoyACP/XF and the Application Task
EnvoyACP/XF Application Programming Manual132179
1-9
Line Ready Considerations
Line Ready Considerations
The following text describes various Line Ready considerations.
Nonswitched Lines
Always issue a CONTROL 11 or CONTROL 17 to ensure that DTR is enabled.
If DSR remains false because of a problem with a modem, cabling, or other hardware, a
request that causes a READ or WRITE to the line completes but returns file-system
error 140 (modem error).
Since most nonswitched line configurations have a switched-line backup configuration,
you should always use CONTROL 11 or 17.
Switched Lines
Line Ready indicates the state of DSR; DSR is set false when the line is first opened and
remains false until DTR is enabled (DSR becomes true). Your application can raise DTR
by issuing a CONTROL 11 or a CONTROL 17. The completion of a CONTROL 17,0,
(don’t wait for DSR), does not guarantee that DSR (and therefore Line Ready) is true.
Your application can issue a subsequent CONTROL 11 to ensure that DSR is true.
Alternatively, your application can issue a CONTROL 17,1, (raise DTR and wait), to
raise DTR and wait for DSR to become true (Line Ready).
Timeouts
DSR can be true even if no connection to a remote device exists.
In this case, a READ[X] remains pending until the application cancels it. A
WRITE[X], however, completes but returns an error 162 (operation timed out).
Entering an Offline State
If a CONTROL, READ[X], or WRITE[X] operation completes and returns file-system
error 140 (modem error), the link enters an offline state (down). When the link is down,
a CONTROL 13 completes and returns file-system error 140, WRITE[X] completes and
returns file-system error 160 (request invalid for line state), and READ[X] calls remain
until cancelled.