Mình note lại các bước mình cài TC lên Volumio 2.882 dùng RopiAddon của bác
@quatmo:
Bản volumio download tại:
https://updates.volumio.org/pi/volumio/2.882/volumio-2.882-2021-04-24-pi.img.zip
SSH vào Volumio với user: volumio và pass: volumio
Lúc này mình đang ở thư mục /home/volumio
#1: Tạo thư mục TidalConnect:
#2: Dùng WinSCP copy 3 file này của bác
@quatmo vào thư mục /tmp tên volumio
- opttidal.tar.gz
https://drive.google.com/file/d/1DS9uGRZj510I6YpswqvdhwTNF-G4cuoQ/view?usp=sharing
- tidalservice.tar.gz
https://drive.google.com/file/d/1Qm723rUIFoWSYvhTG8yWI4c8BxtTPFgd/view?usp=sharing
- tidallibs.tgz
https://drive.google.com/file/d/1WgYq_mH-q4h4hqTvQYylzrnWQVQUYdMO/view?usp=sharing
#3: Copy 3 file trên từ /tmp vào /home/volumio/TidalConnect:
Mã:
sudo cp -vf /tmp/opttidal.tar.gz /home/volumio/TidalConnect
sudo cp -vf /tmp/tidalservice.tar.gz /home/volumio/TidalConnect
sudo cp -vf /tmp/tidallibs.tgz /home/volumio/TidalConnect
#4: Extract Tidal Connect:
Mã:
sudo tar -xf /home/volumio/TidalConnect/opttidal.tar.gz --overwrite -C /
sudo tar -xf /home/volumio/TidalConnect/tidalservice.tar.gz --overwrite -C /
#5: Extract Aarch64 Lib:
Mã:
sudo tar -xf /home/volumio/TidalConnect/tidallibs.tgz -C /usr/lib/
#6: Check device:
Mã:
/opt/tidal/pa_devs/bin/ifi-pa-devs-get
Kết quả của mình nó ra như vầy:
Mã:
volumio@volumio:~$ /opt/tidal/pa_devs/bin/ifi-pa-devs-get
Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924
Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924
Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.front
...................................................................
ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline
ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused
ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused
Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/pa_linux_alsa.c', line: 924
Cannot connect to server socket err = No such file or directory
Cannot connect to server request channel
jack server is not running or cannot be started
device#0=bcm2835 ALSA: IEC958/HDMI (hw:0,1)
device#1=bcm2835 ALSA: IEC958/HDMI1 (hw:0,2)
device#2=snd_rpi_hifiberry_dacplus: HiFiBerry DAC+ HiFi pcm512x-hifi-0 (hw:2,0)
device#3=dmix
Number of devices = 4
Sau khi chạy câu lệnh trên sẽ ra list device -> Copy device name, Ví dụ của mình dùng HiFiBerry DAC+ nó ra là : device#2=snd_rpi_hifiberry_dacplus: HiFiBerry DAC+ HiFi pcm512x-hifi-0 (hw:2,0)
Mình chỉ copy phần phía sau dấu "=" là :
snd_rpi_hifiberry_dacplus: HiFiBerry DAC+ HiFi pcm512x-hifi-0 (hw:2,0)
- Dùng WinCSP edit file này hay dùng câu lệnh:
Mã:
sudo nano /etc/systemd/system/tidal.service
sửa dòng --playback-device
thành: --playback-device "
snd_rpi_hifiberry_dacplus: HiFiBerry DAC+ HiFi pcm512x-hifi-0 (hw:2,0)" \
Tùy vào bác đang dùng DAC nào, thì nó xuất ra tương ứng sau khi chạy file ifi-pa-devs-get ở trên
- Và thay thế các dòng --f "Ropi Streamer" thành --f "Volumio Streamer"
#7: Start Tidal Service:
Mã:
sudo systemctl daemon-reload
sudo systemctl enable tidal.service
sudo systemctl restart tidal.service
sudo systemctl status tidal.service
Sau khi chạy các câu lệnh ở bước #7, nếu Tidal service xanh lè thì nó đã chạy thành công,
Nếu nó không chạy là do thiếu thư viện libcurl3, Tidal ko chạy được, Tiếp lục fix như sau:
#8: Kiểm tra các file thư viện cần chạy cho Tidal Connect:
Mã:
Mã:
sudo ldd /opt/tidal/bin/tidal_connect
Kết quả là:
Mã:
volumio@volumio:~$ sudo ldd /opt/tidal/bin/tidal_connect
linux-vdso.so.1 (0xbeff0000)
.............................................
libswresample.so.2 => /usr/lib/arm-linux-gnueabihf/libswresample.so.2 (0xb549c000)
libFLAC++.so.6 => not found
libFLAC.so.8 => /usr/lib/arm-linux-gnueabihf/libFLAC.so.8 (0xb545e000)
................................................
libXdmcp.so.6 => /usr/lib/arm-linux-gnueabihf/libXdmcp.so.6 (0xb3508000)
Của mình nó bào thiếu
libFLAC++.so.6 => not found
#9: Kiểm tra phiên bản Linux của Volumio 2.882 -> KQ: jessie kernel 4.19.118
Mã:
volumio@volumio:~$ hostnamectl
Static hostname: volumio
Icon name: computer
Chassis: n/a
Machine ID: 926ed696d36ff0b0341c547360843b0f
Boot ID: a066418d872a44908fb71820ad6b4235
Operating System: Raspbian GNU/Linux 8 (jessie)
Kernel: Linux 4.19.118-v7l+
Architecture: arm
#10: Cài thư viện libFLAC++.so.6
Mã:
sudo apt-get update
sudo apt-get install libflac++6
Kết quả khi chạy hai câu lệnh trên:
Mã:
volumio@volumio:~$sudo apt-get update
Get:1 http://archive.volumio.org jessie InRelease [14.9 kB]
Get:2 http://archive.volumio.org jessie InRelease [22.9 kB]
Get:3 http://archive.volumio.org jessie/main Sources [7762 kB]
Get:4 http://archive.volumio.org jessie/contrib Sources [64.5 kB]
Get:5 http://archive.volumio.org jessie/non-free Sources [113 kB]
Get:6 http://archive.volumio.org jessie/rpi Sources [1132 B]
Get:7 http://archive.volumio.org jessie/main armhf Packages [9539 kB]
Get:8 http://archive.volumio.org jessie/contrib armhf Packages [43.3 kB]
Get:9 http://archive.volumio.org jessie/non-free armhf Packages [88.1 kB]
Get:10 http://archive.volumio.org jessie/rpi armhf Packages [1356 B]
Get:11 http://archive.volumio.org jessie/main Sources [57.1 kB]
Get:12 http://archive.volumio.org jessie/ui Sources [17.4 kB]
Get:13 http://archive.volumio.org jessie/main armhf Packages [171 kB]
Get:14 http://archive.volumio.org jessie/ui armhf Packages [58.9 kB]
Ign http://archive.volumio.org jessie/contrib Translation-en
Ign http://archive.volumio.org jessie/main Translation-en
Ign http://archive.volumio.org jessie/non-free Translation-en
Ign http://archive.volumio.org jessie/rpi Translation-en
Ign http://archive.volumio.org jessie/main Translation-en
Ign http://archive.volumio.org jessie/ui Translation-en
Fetched 18.0 MB in 15s (1143 kB/s)
Reading package lists... Done
volumio@volumio:~$ sudo apt-get install libflac++6
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following NEW packages will be installed:
libflac++6
0 upgraded, 1 newly installed, 0 to remove and 27 not upgraded.
Need to get 29.5 kB of archives.
After this operation, 89.1 kB of additional disk space will be used.
Get:1 http://archive.volumio.org/raspbian/ jessie/main libflac++6 armhf 1.3.0-3 [29.5 kB]
Fetched 29.5 kB in 0s (38.3 kB/s)
debconf: delaying package configuration, since apt-utils is not installed
Selecting previously unselected package libflac++6:armhf.
(Reading database ... 25154 files and directories currently installed.)
Preparing to unpack .../libflac++6_1.3.0-3_armhf.deb ...
Unpacking libflac++6:armhf (1.3.0-3) ...
Setting up libflac++6:armhf (1.3.0-3) ...
#11: Kiểm tra lại thư viện:
Mã:
sudo ldd /opt/tidal/bin/tidal_connect
Nếu thành công sẽ ko còn dòng:
libFLAC++.so.6 => not found
volumio@volumio:~$ sudo ldd /opt/tidal/bin/tidal_connect
[sudo] password for volumio:
linux-vdso.so.1 (0xbefc3000)
................................................
libswresample.so.2 => /usr/lib/arm-linux-gnueabihf/libswresample.so.2 (0xb5551000)
libFLAC++.so.6 => /usr/lib/arm-linux-gnueabihf/libFLAC++.so.6 (0xb552c000)
libFLAC.so.8 => /usr/lib/arm-linux-gnueabihf/libFLAC.so.8 (0xb54f0000)
........................................
libXdmcp.so.6 => /usr/lib/arm-linux-gnueabihf/libXdmcp.so.6 (0xb359a000)
#12: Start lai TC bang cac cau lenh o buoc #7
Mã:
sudo systemctl daemon-reload
sudo systemctl enable tidal.service
sudo systemctl restart tidal.service
sudo systemctl status tidal.service
Và Tidal Connect đã cài thành công trên Volumio 2.882
Mã:
volumio@volumio:~$ sudo systemctl status tidal.service
● tidal.service - Tidal Connect Service
Loaded: loaded (/etc/systemd/system/tidal.service; enabled)
Active: active (running) since Fri 2021-07-09 12:08:50 UTC; 9s ago
Main PID: 10423 (tidal_connect)
CGroup: /system.slice/tidal.service
└─10423 /opt/tidal/bin/tidal_connect --tc-certificate-path /opt/tidal/id_certificate/IfiAudio_ZenStream.dat -f Volumio Streamer --codec-mpegh true --codec-mqa false --model-na...
Jul 09 12:08:50 volumio tidal_connect[10423]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.modem
Jul 09 12:08:50 volumio tidal_connect[10423]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline
Jul 09 12:08:50 volumio tidal_connect[10423]: ALSA lib pcm.c:2495:(snd_pcm_open_noupdate) Unknown PCM cards.pcm.phoneline
Jul 09 12:08:50 volumio tidal_connect[10423]: ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused
Jul 09 12:08:50 volumio tidal_connect[10423]: ALSA lib pulse.c:243:(pulse_connect) PulseAudio: Unable to connect: Connection refused
Jul 09 12:08:50 volumio tidal_connect[10423]: Expression 'alsa_snd_pcm_hw_params_set_period_size_near( pcm, hwParams, &alsaPeriodFrames, &dir )' failed in 'src/hostapi/alsa/p...', line: 924
Jul 09 12:08:50 volumio tidal_connect[10423]: Cannot connect to server socket err = No such file or directory
Jul 09 12:08:50 volumio tidal_connect[10423]: Cannot connect to server request channel
Jul 09 12:08:50 volumio tidal_connect[10423]: jack server is not running or cannot be started
Jul 09 12:08:50 volumio tidal_connect[10423]: STARTED TidalConnect services.
Hint: Some lines were ellipsized, use -l to show in full.
---------------------------------------------------------------
Chúc bác thành công.