NAME
irStartTTTimer, irStopTTTimer - start/stop the touch-tone
input string timer
SYNOPSIS
#include <irapi.h>
int irStartTTTimer (channel_id cid);
int irStopTTTimer (channel_id cid);
DESCRIPTION
The irStartTTTimer function starts the timer used for
touch-tone input string collection based on timer expira-
tion.
The IRE_INPUT_DONE event occurs when certain conditions are
satisfied [see IrEVENTS(4IRAPI)]. This event may be gen-
erated if the touch-tone input timer expires. The time
interval starts when irStartTTTimer is called. The IRAPI
library parameter IRP_TT_PRETIME specifies the time period
to wait before the initial touch tone is received while
IRP_TT_INTERTIME specifies the time period to wait between
two successive touch tones [see IrPARAMETERS(4IRAPI)].
If there is no input on the input queue irStartTTTimer
starts a timer for IRP_TT_PRETIME milliseconds. If there is
input on the input queue irStartTTTimer starts a timer for
IRP_TT_INTERTIME milliseconds. If a touch tone is received
before the timeout occurs, the touch-tone timer is canceled.
If a IRE_INPUT_DONE event is not generated upon the receipt
of a touch tone and irStartTTTimer was executed before the
last IRE_INPUT_DONE event occurred, a new timer starts with
a timeout of IRP_TT_INTERTIME. In general, the IRAPI
automatically manages clock timeouts from the point when
irStartTTTimer is called until IRE_INPUT_DONE is generated,
including both predigit and interdigit timeouts.
If a touch-tone timeout occurs before a touch tone arrives
and there is no input on the input queue, IRE_INPUT_DONE is
generated with modifiers IREM_TT and IREM_INPUT_PRE.
If a touch-tone timeout occurs before a touch tone arrives
and if there is input on the input queue, IRE_INPUT_DONE is
generated with modifiers IREM_TT and IREM_INPUT_INTER.
The existing values of the IRP_TT_PRETIME and
IRP_TT_INTERTIME parameters can be retrieved using
irGetParam(3IRAPI) while a new value can be assigned to them
using irSetParam(3IRAPI). Defaults for each parameter are
5000 milliseconds. These parameters must be set to the
desired value before invoking irStartTTTimer.
Refer to irGetInput(3IRAPI) for other conditions under which
IRE_INPUT_DONE event is generated.
Calling irStartTTTimer with an outstanding touch-tone timer
active cancels the outstanding timer and starts a new timer
as defined above.
irStopTTTimer stops the touch-tone timer.
EVENTS
IRE_INPUT_DONE is generated after irStartTTTimer is called
if the conditions explained above are fulfilled.
RETURN VALUE
IRR_OK is returned if the request is successful.
IRR_FAIL is returned if an error occurs.
ERROR
irError is set as follows if an occurs:
IRER_INVALID if the cid is invalid
IRER_SYSERROR if a system or driver call failure occurs
(check irSysError for additional information)
SEE ALSO
irParam(3IRAPI), irGetInput(3IRAPI), IrPARAMETERS(4IRAPI)and
IrEVENTS(4IRAPI).
VERSION
This is version 8/31/00 of this man page.