Closed bertrand-lupart closed 2 years ago
Thanks for the interesting post. Hmm -- can't see anything untoward there alright. Could you enable statistics, maybe turn the log verbosity down to 2 and let it run for a while (say about three minutes after the audio stops) -- we might get to see if audio is actually arriving at Shairport Sync.
YouTube on iOS has always been problematic from the AirPlay perspective; haven't tried it from an AppleTV.
Same issue here, only started appearing a few days ago, maybe with the new version of tvOS. Youtube sound from apple tv stops after a second or so. Sounds from any other app from apple tv work fine though. Perhaps its related to dynamic adaptive streaming of youtube.
Hello Mike, thank you for this great application. I have also the same issue with youtube app on appletv, other apps like Netflix working like a charm. First i tried different settings, ignore_volume_control, keep_dac_busy, disable_synchronisation ... youtube still not properly working Next step was to switch to libalac and self compiled shairport, but this issue still exist. Its also no matter is a DAC or internal sound card will be used. Also audio configuration on apple tv (16bit, only stereo, reset airplay calibration) will not help. Do you have any other idea?
My log is attached.
[Edit: log file attached as file instead of text paste]
Just commenting that I also have this same issue and that it only happens with the Youtube Apple TV app.
Thanks for the posts, @andru79 and @jacobxdouglas and @bertrand-lupart. I don't have a recent Apple TV, I'm afraid, so I've let this slide. @andru79's log file shows nothing unusual at all -- in fact it shows output for a longish play session. Similarly, I can't see anything peculiar about @bertrand-lupart's log. As soon as I can get hold of an ATV, I'll have a look at this. It really does seem to be only the YouTube Apple TV App.
According to this thread: https://discussions.apple.com/thread/251934651 it seems to work with Airplay 2. I have the same issue both with shairplay-sync and and while using an older Apple TV that does not support Airplay 2 as a receiver.
According to this thread: https://discussions.apple.com/thread/251934651 it seems to work with Airplay 2. I have the same issue both with shairplay-sync and and while using an older Apple TV that does not support Airplay 2 as a receiver.
Thanks for that. More and more, it looks like a fault in the YouTube app.
Also facing this issue. Only happens with YouTube tvOS app.
This was always an issue for me with the Youtube tvOS app. Now it just started on the Youtube TV app which prevents me from watching TV with any sound. Is the fix here to update to airplay 2?
Just clarifying, when it is said it only happens with Airplay 2, that is saying that Shairport sync is only Airplay 1, rather than saying YouTube needs to be on an airplay 2 device e.g. AppleTV 4.
Maybe interesting to know is that the youtube kids tvOS app does works (for same content). Surprised that this bug is still present after months, will all airplay 1 users have this problem?
@mikebrady Hereby some additional verbose logging (not sure if it contains any error related info).
After a short idle period and commercial: 22:11:13 the actual video starts including audio 22:11:23 audio drops (video keeps running)
shairport-sync-youtube-verbose.log
YOUTUBE APP Version: 2.06.21.00/web_20210330_00_RC00 Device: TV (PLATFORM_DETAILS_OTT), Apple/AppleTV5-3/0, Cobalt (21.lts.4.300527-gold),AppleTV(14.5)
Shairport-sync software version: "3.3.7-libdaemon-OpenSSL-Avahi-dns_sd-ALSA-stdout-pipe-soxr-metadata-mqtt-sysconfdir:/etc"
I hope this logging provides some information, maybe something we can report back to YouTube. If I could try something out, please let me know.
Just adding I see this - tvOS 4.7.
pi@raspberrypi:~ $ shairport-sync --version 3.3.8-libdaemon-OpenSSL-Avahi-ALSA-soxr-sysconfdir:/usr/local/etc
Only with YouTube.
Thanks. Pretty sure it's an AirPlay 1 issue. In case you missed it, Shairport Sync offers a limited AirPlay 2 functionality on the development
branch.
[UPDATE - no audio from my Apple TV, but works from my iPhone. Both 14.7 - weird]
Thanks. Just rebuilt for AirPlay 2 to test - but I must have done something wrong as I'm not getting any audio output now (using Movie app to test, not YouTube). Works fine if I switch back to the earlier version of the executable and I've checked the volume is turned up.
pi@raspberrypi:~/d/shairport-sync $ ./shairport-sync -vu
0.002222908 "shairport.c:1823" Started!
0.000111510 "shairport.c:1826" Started in Airplay 2 mode!
0.000064114 "shairport.c:1868" software version: "4.0-dev-305-g099d21d3-AirPlay2-libdaemon-OpenSSL-Avahi-ALSA-soxr-metadata-dbus-sysconfdir:/usr/local/etc"
0.000026146 "shairport.c:1874" log verbosity is 1.
0.000072292 "audio_alsa.c:1015" alsa: alsa_maximum_stall_time of 0.200000 sec.
0.000063645 "audio_alsa.c:1302" alsa: disable_standby_mode is "never".
0.000022500 "audio_alsa.c:1304" alsa: disable_standby_mode_silence_threshold is 0.040000 seconds.
0.000023646 "audio_alsa.c:1306" alsa: disable_standby_mode_silence_scan_interval is 0.004000 seconds.
0.000035000 "audio_alsa.c:1345" alsa: output device name is "hw:0".
0.000315103 "shairport.c:1903" libsodium initialised.
0.000030677 "shairport.c:1930" disable resend requests is off.
0.000022083 "shairport.c:1934" diagnostic_drop_packet_fraction is 0.000000. A value of 0.0 means no packets will be dropped deliberately.
0.000025104 "shairport.c:1935" statistics_requester status is 0.
0.000021302 "shairport.c:1937" daemon status is 0.
0.000029583 "shairport.c:1938" daemon pid file path is "/var/run/shairport-sync/shairport-sync.pid".
0.000022761 "shairport.c:1940" rtsp listening port is 7000.
0.000021718 "shairport.c:1941" udp base port is 6001.
0.000020990 "shairport.c:1942" udp port range is 10.
0.000020677 "shairport.c:1943" player name is "knigma-office-audio".
0.000021041 "shairport.c:1944" backend is "alsa".
0.000020573 "shairport.c:1945" run_this_before_play_begins action is "(null)".
0.000021719 "shairport.c:1946" run_this_after_play_ends action is "(null)".
0.000021198 "shairport.c:1947" wait-cmd status is 0.
0.000020937 "shairport.c:1948" run_this_before_play_begins may return output is 0.
0.000021510 "shairport.c:1949" run_this_if_an_unfixable_error_is_detected action is "(null)".
0.000021563 "shairport.c:1950" run_this_before_entering_active_state action is "(null)".
0.000021354 "shairport.c:1951" run_this_after_exiting_active_state action is "(null)".
0.000021458 "shairport.c:1952" active_state_timeout is 10.000000 seconds.
0.000026302 "shairport.c:1953" mdns backend "(null)".
0.000020886 "shairport.c:1957" interpolation setting is "auto".
0.000021458 "shairport.c:1958" interpolation soxr_delay_threshold is 30.
0.000021250 "shairport.c:1959" resync time is 0.050000 seconds.
0.000022395 "shairport.c:1960" allow a session to be interrupted: 0.
0.000020782 "shairport.c:1961" busy timeout time is 0.
0.000020885 "shairport.c:1962" drift tolerance is 0.001995 seconds.
0.000022552 "shairport.c:1963" password is "(null)".
0.000020312 "shairport.c:1964" ignore_volume_control is 0.
0.000020782 "shairport.c:1968" volume_max_db is not set
0.000020156 "shairport.c:1970" volume range in dB (zero means use the range specified by the mixer): 0.
0.000022395 "shairport.c:1974" volume_range_combined_hardware_priority (1 means hardware mixer attenuation is used first) is 0.
0.000022552 "shairport.c:1976" playback_mode is 0 (0-stereo, 1-mono, 1-reverse_stereo, 2-both_left, 3-both_right).
0.000022240 "shairport.c:1977" disable_synchronization is 0.
0.000020937 "shairport.c:1978" use_mmap_if_available is 1.
0.000021042 "shairport.c:1980" output_format automatic selection is enabled.
0.000020937 "shairport.c:1984" output_rate automatic selection is enabled.
0.000021094 "shairport.c:1988" audio backend desired buffer length is 0.200000 seconds.
0.000023125 "shairport.c:1990" audio_backend_buffer_interpolation_threshold_in_seconds is 0.120000 seconds.
0.000023594 "shairport.c:1991" audio backend latency offset is 0.000000 seconds.
0.000022812 "shairport.c:1993" audio backend silence lead-in time is "auto".
0.000021094 "shairport.c:1997" zeroconf regtype is "_raop._tcp".
0.000021093 "shairport.c:1998" decoders_supported field is 1.
0.000021094 "shairport.c:1999" use_apple_decoder is 0.
0.000020729 "shairport.c:2000" alsa_use_hardware_mute is 0.
0.000021146 "shairport.c:2004" no special mdns service interface was requested.
0.000064323 "shairport.c:2008" configuration file name "/usr/local/etc/shairport-sync.conf" resolves to "/usr/local/etc/shairport-sync.conf".
0.000027395 "shairport.c:2014" metadata enabled is 1.
0.000021563 "shairport.c:2015" metadata pipename is "/tmp/shairport-sync-metadata".
0.000022031 "shairport.c:2017" metadata socket address is "(null)" port 0.
0.000021510 "shairport.c:2018" metadata socket packet size is "500".
0.000021354 "shairport.c:2019" get-coverart is 1.
0.000020157 "shairport.c:2037" loudness is 0.
0.000020468 "shairport.c:2038" loudness reference level is -20.000000
0.000229322 "rtsp.c:3194" metadata pipe name is "/tmp/shairport-sync-metadata".
0.013436514 "dbus-service.c:1054" *warning: could not acquire a Shairport Sync native D-Bus interface "org.gnome.ShairportSync.i9519" on the system bus.
1.489757295 "shairport.c:212" "soxr" interpolation has been chosen.
32.398243798 "rtsp.c:2307" Connection 1. Buffered Audio Stream Detected.
0.008001845 "audio_alsa.c:900" Lowest dB value is a mute
0.002661240 "audio_alsa.c:529" alsa: output format chosen is "S32".
0.000176613 "audio_alsa.c:569" alsa: output speed chosen is 44100.
Thanks. I can think of two possibilities:
nqptp
, so it's worth checking that it is installed and running.Would either one of those situations apply?
[Update] Yes, AFAWK AirPlay 2 support only works from macOS or iOS. It partly works from a HomePod, and we believe that it does not work from an Apple TV. Apologies if it is therefore inapplicable in your situation.
This issue has been inactive for 60 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.
..
This issue has been inactive for 60 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.
Shairport Sync now seems to work well (when built for AirPlay 2) on AppleTV. Make sure you are using the latest development
version of Shairport Sync and the latest development
branch of nqptp
.
Thanks.
This issue has been inactive for 45 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.
has a fix for this been released? @mikebrady
has a fix for this been released? @mikebrady
AirPlay 2 support in still only the development branch, but that fix is in it and seems to be working well. Tested on the YouTube app on an Apple TV 4K fully up to date.
This issue has been inactive for 45 days so will be closed 7 days from now. To prevent this, please remove the "stale" label or post a comment.
Hello,
I'm using shairport-sync on a Raspberry Pi plugged into a stereo with the jack port, and it works great ! iPhone, MacBook, Apple TV… can play sound to the stereo via shairport-sync. Thank you for that !
Everything's working perfectly, except for the YouTube app on the Apple TV : the first second on each stream comes to the stereo, then silence. First second of each ad, each video, or each time the video is time warped using the seek bar.
Everything's up to date :
Interestingly, no sound issue streaming from the YouTube iOS app : YouTube iOS -> Airplay 2 -> Apple TV -> Airplay -> shairport-sync
Can't find any error in the shairport-sync logs below (video launched at 21:41:00)
My guess something's wrong with YouTube tvOS app, since other people are reporting issues with Airplay speakers :
But I'd be happy to help troubleshoot if needed.
Thank you,