魔百盒cm311-1a-yst機(jī)頂盒介紹
晶晨S905L3A處理器(12nm制程),2G內(nèi)存+16G存儲(chǔ),百兆網(wǎng)口,并且沒(méi)有自帶WIFI
魔百盒cm311-1a-yst機(jī)頂盒DIY網(wǎng)絡(luò)音樂(lè)播放器,主要是用U盤在機(jī)頂盒安裝Armbian,再在Armbian系統(tǒng)上安裝DietPi系統(tǒng),
DietPi系統(tǒng)內(nèi)可以自動(dòng)安裝很多軟件,有關(guān)網(wǎng)絡(luò)音樂(lè)播放器的就有以下幾種:
1.Squeezelite: audio player for lms & squeezebox(用于LMS和Squeezebox的音頻播放器)
Squeezelite 是一款音頻軟件,可讓您將 DietPi 設(shè)備轉(zhuǎn)變?yōu)橹С?Logitech 媒體服務(wù)器和其他支持軟件的音頻播放播放器
2.GMediaRender: Resource efficient UPnP/DLNA renderer(資源高效的UPnP/DLNA渲染器)
GMediaRender是DLNA 音頻呈現(xiàn)器/端點(diǎn)。允許您從其他設(shè)備(例如 BubbleUPnP)流式傳輸和播放音樂(lè)
3.NAA:HQPlayer 的高質(zhì)量網(wǎng)絡(luò)音頻播放終端。允許您從 HQPlayer 源(例如:Windows)流式傳輸音樂(lè)并直接從您的 DietPi 設(shè)備輸出。
4.Roon Bridge:將您的DietPi變成支持 Roon 的音頻播放器。通過(guò)在另一臺(tái)設(shè)備上使用 Roon 主應(yīng)用程序,您可以將音樂(lè)目錄直接流式傳輸?shù)紻ietPi上運(yùn)行的 Roon Bridge。
5.Roon Server:將您的設(shè)備變成支持 Roon 的音頻播放器和核心服務(wù)器。Roon 查看您的音樂(lè)并查找照片、簡(jiǎn)介、評(píng)論、歌詞和音樂(lè)會(huì)日期,并在藝術(shù)家、作曲家、表演者、指揮和制作人之間建立聯(lián)系。您得到的是一本關(guān)于您的音樂(lè)的可搜索、可瀏覽的雜志。
6.Shairport Sync:是一個(gè) AirPlay 音頻播放器,可以播放從 iTunes、iOS 設(shè)備和第三方 AirPlay 源(如 forked-daapd 和 Airfoil)流式傳輸?shù)囊纛l。由 Shairport Sync 供電的設(shè)備播放的音頻與源保持同步,因此與播放相同源的類似設(shè)備保持同步。這允許在多個(gè)設(shè)備上同步多房間音頻。
以下是所需軟件下載鏈接
鏈接:https://pan.baidu.com/s/1q2n-Tc-5JCwvHitMHXswpQ
提取碼:cqzz
一.安裝armbian
1.1.armbian鏡像
Armbian_23.02.0_amlogic_s905l3a_bullseye_5.15.81_server_2022.12.06
1.2.將鏡像文件寫入tf卡
在windows上用DiskGenius將U盤分區(qū)格式化
首先在DiskGenius左方框中選擇要分區(qū)的U盤,要選正確、要選正確、要選正確(重要的事提醒三次),右鍵點(diǎn)擊,彈出菜單,選擇“快速分區(qū)”,在彈出的快速分區(qū)框,選擇分區(qū)類型:MBR;選擇分區(qū)數(shù)目:自定義1個(gè)分區(qū);在右上方的高級(jí)設(shè)置選FAT32,然后點(diǎn)擊“確定”按鈕。等到完成后,關(guān)閉DiskGenius。
打開(kāi)Win32DiskImager,這時(shí)頭上方的“設(shè)備”欄里有U盤的盤符,盤符如果正確就不管了(如果只有一個(gè)U盤插在電腦上,只要顯示盤符就可以不管,否則要選正確的盤符)。點(diǎn)擊“映像文件”欄右邊的文件夾符號(hào),選擇要寫進(jìn)tf卡的img文件,文件選好后,“任務(wù)進(jìn)度”條下面的“寫入”按鈕可見(jiàn),點(diǎn)擊“寫入”按鈕,開(kāi)始寫入,等到寫完時(shí)會(huì)彈出“寫入完成”框,點(diǎn)擊“OK”按鈕,退出Win32DiskImager。
1.3.設(shè)置dtb
用Notepad++打開(kāi)TF卡的dtb/amllogic目錄,選meson-g12a-s905l3a-cm311.dtb,復(fù)制全部文件名;
繼續(xù)打開(kāi)根目錄下的uEnv.txt,將FDT=/dtb/amlogic/meson-g12a-s905l3a-e900v22c.dtb改成FDT=/dtb/amlogic/meson-g12a-s905l3a-cm311.dtb。
保存退出
1.4.所需軟件
PuTTY 必須是0.77版
DiskGenius
Win32DiskImager
Notepad++
2.安裝Armbian
2.1.將U盤插進(jìn)機(jī)頂盒的USB口,接上網(wǎng)線,插上電源,打開(kāi)電源開(kāi)關(guān)。
2.2.等待5-10分鐘左右,查看路由器的有線連接設(shè)備,會(huì)多出一個(gè)“armbian”設(shè)備,記錄下其IP地址。
2.3.在電腦端運(yùn)行PuTTY,輸入機(jī)頂盒的IP地址,打開(kāi)
出現(xiàn)以下提示
login as:
輸入:root
出現(xiàn)以下提示
root@192.168.100.12's password:
輸入:1234
出現(xiàn)以下提示
Welcome to ARMBIAN!
Documentation: https://docs.armbian.com | Community: https://forum.armbian.com
Create root password:
輸入root的新密碼:67773240
出現(xiàn)以下提示
Repeat root password:
再次輸入root的新密碼:67773240
出現(xiàn)以下提示
Choose default system command shell:
1) bash
2) zsh
輸入:1
出現(xiàn)以下提示
Shell: BASH
Creating a new user account. Press <Ctrl-C> to abort
Please provide a username (eg. your first name):
輸入用戶名:cqzhangjnhua
出現(xiàn)以下提示
Create user (cqzhangjunhua) password:
輸入用戶名為cqzhangjunhua的登錄密碼:67773240
出現(xiàn)以下提示
Repeat user (cqzhangjunhua) password:
再次輸入用戶名為cqzhangjunhua的登錄密碼:67773240
出現(xiàn)以下提示
Please provide your real name: Cqzhangjunhua
請(qǐng)?zhí)峁┠恼鎸?shí)姓名:Cqzhangjunhua
按回車
出現(xiàn)以下提示
Dear Cqzhangjunhua, your account cqzhangjunhua has been created and is sudo enabled.
Please use this account for your daily work from now on.
Detected timezone: Asia/Shanghai
Set user language based on your location? [Y/n]
輸入:y
出現(xiàn)以下提示
Generating locales: zh_CN.UTF-8
root@armbian:~#
到此armbian在U盤的安裝完成。
重要之處、重要之處、重要之處,要激活U盤的剩余空間,請(qǐng)登錄armbian→輸入命令:
armbian-tf
根據(jù)提示回車e將剩余空間擴(kuò)展到當(dāng)前系統(tǒng)分區(qū)和文件系統(tǒng)。
二.安裝DietPi
nano /etc/apt/sources.list
nano /etc/hosts
按照下載的《換源內(nèi)容2》的要求進(jìn)行換源。
1.在瀏覽器中打開(kāi)網(wǎng)頁(yè):
https://github.com/MichaIng/Diet ... es/dietpi-installer
2.將網(wǎng)頁(yè)中的內(nèi)容復(fù)制到Notepad++,保存為dietpi-installer.sh
3.nano /home/dietpi-installer.sh
Notepad++中的dietpi-installer.sh的內(nèi)容,全部復(fù)制到/home/dietpi-installer.sh
輸入ctl+o, enter, ctl+x,保存退出。
4.
chmod +x /home/dietpi-installer.sh
cd /home
./dietpi-installer.sh
提示一:
Please select the Git branch the installer should use:
master : Stable release branch (recommended)
beta : Public beta testing branch
dev : Unstable development branch
選擇:master : Stable release branch (recommended)
按Ok
提示二:
Please enter your name. This will be used to identify the image creator within credits banner.
You can add your contact information as well for end users.
NB: An entry is required.
輸入:用戶名(cqzhangjunhua),按Ok。
提示三:
Please enter the name or URL of the pre-image you installed on this system, prior to running this script. This will
be used to identify the pre-image credits.
EG: Debian, Raspberry Pi OS Lite, Armbian or "forum.odroid.com/viewtopic.php?t=123456" etc.
NB: An entry is required.
輸入:Debian, 按Ok。
提示四:
Please select the current device this is being installed on:
- NB: Select "Generic device" if not listed.
- "Core devices": Fully supported by DietPi, offering full GPU acceleration + Kodi support.
- "Limited support devices": No GPU acceleration guaranteed.
在ARM的下拉列表中選:28 : Generic Amlogic S905,按Ok。
提示五:
Please select an option:
0 : I do not require WiFi functionality, skip related package install.
1 : I require WiFi functionality, install related packages.
選擇:0 : I do not require WiFi functionality, skip related package install。按Ok。
提示六:
Please select a Debian version to install on this system.
Currently installed: buster (ID: 5)
6 : Bullseye (current stable release, recommended)
7 : Bookworm (testing, if you want to live on bleeding edge)
選擇:6 : Bullseye (current stable release, recommended)。按Ok。
出錯(cuò)提示:
┌────────────────────────┤ DietPi-PREP ├──────────────────────────┐
│ - Command: rm /etc/apt/sources.list.d/* │
│ - Exit code: 1 │
│ - DietPi version: v8.7.1 (MichaIng/master) | HW_MODEL: 28 | HW_ARCH: 3 | DISTRO: 6 │
│ - Error log: │
│ rm: cannot remove '/etc/apt/sources.list.d/*': No such file or directory │
│ │
│ Retry : Re-run the last command that failed │
│ DietPi-Config : Edit network, APT/NTP mirror settings etc │
│ Open subshell : Open a subshell to investigate or solve the issue │
│ Send report : Uploads bugreport containing system info to DietPi │
│ ●─ Devs only ─────────────────● │
│ Change command : Adjust and rerun the command │
│ │
│ │
│ <Ok> <Exit> │
│ │
└───────────────────────────────────────────────────────────┘
解決方法:
1.如果/etc/apt目錄下的sources.list.d目錄存在(用WinSCP查看):
將/etc/apt目錄下的sources.list文檔用WinSCP復(fù)制到/etc/apt/sources.list.d目錄下
在上面出錯(cuò)提示框里選擇 "Change command : Adjust and rerun the command"
在彈出的提示框里修改:rm /etc/apt/sources.list.d/* 為以下
rm /etc/apt/sources.list.d/sources.list
2.如果/etc/apt目錄下的sources.list.d目錄不存在(用WinSCP查看):
首先在/etc/apt目錄下建立sources.list.d目錄
mkdir /etc/apt/sources.list.d
然后在按照上面的步驟就可以。
當(dāng)出現(xiàn)以下提示,表示安裝完成。
/lib/modules:
total 4.0K
drwxr-xr-x 3 root root 4.0K Jul 30 06:51 5.15.58-flippy-75+o
[ OK ] DietPi-PREP | Completed, disk can now be saved to .img for later use, or, reboot system to start first run of DietPi.
[ OK ] DietPi-PREP | To create an .img file, you can "poweroff" and run the following command from the host/external DietPi system:
- bash -c "$(curl -sSfL https://raw.githubusercontent.co ... mages/dietpi-imager)"
root@armbian:/home#
5.首次運(yùn)行dietpi
nano /etc/apt/sources.list
nano /etc/hosts
按照下載的《換源內(nèi)容2》的要求進(jìn)行換源。
reboot
重新啟動(dòng)
打開(kāi)電腦的瀏覽器,輸入路由器地址,進(jìn)入路由器設(shè)置,查看局域網(wǎng)內(nèi)的設(shè)備及地址,當(dāng)看到設(shè)備名:DietPi,則記下地址。
打開(kāi)PuTTY軟件,并在地址欄輸入DietPi的地址,點(diǎn)擊打開(kāi)
注意:
第一次登錄DietPi,用戶名:root 登錄密碼:dietpi
提示:
DietPi-Set_software
Do you want to adjust the default global software password for
DietPi-Software installations? We especially recommend to change the default
password "dietpi". This does not affect any existing software passwords.
NB: This password will be saved and encrypted within
"/var/lib/dietpi/dietpi-software/.GLOBAL_PW.bin" to be useable by DietPi
scripts for e.g. web application and database logins. We highly recommend to
apply individual passwords for each software title after first login.
選擇: <Cancel>
提示:
DietPi-Set_software
Change login password for "root" and "dietpi" users?
DietPi has two accounts by default "root" and "dietpi". On first boot, both
share the global password "dietpi", respectively the one set in
"dietpi.txt".
It is highly recommended to change this password, ideally, it should be
different than the global software password.
Would you like to change the login passwords for "root" and "dietpi"?
選擇:Ok
輸入以root身份登錄的密碼:67773240 選擇:Ok
再次:輸入以root身份登錄的密碼:67773240 選擇:Ok
對(duì)之后的提示,可以選擇:No
顯示:
DietPi-Software
Help! : Links to online guides, docs and information
DietPi-Config : Feature-rich configuration tool for your device
●─ Select Software ─────────────────────────────●
Search Software : Find software to install via search box
Browse Software : Select software from the full list
SSH Server : [Dropbear]
Log System : [DietPi-RAMlog #1]
User Data Location : [SD/eMMC | /mnt/dietpi_userdata]
●─ Install or Remove Software ──────────────────●
Uninstall : Select installed software for removal
Install : Go >> Start installation for selected software
選擇:DietPi-Config: Feature-rich configuration tool for your device 按Ok
顯示:
DietPi-Config
Hardware : Generic Amlogic S905 (aarch64)
1 : Display Options
2 : Audio Options
3 : Performance Options
4 : Advanced Options
5 : Language/Regional Options
6 : Security Options
7 : Network Options: Adapters
8 : Network Options: Misc
9 : AutoStart Options
10 : Tools
選擇:3 : Performance Options 按Ok
顯示:
DietPi-Config
Hardware : Generic Amlogic S905 (aarch64) │
│ CPU Temp: 38'c : 100'f │
│ RAM: 1954 MiB | Used: 180 MiB | Free: 1774 MiB
CPU Governor : [schedutil]
CPU Frequency Limits : Max = [Off] | Min = [Off]
選擇:CPU Governor : [schedutil] 按Ok
顯示三個(gè)選擇項(xiàng):
schedutil : Scales CPU frequency between 1000 MHz and 1908 MHz
ondemand : Scales CPU frequency between 1000 MHz and 1908 MHz
performance : Forces CPU frequency to 1908 MHz
選擇:performance : Forces CPU frequency to 1908 MHz 按Ok
顯示:
CPU Governor : [performance]
CPU Frequency Limits : Max = [Off] | Min = [Off]
選擇:CPU Frequency Limits : Max = [Off] | Min = [Off] 按Ok
顯示:
Limit the maximum frequency that your processor can reach.
選擇:1908 MHz 按Ok
顯示:
Limit the minimum frequency that your processor can reach.
選擇:1800 MHz 按Ok
然后選擇 <Back>
顯示:
DietPi-Config
Hardware : Generic Amlogic S905 (aarch64)
1 : Display Options
2 : Audio Options
3 : Performance Options
4 : Advanced Options
5 : Language/Regional Options
6 : Security Options
7 : Network Options: Adapters
8 : Network Options: Misc
9 : AutoStart Options
10 : Tools
選擇:5 : Language/Regional Options 按Ok
顯示:
DietPi-Config
Please select an option:
Locale : [C.UTF-8]
Timezone : [Europe/London]
Keyboard : [gb]
選擇:Timezone : [Europe/London] 按Ok
顯示省略,選擇:Asia 按Ok
顯示省略,選擇:Shanghai 按Ok
顯示省略,選擇:Back
顯示省略,選擇:Exit
顯示省略,選擇:Ok
顯示省略,選擇:Browse Software: Select software from the full list 按Ok
顯示省略,
光標(biāo)放到:[ ] 36 Squeezelite: audio player for lms & squeezebox,按 空格鍵,在方框中加上*
光標(biāo)放到:[ ] 163 GMediaRender: Resource efficient UPnP/DLNA renderer
光標(biāo)放到:[ ] 96 Samba Server: Feature-rich SMB/CIFS server,按 空格鍵,在方框中加上*
還可以選:[ ] 35 Logitech Media Server: aka. LMS, fka. SlimServer, SqueezeCenter, SqueezeboxServer, SliMP3
還可以選:[ ] 124 NAA daemon: signalyst network audio adaptor (naa)
還可以選:[ ] 128 MPD: music player daemon
還可以選:[ ] 86 Roon Extension Manager: manage extensions from within Roon
在Media Systems下面共有29個(gè)軟件,可以根據(jù)自己需要選擇安裝。
選好要安裝的軟件后,按Ok
顯示省略,選擇:Install: Go >> Start installation for selected software 按Ok
顯示省略,按Ok
開(kāi)始安裝所選軟件
顯示:
Show : Show me the upload file content
1 : Opt IN and upload data
0 : Opt OUT and purge uploaded data
選擇:0 按Ok
顯示:
─────────────────────────────────────────────────────
DietPi v8.11.2 : 14:20 - Thu 12/08/22
─────────────────────────────────────────────────────
- Device model : Generic Amlogic S905 (aarch64)
- CPU temp : 40 °C / 104 °F : Optimal temperature
- LAN IP : 192.168.2.77 (eth0)
- MOTD : Check out the DietPi v8.11 release notes:
https://dietpi.com/docs/releases/v8_11/
─────────────────────────────────────────────────────
DietPi Team : https://github.com/MichaIng/DietPi#the-dietpi-project-team
Image by : cqzhangjunhua (pre-image: Debian)
Patreon Legends : Camry2731, Chris Gelatt
Website : https://dietpi.com/ | https://twitter.com/DietPi_
Contribute : https://dietpi.com/contribute.html
Web Hosting by : https://myvirtualserver.com
dietpi-launcher : All the DietPi programs in one place
dietpi-config : Feature rich configuration tool for your device
dietpi-software : Select optimised software for installation
htop : Resource monitor
cpu : Shows CPU information and stats
root@DietPi:~#
至此,DietPi安裝完成。
三.設(shè)置GMediaRender
1.將USB解碼器插入cm311-1a-yst的另一個(gè)USB口
2.輸入dietpi-config命令,選擇音頻設(shè)備
dietpi-config
選擇:2 : Audio Options
選擇:Sound card : [default]
選擇:hw:1,0 : H20 USB Audio
選擇: <Back> ,退出 <Back>
在安卓手機(jī)上安裝Bubbleupnp,Bubbleupnp會(huì)自動(dòng)搜索upnp播放器,在播放器中選擇DietPi,就可以將手機(jī)內(nèi)的音樂(lè)
推送到cm311-1a-yst所接的USB解碼器中播放,而且好像是源碼播放,在解碼器里會(huì)顯示“PCM 44K"或“PCM 192k”。
在播放 44k音樂(lè)時(shí),CPU的負(fù)擔(dān),一般在0.7~1.3%左右,最大不超過(guò)2%
在播放192k音樂(lè)時(shí),CPU的負(fù)擔(dān),一般在3.3~4.6%左右,最大不超過(guò)6%
四.設(shè)置squeezelite
建立squeezelite.service文檔
輸入以下命令:
find / -name squeezelite.service
顯示:
/usr/lib/systemd/system/squeezelite.service
/sys/fs/cgroup/system.slice/squeezelite.service
輸入以下命令:
nano /lib/systemd/system/squeezelite.service
對(duì)文件中的以下內(nèi)容:
[Service]
User=squeezelite
EnvironmentFile=/etc/default/squeezelite
ExecStart=/usr/bin/squeezelite $ARGS
將以上修改成:
[Service]
User=squeezelite
EnvironmentFile=/etc/default/squeezelite
#ExecStart=/usr/bin/squeezelite $ARGS
ExecStart=taskset -c 3 /usr/bin/squeezelite -o hw:1,0 -D dop -p 99 -b 4096:6892
保存退出。
重啟系統(tǒng),設(shè)置完成。
在手機(jī)上或者電腦上輸入DAPHILE的地址,在player頁(yè)面的右下角選擇DietPi-Squeezelite,就可以將DAPHILE選中的音樂(lè)
推送到cm311-1a-yst所接的USB解碼器中播放。
在播放 44k音樂(lè)時(shí), CPU的負(fù)擔(dān),一般在0.7%左右,最大不超過(guò)2%
在播放192k音樂(lè)時(shí), CPU的負(fù)擔(dān),一般在1.3~2.6%左右,最大不超過(guò)3%
在播放DSD64音樂(lè)時(shí), CPU的負(fù)擔(dān),一般在0.7~1.3%左右,最大不超過(guò)2%
在播放DSD128音樂(lè)時(shí),CPU的負(fù)擔(dān),一般在0.7~2%左右,最大不超過(guò)3%
注意:當(dāng)用Squeezelite播放后,再用GMediaRender播放,必須將以下的加#注釋掉,保存退出后重啟系統(tǒng)。
[Service]
User=squeezelite
EnvironmentFile=/etc/default/squeezelite
#ExecStart=/usr/bin/squeezelite $ARGS
#ExecStart=taskset -c 3 /usr/bin/squeezelite -o hw:1,0 -D dop -p 99 -b 4096:6892
|