dtmfGetNumber (Function) |
Top Previous Next |
This waits for a number typed in via DTMF key during an active GSM voice session. The function waits for a maximum number of milliseconds between each key press, and if no key is pressed within the timeout period, the function returns with -1 which indicates the timeout. If a complete number has been received, this number will be returned to the caller. The input sequence must be terminated by pressing the "#" (hash) key.
Any voice messages being played (or in the queue) with voiceTalk will be canceled when a DTMF key is pressed during a call to dtmfGetNumber. Also see voiceStop.
Input: timeout : INT (0..32767) Default 3000 Timeout period in milliseconds between DTMF key-press.
Returns: DINT (0..999999999) -1 : Timeout in waiting for a DTMF key-press or an invalid entry (too long). Otherwise the number typed.
Declaration: FUNCTION dtmfGetNumber : DINT;
Example: INCLUDE rtcu.inc |