41#if !defined(_SPANDSP_V8_H_)
46typedef void (*v8_result_handler_t)(
void *user_data, v8_parms_t *result);
48enum v8_call_function_e
57 V8_CALL_FUNCTION_EXTENSION = 7
62 V8_MOD_V17 = (1 << 0),
63 V8_MOD_V21 = (1 << 1),
64 V8_MOD_V22 = (1 << 2),
65 V8_MOD_V23HDX = (1 << 3),
66 V8_MOD_V23 = (1 << 4),
67 V8_MOD_V26BIS = (1 << 5),
68 V8_MOD_V26TER = (1 << 6),
69 V8_MOD_V27TER = (1 << 7),
70 V8_MOD_V29 = (1 << 8),
71 V8_MOD_V32 = (1 << 9),
72 V8_MOD_V34HDX = (1 << 10),
73 V8_MOD_V34 = (1 << 11),
74 V8_MOD_V90 = (1 << 12),
75 V8_MOD_V92 = (1 << 13)
81 V8_PROTOCOL_LAPM_V42 = 1,
82 V8_PROTOCOL_EXTENSION = 7
87 V8_PSTN_ACCESS_CALL_DCE_CELLULAR = 0x01,
88 V8_PSTN_ACCESS_ANSWER_DCE_CELLULAR = 0x02,
89 V8_PSTN_ACCESS_DCE_ON_DIGITAL = 0x04
92enum v8_pcm_modem_availability_e
94 V8_PSTN_PCM_MODEM_V90_V92_ANALOGUE = 0x01,
95 V8_PSTN_PCM_MODEM_V90_V92_DIGITAL = 0x02,
96 V8_PSTN_PCM_MODEM_V91 = 0x04
120 int modem_connect_tone;
124 unsigned int modulations;
127 int pcm_modem_availability;
132#if defined(__cplusplus)
137SPAN_DECLARE(
int) v8_restart(v8_state_t *s,
149SPAN_DECLARE(v8_state_t *)
v8_init(v8_state_t *s,
152 v8_result_handler_t result_handler,
165SPAN_DECLARE(
int)
v8_free(v8_state_t *s);
176SPAN_DECLARE(
int)
v8_tx(v8_state_t *s, int16_t *amp,
int max_len);
184SPAN_DECLARE(
int)
v8_rx(v8_state_t *s,
const int16_t *amp,
int len);
192SPAN_DECLARE(
const char *) v8_call_function_to_str(
int call_function);
193SPAN_DECLARE(
const char *) v8_modulation_to_str(
int modulation_scheme);
194SPAN_DECLARE(
const char *) v8_protocol_to_str(
int protocol);
195SPAN_DECLARE(
const char *) v8_pstn_access_to_str(
int pstn_access);
196SPAN_DECLARE(
const char *) v8_nsf_to_str(
int nsf);
197SPAN_DECLARE(
const char *) v8_pcm_modem_availability_to_str(
int pcm_modem_availability);
198SPAN_DECLARE(
const char *) v8_t66_to_str(
int t66);
200#if defined(__cplusplus)
struct logging_state_s logging_state_t
Definition logging.h:72
Definition private/v8.h:30
v8_state_t * v8_init(v8_state_t *s, bool calling_party, v8_parms_t *parms, v8_result_handler_t result_handler, void *user_data)
Initialise a V.8 context.
Definition v8.c:1222
int v8_release(v8_state_t *s)
Release a V.8 context.
Definition v8.c:1246
int v8_free(v8_state_t *s)
Release a V.8 context.
Definition v8.c:1252
void v8_log_supported_modulations(v8_state_t *s, int modulation_schemes)
Log the list of supported modulations.
Definition v8.c:289
int v8_rx(v8_state_t *s, const int16_t *amp, int len)
Process a block of received V.8 audio samples.
Definition v8.c:939
v8_status_e
Definition v8.h:100
@ V8_STATUS_NON_V8_CALL
Definition v8.h:110
@ V8_STATUS_IN_PROGRESS
Definition v8.h:102
@ V8_STATUS_V8_OFFERED
Definition v8.h:104
@ V8_STATUS_FAILED
Definition v8.h:112
@ V8_STATUS_V8_CALL
Definition v8.h:108
int v8_tx(v8_state_t *s, int16_t *amp, int max_len)
Generate a block of V.8 audio samples.
Definition v8.c:807