Mike Brady
|
33dd3037da
|
Wait a little longer to allow the master clock to stabilise.
|
2021-06-24 10:45:32 +01:00 |
|
Mike Brady
|
ce49f3a9fd
|
Quieten the PTP informatin age checking code.
|
2021-06-23 17:54:51 +01:00 |
|
Mike Brady
|
861455f703
|
Add some information about the length of time a new clock master has been monitored for ("history") and warn if the PTP information hasn't been updated for more than a second (not extensively tested).
|
2021-06-23 12:18:04 +01:00 |
|
Mike Brady
|
e925e196c8
|
Changes to allow it to compile in FreeBSD and fix a few issues that were picked up by clang 10.
|
2021-06-22 13:49:11 +01:00 |
|
Mike Brady
|
ad3412f5c2
|
Ensure a new master clock is at least 1.1 seconds in mastership before using it. Remember that the mastership can be backdated.
|
2021-06-17 18:17:24 +01:00 |
|
Mike Brady
|
c37ee4542d
|
Add code to skip packets of buffered audio that are late or too early.
|
2021-06-09 19:35:08 +01:00 |
|
Mike Brady
|
f6a9f634c7
|
Accept a new master clock immediately. Don't truncate the first three blocks if it's a normal start. Hacky.
|
2021-06-06 15:53:55 +01:00 |
|
Mike Brady
|
7a26139c44
|
Shorten some arbitrary delays, quieten some debug messages, add (and comment out) disgnostic code to introduce a timing error. Make the buffer size 0.4 sec -- so that if a timing error of 150 ms is detected, enough frames are immediately available to be used.
|
2021-06-03 09:24:26 +01:00 |
|
Mike Brady
|
8bee92a4e6
|
Clean up the statistics output to make it provide information for the stream type. Parameterise it so that it's a bit easier to manage.
|
2021-06-02 17:17:54 +01:00 |
|
Mike Brady
|
5b8d76cfbe
|
When the master clock returns to what the real anchor clock is, the difference between the actual and estimate is calculated and logged. Might have to actually use it...
|
2021-06-01 22:30:31 +01:00 |
|
Mike Brady
|
deeabbfbc5
|
Quieten a rather chatty message.
|
2021-06-01 15:24:31 +01:00 |
|
Mike Brady
|
c5dafbd28b
|
Remember the original anchor information so that if the master clock become equal to it in the future, it can be restored to those exact numbers and eliminate any intervening approximations. Add some diagnostics.
|
2021-06-01 14:51:17 +01:00 |
|
Mike Brady
|
d4ea91aa65
|
Rough and hacky but works with the bit depth of the output DAC to automatically choose the correct AAC decoding sample size. Allocation of rotating buffers is fixed and profligate.
|
2021-06-01 08:56:47 +01:00 |
|
Mike Brady
|
ac515bbfa3
|
Deal with the possibility that the anchor information can be changed suddenly at the start of a Buffered Audio play. If the anchor info changes before the local_anchor info is mature enough (5 seconds), invalidate the local anchor info to force it to be immediately updated with the new anchor info.
|
2021-05-31 09:49:15 +01:00 |
|
Mike Brady
|
5e498173e1
|
Add a little information and remove a little ambiguity from a diagnostic message about anchor and master clocks especially relevant in Realtime Audio streams.
|
2021-05-30 12:12:40 +01:00 |
|
Mike Brady
|
4b5e9787b7
|
Log information when anchor or master clock changes occur.
|
2021-05-30 12:04:06 +01:00 |
|
Mike Brady
|
a109b587ec
|
Flush seems to be working properly and reliably. Some audio glitches removed too by dropping the first two AAC blocks of any passage. Crude. Flush diagnostic linked list stuff left in place.
|
2021-05-30 11:17:06 +01:00 |
|
Mike Brady
|
2ea28c0661
|
Much better flushing. Delayed flushing only works for one delay. Noice artifacts removed when skipping. Pretty solid.
|
2021-05-29 21:24:33 +01:00 |
|
Mike Brady
|
7c68f97d7f
|
flaky but some interesting stuff
|
2021-05-29 15:59:11 +01:00 |
|
Mike Brady
|
9cf4ef032d
|
Improving the flush behaviour.
|
2021-05-29 10:54:44 +01:00 |
|
Mike Brady
|
2986b282d3
|
Does pretty well with flushing. Sometimes misses a flush on a repeat one.
|
2021-05-28 22:20:11 +01:00 |
|
Mike Brady
|
e258cca33a
|
recognise two types of flush -- one with from and until information, the other with just until information. A flush with "with" information is not followed by a new set anchor, whereas a flush without the " with" information is alwasy followed by a new setanchor.
|
2021-05-28 19:16:37 +01:00 |
|
Mike Brady
|
f4ba81ec5f
|
remove redundant item
|
2021-05-26 19:36:31 +01:00 |
|
Mike Brady
|
637c8132e9
|
Move initial delay when using a new bus master to rtp.c and wait, if possible, whenever a new master comes along, to allow it to settle before using it.
|
2021-05-26 18:12:45 +01:00 |
|
Mike Brady
|
26ce13d511
|
a slightly more rational clock handling regime, I hope. Wait for 400 ms when a clock becomes master. Wait five seconds when you get a new master clock.
|
2021-05-26 16:48:25 +01:00 |
|
Mike Brady
|
77e70e497f
|
tighten up on the availability of a clock before feeding audio into the player.
|
2021-05-16 13:02:19 +01:00 |
|
Mike Brady
|
e41795f4da
|
clang
|
2021-05-13 20:59:38 +01:00 |
|
Mike Brady
|
c7bdc2c409
|
Tidy up a message.
|
2021-05-13 20:58:03 +01:00 |
|
Mike Brady
|
2180c7147f
|
If a PTP clock isn't available, use existing timing data if it's still valid.
|
2021-05-13 20:12:12 +01:00 |
|
Mike Brady
|
a3a7fb4849
|
ask for at least 50 ms of a lead-in for buffered audio.
|
2021-05-12 11:32:18 +01:00 |
|
Mike Brady
|
fcf5c7f8d3
|
clang
|
2021-05-12 11:00:41 +01:00 |
|
Mike Brady
|
171001ffd8
|
fix calculation of offset with a negative offset
|
2021-05-12 10:59:33 +01:00 |
|
Mike Brady
|
3f77994948
|
more closely check for time information being available.
|
2021-05-11 18:52:02 +01:00 |
|
Mike Brady
|
2b88215f09
|
Clean up some of the sync timing. Ignore a flush if playing AP2. Set the requested lead time to zero.
|
2021-05-11 10:46:56 +01:00 |
|
Mike Brady
|
a563d5e847
|
Quieten some more debug messages. Fix a misleading clock status return.
|
2021-05-10 16:03:02 +01:00 |
|
Mike Brady
|
04c7f84564
|
Improve NQPTP clock diagnostics, tidy up some messages.
|
2021-05-10 14:16:57 +01:00 |
|
Mike Brady
|
829ea399fc
|
Player thread always gains play lock and keeps ut until terminated. Clean up termination code, add extra diagnistic information and quieten some debug messages.
|
2021-05-10 09:37:42 +01:00 |
|
Mike Brady
|
953ad8ac14
|
Move AP2 player termination code from handle_teardown into the player cleanup function so that cancelling the player thread cleans up properly.
|
2021-05-08 17:46:13 +01:00 |
|
Mike Brady
|
fd4cc98aba
|
Slightly better timing. Bumped version for ejurgensen's new pair_ap work.
|
2021-05-05 18:33:21 +01:00 |
|
Mike Brady
|
6a13062100
|
clang format
|
2021-05-02 14:35:31 +01:00 |
|
Mike Brady
|
04c0d97685
|
Resend requests now work in the AP1-compatible AP2 mode.
|
2021-05-02 14:33:47 +01:00 |
|
Mike Brady
|
c2940eb23b
|
works in AP1-compatible AP2 mode, but resend isn't working.
|
2021-05-02 12:49:41 +01:00 |
|
Mike Brady
|
a68f28ac2b
|
clang format
|
2021-05-01 14:09:38 +01:00 |
|
Mike Brady
|
5f1cbf6d20
|
store the latency so that the resend requst timing computations can be done correctly in the realtime streaming mode.
|
2021-05-01 11:49:24 +01:00 |
|
Mike Brady
|
61b6b5934d
|
check that the clock is valid and reduce the Buffered Audio lead time to 0.25 seconds
|
2021-05-01 11:03:45 +01:00 |
|
Mike Brady
|
91b85a0207
|
Working for Realtime Audio Streams
|
2021-04-30 14:55:11 +01:00 |
|
Mike Brady
|
6760bab493
|
Compile with AP2 flag set
|
2021-04-30 12:30:12 +01:00 |
|
Mike Brady
|
3a02b79a62
|
Update the mdns stuff to work with a string, update audio_alsa rtp.c, rtsp.c and shairport.c to build and work in AirPlay 1 but with AirPlay 2 code in place. Some of it is #defined out.
|
2021-04-30 09:29:30 +01:00 |
|
Mike Brady
|
bdfb1c6ed6
|
player.c compiles and everything builds and runs with the airplay 2 flag off. With airplay_2 flag on, rtp.c won't build, but we know that.
|
2021-04-29 16:51:29 +01:00 |
|
Mike Brady
|
8a73d5972c
|
rtp meged with lots of AP2 stuff still commented out. But it still works.
|
2021-04-29 15:04:50 +01:00 |
|