Releases: mikebrady/shairport-sync
Automake Building Bug Fix
Version 3.3.9 is a single bug fix release.
Bug Fix
- Version 3.3.9 fixes a build failure with convolution raised since
automake 1.16.5
and https://git.savannah.gnu.org/cgit/automake.git/commit/?id=f4a3a70f69e1dbccb6578f39ef47835098a04624
Further details in Fabrice Fontaine's original PR to thedevelopment
branch. Many thanks to Fabrice Fontaine for the bug report and for the fix.
Details
- Please refer to the RELEASENOTES.md for full details of Version 3.3.
Bug Fixes and Enhancements
Version 3.3.8 brings many bug fixes and enhancements and is recommended for all users.
Enhancements
- Documentation for the MQTT interface. Many thanks to minix1234!
Bug Fixes
- Fix a bug in the
alsa
back end. In the interval between checking that the alsa device handle was non-NULL
and actually using it, the handle could be set toNULL
. The interval between check and usage is now protected. - Fix a bug in the
alsa
precision timing code. Thanks to durwin99, Nicolas Da Mutten, mistakenideas, Ben Willmore and giggywithit for the report. - Fix a bug that caused Shairport Sync to hang, but not actually crash, if an
on-...
script failed. - Fix a crash that occurred if metadata support is enabled during compilation but turned off in the configuration file. Thanks to Tim Curtis for the report.
- Fix a crash that occurred playing from AirPower on Android. Thanks to Ircama for the report.
- Fix the
configure.ac
file so that--without-<feature>
configuration options are not interpreted as--with-<feature>
options instead! Thanks to David Racine for the report.
Details
- Please refer to the RELEASENOTES.md for full details.
Version 3.3.7 – Bug Fixes, Enhancements and a New Feature
Version 3.3.7 brings many bug fixes and enhancements and a new feature and is recommended for all users.
-
For the PulseAudio backend
pa
, added a newserver
entry to thepa
section of the configuration file, allowing you to specify a connection to a remote or a local system PulseAudio instance instead of letting PulseAudio choose. Thanks to Guillaume Revaillot for this new feature. -
Please refer to the RELEASENOTES.md for full details.
Version 3.3.6 – Jack Audio Resampling, Bug Fixes and Enhancements
New Features
- Resampling has been added for the Jack Audio backend. This can be used to up-sample to 192kHz. Thanks to Pieter De Gendt for this new feature.
Bug Fixes and Enhancements
- Please refer to the release notes for Version 3.3.6.
Version 3.3.5 – Minor Bug Fixes and Enhancements to the D-Bus Interface
This update contains two bug fixes and enhancements to the D-Bus interface. It is recommended for all users.
For details, please refer to the Release Notes for Version 3.3.5..
Thanks to everyone who reported issues.
Version 3.3.4 – Bug fixes and Minor Enhancements
This update contains a number of bug fixes and minor enhancements. It is recommended for all users.
For details, please refer to the Release Notes for Version 3.3.4..
Thanks to everyone who reported issues.
Version 3.3. Audio Improvements, MQTT, Jack Audio, Stability Improvements, Bug Fixes and Enhancements.
New Feature Highlights:
- Automatic Format and Speed Selection for
alsa
devices. Using thealsa
back end, when you specify the output device, Shairport Sync will now, by default, select the best output format and speed. For instance, if your output device is capable of 32-bit operation, it will be selected. In some situations, this will give a noticeable improvement in sound quality – see the discussion of audio improvements below. The greatest bit depth will always be selected, and the lowest speed that is a multiple of 44,100. - Audio Transient Reduction: A
Disable Standby
feature to eliminate certain faint-but-annoying audible pops and clicks has been added foralsa
devices. The setting prevents an output device entering standby mode and thus minimises standby/busy transitions, which can sometimes be heard. It is pretty impressive, especially combined with fixes to the dithering code described below. If you can enable 24- or 32-bit audio output to your output device, you can get even better results. This feature is available in the ALSA back end (standard in Linux) when it is driving output devices that can provide precision delay information, i.e. most hardware output devices and possibly some virtual devices. - New active/inactive program hooks. Basically, these are "deglitched" replacements for play start/play end program hooks. When a play session starts, the system goes active. When the play session ends, the system remains active for a period determined by the
active_state_timeout
setting, 10 seconds by default. If another play session starts before the period elapses, the system stays active; otherwise the system goes inactive. The hooks are performed when the system goes active or inactive. - A new MQTT client interface, with support for metadata and for some remote control commands.
- A new Jack Audio back end.
- PulseAudio: A new option for the
pa
backend to allow the specification of the audio sink. - CYGWIN: An updated and enhanced installation procedure to install Shairport Sync as a Cygwin service.
- Opt-in default for certain added features: If support for
soxr
, metadata or the Apple ALAC decoder is included during building (i.e. at the./configure
stage), then the features are enabled by default at run time. The features are (1)soxr
interpolation – chosen automatically if the device is fast enough, (2) the Apple ALAC decoder and (3) metadata, which is implied when you include support for metadata, D-Bus, MPRIS or MQTT features. - Shairport Sync can now receive AirPlay streams consisting of raw PCM – 16 bit stereo frames at 44,100 samples per second. Packets must be 352 frames exactly.
- Improved support for big-endian CPUs by adding support for explicit -endian formats, i.e. S16_LE, S16_BE, S24_LE, S24_BE, S32_LE, S32_BE.
- Add a list of
alsa
hardware devices found to the alsa backend help section in theshairport-sync -h
text. (Linux only – doesn't work on FreeBSD/OpenBSD.)
Stability Improvement Highlights:
- Greatly improved stability when playing is interrupted by another play request, by the abrupt disappearance of the audio source or by severe network problems.
- Enhanced detection of unrecoverable device or player errors. A hook is provided to call an external program when there errors are detected.
- Improved robustness when severe transient network problems occur.
More Details
New Features
- A new Jack Audio back end. The rough back end for Jack Audio present in earlier development builds has been extensively rewritten by Jörn Nettingsmeier in a way that is more in keeping with the Jack Audio style. It uses native Jack Audio lockless buffers and offers autoconnect facilities that the previous version didn't have. Many thanks to him.
- A new MQTT client interface, with support for metadata and for some remote control commands, is a new configuration option, thanks to the work of Till Zimmermann. MQTT is an often-used protocol in FOSS home-automation projects (as well as in commercial ones), and as Shairport Sync is often used in these setups, this adds client support for this protocol.
- The volume-control software has been completely rewritten. From a user's point of view, the result should be a much smoother response to volume control changes, free from artefacts. It is now also possible to combine the hardware mixer and the software attenuator in two ways to extend the attenuation range -- giving priority to the software mixer or giving priority to the hardware mixer. see the new
volume_range_combined_hardware_priority
setting in thegeneral
section of the configuration file. - The muting/unmuting code has been rewritten to be simpler and more consistent.
- Two new external program/script hooks –
run_this_before_entering_active_state
andrun_this_after_exiting_active_state
are provided for when the system goes active or inactive. Background: Many users use therun_this_before_play_begins
program hook to turn on an amplifier and therun_this_after_play_ends
hook to turn it off. A big problem is when another play session starts immediately after a play session ends, causing the amplifier to be switched off and then on again very quickly. This happens, for example, when a YouTube clip ends and the next one begins. To get around this, the concept of an active state covering a sequence of play sessions is introduced. When a play session starts, the system goes active -- it enters the active state. When the play session ends, the system remains active for a period determined by theactive_state_timeout
setting, 10 seconds by default. If another play session starts before the period elapses, the system stays active; otherwise the system goes inactive -- it leaves the active state. The two new hooks mentioned above can be used to execute programs/scripts when the system goes active or inactive. They are to be found thesessioncontrol
group of settings. - A new command-line option,
-u
, directs logging toSTDERR
rather than the system log. Useful when you compile Shairport Sync withoutlibdaemon
using the--without-libdaemon
configuration option. - A new feature called
Disable Standby
keeps the output DAC in the play state all the time and helps to remove some annoying popping or clicking noises. This is an attempt to remove the annoying low-level clicking sounds that some output devices make just when they start processing audio and sometimes when they stop. Typically a faint click might be heard just before a play session starts or just before audio resumes after a pause. Similarly, a faint click can sometimes be heard just after a play session ends. It is extremely difficult to remove these clicks completely from the hardware, so this new feature ensures that the output device avoids situations where these clicks might be generated by always playing audio. To accomplish this, if Shairport Sync isn't actually playing anything, audio frames consisting of silence are sent to the output device, keeping it playing. Apart from the initial startup transition, the output device never stops playing and thus never transitions to and from standby mode, avoiding the possibility of generating associated audio disturbances. To enable this feature, a newalsa
group setting with the namedisable_standby_mode
is available. (If you do a full$ sudo make install
, a new sample configuration file with this setting in it is installed at/etc/shairport-sync.conf.sample
or/usr/local/etc/shairport-sync.conf.sample
.) To control this feature, a newalsa
-onlydisable_standby_mode
setting can be set toalways
,auto
ornever
. Thealways
setting is recommended for systems where the output device is dedicated to Shairport Sync. The "Disable Standby" state itself can be set or cleared via the D-Bus interfaceDisableStandby
property. - A new
run_this_if_an_unfixable_error_is_detected
(in thesessioncontrol
group of settings) program hook is provided. At the moment, two conditions can trigger this. The first is if the watchdog is unable to terminate a play session. The second is if the output device stalls for a long period. Both conditions can be caused by malfunctioning DACs. The external program could, for example, reboot the device. - Add a configuration option to specify the PulseAudio output sink. An extra option for the
pa
backend to allow the specification of the audio sink. Thanks to Maciej Wilczyński for his work on this.
Enhancements
- In the
alsa
backend, newplay()
anddelay()
functions minimise the use ofsnd_pcm_recover()
to prevent unnecessary resets of the output DACs. - In the
alsa
backend driver, hardware isn't accessed until the first time it is needed. That is, when Shairport Sync starts up, it no longer needs to access the device momentarily. Instead, it waits for the first use. - The
libdaemon
library is now an optional build. It is not necessary forsystemd
systems and can be omitted. Use the--without-libdaemon
configuration option to leave it out. Note that whenlibdaemon
is omitted, log messages will be sent to the system log by default. Use the-u
command line command to direct log messages toSTDERR
, which is typically the command line console. - At present, Shairport Sync adds dither to the audio (a) if the built-in software-based volume control is used, (b) if the audio is mixed to mono or (3) if there is a reduction in sample size, say from 16- to 8-bit. The code for generating dither has been much improved. Due to a poor pseudo-random number arrangement, the dither noise didn't sound like white noise -- now it does. In addition, if dither is to be added, it is also added to the silence inserted just p...
Version 3.2.2. Timing adjustments for iOS 12 and macOS Mojave. Minor bug fix.
Enhancements
- In this release, the latency calculations are updated to accommodate changes in iOS 12 and AirPlay connections from macOS Mojave. Thanks to artenverho who first reported the issue.
- Formatting of the settings file
shairport-sync.conf
has been fixed, thanks to the work of roblan.
Bug Fix
- A problem that prevented the
run_this_when_volume_is_set
script or program from running when the volume control is changed has been fixed. Thanks to shaven for the report.
Version 3.2.1. Stability Improvements using Soxr Interpolation.
Please see the Release Notes for 3.2.
Bug Fix
This release fixes a bug that was causing problems when soxr
interpolation was chosen, and is recommended for all users.
Problems caused by the bug included instability during or after a play session and possibly an extremely slight click on very loud audio. Thanks are due to hanaguro, FnasBas, priitohlo, David Krmpotić and artenverho.
Version 3.2. New D-Bus and MPRIS Interfaces, Important Bug Fixes and Enhancements.
Version 3.2
Version 3.2 introduces two big new features – MPRIS support and a "native" Shairport Sync D-Bus interface. MPRIS offers a standard set of facilities for implementing remote control and the native D-Bus interface allows local programs to interact directly with Shairport Sync. When used with either of these interfaces, Shairport Sync offers access to the remote control commands available to control the source, and also offers access to metadata, including titles and cover art. These new features are experimental, but are already useful.
This release of Shairport Sync contains important bug fixes and stability improvements and is recommended for all users. If offers better synchronisation, better compatibility with third-party AirPlay sources, greater stability when used with YouTube and macOS system sound, faster resynchronisation, better performance on noisy or congested networks and many other improvements.
A quick INSTALL guide for the Raspberry Pi, a how-to CAR INSTALL guide and a note about installing to OpenBSD have been added.
Here are some of the details:
New Features
- Shairport Sync now offers an IPC interface via D-Bus. It provides an incomplete but functional MPRIS interface and also provides a "native" Shairport Sync interface, both of which rely on D-Bus. Both provide some metadata and some remote control. The native interface includes status information about whether the remote control connection is viable or not, i.e. whether it can still be used to control the client. A remote control connection to the audio client becomes valid when the client starts AirPlaying to Shairport Sync. The connections remains valid until the audio source deselects Shairport Sync for AirPlay, or until the client disappears, or until another client starts AirPlaying to Shairport Sync. After 15 minutes of inactivity, the remote contol connection will be dropped.
Enhancements
- OpenBSD compatibility. Shairport Sync now compiles on OpenBSD - please consult the OpenBSD note for details.
- A new
volume_control_profile
, in thegeneral
section and for advanced use only, with two options:"standard"
which uses the standard volume control profile – this has a higher transfer profile at low volumes and a lower transfer profile at high volumes – or"flat"
which uses a uniform transfer profile to linearly scale the output mixer's dB according to the AirPlay volume. - Some DACs have a feature that the lowest permissible "attenuation" value that the built-in hardware mixer can be set to is not an attenuation value at all – in fact, it is a command to mute the output completely. Shairport Sync has always checked for this feature, basically in order to ignore it when getting the true range of attenuation values offered by the mixer.
However, with this enhancement, Shairport Sync can actually use this feature to mute the output where appropriate. - Added or improved compatibility with AirFoil, TuneBlade, Swinsian, AirAudio, Synology AudioStation/5.2.
Bug Fixes
- Better AirPlay synchronisation. Older versions of Shairport Sync added an 11,025 frame (0.25 seconds) offset to all the latencies negotiated with the sender. This seems now incorrect for AirPlay sources. Accordingly, the logic Shairport Sync uses to determine the extra delay has been revised. The result is better sync with videos, e.g, YouTube, while iTunes and ForkedDaapd synchronisation is unaffected. Older versions of AirPlay are still handled correctly.
- Much faster termination of a play session, leading to increased stability playing YouTube audio, etc.
- Improved resynchronisation logic should improve performance on congested networks.
- Dithering is now off when
ignore_volume_control
is true. Thanks to yejun for working on this independently. - Better volume level continuity. In recent versions of iOS (11.2) and mac OS (10.13.2), when play is resumed after a pause, the volume level is not always restored, and, if software volume control is being used, Shairport Sync plays at full volume. This issue has been addressed by storing the last airplay volume setting when a play session ends and using it as a default when a new play session begins.
- Better mixer compatibility. A bug in the hardware volume control affected output devices that have hardware mixers but that do not allow the volume to be set in dB. One example is the Softvol plugin in ALSA. Shairport Sync failed silently when presented with such a device when hardware volume control is enabled: the volume events have no effect. The bug has been fixed by adding two missing lines of code to the
init()
function inaudio_alsa.c
. Thanks to Jakub Nabaglo for finding and fixing the bug. - Thanks to belboj, funtax, Janusz Kowalczyk, Mmoi-Fr, mistipen, artenverho, Jörg Krause and David Krmpotić for help with bug detection, investigation and repair.
Other Changes
clip
andsvip
metadata messages are now only generated for a play connection, not for all connections (e.g. connections that just enquire if the service is present).pfls
andprsm
metadata messages are less frequent, especially when a play session starts.- Shairport Sync now uses about an extra half megabyte of RAM for compatibility with TuneBlade's option to have a very long latency -- up to five seconds.
- Improvements in missing-packet resend request logic, and if an error occurs making the request, back off for half a second.
- Include the
-pthread
flag -- including the pthread library with-lpthread
isn't always enough. - Add optional timing annotations to debug messages -- see the new settings in the diagnostic stanza of the configuration file.
Updated Documentation
- Quick INSTALL for Raspberry Pi, CAR INSTALL and OPENBSD notes added.
- Improvements in the documentation relating to scripts -- thanks to Niklas Janz.
- Typo fixes! Thanks to corbinsantin and others.