34#if !defined(_SPANDSP_V18_H_)
35#define _SPANDSP_V18_H_
53 V18_MODE_V23VIDEOTEX = 6,
55 V18_MODE_V21TEXTPHONE = 7,
57 V18_MODE_V18TEXTPHONE = 8
60#if defined(__cplusplus)
76SPAN_DECLARE(v18_state_t *)
v18_init(v18_state_t *s,
92SPAN_DECLARE(
int)
v18_free(v18_state_t *s);
119SPAN_DECLARE(
int)
v18_put(v18_state_t *s,
const char msg[],
int len);
128SPAN_DECLARE(
int)
v18_encode_dtmf(v18_state_t *s,
char dtmf[],
const char msg[]);
137SPAN_DECLARE(
int)
v18_decode_dtmf(v18_state_t *s,
char msg[],
const char dtmf[]);
139SPAN_DECLARE(uint16_t) v18_encode_baudot(v18_state_t *s, uint8_t ch);
141SPAN_DECLARE(uint8_t) v18_decode_baudot(v18_state_t *s, uint8_t ch);
149#if defined(__cplusplus)
SPAN_DECLARE_NONSTD(void) async_rx_put_bit(void *user_data
Accept a bit from a received serial bit stream.
void(* put_msg_func_t)(void *user_data, const uint8_t *msg, int len)
Definition async.h:93
struct logging_state_s logging_state_t
Definition logging.h:75
Definition private/v18.h:30
int calling_party
TRUE if we are the calling modem.
Definition private/v18.h:32
int v18_free(v18_state_t *s)
Release a V.18 context.
Definition v18.c:908
const char * v18_mode_to_str(int mode)
Return a short name for an V.18 mode.
Definition v18.c:915
int v18_encode_dtmf(v18_state_t *s, char dtmf[], const char msg[])
Convert a text string to a V.18 DTMF string.
Definition v18.c:387
int v18_decode_dtmf(v18_state_t *s, char msg[], const char dtmf[])
Convert a V.18 DTMF string to a text string.
Definition v18.c:408
v18_state_t * v18_init(v18_state_t *s, int calling_party, int mode, put_msg_func_t put_msg, void *user_data)
Initialise a V.18 context.
Definition v18.c:826
int v18_put(v18_state_t *s, const char msg[], int len)
Put a string to a V.18 context's input buffer.
Definition v18.c:779
int v18_release(v18_state_t *s)
Release a V.18 context.
Definition v18.c:902