[mythtv-users] Airplay Sync with Multiple Devices - Mythtv only one out of sync
Bob H.
bob.havlin at gmail.com
Wed Dec 19 06:25:26 UTC 2012
On 12/18/2012 9:52 PM, Jean-Yves Avenard wrote:
> All I can say is this:
> on my system, using ALSA, sync is perfect between all my system.
>
> I have to admit that I only work as hard as I could to get my system
> in sync. And to my defence, that's more than anyone did because none
> of the other AirPlay implementation (other than apple) actually care
> about audio latencies, they just play the audio as soon as they
> receive it.
>
> In your log, you have buffer underruns, increase the ALSA audio buffer
> as probably mentioned in the log if you run mythfrontend with -v
> audio.
> audio buffer underruns will keen your latency and throws off any
> calculations performed.
>
Thanks for all the help!!
I followed your suggestion to do what the logfile said (duh) and
increased the buffer with:
echo 192 | sudo tee /proc/asound/card0/pcm0p/sub0/prealloc
previously it was set to 64.
That seemed to help quite a bit, but occasionally it falls out again.
Strange that the frontend seems to know that it is out of sync as per
the "diffts", but does not correct it.
Any idea how to go about getting it to make a "diffts" correction if it
gets greater than say 100ms?
--- logfile snippet ---
Session: 1
Content-Type: text/parameters
Content-Length: 44
User-Agent: iTunes/11.0.1 (Windows; Microsoft Windows 7 x64 Home Premium
Edition Service Pack 1 (Build 7601)) AppleWebKit/536.27.1
Client-Instance: 7C8434C066EC100F
DACP-ID: 7C8434C066EC100F
Active-Remote: 2685481341
progress: 4249176165/4253472753/4259697249
2012-12-18 22:13:33.325767 D RAOP Conn: Header(192.168.2.151) =
SET_PARAMETER rtsp://192.168.2.151/3438712732 RTSP/1.0
2012-12-18 22:13:33.325784 D RAOP Conn: Header(192.168.2.151) = CSeq: 24
2012-12-18 22:13:33.325798 D RAOP Conn: Header(192.168.2.151) = Session: 1
2012-12-18 22:13:33.325811 D RAOP Conn: Header(192.168.2.151) =
Content-Type: text/parameters
2012-12-18 22:13:33.325825 D RAOP Conn: Header(192.168.2.151) =
Content-Length: 44
2012-12-18 22:13:33.325849 D RAOP Conn: Header(192.168.2.151) =
User-Agent: iTunes/11.0.1 (Windows; Microsoft Windows 7 x64 Home Premium
Edition Service Pack 1 (Build 7601)) AppleWebKit/536.27.1
2012-12-18 22:13:33.325864 D RAOP Conn: Header(192.168.2.151) =
Client-Instance: 7C8434C066EC100F
2012-12-18 22:13:33.325877 D RAOP Conn: Header(192.168.2.151) =
DACP-ID: 7C8434C066EC100F
2012-12-18 22:13:33.325891 D RAOP Conn: Header(192.168.2.151) =
Active-Remote: 2685481341
2012-12-18 22:13:33.326188 D RAOP Conn: Content(44) = progress:
4249176165/4253472753/4259697249
2012-12-18 22:13:33.326228 D RAOP Conn: Sending(17): RTSP/1.0 200 OK
2012-12-18 22:13:33.326248 D RAOP Conn: text/parameters: name=progress
parem=4249176165/4253472753/4259697249
2012-12-18 22:13:33.326269 I RAOP Conn: Progress: 01:37/03:58
2012-12-18 22:13:33.326279 D RAOP Conn: Sending(25): Server:
AirTunes/130.14
2012-12-18 22:13:33.326288 D RAOP Conn: Sending(6): CSeq:
2012-12-18 22:13:33.326295 D RAOP Conn: Sending(2): 24
2012-12-18 22:13:33.326302 D RAOP Conn: Sending(2):
2012-12-18 22:13:33.326310 D RAOP Conn: Sending(2):
2012-12-18 22:13:33.326387 D RAOP Conn: Finished SET_PARAMETER 24 , Send: 1
2012-12-18 22:13:33.424061 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:13:33.424080 D RAOP Conn: SYNC: cur:96449635
next:96451643 time:18446744072397499504
2012-12-18 22:13:33.424156 D RAOP Conn: Queue=127 buffer=732ms
ideal=2008ms diffts:-281ms
2012-12-18 22:13:34.422709 E RAOP Conn: Audio discontinuity seen.
Played 38151 (96450629) expected 37964
2012-12-18 22:13:34.429966 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:13:34.430007 D RAOP Conn: SYNC: cur:96450640
next:96452648 time:18446744072397500509
2012-12-18 22:13:34.430048 D RAOP Conn: Drop 1 packets
2012-12-18 22:13:34.430076 D RAOP Conn: Queue=251 buffer=2000ms
ideal=2008ms diffts:-18ms
2012-12-18 22:13:34.430174 E RAOP Conn: Audio discontinuity seen.
Played 38153 (96450645) expected 38152
2012-12-18 22:13:34.432796 I AO: OutputAudioLoop: Play Event
2012-12-18 22:13:34.432829 I ALSA: WriteAudio: buffer underrun
2012-12-18 22:13:35.436001 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:13:35.436042 D RAOP Conn: SYNC: cur:96451646
next:96453654 time:18446744072397501516
2012-12-18 22:13:35.436097 D RAOP Conn: Queue=154 buffer=2000ms
ideal=2008ms diffts:-23ms
2012-12-18 22:13:36.441932 D RAOP Conn: Receiving SYNC packet
...
2012-12-18 22:20:19.488302 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:19.488342 D RAOP Conn: SYNC: cur:4863635 next:4865643
time:18446744072397905568
2012-12-18 22:20:19.488398 D RAOP Conn: Queue=220 buffer=2002ms
ideal=2008ms diffts:-555ms
2012-12-18 22:20:20.493354 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:20.493395 D RAOP Conn: SYNC: cur:4864641 next:4866649
time:18446744072397906573
2012-12-18 22:20:20.493454 D RAOP Conn: Queue=220 buffer=2001ms
ideal=2008ms diffts:-556ms
2012-12-18 22:20:21.499324 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:21.499363 D RAOP Conn: SYNC: cur:4865647 next:4867655
time:18446744072397907579
2012-12-18 22:20:21.499415 D RAOP Conn: Queue=220 buffer=2001ms
ideal=2008ms diffts:-556ms
2012-12-18 22:20:22.505355 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:22.505396 D RAOP Conn: SYNC: cur:4866653 next:4868661
time:18446744072397908585
2012-12-18 22:20:22.505454 D RAOP Conn: Queue=220 buffer=2001ms
ideal=2008ms diffts:-556ms
2012-12-18 22:20:23.511407 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:23.511448 D RAOP Conn: SYNC: cur:4867658 next:4869666
time:18446744072397909591
2012-12-18 22:20:23.511503 D RAOP Conn: Queue=220 buffer=2001ms
ideal=2008ms diffts:-555ms
2012-12-18 22:20:24.516505 D RAOP Conn: Receiving SYNC packet
2012-12-18 22:20:24.516549 D RAOP Conn: SYNC: cur:4868664 next:4870672
time:18446744072397910596
More information about the mythtv-users
mailing list