naztronaut / dancyPi-audio-reactive-led

Real-time WS2812b LED strip music visualization using Python and the ESP8266 or Raspberry Pi.
https://www.easyprogramming.net/raspberrypi/audio_reactive_holiday_leds.php
MIT License
240 stars 87 forks source link

New Feature: Spectrum Analyzer #39

Open Pushpit07 opened 3 years ago

Pushpit07 commented 3 years ago

I was working on a project and wanted to construct this- https://www.instructables.com/Raspberry-Pi-Spectrum-Analyzer-with-RGB-LED-Strip-/

I am using dancyPi and modified some code to achieve this but was unsuccessful. Can someone probably help in creating this ?

Pushpit07 commented 3 years ago
Screenshot 2021-03-20 at 18 16 00
naztronaut commented 3 years ago

You can most likely do this with numpy. This project uses numpy to generate the LED visualizations, Here's the code for the scroll effects: https://github.com/naztronaut/dancyPi-audio-reactive-led/blob/master/python/visualization.py#L108

If you can figure out the sequence needed for the spectrum analyzer, you should be able to do something similar. I'm still learning and getting comfortable with numpy so I'm a little bit away from being able to do this efficiently. But I got myself a 8x8 WS2812b LED Panel for this purpose.

Hope this helps guide you in the right direction. Good luck! We can keep this issue open to see if anyone else has already worked on this.