Hello!
I recently needed the transfer of sound to the audio system through the raspberry, I want to share my experience in tuning.
Step 0. PreparationWe need:
')
- Straight arms;
- Raspberry Pi (If you buy the necessary Raspberry Pi without wi-fi or bluetooth);
- 5V 2A charger to power the Raspberry Pi;
- SD card at 8GB minimum.
Step 1. Installation1. Go to the
download section on the Malinki website and download Raspbian (Not Lite)
2. Unpack the archive
3. Format SD card:
- Delete all partitions (Mac - Disk Utility, Windows - Create and Format, Linux - gparted);
- Create 1 primary partition.
4.1 Write to USB flash drive (Windows):
- Download program Win32DiskImager ;
- Open the Raspbian image in Win32DiskImager;
- Select the letter of the carrier;
- Click Write.
4.2 Write to USB flash drive (Mac / Linux):
- Download Etcher ;
- Open the image of Raspbian in Etcher;
- Choose a carrier;
- Click Flash.
5. We take out and insert the SD card into the computer and open a single partition (it should be called BOOT). Create an ssh file there.
6. Insert the SD card into the Raspberry Pi
Step 2. Configure1. Find out the IP address of our Raspberry Pi
2. Connect to it via SSH. I prefer
puty3. Login, login: pi, password: raspberry
4. Register in the console this
sudo apt-get upgrade sudo apt-get install bluez pulseaudio-module-bluetooth python-gobject python-gobject-2 bluez-tools sudo usermod -a -G lp ( - pi)
5. Registering this
sudo nano /etc/bluetooth/audio.conf
and get into a text editor. Under the caption [General] add this
Enable=Source,Sink,Media,Socket
Press Ctrl + O, Ctrl + X.
6. Further we register:
sudo nano /etc/pulse/daemon.conf
here we are looking for the string “resample-method = speex-float-3”. If not at the beginning of this line; - add it.
After that we enter
resample-method = trivial
Poke Ctrl + O Ctrl + X again
7. And again we prescribe:
sudo nano /etc/bluetooth/main.conf
Here we can change the device name to any other by editing the string "Name" if before this line there is # we remove it and edit the name we want, it should look something like this "
Name=
".
Next we look for the string "
Class
" and if it is # we remove it before it, we do it so that it is like this
Class=0x20041C
8. Autostart
1. Create an OnBluetooth file (sudo nano /etc/init.d/OnBluetooth) in /etc/init.d/. Into it
write this:
2. Write to Konosl
chmod 755 /etc/init.d/OnBluetooth
3. Write to console
update-rc.d OnBluetooth enable
9. Choose where the audio will be displayed. To do this, type
sudo raspi-config
, go to Advanced on Sound and choose which one we need. After that click finish. Done!
Step 3. ConnectingThe bluetooth connection is working right away, now it's time to set up an internet connection.
For Windows:
●
Download and unpack the archive in a convenient place.
● Edit the audio.bat file:
- Your_IP change to your raspberry ip
- UserName change to login from raspberry pi
- Password change to password from login raspberry pi
● Run
Step 4. Verification.- Turn on Raspberry PI
- We connect our audio system or headphones to the port that we selected in the raspi-config.
- Turn on bluetooth on your phone or open a file on your computer
- Turn on the music
- Rejoice
Conclusion
I hope that at least someone this article was useful. Thanks for attention.