Raspberry Pi + Rune Audio ::: Một trải nghiệm nghe nhạc mới

tml3nr

Moderator
Mình chỉ chạy được sau khi reboot lại.
Nếu mà play nhạc từ NAS thì sau đó stop, play Tidal Connect từ phone qua smpd thì tịt không phát được, dù ifi-streamer-tidal-connect.service vẫn active xanh lè. (thử sudo systemctl stop pipe, rồi restart ifi-streamer-tidal-connect.service mà vẫn tịt)
Muốn xài TC chỉ có cách reboot lại Pi.
Chờ bác sửa các lỗi này.
Anh xem mấy bài này ạ:

http://www.hdvietnam.org/posts/10523818/

http://www.hdvietnam.org/posts/10525955/
 

linh0983

Well-Known Member
Bác @Thanhvo31 mình cài aprenderer vào (Pi3+ FE Arch linux AoE) ko có âm thanh bác ơi ? :rolleyes:


VBgytnu.jpg


cd /usr
wget http://albumplayer.ru/linux/aprenderer-arm64.tar.gz
tar -zxvf aprenderer-arm64.tar.gz
cd aprenderer
cp aprenderer.service /etc/systemd/system/
systemctl start aprenderer
systemctl enable aprenderer

Thiếu gì a ? :D
 

rndce

Well-Known Member
Hôm đó em múa may quay cuồng kinh dị lắm nên khi nó chạy được em cũng hơi mơ màng. Phải làm lại vài lần nữa mới viết ra được tút chính xác anh ạ.

Cơ bản em làm theo trình tự sau:

- Disable hết tất cả các service liên quan đến audio của 0.9.6. Chỉ chừa lại OS trơn.

- Setup thủ công từng packet lần lượt theo 2 cách của 2 dev:

https://github.com/shawaj

https://github.com/seniorgod

- Trong khi setup từng package, thay đổi source list cho phù hợp.

- Nếu package nào bị lỗi, fix cho xong rồi mới đi típ.

- Sau khi xào qua xào lại hai cách của 2 ông này. Em thấy TC chạy được với git của shawaj (Có thể package 2 bên khác nhau, em chưa xem kỹ vì không có thời gian).

Sau khi Tidal chạy được. Em trả dần về các settings optimize của bản gốc (Hiện em đang làm tới đoạn này).

Hiện tại em thấy TC xuất ra alsa, không liên quan đến aplay-rt. aplay-rt chỉ đơn thuần là một app đẩy nhạc cho mpd.
Theo hướng dẫn của bác @tml3nr , mình Note lại các bước mình đã cài Tidal Connect lên Smpd 0.96:
(Các bước này mình theo file install.sh của shawaj: https://github.com/shawaj/HiTide/blob/main/install.sh)
B1: # add stretch repo to sources list
Mã:
# add stretch repo to sources list
echo "deb http://archive.raspbian.org/raspbian stretch main" >> /etc/apt/sources.list
B2: # update package list and install dependencies
Mã:
sudo apt update
sudo apt install -y multiarch-support libavformat57 git libportaudio2* libflac++6v5* libavahi-common3 libavahi-client3 alsa-utils
Ở bước này có thể làm theo cách của bác @tml3nr :
- Setup thủ công từng packet lần lượt
- Nếu package nào bị lỗi, fix cho xong rồi mới đi típ
Mã:
sudo apt install -y multiarch-support
sudo apt install -y libavformat57
sudo apt install -y git
sudo apt install -y libportaudio2*
sudo apt install -y libflac++6v5*
sudo apt install -y libavahi-common3
sudo apt install -y libavahi-client3
sudo apt install -y alsa-utils
Ví dụ như lúc mình cài libflac++6v5*
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
thi nó báo thiếu libflac8 như dưới
Mã:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libflac++6v5' for glob 'libflac++6v5*'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
libflac++6v5 : Depends: libflac8 (>= 1.3.0) but it is not going to be installed
Mình cài libflac8 :
Mã:
sudo apt-get install libflac8
Xong rồi cài lại libflac++6v5*, thì ok.
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
B3: # create working folder
Mã:
sudo mkdir /usr/ifi
cd /usr/ifi
B4: # download and install other needed dependencies
Mã:
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo apt install -y ./libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/c/curl/libcurl3_7.38.0-4+deb8u16_armhf.deb
sudo apt install -y ./libcurl3_7.38.0-4+deb8u16_armhf.deb
B5: # clone git repo
Mã:
sudo git clone https://github.com/shawaj/ifi-tidal-release
B6: # correct permissions
Mã:
sudo chmod +x /usr/ifi/ifi-tidal-release/play
sudo chmod +x /usr/ifi/ifi-tidal-release/bin/tidal_connect_application
sudo chmod +x /usr/ifi/ifi-tidal-release/pa_devs/run.sh
B7: #change output device here
Chạy lệnh:
Mã:
aplay -l
, để kiểm tra Output dive, của mình nó ra
Mã:
card 0: BossDAC [BossDAC], device 0: Boss DAC HiFi [Master] pcm512x-hifi-0 [ ]
Nên mình sẽ sửa nội dung trong file devices như sau
Mã:
sudo nano /usr/ifi/ifi-tidal-release/pa_devs/devices
paste doan nay vao, luu lai
Mã:
device#0=BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)
#device#0=rockchip-spdif: - (hw:0,0)
#device#1=iFi Pro iDSD: USB Audio (hw:1,0)
#device#2=sysdefault
#device#3=default
#device#4=dmix
Number of devices = 1
B8: Sua file ifi-streamer-tidal-connect.service
Mã:
sudo nano /usr/ifi/ifi-tidal-release/ifi-streamer-tidal-connect.service
Chèn thêm "--playback-device ........" dưới "--enable-mqa-passthrough false \" như sau:
Mã:
--playback-device "BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)" \
Như file service của mình sau khi chèn nó sẽ như sau:
Mã:
[Unit]
Description=RasPi Streamer Tidal Connect Service
[Service]
Restart=on-failure
ExecStart=/usr/ifi/ifi-tidal-release/bin/tidal_connect_application \
                --tc-certificate-path "/usr/ifi/ifi-tidal-release/id_certificate/IfiAudio_ZenStream.dat" \
                -f "HiTide RasPi Streamer" \
                --codec-mpegh true \
                --codec-mqa false \
                --model-name "HiTide RasPi Streamer" \
                --disable-app-security false \
                --disable-web-security false \
                --enable-mqa-passthrough false \
                --playback-device "BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)" \
                --log-level 3 \
                --enable-websocket-log "0"

User=root
Group=root
RestartSec=1
KillMode=control-group
[Install]
WantedBy=multi-user.target
Lưu ý, nội dung của --play-back device trong file service phải trùng với nội dung sau "device#0=" trong file devices (/usr/ifi/ifi-tidal-release/pa_devs/devices)
B9: # deploy files
Mã:
# deploy files
sudo ./ifi-tidal-release/file-deploy.sh
B10: # start service and check on status
Mã:
sudo systemctl daemon-reload
sudo systemctl enable ifi-streamer-tidal-connect.service
sudo systemctl start ifi-streamer-tidal-connect.service
sudo systemctl status ifi-streamer-tidal-connect.service
Nếu ifi-streamer-tidal-connect.service active xanh lè thì tận hường Tidal Connect trước đã,
Phần alsa release khi sau khi play nhạc từ app Tidal tren điện thoại để nghe nhạc offline trên NAS, nhờ bác Hải @tml3nr hướng dẫn thêm.
Ngoài ra nếu muốn thay đổi oupt device thì quay lại từ B7, sau đó thì chạy lại mấy lệnh sau:
Mã:
#after changing  output device again
sudo systemctl daemon-reload
sudo systemctl restart ifi-streamer-tidal-connect.service
 
Chỉnh sửa lần cuối:

pana800

Active Member
Theo hướng dẫn của bác @tml3nr , mình Note lại các bước mình đã cài Tidal Connect lên Smpd 0.96:
(Các bước này mình theo file install.sh của shawaj: https://github.com/shawaj/HiTide/blob/main/install.sh)
B1: # add stretch repo to sources list
Mã:
# add stretch repo to sources list
echo "deb http://archive.raspbian.org/raspbian stretch main" >> /etc/apt/sources.list
B2:# update package list and install dependencies
Mã:
sudo apt update
sudo apt install -y multiarch-support libavformat57 git libportaudio2* libflac++6v5* libavahi-common3 libavahi-client3 alsa-utils
Cho mình xin link bản smpd với.
 

Thanhvo31

Well-Known Member
Bác @Thanhvo31 mình cài aprenderer vào (Pi3+ FE Arch linux AoE) ko có âm thanh bác ơi ? :rolleyes:


VBgytnu.jpg


cd /usr
wget http://albumplayer.ru/linux/aprenderer-arm64.tar.gz
tar -zxvf aprenderer-arm64.tar.gz
cd aprenderer
cp aprenderer.service /etc/systemd/system/
systemctl start aprenderer
systemctl enable aprenderer

Thiếu gì a ? :D

Kiểm tra:
systemctl status aprenderer, nếu chưa, phải cài lại từ đầu.
Nếu rồi, vào ip:7779
Xem đã chọn được card chưa? Nếu chưa, xóa file /etc/asound.conf đi.
Nếu rồi, vào tab gerenal chọn ALSA Period = 255, ALSA Buffer =50000.
 

linh0983

Well-Known Member
Theo hướng dẫn của bác @tml3nr , mình Note lại các bước mình đã cài Tidal Connect lên Smpd 0.96:
(Các bước này mình theo file install.sh của shawaj: https://github.com/shawaj/HiTide/blob/main/install.sh)
B1: # add stretch repo to sources list
Mã:
# add stretch repo to sources list
echo "deb http://archive.raspbian.org/raspbian stretch main" >> /etc/apt/sources.list
B2: # update package list and install dependencies
Mã:
sudo apt update
sudo apt install -y multiarch-support libavformat57 git libportaudio2* libflac++6v5* libavahi-common3 libavahi-client3 alsa-utils
Ở bước này có thể làm theo cách của bác @tml3nr :
- Setup thủ công từng packet lần lượt
- Nếu package nào bị lỗi, fix cho xong rồi mới đi típ
Mã:
sudo apt install -y multiarch-support
sudo apt install -y libavformat57
sudo apt install -y git
sudo apt install -y libportaudio2*
sudo apt install -y libflac++6v5*
sudo apt install -y libavahi-common3
sudo apt install -y libavahi-client3
sudo apt install -y alsa-utils
Ví dụ như lúc mình cài libflac++6v5*
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
thi nó báo thiếu libflac8 như dưới
Mã:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libflac++6v5' for glob 'libflac++6v5*'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
libflac++6v5 : Depends: libflac8 (>= 1.3.0) but it is not going to be installed
Mình cài libflac8 :
Mã:
sudo apt-get install libflac8
Xong rồi cài lại libflac++6v5*, thì ok.
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
B3: # create working folder
Mã:
sudo mkdir /usr/ifi
cd /usr/ifi
B4: # download and install other needed dependencies
Mã:
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo apt install -y ./libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/c/curl/libcurl3_7.38.0-4+deb8u16_armhf.deb
sudo apt install -y ./libcurl3_7.38.0-4+deb8u16_armhf.deb
B5: # clone git repo
Mã:
sudo git clone https://github.com/shawaj/ifi-tidal-release
B6: # correct permissions
Mã:
sudo chmod +x /usr/ifi/ifi-tidal-release/play
sudo chmod +x /usr/ifi/ifi-tidal-release/bin/tidal_connect_application
sudo chmod +x /usr/ifi/ifi-tidal-release/pa_devs/run.sh
B7: #change output device here
Chạy lệnh:
Mã:
aplay -l
, để kiểm tra Output dive, của mình nó ra
Mã:
card 0: BossDAC [BossDAC], device 0: Boss DAC HiFi [Master] pcm512x-hifi-0 [Boss DAC HiFi [ ]
Nên mình sẽ sửa nội dung trong file devices như sau
Mã:
sudo nano /usr/ifi/ifi-tidal-release/pa_devs/devices
paste doan nay vao, luu lai
Mã:
device#0=BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)
#device#0=rockchip-spdif: - (hw:0,0)
#device#1=iFi Pro iDSD: USB Audio (hw:1,0)
#device#2=sysdefault
#device#3=default
#device#4=dmix
Number of devices = 1
Vì nó cùng 1 source so sánh với Moode thiếu cái gì dò ra rất nhanh a . :oops:

Mã:
systemctl daemon-reload
systemctl start ifi-streamer-tidal-connect.service
systemctl status ifi-streamer-tidal-connect.service
systemctl enable ifi-streamer-tidal-connect.service




login as: pi
[email protected]'s password:
RaspiOS 10.6 | 5.4.77-v7l+ #1371 | armv7l (32-bit)

                      ____     __        ____
          __ _  ___  / __ \___/ /__     /_  /
         /  ' \/ _ \/ /_/ / _  / -_)     / /
        /_/_/_/\___/\____/\_,_/\__/     /_/

                 moOde audio player
              Release 7.1.0 2021-03-15
                (C) 2014 Tim Curtis


The programs included with moOde are free software; the
exact distribution terms for each program are described
in the individual files in /usr/share/doc/*/copyright.
Moode comes with absolutely no warranties expressed or
implied, or any other guarantees.

pi@moode:~ $ curl -sSL https://raw.githubusercontent.com/shawaj/HiTide/main/install.sh | sudo bash
Get:1 http://archive.raspberrypi.org/debian buster InRelease [32.9 kB]
Get:2 http://raspbian.raspberrypi.org/raspbian buster InRelease [15.0 kB]
Get:3 http://archive.raspbian.org/raspbian stretch InRelease [15.0 kB]
Get:4 http://archive.raspberrypi.org/debian buster/main armhf Packages [372 kB]
Get:5 http://raspbian.raspberrypi.org/raspbian buster/main armhf Packages [13.0 MB]
Get:6 http://archive.raspbian.org/raspbian stretch/main armhf Packages [11.7 MB]
Get:7 http://raspbian.raspberrypi.org/raspbian buster/non-free armhf Packages [104 kB]
Fetched 25.2 MB in 34s (732 kB/s)
Reading package lists... Done
Building dependency tree
Reading state information... Done
112 packages can be upgraded. Run 'apt list --upgradable' to see them.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libportaudio2' for glob 'libportaudio2*'
Note, selecting 'libflac++6v5' for glob 'libflac++6v5*'
git is already the newest version (1:2.20.1-2+deb10u3).
libavahi-client3 is already the newest version (0.7-4+b1).
libavahi-client3 set to manually installed.
libavahi-common3 is already the newest version (0.7-4+b1).
libavahi-common3 set to manually installed.
libportaudio2 is already the newest version (19.6.0-1).
libportaudio2 set to manually installed.
multiarch-support is already the newest version (2.28-10+rpi1).
The following additional packages will be installed:
  libavcodec57 libavutil55 libbluray1 libswresample2 libva-drm1 libva-x11-1 libva1 libvpx4 libwebpmux2 libx264-148 libx265-95
Suggested packages:
  libbluray-bdj
The following NEW packages will be installed:
  libavcodec57 libavformat57 libavutil55 libbluray1 libflac++6v5 libswresample2 libva-drm1 libva-x11-1 libva1 libvpx4 libwebpmux2 libx264-148 libx265-95
The following packages will be upgraded:
  alsa-utils
1 upgraded, 13 newly installed, 0 to remove and 111 not upgraded.
Need to get 8,391 kB of archives.
After this operation, 21.7 MB of additional disk space will be used.
Get:1 http://archive.raspberrypi.org/debian buster/main armhf alsa-utils armhf 1.1.8-2+rpt1 [1,010 kB]
Get:3 http://archive.raspbian.org/raspbian stretch/main armhf libva1 armhf 1.7.3-2 [46.2 kB]
Get:4 http://archive.raspbian.org/raspbian stretch/main armhf libva-drm1 armhf 1.7.3-2 [14.5 kB]
Get:5 http://archive.raspbian.org/raspbian stretch/main armhf libva-x11-1 armhf 1.7.3-2 [18.0 kB]
Get:6 http://archive.raspbian.org/raspbian stretch/main armhf libavutil55 armhf 7:3.2.15-0+deb9u2 [246 kB]
Get:7 http://archive.raspbian.org/raspbian stretch/main armhf libswresample2 armhf 7:3.2.15-0+deb9u2 [102 kB]
Get:8 http://archive.raspbian.org/raspbian stretch/main armhf libvpx4 armhf 1.6.1-3+deb9u2 [432 kB]
Get:9 http://archive.raspbian.org/raspbian stretch/main armhf libwebpmux2 armhf 0.5.2-1 [80.1 kB]
Get:10 http://archive.raspbian.org/raspbian stretch/main armhf libx264-148 armhf 2:0.148.2748+git97eaef2-1+rpi1 [786 kB]
Get:11 http://archive.raspbian.org/raspbian stretch/main armhf libx265-95 armhf 2.1-2 [447 kB]
Get:12 http://archive.raspbian.org/raspbian stretch/main armhf libavcodec57 armhf 7:3.2.15-0+deb9u2 [4,170 kB]
Get:13 http://archive.raspbian.org/raspbian stretch/main armhf libbluray1 armhf 1:0.9.3-3 [122 kB]
Get:14 http://archive.raspbian.org/raspbian stretch/main armhf libavformat57 armhf 7:3.2.15-0+deb9u2 [882 kB]
Get:2 https://mirror.freedif.org/Raspbian/raspbian buster/main armhf libflac++6v5 armhf 1.3.2-3 [34.7 kB]
Fetched 8,391 kB in 9s (954 kB/s)
apt-listchanges: Reading changelogs...
(Reading database ... 68244 files and directories currently installed.)
Preparing to unpack .../00-alsa-utils_1.1.8-2+rpt1_armhf.deb ...
Unpacking alsa-utils (1.1.8-2+rpt1) over (1.1.8-2) ...
Selecting previously unselected package libva1:armhf.
Preparing to unpack .../01-libva1_1.7.3-2_armhf.deb ...
Unpacking libva1:armhf (1.7.3-2) ...
Selecting previously unselected package libva-drm1:armhf.
Preparing to unpack .../02-libva-drm1_1.7.3-2_armhf.deb ...
Unpacking libva-drm1:armhf (1.7.3-2) ...
Selecting previously unselected package libva-x11-1:armhf.
Preparing to unpack .../03-libva-x11-1_1.7.3-2_armhf.deb ...
Unpacking libva-x11-1:armhf (1.7.3-2) ...
Selecting previously unselected package libavutil55:armhf.
Preparing to unpack .../04-libavutil55_7%3a3.2.15-0+deb9u2_armhf.deb ...
Unpacking libavutil55:armhf (7:3.2.15-0+deb9u2) ...
Selecting previously unselected package libswresample2:armhf.
Preparing to unpack .../05-libswresample2_7%3a3.2.15-0+deb9u2_armhf.deb ...
Unpacking libswresample2:armhf (7:3.2.15-0+deb9u2) ...
Selecting previously unselected package libvpx4:armhf.
Preparing to unpack .../06-libvpx4_1.6.1-3+deb9u2_armhf.deb ...
Unpacking libvpx4:armhf (1.6.1-3+deb9u2) ...
Selecting previously unselected package libwebpmux2:armhf.
Preparing to unpack .../07-libwebpmux2_0.5.2-1_armhf.deb ...
Unpacking libwebpmux2:armhf (0.5.2-1) ...
Selecting previously unselected package libx264-148:armhf.
Preparing to unpack .../08-libx264-148_2%3a0.148.2748+git97eaef2-1+rpi1_armhf.deb ...
Unpacking libx264-148:armhf (2:0.148.2748+git97eaef2-1+rpi1) ...
Selecting previously unselected package libx265-95:armhf.
Preparing to unpack .../09-libx265-95_2.1-2_armhf.deb ...
Unpacking libx265-95:armhf (2.1-2) ...
Selecting previously unselected package libavcodec57:armhf.
Preparing to unpack .../10-libavcodec57_7%3a3.2.15-0+deb9u2_armhf.deb ...
Unpacking libavcodec57:armhf (7:3.2.15-0+deb9u2) ...
Selecting previously unselected package libbluray1:armhf.
Preparing to unpack .../11-libbluray1_1%3a0.9.3-3_armhf.deb ...
Unpacking libbluray1:armhf (1:0.9.3-3) ...
Selecting previously unselected package libavformat57:armhf.
Preparing to unpack .../12-libavformat57_7%3a3.2.15-0+deb9u2_armhf.deb ...
Unpacking libavformat57:armhf (7:3.2.15-0+deb9u2) ...
Selecting previously unselected package libflac++6v5:armhf.
Preparing to unpack .../13-libflac++6v5_1.3.2-3_armhf.deb ...
Unpacking libflac++6v5:armhf (1.3.2-3) ...
Setting up libva1:armhf (1.7.3-2) ...
Setting up libx264-148:armhf (2:0.148.2748+git97eaef2-1+rpi1) ...
Setting up libx265-95:armhf (2.1-2) ...
Setting up alsa-utils (1.1.8-2+rpt1) ...
Setting up libva-drm1:armhf (1.7.3-2) ...
Setting up libva-x11-1:armhf (1.7.3-2) ...
Setting up libwebpmux2:armhf (0.5.2-1) ...
Setting up libvpx4:armhf (1.6.1-3+deb9u2) ...
Setting up libflac++6v5:armhf (1.3.2-3) ...
Setting up libbluray1:armhf (1:0.9.3-3) ...
Setting up libavutil55:armhf (7:3.2.15-0+deb9u2) ...
Setting up libswresample2:armhf (7:3.2.15-0+deb9u2) ...
Setting up libavcodec57:armhf (7:3.2.15-0+deb9u2) ...
Setting up libavformat57:armhf (7:3.2.15-0+deb9u2) ...
Processing triggers for systemd (241-7~deb10u4+rpi1) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for libc-bin (2.28-10+rpi1) ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  850k  100  850k    0     0  3004k      0 --:--:-- --:--:-- --:--:-- 2994k
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libssl1.0.0' instead of './libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb'
The following NEW packages will be installed:
  libssl1.0.0
0 upgraded, 1 newly installed, 0 to remove and 111 not upgraded.
Need to get 0 B/871 kB of archives.
After this operation, 1,910 kB of additional disk space will be used.
Get:1 /usr/ifi/libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb libssl1.0.0 armhf 1.0.1t-1+deb8u12 [871 kB]
Preconfiguring packages ...
Selecting previously unselected package libssl1.0.0:armhf.
(Reading database ... 68327 files and directories currently installed.)
Preparing to unpack .../libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb ...
Unpacking libssl1.0.0:armhf (1.0.1t-1+deb8u12) ...
Setting up libssl1.0.0:armhf (1.0.1t-1+deb8u12) ...
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
100  231k  100  231k    0     0  1153k      0 --:--:-- --:--:-- --:--:-- 1153k
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libcurl3' instead of './libcurl3_7.38.0-4+deb8u16_armhf.deb'
The following packages were automatically installed and are no longer required:
  cmake-data librhash0 libuv1
Use 'sudo apt autoremove' to remove them.
The following additional packages will be installed:
  cmake-data
The following packages will be REMOVED:
  cmake curl libcurl4 rpi-update
The following NEW packages will be installed:
  libcurl3
The following packages will be upgraded:
  cmake-data
1 upgraded, 1 newly installed, 4 to remove and 109 not upgraded.
Need to get 1,628 kB/1,866 kB of archives.
After this operation, 13.1 MB disk space will be freed.
Get:1 /usr/ifi/libcurl3_7.38.0-4+deb8u16_armhf.deb libcurl3 armhf 7.38.0-4+deb8u16 [237 kB]
Get:2 http://archive.raspberrypi.org/debian buster/main armhf cmake-data all 3.16.3-3~bpo10+1 [1,628 kB]
Fetched 1,628 kB in 2s (715 kB/s)
apt-listchanges: Reading changelogs...
(Reading database ... 68347 files and directories currently installed.)
Removing cmake (3.13.4-1) ...
Removing rpi-update (20200409) ...
Removing curl (7.64.0-4+deb10u1) ...
Removing libcurl4:armhf (7.64.0-4+deb10u1) ...
Selecting previously unselected package libcurl3:armhf.
(Reading database ... 68314 files and directories currently installed.)
Preparing to unpack .../libcurl3_7.38.0-4+deb8u16_armhf.deb ...
Unpacking libcurl3:armhf (7.38.0-4+deb8u16) ...
Preparing to unpack .../cmake-data_3.16.3-3~bpo10+1_all.deb ...
Unpacking cmake-data (3.16.3-3~bpo10+1) over (3.13.4-1) ...
Setting up libcurl3:armhf (7.38.0-4+deb8u16) ...
Setting up cmake-data (3.16.3-3~bpo10+1) ...
Processing triggers for man-db (2.8.5-2) ...
Processing triggers for libc-bin (2.28-10+rpi1) ...
Cloning into 'ifi-tidal-release'...
remote: Enumerating objects: 64, done.
remote: Counting objects: 100% (64/64), done.
remote: Compressing objects: 100% (53/53), done.
remote: Total 64 (delta 15), reused 38 (delta 1), pack-reused 0
Unpacking objects: 100% (64/64), done.
? ifi-streamer-tidal-connect.service - RasPi Streamer Tidal Connect Service
   Loaded: loaded (/lib/systemd/system/ifi-streamer-tidal-connect.service; disabled; vendor preset: enabled)
   Active: active (running) since Thu 2021-03-18 21:52:27 EDT; 38ms ago
Main PID: 2210 (tidal_connect_a)
    Tasks: 1 (limit: 4323)
   CGroup: /system.slice/ifi-streamer-tidal-connect.service
           +-2210 /usr/ifi/ifi-tidal-release/bin/tidal_connect_application --tc-certificate-path /usr/ifi/ifi-tidal-release/id_certificate/IfiAudio_ZenStrea

Mar 18 21:52:27 moode systemd[1]: Started RasPi Streamer Tidal Connect Service.
lines 1-9/9 (END)
 

nqn_vnn

Well-Known Member
Em có con Jetson Nano 4G Ram ... dùng cài app gì nghe nhạc thay pi các Bác nhỉ? Thay pi3 có hiệu quả ko ạ?
 

linh0983

Well-Known Member
Kiểm tra:
systemctl status aprenderer, nếu chưa, phải cài lại từ đầu.
Nếu rồi, vào ip:7779
Xem đã chọn được card chưa? Nếu chưa, xóa file /etc/asound.conf đi.
Nếu rồi, vào tab gerenal chọn ALSA Period = 255, ALSA Buffer =50000.
Ok bác a . Đã thấy card ảo . . . :confused:

TARGET [dc:a6:32:f6:5b:2c]

AoE STATUS : CONNECTED
AoE SESSION: 36559
AoE VSOUND : OPEN(0) (timeout:0 eof:0 intr:0)
PCM PARAM : S16_LE 44100 2 chunk_bytes:588 period_us:3333
AoE STATS : aoe.dreq=64 aoe.recv=64 (count:1564901 timeout:21 recover:20)

period (us) : 3333
receive packets : 1629878 (AoE 1593044, Others 36834)
poll total : 71550
poll avg. (ms) : 184 (min 106, max 213, expected 213)
poll/chunk x1000: 44 (aoe.recv=64)
dreq/chunk x1000: 16 (aoe.dreq=64)
trip/chunk (us) : 127
act /chunk (ns) : 919

5be9510f4f6d89a90f10367e988ec939.jpg
 
Chỉnh sửa lần cuối:

pana800

Active Member
Mình gửi bác bản SMPD 0.96 của bác @quatmo đã có Upmpdcli (có thể cài thêm Bubble Upnp Server lên tạo Open Home stream Tidal qua smpd này), mình cài thêm Tidal Connect trên bản này:
https://drive.google.com/file/d/1oc_OCwYg6aRmPfSCU_u0poWRCc_Rl8AW/view?usp=sharing
Cám ơn bạn,
Mình ghi ra card loay hoay mãi không boot trên pi3, cuối cùng đổi file dt-blob.bin nó mới boot. :)
Chắc chờ bản của @@tml3nr luôn vì mình đang xài chính trên Pi2 và Pi4.
 
Chỉnh sửa lần cuối:

quatmo

Well-Known Member
Như bác @quatmo nói, chung client_id, không bị văng mới là lạ :p:D
Theo mình biết TC client_id nó có khác một chút, nó là ID mà TD cấp cho các đối tác, những đơn vị làm phần mềm/phần cứng dùng TD.

Còn user đăng nhập thì TD gửi về Token riêng. Nghĩa là một TC client_id có thể dùng chung cho rất nhiều sản phẩm/User. Ví dụ TC client_id của ifaudio này, trừ khi họ cập nhật lại phần mềm/thay đổi client_id trong đó (nói TD xóa bỏ) mình mới không dùng tiếp được. Tuy nhiên vẫn có thể đi "sưu tầm" client_id khác gắn vào.

Biết điều này là do làm cái Plugin Tidal Volumio. Gắn client_id thì TD trả về file FLAC.

PS: Mình xài TC Volumio không thấy bị văng (sau vài ngày sử dụng trên 2.8 và 3.014).
 

quatmo

Well-Known Member
Theo hướng dẫn của bác @tml3nr , mình Note lại các bước mình đã cài Tidal Connect lên Smpd 0.96:
(Các bước này mình theo file install.sh của shawaj: https://github.com/shawaj/HiTide/blob/main/install.sh)
B1: # add stretch repo to sources list
Mã:
# add stretch repo to sources list
echo "deb http://archive.raspbian.org/raspbian stretch main" >> /etc/apt/sources.list
B2: # update package list and install dependencies
Mã:
sudo apt update
sudo apt install -y multiarch-support libavformat57 git libportaudio2* libflac++6v5* libavahi-common3 libavahi-client3 alsa-utils
Ở bước này có thể làm theo cách của bác @tml3nr :
- Setup thủ công từng packet lần lượt
- Nếu package nào bị lỗi, fix cho xong rồi mới đi típ
Mã:
sudo apt install -y multiarch-support
sudo apt install -y libavformat57
sudo apt install -y git
sudo apt install -y libportaudio2*
sudo apt install -y libflac++6v5*
sudo apt install -y libavahi-common3
sudo apt install -y libavahi-client3
sudo apt install -y alsa-utils
Ví dụ như lúc mình cài libflac++6v5*
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
thi nó báo thiếu libflac8 như dưới
Mã:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libflac++6v5' for glob 'libflac++6v5*'
Some packages could not be installed. This may mean that you have
requested an impossible situation or if you are using the unstable
distribution that some required packages have not yet been created
or been moved out of Incoming.
The following information may help to resolve the situation:

The following packages have unmet dependencies:
libflac++6v5 : Depends: libflac8 (>= 1.3.0) but it is not going to be installed
Mình cài libflac8 :
Mã:
sudo apt-get install libflac8
Xong rồi cài lại libflac++6v5*, thì ok.
Mã:
pi@smpd:~ $ sudo apt-get install libflac++6v5*
B3: # create working folder
Mã:
sudo mkdir /usr/ifi
cd /usr/ifi
B4: # download and install other needed dependencies
Mã:
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/o/openssl/libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo apt install -y ./libssl1.0.0_1.0.1t-1+deb8u12_armhf.deb
sudo curl -k -O -L http://security.debian.org/debian-security/pool/updates/main/c/curl/libcurl3_7.38.0-4+deb8u16_armhf.deb
sudo apt install -y ./libcurl3_7.38.0-4+deb8u16_armhf.deb
B5: # clone git repo
Mã:
sudo git clone https://github.com/shawaj/ifi-tidal-release
B6: # correct permissions
Mã:
sudo chmod +x /usr/ifi/ifi-tidal-release/play
sudo chmod +x /usr/ifi/ifi-tidal-release/bin/tidal_connect_application
sudo chmod +x /usr/ifi/ifi-tidal-release/pa_devs/run.sh
B7: #change output device here
Chạy lệnh:
Mã:
aplay -l
, để kiểm tra Output dive, của mình nó ra
Mã:
card 0: BossDAC [BossDAC], device 0: Boss DAC HiFi [Master] pcm512x-hifi-0 [ ]
Nên mình sẽ sửa nội dung trong file devices như sau
Mã:
sudo nano /usr/ifi/ifi-tidal-release/pa_devs/devices
paste doan nay vao, luu lai
Mã:
device#0=BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)
#device#0=rockchip-spdif: - (hw:0,0)
#device#1=iFi Pro iDSD: USB Audio (hw:1,0)
#device#2=sysdefault
#device#3=default
#device#4=dmix
Number of devices = 1
B8: Sua file ifi-streamer-tidal-connect.service
Mã:
sudo nano /usr/ifi/ifi-tidal-release/ifi-streamer-tidal-connect.service
Chèn thêm "--playback-device ........" dưới "--enable-mqa-passthrough false \" như sau:
Mã:
--playback-device "BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)" \
Như file service của mình sau khi chèn nó sẽ như sau:
Mã:
[Unit]
Description=RasPi Streamer Tidal Connect Service
[Service]
Restart=on-failure
ExecStart=/usr/ifi/ifi-tidal-release/bin/tidal_connect_application \
                --tc-certificate-path "/usr/ifi/ifi-tidal-release/id_certificate/IfiAudio_ZenStream.dat" \
                -f "HiTide RasPi Streamer" \
                --codec-mpegh true \
                --codec-mqa false \
                --model-name "HiTide RasPi Streamer" \
                --disable-app-security false \
                --disable-web-security false \
                --enable-mqa-passthrough false \
                --playback-device "BossDAC: Boss DAC HiFi [Master] pcm512x-hifi-0 (hw:0,0)" \
                --log-level 3 \
                --enable-websocket-log "0"

User=root
Group=root
RestartSec=1
KillMode=control-group
[Install]
WantedBy=multi-user.target
Lưu ý, nội dung của --play-back device trong file service phải trùng với nội dung sau "device#0=" trong file devices (/usr/ifi/ifi-tidal-release/pa_devs/devices)
B9: # deploy files
Mã:
# deploy files
sudo ./ifi-tidal-release/file-deploy.sh
B10: # start service and check on status
Mã:
sudo systemctl daemon-reload
sudo systemctl enable ifi-streamer-tidal-connect.service
sudo systemctl start ifi-streamer-tidal-connect.service
sudo systemctl status ifi-streamer-tidal-connect.service
Nếu ifi-streamer-tidal-connect.service active xanh lè thì tận hường Tidal Connect trước đã,
Phần alsa release khi sau khi play nhạc từ app Tidal tren điện thoại để nghe nhạc offline trên NAS, nhờ bác Hải @tml3nr hướng dẫn thêm.
Ngoài ra nếu muốn thay đổi oupt device thì quay lại từ B7, sau đó thì chạy lại mấy lệnh sau:
Mã:
#after changing  output device again
sudo systemctl daemon-reload
sudo systemctl restart ifi-streamer-tidal-connect.service

Các bác viết hướng dẫn rõ ràng quá, mình phải học theo các bác khoản này.
 

tml3nr

Moderator
Mong chờ anh ra hàng quá!

Em mới mua thêm Pi 2 chỉ để chờ dùng bản Mod này.

Em thích xài bản anh mod, anh tinh tế cẩn trọng. Chờ không sao cả.
Mời anh Quạt và cả nhà dùng thử ạ :confused:

http://smpd.local:7779/ | Setup aprenderer

http://smpd.local:8200/ | Xem status minidlna

Lưu ý khi chuyển đổi giữa Tidal và nhạc offline:

- Sau khi play TC. Chỉ cần đổi sang output khác là alsa release (Play aprenderer được).

- Sau khi play aprenderer. Chỉ cần xóa hết nhạc trong playlist (queue) cùa bubbleupnp là alsa release (Play Tidal được).

Để thay đổi âm thanh aprenderer:

- Vào http://smpd.local:7779/ Thẻ System. Thay đổi Process Priority. Nếu set 99 nó sẽ chạy RT.

Để thay đổi âm thanh TC:

Mã:
nano /lib/systemd/system/ifi-streamer-tidal-connect.service

Set 2 em này 99 nó sẽ chạy RT:

Mã:
CPUSchedulingPriority=99
LimitRTPRIO=99

Mã:
[Unit]
Description=RasPi Streamer Tidal Connect Service
After=network.target sound.target

[Service]
Restart=on-failure
ExecStart=/usr/ifi/ifi-tidal-release/bin/tidal_connect_application \
         --tc-certificate-path "/usr/ifi/ifi-tidal-release/id_certificate/IfiAudio_ZenStream.dat" \
         -f "smpd" \
         --codec-mpegh true \
         --codec-mqa false \
         --model-name "HiTide RasPi Streamer" \
         --disable-app-security false \
         --disable-web-security false \
         --enable-mqa-passthrough false \
         --log-level 3 \
         --enable-websocket-log "0"

CPUSchedulingPolicy=fifo
CPUSchedulingPriority=81
LimitRTPRIO=81
LimitMEMLOCK=infinity

User=root
Group=root
RestartSec=1
KillMode=control-group

[Install]
WantedBy=multi-user.target

Sau đó:

Mã:
sudo systemctl daemon-reload
sudo systemctl restart ifi-streamer-tidal-connect

hoặc:

Mã:
sudo systemctl daemon-reload
sudo systemctl restart soundset

Ghi chú thêm:

- Em dùng soundset.service để start TC và aprenderer cho dễ kiểm soát trình tự startup.

- Không cần edit "ifi-streamer-tidal-connect.service" khi set dac.

- Lệnh set dac cho TC đã chạy được:

+ Bật dac

+ Chạy lệnh:

Mã:
cd /usr/ifi
sudo ifi-tidal-release/pa_devs/run.sh

- File "/usr/ifi/ifi-tidal-release/pa_devs/devices" nếu edit như sau em nghĩ là sẽ play được các dac từ hw:0 cho đến hw:2:

Mã:
device#0=dac_1: - (hw:0,0)
device#1=dac_2: - (hw:1,0)
device#2=dac_3: - (hw:2,0)
device#3=sysdefault
device#4=default
device#5=dmix
Number of devices = 6

 
Chỉnh sửa lần cuối:

rndce

Well-Known Member
Chỉnh sửa lần cuối:

tml3nr

Moderator
Cuối tuần có món ngon để chiến. Many Thanks bác @tml3nr
Bản này có sẵn upmpdcli ko bác Hải. Em tính dùng thêm Bubble Server để tạo Open Home.
upmpdcli muốn chạy được phải có mpd anh ạ. Khi có nó vào mpd sẽ bị nặng tiếng.

Lúc trước mình dùng upmpdcli vì nó có plugin Tidal. Nhưng mấy tháng nay đã hết chạy được do Tidal đổi api.

Em thấy cái TC này hay hơn bubbleupnp server + upmpdcli nhiều anh ạ. TC nó lấy nhạc trực tiếp từ internet.

Bubbleupnp server cần phải có java. upmpdcli cần có mpd. Nhạc từ Tidal lấy về bubbleupnp server rồi mới đẩy sang upmpdcli.

Em rất thích bộ tam sên TC, aprenderer và minidlna này vì theo em nó có lợi rất nhiều mặt.
 

tinnnnnnn

Member
upmpdcli muốn chạy được phải có mpd anh ạ. Khi có nó vào mpd sẽ bị nặng tiếng.

Lúc trước mình dùng upmpdcli vì nó có plugin Tidal. Nhưng mấy tháng nay đã hết chạy được do Tidal đổi api.

Em thấy cái TC này hay hơn bubbleupnp server + upmpdcli nhiều anh ạ. TC nó lấy nhạc trực tiếp từ internet.

Bubbleupnp server cần phải có java. upmpdcli cần có mpd. Nhạc Tidal lấy về bubbleupnp server rồi đẩy sang upmpdcli.

Em rất thích bộ tam sên TC, aprenderer và minidlna này vì theo em nó có lợi rất nhiều mặt.
Anh coi dùm sao nó không boot được. Cám ơn
 
Bên trên