Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Python read output sound not input

Tags:

Any clue on what the easiest way to read the system sound level is?

I'm planning on creating an equalizer made out of short led strips and hooking them up to an Arduino or RaspberryPi. I've seen a lot of examples how to do it with the input, mic or such but not that much with the overall output. At this point I can't care about program specific or system wide, I'm happy when I actually get readings. Any advise would be welcome.

-- EDIT --

based on How get sound input from microphone in python, and process it on the fly? I changed the PCM_CAPTURE to PCM_PLAYBACK which results in python saying read is not possible on the output/playback.

I'm now attempting to create a loopback device, the idea is to pipe the playback back to a separate capture and read it then but no luck so far and I don't know how neat/clean this way is. I can't really imagine that this is the way to go.


Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!