The goal of this project is to build a Web Control Point to display "Now Playing", "Album Art" and provide basic control over the Media Renderers on the local network.
My initial intention was to build a lovely web app for my WiiM mini devices because I missed so much from volumio, logitech media server or roon. Hence, the project name was "WiiM mini UI". Since the web app does interact with all Media Renderers on your system. (As long as it supports proper UPnP. (Sorry for OpenHome users. I'll put that into my to-do list))
Song metata will support Local DLNA server, Spotify, Qobuz, iHeart Radio, tuneIn Radio, Deezer and Amazon Music. I am sorry I am currently not a subscriber of TIDAL.
Depends on if you are a developer or an end user. There are several ways to hit the ground running.
The system consists of two parts. A backend server (node.js) and an interactive web user interface (vuetify 3).
To be able to compile and run, you need to first install the following tools if you do not have them already.
Once you have both Node.js and Yarn installed, then rest should be fairly straightforward. Next step is to run :
yarn install
this command will install all necessary libraries for you from here.
As a developer, you might want to run both back-end and front-end service separately. Ideally, you do not need to rebuild both projects at the same time so they won't interfere with one other.
By running yarn ui dev
will host a hot-swap version of web server to run the front-end code on localhost:3000. Meanwhile, running yarn server serve
will kick in back-end server on localhost:8080.
If you wish just to build and run, You only need the following commands :
yarn ui build
yarn serve
These commands will first build the web app into a bundled, minified package. Then the script will copy the productionalized web app into the right place and start the back-end services and host it under the node.js as a static page. In this mode, you really only need to hit http://localhost:8080 to run the web app.
IMPORTRANT The web app had a hard coded "server" location inside of /web_client/constants/Constants.ts file. Please change SERVER_URL and SERVER_PORT accordingly.
If you wish to run this web app anywhere else, such as a mini Single Board Computer like a Raspberry Pi or even deploy as a docker container. All you have to do is to run the yarn ui build
command first. After the building process has finished, you just have to copy /web_client/dist directory into a directory where you wish to run the service. For example! If your Node.js is running at /helloWorld folder, then you need to copy /web_client/dist into /HelloWorld/public. After that, just copy /wiim_server into /HelloWorld directory and run with node server.js (after you properly installed by running npm install
).
`yarn ui build
.node server.js
to start both back-end server and front-end web app.Grant access through SSH terminal into your Raspberry Pi
sudo apt-get update
sudo apt-get upgrade
sudo apt remove node (If you already had an older version installed)
sudo apt remove nodejs (If you already had an older version installed)
-fsSL https://deb.nodesource.com/setup_18.x | sudo -E bash - (This command will download latest node.js)
sudo apt-get install -y nodejs (Install Node.js)
node -v (check if node.js is properly installed)
At your current computer, kick in a build by yarn ui build
Copy /web_client/dist into Raspberry Pi to where you want your code to be hosted
Copy server.js and package.json files in /wiim_server/ into your
Run npm install
to install dependencies.
Run hostname -I
to find out your IP address on the Raspberry Pi.
Run node server.js
to run the Server + Web App.
Run a browser to [Raspberry Pi IP Address] : [Running port number] You should be able to see the web app running.
sudo npm install -g pm2
(install pm2)pm2 start server.js
(starting wiim_server)pm2 startup systemd
(generate a script that will launch PM2)sudo env PATH=$PATH/....
and paste into the terminal and run itpm2 save
(save current state of PM2 with server.js running)pm2 list
(list of services running under pm2)pm2 status
(status of pm2)pm2 show server
(this will show wiim_server in details)Reported by users, the building tools might not properly compile on Windows 11. Due to the tool set for building the project mainly used tools to run under Linux/OSX. There i s also a copy of production built web app already placed in the /wiim_server/public folder. You should be able to run just by using following commands :
You will then need to click on the SPEAKER icon to select a Media Renderer on your own network. You should be able to see the screen as follows. Keep in mind! You will need to select a Media Renderer first. Otherwise you won't be able to control playback/pause/next on it.
When you click on the artist name (a pink button), that should bring up a card below the main player.
The server location should host both the wiim_server and web app from the same server. However, occasionally during the development, you may have a web app and wiim_server running on different machines or different ports. You may click on the SETUP icon to change the IP address.
8/3/22
7/25/22
7/24/22