tvos: Apple TV target and playback spike #23

Merged
namillis merged 2 commits from spike/tvos into main 2026-11-18 04:07:48 +00:00
Owner

Phase 0 of LiveWire for Apple TV: a second app target that plays the pool with the iPhone app's KSPlayer code, plus the spike runner that tested it on Gabriel's Apple TV 4K (3rd gen).

What changed

  • project.yml: new LiveWireTV target and scheme (tvOS 18, me.namillis.livewire.tvos, KSPlayer 2.3.4, plain-http allowed, Personal Team signing for debug builds).
  • LiveWireTV/: a full-screen player with a status line, and TVSpikeExtras (-soak <id> <minutes>, -matchZap, -matchFrameRate on|off) for the device checks.
  • SpikeRunner works with either app model (SpikeHost) and writes its results to Caches.
  • Two #if os(iOS) guards in PlaybackController (AirPlay route, auto picture-in-picture).
  • LiveOptions.matchFrameRate, off by default: a stream never switches the TV's refresh rate unless the setting is on.
  • Fix for both apps: a live stream whose clock stops now reconnects after 10 s, whatever state KSPlayer reports. On the TV soak, a stream buffered once and then sat on a still picture for 12 minutes without reconnecting.

Results on the Apple TV (tvOS 27.3, Xcode 27.2)

  • Live: 8 of 11 test channels played, first frame 1.3–3.9 s. TNT, Sky Sports Main Event and ITV 1 were refused by their providers on three runs (they played in the Simulator an hour earlier).
  • Live Now: both games played. Catch-up (ESPN SportsCenter) played. Retry moved Fox News to another source.
  • Soak, 30 min on NBC 4: memory 24–88 MB and flat, thermal state nominal, no crash. With the fix, a dead source reconnected 3 times, then stopped with "This channel keeps freezing".
  • Match Content (TV setting on): with matching on, BBC One switched the TV to 25 Hz and NBC 4 back to 29.97 Hz. With matching off, no criteria were set and the TV never switched.

Not a goal

No TV UI beyond the player. Phase 1 (#24, stacked on this one) moves the shared code into Shared/.

Checks

  • LiveWireTV builds for the tvOS Simulator and the device.
  • iPhone scheme builds; LiveWireTests 68/68 pass.

Screenshot: BBC One playing in the tvOS Simulator (to be attached).

Phase 0 of LiveWire for Apple TV: a second app target that plays the pool with the iPhone app's KSPlayer code, plus the spike runner that tested it on Gabriel's Apple TV 4K (3rd gen). ## What changed - `project.yml`: new `LiveWireTV` target and scheme (tvOS 18, `me.namillis.livewire.tvos`, KSPlayer 2.3.4, plain-http allowed, Personal Team signing for debug builds). - `LiveWireTV/`: a full-screen player with a status line, and `TVSpikeExtras` (`-soak <id> <minutes>`, `-matchZap`, `-matchFrameRate on|off`) for the device checks. - `SpikeRunner` works with either app model (`SpikeHost`) and writes its results to Caches. - Two `#if os(iOS)` guards in `PlaybackController` (AirPlay route, auto picture-in-picture). - `LiveOptions.matchFrameRate`, off by default: a stream never switches the TV's refresh rate unless the setting is on. - Fix for both apps: a live stream whose clock stops now reconnects after 10 s, whatever state KSPlayer reports. On the TV soak, a stream buffered once and then sat on a still picture for 12 minutes without reconnecting. ## Results on the Apple TV (tvOS 27.3, Xcode 27.2) - Live: 8 of 11 test channels played, first frame 1.3–3.9 s. TNT, Sky Sports Main Event and ITV 1 were refused by their providers on three runs (they played in the Simulator an hour earlier). - Live Now: both games played. Catch-up (ESPN SportsCenter) played. Retry moved Fox News to another source. - Soak, 30 min on NBC 4: memory 24–88 MB and flat, thermal state nominal, no crash. With the fix, a dead source reconnected 3 times, then stopped with "This channel keeps freezing". - Match Content (TV setting on): with matching on, BBC One switched the TV to 25 Hz and NBC 4 back to 29.97 Hz. With matching off, no criteria were set and the TV never switched. ## Not a goal No TV UI beyond the player. Phase 1 (#24, stacked on this one) moves the shared code into `Shared/`. ## Checks - `LiveWireTV` builds for the tvOS Simulator and the device. - iPhone scheme builds; `LiveWireTests` 68/68 pass. Screenshot: BBC One playing in the tvOS Simulator (to be attached).
Adds the LiveWireTV tvOS target (tvOS 18, me.namillis.livewire.tvos) built on the
iPhone app's pool and playback code. SpikeRunner takes a SpikeHost protocol and
writes to Caches. TVSpikeExtras adds the soak and Match Content checks.
LiveOptions.matchFrameRate (off by default) stops streams setting display criteria.
On the Apple TV soak a stream buffered once, then showed a still picture for 12
minutes with no further state change, so the buffering timer never fired. A
2 s progress check now reconnects after 10 s without the clock moving.
Also sets the LiveWireTV target's signing team for device builds.
namillis deleted branch spike/tvos 2026-11-18 04:07:48 +00:00
Sign in to join this conversation.
No reviewers
No labels
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
namillis/LiveWireiOS!23
No description provided.