ISDN_VOICE(3X) — NEWS-OS Programmer’s Manual
NAME
isdn_voice_call, isdn_voice_disc, isdn_voice_recv, isdn_voice_stat, isdn_voice_noinfo, isdn_voice_dtmf − support ISDN telephone call
SYNOPSIS
#include <newsisdn/isdn_iotype.h>
intisdn_voice_stat(info)
structc_status ∗info;
intisdn_voice_noinfo(noinfo)
structn_info∗noinfo;
intisdn_voice_call(addr, sub, wait_time)
char∗addr;
char∗sub;
intwait_time;
intisdn_voice_disc(wait_time)
intwait_time;
intisdn_voice_recv(wait_time)
intwait_time;
intisdn_voice_dtmf(c)
intc;
DESCRIPTION
isdn_voice_stat copies the status of the ISDN voice channel into the info structure.
isdn_voice_noinfo copies the ISDN peer address into the noinfo structure. However, this information is only valid when isdn_voice_stat() returns status of CALL_SETUP, CALL_ALERT or CALL_EST.
isdn_voice_call makes a telephone call to the specified peer addr and sub address. Optionally addr may include “-”. To omit the sub-address, sub should be (char ∗)0. This function waits in max wait_time seconds for the connection to establish. It returns immediately if wait_time is set to 0.
isdn_voice_disc closes a telephone connection. This function waits in max wait_time seconds for disconnection. It returns immediately if wait_time is set to 0.
isdn_voice_recv accepts an incoming telephone call. This function waits in max wait_time seconds for the connection to establish. It returns immediately if wait_time is set to 0.
isdn_voice_dtmf makes a Dual Tone Modulated Frequency tone for 200 msec. c should be selected among ’0’−’9’, ’A’−’D’, ’∗’ and ’#’.
RETURN VALUE
All functions described above return 0 on success. In case of execution error, a −1 is returned with an error code stored in errno. On timeout a −2 is returned. In case of failure to establish or deestablish a call, a −3 is returned; the cause value can be interrogated with isdn_voice_stat.
FILES
/usr/sony/lib/libisdn.a, /sys/newsisdn/isdn_iotype.h
SEE ALSO
xisdn(1), telcall(1), teldisc(1), telans(1), telstat(1)
NEWS-OSRelease 4.1C