Controlling Audio Volume

I am running balenaOS 6.9.4+rev1 and would like to change the volume from command line, but I can’t figure out how to do this. Inside my docker container if I run amixer I get an error about not being able to find simple controller ‘Master,0’ or ‘PCM,0’. What is the best way to change the volume on a balena device?

Hello, can you tell us a little more about your setup? What type of device are you using and what hardware (sound card, audio HAT, HDMI) is outputting the audio? What type of software/app is generating the audio in your container?

This is on a RPI5. It is using usb audio.
cat /proc/asound/cards shows the card as number 2.

2 [Audio ]: USB-Audio - KT USB Audio
KTMicro KT USB Audio at usb-xhci-hcd.0-2, full speed

amixer -c 2 shows

Simple mixer control 'Headphone',0
  Capabilities: pvolume pswitch pswitch-joined
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 100
  Mono:
  Front Left: Playback 10 [10%] [-45.00dB] [on]
  Front Right: Playback 10 [10%] [-45.00dB] [on]
Simple mixer control 'Mic',0
  Capabilities: cvolume cvolume-joined cswitch cswitch-joined
  Capture channels: Mono
  Limits: Capture 0 - 100
  Mono: Capture 100 [100%] [0.00dB] [on]

And finally I can control volume using
amixer -c 2 sset "Headphone" 5%+