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
Mike Brady
a8caa0f913
Move latency calculations to rtp.c. Remove checks for infeasible latencies from player.c.
2021-04-28 13:03:27 +01:00
Mike Brady
ca56287254
Make the first output backend in the list of backends the default and make its name the default output_name. Clang-format everything
2020-09-03 09:53:13 +01:00
Mike Brady
320baa4db9
quieten some debug messages
2020-06-15 12:16:59 +01:00
Mike Brady
9d6adc6f1f
one less debug message.
2020-06-14 14:29:55 +01:00
Mike Brady
f89830eb2c
Send more timing sync requests at the start. The debug messages are a bit noisy.
2020-06-14 14:26:22 +01:00
Mike Brady
ead6cfc4ad
Emphasise one debug message
2020-06-14 09:49:10 +01:00
Mike Brady
19a7bd4969
quieten some debug messages
2020-06-12 10:10:26 +01:00
Mike Brady
f5eceff6f7
Store clock drift information for each client based on its IP. This is stored in RAM, not on disk. Used at the start of a new session until new clock drift data is ready.
2020-06-11 12:09:55 +01:00
Mike Brady
92074c2b96
add code to calculate the diffusion multiplier based on the ending diffusion multiplier and the number of entries.
2020-06-10 20:04:03 +01:00
Mike Brady
0517a233c1
Fix the recording of the sample count if it's less than the threshold. Use the last gradient / drift if the number of samples is less than the threshold.
2020-06-10 14:21:29 +01:00
Mike Brady
9f9b36c01f
Clean up and bug-fix the code for estimating remote-to-local clock drift using least squares linear regression. Use the estimated remote-to-local difference and the calculated drift instead of just using the difference estimated from the last-exchanged timing message.
2020-06-09 11:37:24 +01:00
Mike Brady
5decc1bb06
Make the pipe, hub and mqtt separate threads with their own metadata queues. If one blocks, no new metadata is sent to it and the others are unaffected.
2020-05-30 15:49:00 +01:00
Mike Brady
54d761ff7d
Clean up some of the wording and layout of the configuration file
...
Clean up and improve the way lead-in sillence is used to give a more accurate sync time to the first packet of audio.
Allow very good sync to occur with 0.3 seconds of lead-in silence.
Improve the use of the buffer offset.
Format some other files.
2020-05-18 16:55:09 +01:00
Mike Brady
40289ca6d3
functional with full removal of get_absolute_time_fp() but not quite starting correctly
2020-02-24 22:23:08 +00:00
Mike Brady
32427423af
update packet reception statistics to use nanosecond timing
2020-02-24 19:58:35 +00:00
Mike Brady
686fc2a5c1
Add missing frame status field, fix a bug with the first missing frame variable, expose the settings for resending, remove some commented out code.
2019-10-10 09:23:20 +01:00
Mike Brady
c8b0be30b4
find . \( -name \*.cpp -or -name \*.h -or -name \*.c \) -exec clang-format -i -style='{BasedOnStyle: llvm, IndentWidth: 2, ColumnLimit: 100}' '{}' \;
2019-06-19 19:06:54 +01:00
Mike Brady
9fd4a39729
check for a couple of divide-by-zero possiblities.
2019-05-19 13:53:25 +01:00
Mike Brady
223dfd7801
only need to ensure at least one packet has been received, it seems.
2019-04-02 16:33:30 +01:00
Mike Brady
40ed76b411
wait for packets to be received before starting to calculate the nominal remote input rate.
2019-04-02 16:29:17 +01:00
Mike Brady
1f45b8c006
allow calculation of nominal source frame rates even when the connection is error prone.
2019-04-02 15:37:38 +01:00
Mike Brady
89340f20c9
3.3 release candidate 0
2019-03-04 12:38:20 +00:00
Mike Brady
2e4428538d
Add an "active" mode that can time out after a period -- 10 seconds by default -- after play ends.
2019-01-21 21:43:55 +00:00
Mike Brady
1b3d64ce85
Quieten a debug message.
2019-01-08 12:59:04 +00:00
Mike Brady
e5452e5172
Make the idle timeout on the RTSP link the same as the overall timeout -- 30 seconds is a bit short. Add checks to the alsa interface timing -- 15 ms to write a packet of frames, 1 ms to ask for the delay.
2018-12-08 14:12:33 +00:00
Mike Brady
e49707e051
Ensure no pthread cancellation can occur during an ALSA-related call.
2018-12-03 12:44:57 +00:00
Mike Brady
a5c65ceced
Move UDP port cloure to the RTSP thread, don't allow calls to mdns_* to be cancelled. Remove usage of (p)select in rtsp thread handling.
2018-11-30 14:55:04 +00:00
Mike Brady
0eac2b9cb3
Move closing of ports to the player thread cleanup. They can be bound without the UDP threads ever having been called, so they must be closed when the player thread exits.
2018-11-29 22:03:49 +00:00
Mike Brady
4a5b0009a4
Quieten a debug message
2018-11-29 17:13:12 +00:00
Mike Brady
ca45d2ecbe
Clang formatted.
2018-11-29 12:18:07 +00:00
Mike Brady
c318796e55
Add an uncancellable usleep timer. Make the player and UDP thread cleanups uncancellable.
2018-11-29 11:37:56 +00:00
Mike Brady
7bf22b4265
Add some debug messages to closing the UDP ports.
2018-11-28 19:49:12 +00:00
Mike Brady
1cf28be647
Add SO_REUSEADDR to the UDP sockets. See if it makes any difference.
2018-11-28 19:39:11 +00:00
Mike Brady
22f3e3e318
Move watchdog to cover connection from start, not just from start of play. Start investigating UDP port allocation. Tidy up handling or RTSP write errors -- remove the pselect code from before a write.
2018-11-28 17:18:03 +00:00
Mike Brady
eaa98ea7d9
Quieten a few debug messages.
2018-11-27 17:40:07 +00:00
Mike Brady
3b4654df77
Make some alsa operation sequences un-cancellable. Make some cleanup sequences un-cancellable.
2018-11-24 22:28:52 +00:00
Mike Brady
998e7cea2c
clang-format
2018-11-24 11:16:57 +00:00
Mike Brady
d93aeec50a
Quieten a few debug messages.
2018-11-23 15:11:04 +00:00