- audio.vol([channel,] left [, right])
- left, right = audio.vol([channel])
SYNOPSIS
DESCRIPTION
channel selects the controlled volume, use "play" to access the playback volume and "rec" to access the recording volume. The default is accessing the playback volume.
If two volume values are given, sets the volume of the left and right channels respectively. if only one value is given, both channels are set to the same value.
Value range is 0..255. Actual hardware might have a lower resolution though, so the returned values are rounded to the closes possible value.
RETURN VALUE
Returns two numbers, the active volumes of left and right channel of the digital audio device.
EXAMPLE
Note how the printed value was rounded down.
>
>
audio.vol(41)
print(audio.vol())
40 40