Repository navigation
Conversation
Upstream now reads the host clock from CLOCK_MONOTONIC_RAW on Linux so NTP slew no longer drags the measured time offset across the hard-sync threshold. Our ALSA sink stamped notify_audio_played() with its own steady_clock, which after this bump sits in a different clock domain than the sync task, so it moves to the new SendspinClient::now_us(). Co-Authored-By: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01XKijnP8uVFcwYBESpoUeYP
|
This PR changes two C++ files (
Proposed patch, not applied here: I am deliberately not pushing that here. It is a security-relevant dependency change that belongs in its own PR rather than bundled into a C++ pin bump, and this environment has no Elixir toolchain, so I cannot run Everything else on this PR is green or still running; the C++ build and patch re-validation are covered in the description. Generated by Claude Code |
Pin
b95cf854a784ed308b1f8fe9697f414b02768ddd(v0.9.5) →985fba57afb0462b520ab9ce974d1860858ed685(main, post-v0.9.5, upstream #210)No tag newer than v0.9.5 exists upstream, so this pins branch HEAD. Three commits land in the range.
Why this matters
The motivating change is upstream #208, which moves
platform_time_us()toCLOCK_MONOTONIC_RAWon Linux.std::chrono::steady_clockisCLOCK_MONOTONIC, which NTP slews; aiosendspin already timestamps on the raw clock, so while the host's time daemon corrects the system clock the measured offset moves at the slew rate, outruns the time filter's drift model, and playback hard-corrects. Upstream measured a 31 ms divergence from one systemd-timesyncd sync, and repeated loss of sync without the fix. That is exactly the failure mode our rpi3 players would see on a device whose clock is being disciplined.#208 also adds
SendspinClient::now_us()so consumers can stamp in the library's clock domain — and that is a required change on our side, not an optional one.AlsaPipeSinkstampednotify_audio_played()with its ownsteady_clock; after the bump that reading sits in a different clock domain than the sync task, which would reintroduce the same drift from the consumer side. This PR therefore also changesc_src/sendspin_player/src/alsa_pipe_sink.cppto callSendspinClient::now_us(). It is one line plus a comment, and the bump is not safe to take without it.The other two commits are inert for us: #210 adds a Windows clang-cl path (the Linux branch of
cmake/host.cmakeandnetwork_info.cpponly had includes regrouped and warning flags moved behind a non-MSVCelse()), and #206 is a dependabot bump of a release-drafter GitHub Action.Patch 0003 re-validation
patch -p1 --dry-runagainst upstream at the new SHA applies cleanly with no fuzz or offset — no regeneration needed. The hook is not absorbed upstream; the markers are absent before the patch and present after. The CMake configure-timeassert_patch_markersgate passed on both markers, andsendspin_host_listener_boundresolves in the linked binary.Host build
Verified in the cloud env (Ubuntu 24.04, cmake 3.28.3, g++ 13.3.0, libasound2-dev):
cmake -S c_src/sendspin_player -B /tmp/ssp-build && cmake --build /tmp/ssp-build -jconfigures and builds to a linkedsendspin_player, with no warnings from our four translation units under-Wall -Wextra.Only
CMakeLists.txtandalsa_pipe_sink.cppchange; nopriv/binaries or build output are committed.Before release
Firmware needs a rebuild and rpi3 hardware validation — the clock change is a timing-path change, so the thing to watch on-device is sync behaviour across an NTP correction, not just that audio plays. No other open PR touches the sendspin-cpp pin.
Generated by Claude Code