Hi
I think we should move the discussion of this embedded Squeezelite
player to this place, so we don't waste space in Triodes Squeezelite
thread.

Background:
We wanted to use piCore on a raspeberry, because this small linux is
designed as a read-only system which is so small that it runs entirely
in RAM and it only writes to the CF-card whan it is told to. So
therefore it is very robust and can survive power cuts etc. 
Tinycore/Microcore linux can be found here:
http://distro.ibiblio.org/tinycorelinux/
And discussion about the Raspberry port can be found here:
http://forum.tinycorelinux.net/index.php?board=56.0
Triodes nice Squeezelite player can be found here:
http://forums.slimdevices.com/showthread.php?97046-Announce-Squeezelite-a-small-headless-squeezeplay-emulator-for-linux-(alsa-only)

The "HOW-TO" make the piCoPlayer can be found here:
The original post is here:
http://forums.slimdevices.com/showthread.php?97046-Announce-Squeezelite-a-small-headless-squeezeplay-emulator-for-linux-(alsa-only)&p=732506&viewfull=1#post732506

And here is a copy of the documentation:

Burn the Picore image to a CF card ( I use Win32Diskimager)

Then boot the Raspberry.

As Picore is running in read only mode om a partition called mmcblk0p1
you need to make another partition where it can have all the
configuration files and the extensions and the Squeezelite player.
In order to make such a partition I did this (It was here I had the most
difficulties) Each line is the commands I used:

fdisk /dev/mmcblk0
n new
p primary
2 partition number 1-4
6 first cylinder
+20M I made a 20 MB partition for this - you could choose any size you
want (up to the CF-card size)
t change partition Id
83 linux file system
w to write the changes to the card

sudo reboot


Next I formated it to the ext4 format:
mkfs.ext4 /dev/mmcblk0p2

sudo reboot


Then you need to define where Picore will find your extensions, you do
that by this command:
tce-setdrive

And then you choose 2= /mnt/mmcblk0p2


Download Squeezelite and put in a writeable place like mnt/mmcblk0p2,
you can so that by this command

wget http://squeezelite.googlecode.com/fi...zelite-armv6hf -P
/mnt/mmcblk0p2


Then I had some problems that squeezelite would not start - it turned
out that I had to allow it to be executed - using this command
chmod 755 /mnt/mmcblk0p2/squeezelite-armv6hf


You need to install Alsa, flac libmad and libvorbis. You do that by
using the package manager in Picore called tce. Therefor at command
promt write:
tce
s search
a (a in order to search for Alsa) then Enter
select alsa.tcz (at present no 4) enter
q quit
i install


s search
f (f in order to find flac.tcz (present no 9)) Enter
9 enter
q quit
i install

s search
l (l in order to find libmad.tcz (presently no 57)) Enter
57 enter
q quit
i install

s search
l (l in order to find libvorbis.tcz (presently no 88))
88 enter
q quit
i install

sudo reboot


Then in order to automatically to start Squeezelite everytime the
Raspberry reboot, you need to add this program to the bootlocal file
which is used for this purpose.
As I have been doing this without GUI the only editor present is the vi
editor, which also gave me a hard time. But these are the command you
have to use: 

sudo vi /opt/bootlocal.sh
Then pres i (for insert)
then move the cursor to the first empty line and write:
sudo /mnt/mmcblk0p2/squeezelite-armv6hf -a 80:4

Press "esc" in order to get out of "insert mode" 
Then type
:wq and Enter - in order to save and exit vi


These changes is not actually written to the bootlocal.sh file (as it is
in read only mode) but instead the changes is saved another place and
during reboot used - so in order to get Picore to save these changes and
use them the next time you reboot you have to do a manual backup.

So at command promt type 
filetool.sh -b

And now you can reboot and your Raspberry should start Squeezelite. I
have tried different Alsa buffer sizes and I think that 80:4 is fine -
for me the Squeezelite is in perfect sync with both a Duet and A
Logitech radio, if I use to high values like 500:4 or 200:4 the sync is
not as perfect. Using 50:4 resulted in some stuttering in the sound


Now you have a dedicated very small Squeezelite player, which boots very
rapidly, it doesn't use swap and can survive that you just pull the
power plug - so it is almost as an embedded hardware player, like a
Duet.


Regards
Steen


------------------------------------------------------------------------
sbp's Profile: http://forums.slimdevices.com/member.php?userid=37237
View this thread: http://forums.slimdevices.com/showthread.php?t=97803

_______________________________________________
unix mailing list
[email protected]
http://lists.slimdevices.com/mailman/listinfo/unix

Reply via email to