In general, people love music, and also the lights, that's why we thought of uniting them and getting to create this project. It is useful for ambiance, for decor lovers who include LED strips. It is a project that can be folded on several needs, being possible to place it in different shapes or places, depending on the desire of each (for example, we can create a picture frame, we can hang the LEDs in the corners or behind the TV, and ideas can go on and on).
Technology today has managed to develop extremely fast and amazing. It will always manage to bring a plus in our life and improve it. Through the idea of our project we want to bring a plus in the area of music and scenery, it is the basis of several ideas that can be implemented to create a pleasant atmosphere for those who use it.
The project works using a raspberry pi zero being the one that processes the code, retirve the information from the sensor (in our case this is the microphone) and these are transmitted to the led strip to create the play of lights.
Note:In the project is made a comparison between headphones gamer HyperX Cloud II, Mic with 18 kHz frequency and mini USB Mic with 10-16 kHz frequency. It can be observed as at a lower frequency project performance decreases( the sounds are not so well received and because of that the intensity of the LEDs is not so good)
Note: The off button writes the false text to a txt filewhen updating the microphone. That file is read once every 2 seconds if it is false, enter the branch that accesses off, and if he doesn't continue the checks until he gets to read false. After that we have to press the on button to write in that file true, so we can run the project again.
How to install and useApache installation:
Before installing the server, make sure we have an up-to-date machine. To do this we must have administrator rights, either because of the sudo command.
sudo apt update
sudo apt upgrade
sudo apt update
Once the Raspberry Pi is up to date, we will install the Apache server.
sudo apt install apache2
PHP installation:
sudo apt install php php-mbstring
To know if PHP is working properly:
- First delete the file “index.html” in the directory “/var/www/html”.
sudo rm /var/www/html/index.html
- Then create an “index.php” file in this directory, with this command line
echo "<?php phpinfo ();?>" > /var/www/html/index.php
- For the project dependencies you will need to run install.py script that was taken over from internet. These dependencies include numpy, pyaudio and rpi_ws281x library along with few others:
sudo python3 install.py
- Once the script is done running, pi will need to reboot:
sudo reboot
- The project is working by running the following command:
sudo python3 visualization.py scroll
Comments