Loading...
Searching...
No Matches
Audio playback and recording
Internal API functions

Internal interfaces for the audio playback and recording code. More...

Collaboration diagram for Audio playback and recording:

## Functions

void | playrec_open (unsigned int numch)
| Initialise the playrec module.
void | playrec_close ()
| Closes the playrec module.
void | playrec_new_digit_record (int handle, char digit)
| Called by the `MMQ` when the `DSP` detects a digit event.
void | playrec_new_digit_play (int handle, char digit)
| Called by the `MMQ` when the `DSP` detects a digit event.
void | play_reset_hw_gain (int handle)
| Reset the hardware play gain to the configured default value.
void | record_reset_hw_gain (int handle)
| Reset the hardware record gain to the configured default value.

## Detailed Description

Internal interfaces for the audio playback and recording code.

## Function Documentation

## playrec_new_digit_play()

void playrec_new_digit_play | ( | int | handle,
|  | char | digit )

Called by the `MMQ` when the `DSP` detects a digit event.

Causes a playback operation on handle to be terminated if digit is listed in its `Play::term_digit` field.

References Play::list, Audio::mutex, Audio::state, Audio::term_digits, VPB_AUDIO_PLAYING, and VPB_AUDIO_TERMINATE.

## playrec_new_digit_record()

void playrec_new_digit_record | ( | int | handle,
|  | char | digit )

Called by the `MMQ` when the `DSP` detects a digit event.

Causes a record operation on handle to be terminated if digit is listed in its `Record::term_digit` field.

References Record::list, Audio::mutex, Audio::state, Audio::term_digits, VPB_AUDIO_RECORDING, and VPB_AUDIO_TERMINATE.

## playrec_open()

void playrec_open | ( | unsigned int | numch | ) |

Initialise the playrec module.

Parameters

  numch | The total number of channels to support.

This module is opened once for all ports on all boards in the system.

References VPBREG::cardinfo, VPBREG::defbal1, VPBREG::defbal2, VPBREG::defbal3, VPBREG::defPlayGain, VPBREG::defRecordGain, VPBREG::defRecordGainDown, VPBREG::defSPlayGain, VPBREG::defSRecordGain, get_board_type(), get_port_type(), Audio::hw_gain, Audio::linear_gain, Play::list, Record::list, Record::rgaindown, set_codec_reg(), Audio::sw_gain, VPBREG::useconf, Record::v4log_agcstate, vpb_c, VPB_FXS, VPB_OPCI, VPB_OSW, VPB_PRI, VPB_V4LOG, and VPB_V4PCI.