|
Deprecated functions | |
| VT_DEPRECATED (int WINAPI vpb_bridge(int h1, int h2, BridgeMode mode, int resource)) | |
Defines | |
| #define | VPB_RING_STATION_ON -1 |
| Ring station port with default cadence. | |
| #define | VPB_RING_STATION_OFF 0 |
| Stop station port ringing. | |
Enumerations | |
| enum | HookState { VPB_ONHOOK = 0, VPB_OFFHOOK = 1, VPB_FASTOFFHOOK = 2 } |
| Symbolic hook states. More... | |
| enum | BridgeMode { VPB_BRIDGE_OFF = 0, VPB_BRIDGE_ON = 1 } |
| Port bridging control flags. More... | |
Functions | |
| HookState WINAPI | vpb_get_hookstate (VPBPortHandle handle) |
| Return the hook state of a port. | |
| void WINAPI | vpb_sethook_async (VPBPortHandle handle, HookState hookstate) |
| Signal a port to set its hook state. Returns immediately. | |
| void WINAPI | vpb_sethook_sync (VPBPortHandle handle, HookState hookstate) |
| Set the hook state of a port. Waits for it to change before returning. | |
| void WINAPI | vpb_ring_station_async (VPBPortHandle handle, int cadence=-1) |
| Start or stop a station port ringing. | |
| int WINAPI | vpb_bridge (VPBPortHandle h1, VPBPortHandle h2, BridgeMode mode) |
| Create a full duplex bridge between ports h1 and h2. | |
| int WINAPI | vpb_listen (VPBPortHandle dest, VPBPortHandle src, BridgeMode mode) |
| Create a half duplex bridge routing audio from src to dest. | |
| int WINAPI | vpb_soft_bridge (int h1, int h2, int mode) |
| void WINAPI | vpb_set_codec_reg (VPBPortHandle handle, uint16_t addr, uint16_t value) |
| enum BridgeMode |
| enum HookState |
| HookState WINAPI vpb_get_hookstate | ( | VPBPortHandle | handle | ) |
Return the hook state of a port.
| handle | The handle of the port to query. |
VPB_ONHOOK or VPB_OFFHOOK if the query succeeds. | VpbException | will be thrown in the event of an error. |
| void WINAPI vpb_ring_station_async | ( | VPBPortHandle | handle, | |
| int | cadence = -1 | |||
| ) |
Start or stop a station port ringing.
| handle | The handle of the port to control. | |
| cadence | The ring cadence value. |
0 - Stop ringing.1 - Ring a guard tone cadence. Often used before sending caller id.2 - Normal ring for Australian phone networks. (DR0)3-9 - DR1 to DR7 of the AS/ACIF S002:2001 distinctive ring series.10 - US ring cadence.
There is an additional special ring cadence 255, which like 0, stops the station ringing, but in addition will signal an OpenPCI FXS port to enter a mode where caller id information can be transmitted to a handset that is still on hook. ie. for US style caller id, you would generate one second of cadence 1 tone, stopped by a cadence 255 signal. The caller id tones can then be sent, and normal ringing commenced using cadence 2 - 10. Convenience functions to do this are provided with the CTPort interface to ctserver.
1 - 10 will all cause its normal ring cadence to be generated.
1.5.4