Go Back   Home > Forums > >
Home Forums Rules Articles diyAudio Store Blogs Gallery Wiki Register Donations FAQ Calendar Search Today's Posts Mark Forums Read

Software Tools SPICE, PCB CAD, speaker design and measurement software, calculators

SlimStreamer: Multiroom Streamer That Does Not Resample
SlimStreamer: Multiroom Streamer That Does Not Resample
Please consider donating to help us continue to serve you.

Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
Reply
 
Thread Tools Search this Thread
Old 17th December 2017, 10:54 AM   #1
gimesketvirtadieni is offline gimesketvirtadieni
diyAudio Member
 
Join Date: Apr 2015
Default SlimStreamer: Multiroom Streamer That Does Not Resample

Hello DIY Community

Let me introduce my pet project, I have been working for while. SlimStreamer (GitHub - gimesketvirtadieni/slimstreamer) is an audio streaming software for Linux with multiroom functionality. SlimStreamer captures audio playback from ALSA and broadcasts it to connected Squeezebox devices (real or ‘virtual’ like squeezelite) through SlimProto protocol. Moreover, while capturing, original sampling rate is preserved and PCM stream does not get resampled to a predefined frequency. Other solutions (like AirPlay, SnapCast, ...) use predefined sample rate, so original PCM stream is resampled in case sample rate does not match.

In other words, you can use any Linux software that outputs audio to the default ALSA device (MPD, Mopidy, Spotify client, ...) and SlimStreamer will capture it and redirect to connected Squeezebox players (for example squeezelite) in a transparent way.

I am still working on supporting SlimProto (it is still missing). However most tricky part, PCM capture in a bit-perfect way, is working fine, also single-threaded asynchronous TCP server is done.

Few more details:
-> SlimStreamer is written in C++17 (one should read it is very fast and lightweight)
-> It uses two ALSA plugins: SlimPlexor (GitHub - gimesketvirtadieni/slimplexor) and Loopback (Matrix:Module-aloop - AlsaProject)
-> SlimStreamer's source code is in Public Domain (Unlicensed)

Any comments / feedback about whether you find it relevant / interesting / useful are much appreciated Click the image to open in full size.


Click the image to open in full size.
gimesketvirtadieni

Last edited by gimesketvirtadieni; 19th December 2017 at 07:16 AM. Reason: links were corrected
  Reply With Quote
Old 22nd December 2017, 09:36 PM   #2
CharlieLaub is offline CharlieLaub  United States
diyAudio Member
 
Join Date: Mar 2007
Location: Michigan
This is interesting, especially the possibility to not resample. I have a couple of questions...

What transport (streaming protocol) are you using?

How well synchronized are multiple clients that should receive the same stream?

What happens when the sample rate of the stream-ed audio is not supported by the sink at the end of the line (e.g. the DAC)? How does the program handle that?
__________________
Visit my Audio Web Page <<--CLICK TO LEARN MORE-->> Get my LADSPA plugins
  Reply With Quote
Old 23rd December 2017, 11:37 AM   #3
gimesketvirtadieni is offline gimesketvirtadieni
diyAudio Member
 
Join Date: Apr 2015
I use SlimProto (SlimProto TCP protocol - SqueezeboxWiki), the same protocol used by Logitech Media Server (Logitech Media Server - SqueezeboxWiki). In other words, SlimStreamer mimics Logitech Media Server. This protocol came a long way; companies like Slim Devices and Logitech put a lot of expertise into it: SlimProto is the next version of SLIMP3, it supports lots of codecs, it allows using various sample rates, synchronisation, DSD over PCM (have not tested), … However the main reason I have chosen using it – players can be Pi Model A or Zero with decent DAC running a single SW player (squeezelite). The rest of the music functionality is done on server (regular player, MPD, Mopidy, Spotify, ShairPlay, …).

Synchronisation is done by the players (in my case by squeezelite). SlimStreamer just provides ‘master’ timestamps. So far, my experience with in-sync playback by squeezelite was very good (even on WiFi). Although I am still completing support for SlimProto so I used LMS for tests.

What happens when the sample rate of the stream-ed audio is not supported by the sink at the end of the line (e.g. the DAC)? How does the program handle that?

There are several way to get around unsupported sample rate by particular player's DAC. Clients report supported sample rates to the server so it may decide if a client should be used for streaming. However probably the most common way is to use ALSA ‘plug’ plugin before sending to DAC, it will resample if DAC does not support a specific rate.

I can see you developed several LADSPA plugins. I guess you know a lot about ALSA internals as well. Any tip / advice regarding SlimPlexor (it’s my ALSA plugin required to route PCM to a predefined by a sample rate loopback device) is more than welcome
  Reply With Quote
Old 23rd January 2018, 07:11 PM   #4
gimesketvirtadieni is offline gimesketvirtadieni
diyAudio Member
 
Join Date: Apr 2015
Hello DIY Community

Let me share a great news - SlimStreamer is available for alpha testing! Please find instructions how to build it on the front page of the github project. Can't wait for anyone trying it out and providing feedback. Please note, you need to build and setup SlimPlexor and then SlimStreamer to make it work all the way
  Reply With Quote

Reply


SlimStreamer: Multiroom Streamer That Does Not ResampleHide this!Advertise here!
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiroom audio from bluetooth source - is it possible? Razva Everything Else 8 5th June 2015 01:02 AM
DIY Multiroom Sound System Jeggebraaten Vendor's Bazaar 0 29th August 2013 06:54 PM
Multiroom amplifier system KnoB Chip Amps 2 21st October 2005 02:10 PM
Q: Resample before DAC ? MWP Digital Source 3 1st April 2004 03:57 PM


New To Site? Need Help?

All times are GMT. The time now is 03:13 AM.


Search Engine Optimisation provided by DragonByte SEO (Pro) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 15.79%
vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2018 DragonByte Technologies Ltd.
Copyright ©1999-2018 diyAudio
Wiki