Wednesday, November 30, 2016

Easily install Logitech Media Server (Squeezebox Server) and Squeezelite on your Pi with Armbian Jessie

Do you have any spare Pi?
I am talking about the Raspberry Pi, Orange Pi, Banana Pi, Cubieboard, pcDuino, Odroid, NanoPi and the likes...

Why not transform it into a Sonos-like multimedia server and player?
It's soooo easy!

All we need is two nice pieces of software: the Logitech Media Server (aka Squeezebox server) and a player to connect to it, which is going to be Squeezelite.

First of all, download the right image of Armbian for your board HERE
Please choose "Jessie server" image, if available. This is the version for server usage, with no desktop environments.
Follow the instructions and setup the operating system (we have faith you can manage this on your own, since you have a spare development board...)

How to install the Logitech Media Server / Squeezebox Server

Now, we have to install the Logitech Media Server, but we have to download it first. From the command line give the following command:
wget http://downloads.slimdevices.com/nightly/7.9/sc/ffd0b97/logitechmediaserver_7.9.0~1480398011_arm.deb -O lms.deb
(Please notice that from http...to..._arm.deb there are no spaces)
And let's wait for the file to be downloaded.  If you get a file not found error, you'll have to visit this website with a browser:
http://downloads.slimdevices.com/nightly/?ver=7.9
Find the most recent version of the _arm.deb version available, right click on it to copy it's link, and substitute this link in the above command.

Once the Logitech Media Server installation package has been downloaded, proceed with its installation:
sudo dpkg -i lms.deb
That's it! The Logitech Media Server is now installed, and you can go to:
http://ip-address-of-the-board:9000
 from any browser to set it up.

How to install the Squeezelite player

To actually play/stream your music collection or listen to online radios, you'll also need a player. This can be installed on the same board as the Logitech Media Server (so you will have a Server and a Player on the same machine), or on different boards which will work as players that connect to the Server (you can have as many players as you want!)

So, let's install Squeezelite, the Player "side" of this combo.
First we need to refresh the packages list of our installation:
sudo apt-get update
 Then we can install squeezelite:
sudo apt-get install squeezelite
That's basically it! Squeezelite will be installed and will automatically be launched at startup.

If you are using an external usb soundcard you might need to tweak with the squeezelite configuration file, which is /etc/default/squeezelite

First you will need to find out the name of the soundcard, and to do this you have to issue the following command:
sudo /usr/bin/squeezelite -l
Check the output and identify the name of your sound card. Copy it, then open the configuration file:
sudo nano /etc/default/squeezelite
Find the following line:
SL_SOUNDCARD="sysdefault:CARD=ALSA"
and substitute sysdefault:CARD=ALSA with the name of the card you have copied before.

If you want to give your player a different name than your hostname, just edit this line:
SL_NAME="$(hostname -s)"
and change the string within the quotes to the name you want to give this player.

The other options usually don't need to be touched.
That was easy, wasn't it?

Enjoy your music on your Pi!

Friday, September 9, 2016

Hermit: an Android app to save on apps

Has the free space on your smartphone alarmingly decreased after installing all the official apps of the websites and social network you use most?
Then a hermit is going to help you. Yes, Hermit (link): an Android app that allows users to create "lite apps" of their own favorite websites, saving them from installing the official (memory and space consuming) applications.

To understand what a "Lite App" is, just imagine your favorite website running inside a custom-made app with the following features:
  • Every "website"/lite app is encapsulated in its own environment, virtually transforming it into a native app: this way each lite app is completely separated from the others.
  • Cookies are isolated, which means that your activity inside the lite app will not be tracked like it would be if you were doing the same inside a browser tab.
  • The sandbox environment makes it impossible for users to get a virus or malware from a lite app.
  • Private browsing is enabled by default, so no history of your browsing is maintained on your device.
  • Each Lite App can have its own independent settings, so that users can customize each lite app differently from the others.
  • Ad blocking (no root needed).
  • Each lite app can have its own icon in the launcher, which will instantly open the website it encapsulates (no need to wait for the browser to be launched, then a new tab to be opened and then finally the website to be loaded).
  • Every lite app has its own set of bookmarks. For example, your Facebook lite app can save links to your favorite pages and groups, so that you can find them instantly when you need them.
  • Lite apps don't run in the background, therefore when you close one, it will be completely wiped from memory. This means it will not consume any resources (no memory, no traffic, no battery)
  • Permissions like the use of the camera or to share the user's location are only activated when the user wants.
Even though you can create lite apps from virtually any website, Hermit comes with a library of very popular apps it can efficiently replace, which include social networks (like Facebook, Instagram and Twitter), news sites (like CNN, the NYT, Google News), entertainment apps (like YouTube or IMDb), shopping apps (like Amazon, Groupon or Woot!) and many others.

And lite apps also support notifications!

How much space does your Facebook app take on your smartphone?
My Hermit installation, with its Facebook lite app (and six more lite apps!) only takes less than 20 megabytes on my phone.

But it's not just a matter of space, it's also a matter of privacy: with Hermit, your personal data is not shared with any other apps. And your phone will not run as many apps in the background as it would if you installed as many official apps, thus improving your battery life.

The free version of Hermit is fully functional and shows no ads, but it's limited to the creation of two lite apps.
To create more than two, you will need to purchase the full version: maybe it's not the least expensive app on the market, but -as the developers point out- your privacy is worth more than the price of a sandwich!
And if you are a student, you can even upgrade for free.

You can download Hermit for Android from the Play Store by clicking here.