Main Page | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

bell_r2_mf.h File Reference

Go to the source code of this file.

Defines

#define _SPANDSP_BELL_R2_MF_H_
#define MAX_BELL_MF_DIGITS   128

Typedefs

typedef bell_mf_tx_state_s bell_mf_tx_state_t
typedef bell_mf_rx_state_s bell_mf_rx_state_t
typedef r2_mf_tx_state_s r2_mf_tx_state_t
typedef r2_mf_rx_state_s r2_mf_rx_state_t

Functions

 SPAN_DECLARE (int) bell_mf_tx(bell_mf_tx_state_t *s
 Release a V.8 context.
 SPAN_DECLARE (bell_mf_tx_state_t *) bell_mf_tx_init(bell_mf_tx_state_t *s)
 Initialise a Bell MF generator context.
 SPAN_DECLARE (r2_mf_tx_state_t *) r2_mf_tx_init(r2_mf_tx_state_t *s
 Initialise an R2 MF tone generator context.
 SPAN_DECLARE (size_t) bell_mf_rx_get(bell_mf_rx_state_t *s
 Get a string of digits from a Bell MF receiver's output buffer.
 SPAN_DECLARE (bell_mf_rx_state_t *) bell_mf_rx_init(bell_mf_rx_state_t *s
 Initialise a Bell MF receiver context.
 SPAN_DECLARE (r2_mf_rx_state_t *) r2_mf_rx_init(r2_mf_rx_state_t *s
 Initialise an R2 MF receiver context.

Variables

int16_t amp []
int16_t int max_samples
const char * digits
const char int len
int16_t int samples
char digit
int fwd
char * buf
char int max
digits_rx_callback_t callback
digits_rx_callback_t void * user_data


Detailed Description


Define Documentation

#define MAX_BELL_MF_DIGITS   128
 

The maximum number of Bell MF digits we can buffer.


Typedef Documentation

typedef struct bell_mf_rx_state_s bell_mf_rx_state_t
 

Bell MF digit detector descriptor.

typedef struct bell_mf_tx_state_s bell_mf_tx_state_t
 

Bell MF generator state descriptor. This defines the state of a single working instance of a Bell MF generator.

typedef struct r2_mf_rx_state_s r2_mf_rx_state_t
 

MFC/R2 tone detector descriptor.

typedef struct r2_mf_tx_state_s r2_mf_tx_state_t
 

MFC/R2 tone detector descriptor.


Function Documentation

SPAN_DECLARE r2_mf_rx_state_t  ) 
 

Initialise an R2 MF receiver context.

Parameters:
s The R2 MF receiver context.
fwd TRUE if the context is for forward signals. FALSE if the context is for backward signals.
callback An optional callback routine, used to report received digits. If no callback routine is set, digits may be collected, using the r2_mf_rx_get() function.
user_data An opaque pointer which is associated with the context, and supplied in callbacks.
Returns:
A pointer to the R2 MF receiver context.

SPAN_DECLARE bell_mf_rx_state_t  ) 
 

Initialise a Bell MF receiver context.

Parameters:
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.
Returns:
A pointer to the Bell MF receiver context.

SPAN_DECLARE size_t   ) 
 

Get a string of digits from a Bell MF receiver's output buffer.

Parameters:
s The Bell MF receiver context.
buf The buffer for the received digits.
max The maximum number of digits to be returned,
Returns:
The number of digits actually returned.

SPAN_DECLARE r2_mf_tx_state_t  ) 
 

Initialise an R2 MF tone generator context.

Parameters:
s The R2 MF generator context.
fwd TRUE if the context is for forward signals. FALSE if the context is for backward signals.
Returns:
A pointer to the MFC/R2 generator context.

SPAN_DECLARE bell_mf_tx_state_t  ) 
 

Initialise a Bell MF generator context.

Parameters:
s The Bell MF generator context.
Returns:
A pointer to the Bell MF generator context.

SPAN_DECLARE int   ) 
 

Release a V.8 context.

Parameters:
s The Bell MF generator context.
amp The buffer for the generated signal.
max_samples The required number of generated samples.
Returns:
The number of samples actually generated. This may be less than max_samples if the input buffer empties.


Generated on Fri Aug 28 20:12:28 2009 for spandsp by  doxygen 1.3.9.1