Skip to content

jonhilgart22/audio-viz-pi

Repository files navigation

audio-viz-pi

Real-time audio visualization for raspberry pi

Materials

  • Purchase everything from this guide except for the DFRobot ESP32 FireBeetle chip.
  • Assemble following the adafruit guide here. One tricky thing is sodering the white wire from the rainbow cable to the 24 GPIO pin. You can see an image of this below. Also of note, we did NOT need to solder the E jumper between the 8 or 16 location. Everything worked fine without this.
  • You'll also need a usb microphone. I used this one.

pin 24

Results

  1. Audio Processing
  • You can display the frequency steptrum of audio in near real-time as shown below.

first_audio_image

  • In addition, there is an option to have the color bars change gradually over time shown below. second_audio_image
  1. Displaying Images
  • With the 64x64 matrix hooked up to the pi, you can also display images such as this image of a walk in the woods.

walk_in_woods

Install

  • All on your raspberry pi
  1. Follow the instructions here https://github.com/hzeller/rpi-rgb-led-matrix/tree/master/bindings/python

  2. Install

apt-get libasound2-dev

on your raspberry pi

  1. Install Poetry
curl -sSL https://raw.githubusercontent.com/python-poetry/poetry/master/get-poetry.py | python
  1. Install poetry dependencies
poetry install

Run

This should all be run on your raspbrerry pi

  1. Launch this program
sudo python3 -m run_audio_processing
  • This uses two threads to read in audio data pushed to a queue. Then, we read data from the queue and pass it to the visuzliation program.
  1. Alternatively, you can use this bash script
sudo ./run_audio_processing.sh
  • This passes in audio data using a named pipe from ffmeg to spectrum_matrix.py

About

Audio visualization for raspberry pi

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published