Код: Выделить всё
pi@raspberrypi:~ $ /usr/bin/arecord -D plughw:0,0 -d 10 -f S16_LE /opt/test.wav
Recording WAVE '/opt/test.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono
pi@raspberrypi:~ $ sox /opt/test.wav -n stat 2>&1 | sed -n 's#^Volume adjustment:[^0-9]*\([0-9.]*\)$#\1#p'
292.571
pi@raspberrypi:~ $ /usr/bin/arecord -D plughw:0,0 -d 10 -f S16_LE /opt/test.wav
Recording WAVE '/opt/test.wav' : Signed 16 bit Little Endian, Rate 8000 Hz, Mono
pi@raspberrypi:~ $ sox /opt/test.wav -n stat 2>&1 | sed -n 's#^Volume adjustment:[^0-9]*\([0-9.]*\)$#\1#p'
77.466
pi@raspberrypi:~ $