CA_Close_Record_Channel()

Purpose

Close a record channel.

Libraries

Blueworx Voice Response library (libvae.a)

Custom Server library (libca.a)

Syntax

#include "CA_header.h"
int CA_Close_Channel (
  CHANNEL_INFO_ST *chan_info_sp
)

Description

This subroutine closes a record channel, specified in chan_info_sp, previously opened using CA_Open_Record_Channel(). No more voice data can be read from this channel.

Recording is controlled by the custom server and can span multiple state table actions.

User functions using this call should be invoked by a SendData state table action and not by RecordVoiceToHost. RecordVoiceToHost controls foreground record operations, whereas CA_Close_Record_Channel() is used for background custom server controlled recording.

Parameters

chan_info_sp
A pointer to a CHANNEL_INFO_ST structure, returned by an earlier call to CA_Open_Record_Channel().

Return codes

0
Successful
-1
Unsuccessful (global error number CA_errno is set to indicate the error)

Error names

CA_CALL_ACCESS_DENIED
CA_CHANNEL_NOT_OPEN
CA_FUNC_FAILED
CA_INTERNAL_FD_ERROR
CA_INV_ADDR
CA_INV_CHANNEL
CA_INV_PACK
CA_NOT_CHANNEL_OWNER
CA_NOT_INIT
CA_SIGNAL_RECEIVED
CA_TERMINATING

Related information

CA_Open_Record_Channel(), CA_Poll(), CA_Record_Voice_Stream(), CA_Start_Record_Channel(), CA_Stop_Record_Channel().