Discussion:
CAPI functions for Audio
(too old to reply)
Kinfe Tadesse
2006-04-11 09:44:26 UTC
Permalink
Hi All,

I hope CAPI surely has some functions for sending audio to the phone line
and receiving audio data from the phone line (through the ISDN card). I am
trying to access info. from an application via telephone. I appreciate any
information that will help me send processed audio to the phone line and
receive audio through the phone.

Best regards,

K T.
Tobias Erichsen
2006-04-11 13:09:16 UTC
Permalink
Post by Kinfe Tadesse
Hi All,
I hope CAPI surely has some functions for sending audio to the phone line
and receiving audio data from the phone line (through the ISDN card). I am
trying to access info. from an application via telephone. I appreciate any
information that will help me send processed audio to the phone line and
receive audio through the phone.
You need to select bit-transparent b-protocol in CAPI in CONNECT_REQ
for outgoing calls and CONNECT_RESP for incoming calls.

To do so, you select B1=1, B2=1, B3=0

After you established the b-channel-connection (CONNECT_B3_ACTIVE_IND),
you will receive DATA_B3_INDs which contains audio-data which is encoded
according to ITU-specification G.711 (depending on whether you are located
in the US or Europe, the encoding-law will be u-Law or A-Law).

There is quite a bit amount of source-code around the web to decode between
G.711
data and linear 16 PCM. But beware, that CAPI sends & accepts each G.711
octet
with inversed bit-order (this has historic reasons due to the use of some
Siemens
ISDN-chips).

Best regards,
Tobias

Loading...