Synopsis:
term_event=SMplaypr(vox_chan,ipf_id, prompt_no [,dataformat, samplerate])
Arguments:
vox_chan – The voice channel
ipf_id – The ipf file ID (as specified in the PR.PAR)
prompt_no – The prompt number withing the IPF file to play (starting from 1)
[dataformat] – Optional format of ipf file
[samplerate] – Optional sample rate of ipf file
Description: This function allows a single word/phrase to be played from a specific IPF file specified by the ipf_id. The word/phrase to play is specified by the prompt_no argument,
The optional dataformat argument defines what the speech file format in the IPF file, and defaults to SMDataFormatOKIADPCM (see SMplay() for a list of valid speech file formats).
The optional samplerate can specify the same rate of the data in the IPF file and defaults to 6000 if not specified (see SMplay for a list of valid sample rates).
Returns: The function will return the terminating event that caused the play function to complete which will be one of the following as defined in ACULAB.INC
# Terminating events
const TERM_ERROR = -1;
const TERM_TONE = 1;
const TERM_ABORT = 6;
const TERM_EODATA = 7;
The function may also return other negative error codes if invalid parameters were specified.