HI_ACODEC_GET_DACL_VOLUME

Applicability

Product

Supported

Atlas A3 training products/Atlas A3 inference products

Atlas A2 training products/Atlas A2 inference products

Atlas 200I/500 A2 inference products

Atlas inference products

Atlas training products

Description

Obtains the output volume of the audio-left channel.

Prototype

int ioctl(int fd, HI_ACODEC_GET_DACL_VOLUME, hi_acodec_volume_ctrl *arg)

Parameters

Parameter

Input/Output

Description

fd

Input

File descriptor of the audio codec.

HI_ACODEC_GET_DACL_VOLUME

Input

ioctl number.

arg

Output

Volume control parameter of the embedded audio codec.

Returns

  • 0: success
  • Other values: failure

Restrictions

  • Output volume range of the audio-left channel: [0, 127]. A larger value indicates lower volume. The value 0 indicates the maximum volume (6 dB), and the value 127 indicates the minimum volume (muted).
  • For example, if the volume_ctrl variable in the hi_acodec_volume_ctrl structure is set to x, the volume is adjusted to (6 – x) dB.