spandsp
3.0.0
|
#include <stdlib.h>
#include <inttypes.h>
#include <string.h>
#include <stdio.h>
#include <stddef.h>
#include "spandsp/stdbool.h"
#include "floating_fudge.h"
#include "spandsp/telephony.h"
#include "spandsp/alloc.h"
#include "spandsp/fast_convert.h"
#include "spandsp/logging.h"
#include "spandsp/bit_operations.h"
#include "spandsp/bitstream.h"
#include "spandsp/complex.h"
#include "spandsp/vector_float.h"
#include "spandsp/complex_vector_float.h"
#include "spandsp/vector_int.h"
#include "spandsp/complex_vector_int.h"
#include "spandsp/modem_echo.h"
#include "spandsp/async.h"
#include "spandsp/power_meter.h"
#include "spandsp/arctan2.h"
#include "spandsp/dds.h"
#include "spandsp/crc.h"
#include "spandsp/complex_filters.h"
#include "spandsp/v29rx.h"
#include "spandsp/v34.h"
#include "spandsp/private/bitstream.h"
#include "spandsp/private/logging.h"
#include "spandsp/private/modem_echo.h"
#include "spandsp/private/power_meter.h"
#include "spandsp/private/v34.h"
#include "v22bis_rx_1200_rrc.h"
#include "v22bis_rx_2400_rrc.h"
#include "v34_rx_2400_low_carrier_rrc.h"
#include "v34_rx_2400_high_carrier_rrc.h"
#include "v34_rx_2743_low_carrier_rrc.h"
#include "v34_rx_2743_high_carrier_rrc.h"
#include "v34_rx_2800_low_carrier_rrc.h"
#include "v34_rx_2800_high_carrier_rrc.h"
#include "v34_rx_3000_low_carrier_rrc.h"
#include "v34_rx_3000_high_carrier_rrc.h"
#include "v34_rx_3200_low_carrier_rrc.h"
#include "v34_rx_3200_high_carrier_rrc.h"
#include "v34_rx_3429_rrc.h"
#include "v34_local.h"
#include "v34_tables.h"
#include "v34_superconstellation_map.h"
#include "v34_convolutional_coders.h"
#include "v34_shell_map.h"
#include "v34_probe_signals.h"
Macros | |
#define | M_PI 3.14159265358979323846264338327 |
#define | FP_Q9_7_TO_F(x) ((float) x/128.0f) |
#define | CARRIER_NOMINAL_FREQ 1800.0f |
#define | EQUALIZER_DELTA 0.21f |
#define | EQUALIZER_SLOW_ADAPT_RATIO 0.1f |
#define | V34_TRAINING_SEG_1 0 |
#define | V34_TRAINING_SEG_4 0 |
#define | V34_TRAINING_END 0 |
#define | V34_TRAINING_SHUTDOWN_END 0 |
#define | complex_sig_set(re, im) complex_setf(re,im) |
#define | complex_sig_t complexf_t |
#define | TRAINING_SCALE(x) (x) |
#define | BYPASS_VITERBI |
Enumerations | |
enum | { TRAINING_TX_STAGE_NORMAL_OPERATION_V34 = 0, TRAINING_TX_STAGE_NORMAL_OPERATION_CC = 1, TRAINING_TX_STAGE_PARKED } |
Functions | |
float | v34_rx_carrier_frequency (v34_state_t *s) |
void | v34_put_mapping_frame (v34_rx_state_t *s, int16_t bits[16]) |
int | v34_rx_fillin (v34_state_t *s, int len) |
Fake processing of a missing block of received V.34 modem audio samples. More... | |
int | v34_rx (v34_state_t *s, const int16_t amp[], int len) |
Process a block of received V.34 modem audio samples. More... | |
void | v34_rx_set_signal_cutoff (v34_state_t *s, float cutoff) |
void | v34_set_put_bit (v34_state_t *s, span_put_bit_func_t put_bit, void *user_data) |
Change the put_bit function associated with a V.34 modem context. More... | |
void | v34_set_put_aux_bit (v34_state_t *s, span_put_bit_func_t put_bit, void *user_data) |
Change the put_aux_bit function associated with a V.34 modem context. More... | |
int | v34_rx_restart (v34_state_t *s, int baud_rate, int bit_rate, int high_carrier) |
void | v34_set_qam_report_handler (v34_state_t *s, qam_report_handler_t handler, void *user_data) |
int v34_rx | ( | v34_state_t * | s, |
const int16_t | amp[], | ||
int | len | ||
) |
Process a block of received V.34 modem audio samples.
Process a block of received V.34 modem audio samples.
s | The modem context. |
amp | The audio sample buffer. |
len | The number of samples in the buffer. |
float v34_rx_carrier_frequency | ( | v34_state_t * | s | ) |
Get the current received carrier frequency.
s | The modem context. |
References dds_frequency(), and v34_rx_state_t::v34_carrier_phase_rate.
int v34_rx_fillin | ( | v34_state_t * | s, |
int | len | ||
) |
Fake processing of a missing block of received V.34 modem audio samples.
Fake processing of a missing block of received V.34 modem audio samples. (e.g due to packet loss).
s | The modem context. |
len | The number of samples to fake. |
References v34_state_s::logging, and span_log().
void v34_rx_set_signal_cutoff | ( | v34_state_t * | s, |
float | cutoff | ||
) |
Set the power level at which the carrier detection will cut in
s | The modem context. |
cutoff | The signal cutoff power, in dBm0. |
References v34_rx_state_t::carrier_off_power, v34_rx_state_t::carrier_on_power, and power_meter_level_dbm0().
void v34_set_put_aux_bit | ( | v34_state_t * | s, |
span_put_bit_func_t | put_bit, | ||
void * | user_data | ||
) |
Change the put_aux_bit function associated with a V.34 modem context.
Change the put_aux_bit function associated with a V.34 modem context.
s | The modem context. |
put_bit | The callback routine used to process the aux data received. |
user_data | An opaque pointer. |
void v34_set_put_bit | ( | v34_state_t * | s, |
span_put_bit_func_t | put_bit, | ||
void * | user_data | ||
) |
Change the put_bit function associated with a V.34 modem context.
Change the put_bit function associated with a V.34 modem context.
s | The modem context. |
put_bit | The callback routine used to process the data received. |
user_data | An opaque pointer. |
void v34_set_qam_report_handler | ( | v34_state_t * | s, |
qam_report_handler_t | handler, | ||
void * | user_data | ||
) |
Set a handler routine to process QAM status reports
s | The modem context. |
handler | The handler routine. |
user_data | An opaque pointer passed to the handler routine. |