diff --git a/docs/API_reference/en/medialib/audio.Record.md b/docs/API_reference/en/medialib/audio.Record.md index 50ae72448ba05f629602b8892b9ed2334e93f6bc..8c11f659ed2cabab17ef8c57991b79a57030e6cd 100644 --- a/docs/API_reference/en/medialib/audio.Record.md +++ b/docs/API_reference/en/medialib/audio.Record.md @@ -296,7 +296,7 @@ This method sets the callback function for the end of the recording. | 0 | Start playback | | 3 | Playback ends | -### Record.gain +### Record.gain_set ```python Record.gain(code_gain,dsp_gain) @@ -304,7 +304,7 @@ Record.gain(code_gain,dsp_gain) This method sets the recording gain. -> Currently, only the EC600N/EC800N series modules support this function. +> Currently, only the EC200N/EC600N/EC800N/EC600S/EG915N/EC600M/EC800M/EG810M/EG800P series modules support this function. **Parameter:** @@ -315,6 +315,23 @@ This method sets the recording gain. `0` - Successful execution; `-1`- Failed execution. +### Record.gain_get + +```python +Record.gain() +``` + +This method obtains the set recording gain. + +> Currently, only the EC200N/EC600N/EC800N/EC600S/EG915N/EC600M/EC800M/EG810M/EG800P series modules support this function. + +**Return Value:** + +The return value is a tuple, with the form of:`(code_gain, dsp_gain)` + +- `code_gain` - Integer type. Uplink codec gain. +- `dsp_gain` - Integer type. Uplink digital gain. + ### Record.amrEncDtx_enable ```python diff --git a/docs/API_reference/zh/medialib/audio.Record.md b/docs/API_reference/zh/medialib/audio.Record.md index dec73c139153726011d09b4d738a1b9dbd870708..3e9593f2e2591f9ab7187c76f0192baa504c00cb 100644 --- a/docs/API_reference/zh/medialib/audio.Record.md +++ b/docs/API_reference/zh/medialib/audio.Record.md @@ -252,15 +252,15 @@ def cb(audio_msg): | 0 | 录音开始 | | 3 | 录音结束 | -### `Record.gain` +### `Record.gain_set` ```python -Record.gain(code_gain,dsp_gain) +Record.gain_set(code_gain,dsp_gain) ``` 该方法用于设置录音增益。 -> 目前仅EC600N/EC800N系列模组支持该功能。 +> 目前仅EC200N/EC600N/EC800N/EC600S/EG915N/EC600M/EC800M/EG810M/EG800P系列模组支持该功能。 **参数描述:** @@ -271,6 +271,27 @@ Record.gain(code_gain,dsp_gain) `0` 表示成功,`-1`表示失败。 +### `Record.gain_get` + +```python +Record.gain() +``` + +该方法获取设置的录音增益。 + +> 目前仅EC200N/EC600N/EC800N/EC600S/EG915N/EC600M/EC800M/EG810M/EG800P系列模组支持该功能。 + +**参数描述:** + +无参数 + +**返回值描述:** + +返回值是一个元组,返回值形式为:`(code_gain, dsp_gain)` + +- `code_gain` - 上行编解码器增益。 +- `dsp_gain` - 上行数字增益。 + ### `Record.amrEncDtx_enable` ```python