Go to the source code of this file.
Classes | |
struct | bell_mf_tx_state_t |
struct | bell_mf_rx_state_t |
struct | r2_mf_tx_state_t |
struct | r2_mf_rx_state_t |
Defines | |
#define | _SPANDSP_BELL_R2_MF_H_ |
#define | MAX_BELL_MF_DIGITS 128 |
Enumerations | |
enum | mf_tone_types_e { BELL_MF_TONES, R2_MF_TONES, SOCOTEL_TONES } |
Functions | |
int | bell_mf_tx (bell_mf_tx_state_t *s, int16_t amp[], int max_samples) |
Generate a buffer of Bell MF tones. | |
size_t | bell_mf_tx_put (bell_mf_tx_state_t *s, const char *digits) |
Put a string of digits in a Bell MF generator's input buffer. | |
bell_mf_tx_state_t * | bell_mf_tx_init (bell_mf_tx_state_t *s) |
Initialise a Bell MF generator context. | |
int | r2_mf_tx (r2_mf_tx_state_t *s, int16_t amp[], int samples) |
Generate a block of R2 MF tones. | |
int | r2_mf_tx_put (r2_mf_tx_state_t *s, char digit) |
Generate a block of R2 MF tones. | |
r2_mf_tx_state_t * | r2_mf_tx_init (r2_mf_tx_state_t *s, int fwd) |
Initialise an MFC/R2 tone generator context. | |
int | bell_mf_rx (bell_mf_rx_state_t *s, const int16_t amp[], int samples) |
Process a block of received Bell MF audio samples. | |
size_t | bell_mf_rx_get (bell_mf_rx_state_t *s, char *buf, int max) |
Get a string of digits from a Bell MF receiver's output buffer. | |
bell_mf_rx_state_t * | bell_mf_rx_init (bell_mf_rx_state_t *s, void(*callback)(void *user_data, const char *digits, int len), void *user_data) |
Initialise a Bell MF receiver context. | |
int | r2_mf_rx (r2_mf_rx_state_t *s, const int16_t amp[], int samples) |
Process a block of received R2 MF audio samples. | |
r2_mf_rx_state_t * | r2_mf_rx_init (r2_mf_rx_state_t *s, int fwd) |
Initialise an R2 MF receiver context. |
int bell_mf_rx | ( | bell_mf_rx_state_t * | s, | |
const int16_t | amp[], | |||
int | samples | |||
) |
Process a block of received Bell MF audio samples.
Process a block of received Bell MF audio samples.
s | The Bell MF receiver context. | |
amp | The audio sample buffer. | |
samples | The number of samples in the buffer. |
size_t bell_mf_rx_get | ( | bell_mf_rx_state_t * | s, | |
char * | buf, | |||
int | max | |||
) |
Get a string of digits from a Bell MF receiver's output buffer.
s | The Bell MF receiver context. | |
digits | The buffer for the received digits. | |
max | The maximum number of digits to be returned, |
bell_mf_rx_state_t* bell_mf_rx_init | ( | bell_mf_rx_state_t * | s, | |
void(*)(void *user_data, const char *digits, int len) | callback, | |||
void * | user_data | |||
) |
Initialise a Bell MF receiver context.
s | The Bell MF receiver context. | |
callback | An optional callback routine, used to report received digits. If no callback routine is set, digits may be collected, using the bell_mf_rx_get() function. | |
user_data | An opaque pointer which is associated with the context, and supplied in callbacks. |
int bell_mf_tx | ( | bell_mf_tx_state_t * | s, | |
int16_t | amp[], | |||
int | max_samples | |||
) |
Generate a buffer of Bell MF tones.
s | The Bell MF generator context. | |
amp | The buffer for the generated signal. | |
max_samples | The required number of generated samples. |
bell_mf_tx_state_t* bell_mf_tx_init | ( | bell_mf_tx_state_t * | s | ) |
Initialise a Bell MF generator context.
s | The Bell MF generator context. |
size_t bell_mf_tx_put | ( | bell_mf_tx_state_t * | s, | |
const char * | digits | |||
) |
Put a string of digits in a Bell MF generator's input buffer.
s | The Bell MF generator context. | |
digits | The string of digits to be added. |
int r2_mf_rx | ( | r2_mf_rx_state_t * | s, | |
const int16_t | amp[], | |||
int | samples | |||
) |
Process a block of received R2 MF audio samples.
Process a block of received R2 MF audio samples.
s | The R2 MF receiver context. | |
amp | The audio sample buffer. | |
samples | The number of samples in the buffer. |
r2_mf_rx_state_t* r2_mf_rx_init | ( | r2_mf_rx_state_t * | s, | |
int | fwd | |||
) |
Initialise an R2 MF receiver context.
s | The R2 MF receiver context. | |
fwd | TRUE if the context is for forward signals. FALSE if the context is for backward signals. |
int r2_mf_tx | ( | r2_mf_tx_state_t * | s, | |
int16_t | amp[], | |||
int | samples | |||
) |
Generate a block of R2 MF tones.
s | The R2 MF generator context. | |
amp | The buffer for the generated signal. | |
samples | The required number of generated samples. |
r2_mf_tx_state_t* r2_mf_tx_init | ( | r2_mf_tx_state_t * | s, | |
int | fwd | |||
) |
Initialise an MFC/R2 tone generator context.
s | The R2 MF generator context. | |
fwd | TRUE if the context is for forward signals. FALSE if the context is for backward signals. |
int r2_mf_tx_put | ( | r2_mf_tx_state_t * | s, | |
char | digit | |||
) |
Generate a block of R2 MF tones.
s | The R2 MF generator context. | |
digit | The digit to be generated. |