set-volume

added in V1.3

Use the interface to adjust the gain of input signal, headphones, and microphone.

You can obtain the range of recording parameters using get-info.

"audio-range": {
    "hdmi": [],       // range of input gain
    "mic": [],        // range of microphone gain
    "phone": [],      // range of headphones gain
  }

Response Body

GET http://ip/usapi?method=set-volume&is-mic=1&mic-gain=0&is-spi=1&spi-gain=0&is-phone=1&phone-gain=0
Parameter Description
method set-volume
is-mic Indicates whether the microphone gain adjustment is enabled.
0 indicates it is mute.
1 indicates it is enabled.
mic-gain Indicates the microphone gain in dB. The default value is 0.
is-spi Indicates whether the input gain adjustment is enabled.
0 indicates it is mute.
1 indicates it is enabled.
spi-gain Indicates the input gain in dB. The default value is 0.
is-phone Indicates whether the headphone gain adjustment is enabled.
0 indicates it is mute.
1 indicates it is enabled.
phone-gain Indicates the headphone gain in dB. The default value is 0.

Response Body

{
  "result": 0
}
Item Description
result 0 indicates that the request was accepted successfully. Refer to API Status Codes to find specific description for other values.

results matching ""

    No results matching ""

    results matching ""

      No results matching ""