Search This Blog

Loading...

Thursday, May 29, 2014

Ride my Truck

After fiddling around with the Squeezebox Touch for years it finally broke. Thx G... ;)

To be honest. The Touch did a real great job for years. And still does a good job in many homes out there. However. Time goes on.

I wanted to replace it with an embedded ARM board. First I had a look at the Wandboard, which was chosen by the folks at Squeezebox forums who developed the Community Squeeze OS. I didn't really like it due to several reasons. (Note: Community Squeeze OS is no more (5/2014) available btw!)

I've then been trying (Raspberry PI and UDOO (same Freescale processor as Wandboard) ) and comparing this or that ARM board featurewise as replacement for my SB Touch (which is nothing else then an embedded board and a well done customized Linux).

The Cubox-I family was also based on the Freescale processor. Then there was a new Humminboard and a Banana Pi.  A friend of mine refered to the Odroid boards.   Hmmh. No. Not any of these really convinced me.

By coincidence I stepped over the Cubitruck. That one looked really interesting on a first glance, regarding price and features. 





I then analysed what's going on in the related user and customer forums
of most of above mentioned boards. I also had a look at Rune and Volumio to find out about this or that showstopper.

This activity is IMO one of the key activities if you look for an ARM board !!

Even if a board comes with a great set of features, it doesn't mean these are all working properly.
If drivers are not available or flawed, it can take forever to get things going.
You might never manage to get this or that feature going or properly going.

An active and large community makes such a board a success and NOT its great HW features. At least that's my experience.

Not to forget. Companies or product families known for short lifecycle products will not attract the community and related involvement either.

Best example is the Raspberry PI. A rather crappy board performance and a limited set of features (compared to e.g. a Cubitruck), but a huge  and  great community supporting it. It's long lifecycle not only attracts developers in writing software, patches, etc., no even on the hardware side there are numerous small companies, developing nice little gadgets for the Raspberry Pi.

With all that in mind I still went for the Cubitruck. It gave me the best of two worlds.
A rather active community, great HW features and useful software.
It's lifecycle will probably be on the short side.  Solid-Run got a lot going on around Cubox-I, Humminboard etc. . It doesn't look to me that these folks will have a long lasting focus on the Cubitruck.

However. I'll take that risk, since all audio related features I'm focused on are working quite well already.



Below a list why the Cubitruck won over above mentioned boards:

1. Nand Flash  - OS can reside onboard  -- no more corruption of SD cards
2. Reasonably fast (Udoo and other Freescale i.MX.6 boards are faster on paper and even got 4 processors. However the devices I tested didn't really work smooth - that might have changed nowadays)
3. 2GB RAM
4. Gbit Lan
5. Battery management and on-board battery supply option (works like a tablet),
    you could skip a linear supply.
6. Programmable GPIO pins
7. I2S and SPDIF output
8. A rather active community (not comparable to the Raspberry crowd
    though)
9. Several OS images available already
10. 5V supply voltage
11. Case included
12. Sata
13. Seperated USB and ethernet controllers (unlike RPI up to RPI 2)
14. And more stuff like, Infrared, programmable status LED, Wifi&BT
      onboard,.....

and all that @ around 90$/€.

That's IMO a much much better value then a Raspberry PI or the other boards I had a look at.


As I mentioned earlier. The key issue is to find the best software package for your board.

There are several projects ongoing, which provide headless OS server images for several boards. A quality streaming client should in any case be headless!

And there are SD card images, which focus on audio only.

Volumio just (07/2014) released an image for the Cubitruck. Rune and Community Squeeze OS (no longer available ??!!??) might come up with an image for the Cubitruck sooner or later.

These distros don't really add value to me. I don't need a Web interface for setup and configuration or player control (and related overhead) and I don't use MPD (I made my experiences running MPD for a while some years back!).

Update 03/30/15:

I'm using Squeeze On Arch for my Cubitruck since 1/2015.
It's an Arch Linux based system delivering the latest Logitechmediaserver and squeezelite. Configuration can be done via Web Interface.
That's all I ever wanted.



There are some little downsides. You will not find many gadgets for the Cubitruck. The Raspberry Pi universe offers e.g. all kind of piggy-back I2S DACs etc... .


There is an I2S output and there's also an I2S driver in the kernel. People are running I2S DACs on the CT. It's a little more complicated to get things going though, since it requires a little soldering to activate the I2S bus.
See Annex 2.


I  tried several USB DACs (Joro_S DSD DAC, Teac UD501, AQ Dragonfly 1.2, M2Tech USB DAC, iFi Nano DSD, RME Fireface UCX)  on the CT and they all performed really well. I've been told that the Gustard X-12 is a $500 device
which delivers outstanding value for the money. I might try that one.

Since all above DACs sound quite good, I kept the Joro DAC ( for my living room system). Returning a DIY DAC is not possible. It sounds very good with a good external power supply and a USB filter in front of it. The Joro AC comes with a Reclocker and an I2S isolator.

I do think there's no need to go the I2S route, if you have such a device at hand. You'll always be much more flexible with an USB audio device and the generic USB audio driver.

With the Cubitruck and e.g. the iFi DAC you'll be in the pricerange of a Squeezebox Touch.  With these two devices at hand, we're IMO talking about  a rather serious audio performance in comparison to the good old SBT.
Obviously there is no display. Who needs that? You'll need iPeng(iOS) or Orange Squeeze (Android) and a webbrowser to control your client and system.

Bottom line.

I highly recommend to have a look at the Cubitruck and Squeeze On Arch.
With this setup you'll be able to compete with many commercial streaming clients out there.




Just a word about the server. With Squeeze On Arch as a server you'll run the latest LogitechmediaServer (LMS) package that even includes latest Triode patches such as DOP support.
The Cubitruck handles a couple of thousand albums quite well.
There might be issues if you try to handle thousands of CDs and coverarts as well as challenging DSP processing (resampling/convolution), multiple streams and other network services, such as DLNA, fileserver etc in parallel.
For a basic setup my Cubitrucks works extremely well though and won't require more then 2-3W idle power.

My data is stored on an external separately powered 2TB 2.5inch (5V supply!) HDD.

You basically need 2 * 5V. One for the CT and one for the HDD. As a temporary/initial solution you can easily use e.g. 13000mAh batteries from e.g. Anker which come with 2* 5V outputs at $25.

If ou need more horsepower you won't get around using a powerful Intel machine, with plenty of horsepower to handle multiple demanding server duties such as resampling, image and video realtime conversions as well as handling multiple clients (streams).
However. The CT manages to handle the LMS and squeezelite. Under normal conditions (playback) you won't see a higher processor load then 1% (squeezelite = 0,3%).


Bottom line: I'd highly recommend the Cubitruck with Squeeze On Arch for audio server and player duties. Attach to the CT a class compliant DAC.
And use 2*5V quality power supplies. I guess you'll be more than happy.

With that in mind and the HW setup done, there's no big deal to try Volumio for Cubitruck. By swapping SD cards you can compare the systems easily.


I'll keep you posted.

Enjoy.

################################################
################################################

Annex 1:  HW List BoQ

This is what you need to get going.

1. Cubietruck board
2. Cooling
3. SD card (*2 for backup)

Optional:

4. USB Power supply 2.5A (1.5A will easily do if you don't power a Sata HDD)
    You might use a standard charging adapter.
5. (micro-) SD card reader for your PC to write and backup SD-cards
6. Li-Po battery 3.7V
7. Sata cable

Note: The better the 5V supply the better your CT will perform. 


Annex 2: I2S


To make I2S output work 4 resistors need to be soldered from one position into another position. Over here you'll see how it is done.

This action requires solid soldering skills!


####OUTDATED#####

Checkout Squeeze On Arch

#################
#################

Annex 3: CT - Debian Wheezy/Jessy + DAC + LMS + Squeezelite Installation/Integration

I might consider an article and building a public image in the future.

However. If you're interested in getting a fully integrated and tested setup,
that includes also many of my Touch Toolbox optimizations I might be able to
support you. Just PM me.


Annex 4: Binaries for CT - Debian Jessie (Wheezy)


If you try to run LMS on the CT with a Debian Wheezy ARM image, you'll find out that flac,faad and sox as supplied by LMS won't work.
Neither the Debian supplied LMS, nor the LMS nightly build .debs  come with working binaries.
(Note: LMS won't work on Debian Jessie at all due to Perl incompatibility!)

Basically your CT Wheezy LMS server won't be able to decode or transcode most of your music files.

You can't just use standard flac and faad binaries that come via Debian.
Logitech and some community members make patches available to e.g. allow fwd and rew functions. These patches also correct some bugs.


Beside that Triode (the man behind squeezelite) is not offering a squeezelite binary for the Allwinner A20 (arm7hf) (Cubitruck) for download.
I prepared  a binary with resampling enabled and another without.

The binaries are all built on Debian Jessie (the most current testing release).
I havn't tested them on Debian Wheezy for now!


If you run into problems, please let me know!

#####################################

Please, make a backup of your SD-card first!!!!!!!!!!!!!


You install and run the supplied SW at your own risk!

#####################################

Login to your CT via ssh as root first .
All you need to do now is following (copy/paste below commands):

apt-get install wget

wget --no-check-certificate https://googledrive.com/host/0BwPQKbfk8zfHRjduTkJ1MnVIcXM
mv  0BwPQKbfk8zfHRjduTkJ1MnVIcXM jessie-083014.tar
tar xvf jessie-083014.tar
cd jessie-083014
./setup-lms
./setup-sl

shutdown -r now

Note:
You can skip the setup scripts if you know what you're doing. You'll find the binaries in the jessie-083014 folder.
During the next days I'll add an start script and config file for squeezelite.

Enjoy.


....







4 comments:

  1. Hi soundcheck,
    Thanks you for a very interesting post.
    I will read around to see whether it is doable with my limited linux knowledge.
    i am awaiting your impressions of the UD80 FDA from hifmediy!!

    kp93300

    ReplyDelete
  2. Hi Klaus,
    eagerly waitimg for your progress reports. We are playing with CT for some time now and are quite happy as well. Just some minor issues with the LMS, but we'll get these sorted out.

    Cheers: Holger

    ReplyDelete
  3. Hi soundcheck. I agree with must of your points. Cubietruck is an excellent platform, even if I prefer IMX6 based solutions (I did some tests and somehow they sound better, probably a more strict application diagram results in less crosstalk).
    I just released a new version of Volumio for cubietruck
    http://volumio.org/volumio-audiophile-music-player-for-cubietruck-is-out/

    Let me know what you think

    michelangelo

    ReplyDelete
  4. Hi,

    Thanks for this informative entry. A few days ago, I recommended a non-Linuxer friend a Cubietruck for an almost identical usage scenario (running LMS and squeezelite in one box; only difference: his audio files are on an old NAS).

    It's gonna be my job to configure the OS and the software. Hope I'll figure it out even without the Wheezy installation guide you're thinking about ;)

    ReplyDelete