User guide
August 2001 127
Handling Incoming and Outgoing Calls
The following example shows the steps involved in using
RHT_START_PCPM to detect answer.
1. The application starts RHT_START_PCPM with
VPstartStop_s fields ‘LineTerm0’ and ‘Timeout’ set.
2. When RHT_START_PCPM returns, the application calls
RHT_GET_STATUS for the VP device and checks
VPchanStatus_s.TermType.
Interpreting Results
1. If VPchanStatus_s =
T_RHT_PCPM, then
RHT_START_PCPM determined the line state. The
VPchanStatus_s.PCPMtype field contains the line status
information.
2. If VPchanStatus_s.TermType =
T_RHT_TIMEOUT, then
RHT_START_PCPM did not detect any condition within the
allotted amount of time.
3. If VPchanStatus_s.TermType =
T_RHT_LINEOFF, the CO
either answered or disconnected the call before answering.
The application calls RHT_GET_STATUS for the line
device and checks RTNI_lineStatus_s.TermType. This field
contains information about the status of the line.
Terminating an Outbound Call
Terminating an outbound uses the same procedure as
terminating an inbound call, except that outbound calls
terminate using a Clear Forward rather than a Clear Back
signal. RHT_DISCONNECT handles this distinction. For more
information about terminating calls, see Terminating an
Inbound Call on page 119.