Skip to content

feat(io0): real dual-vendor ASIO primary + capture-only compatibility probe - #770

Merged
masarray merged 10 commits into
mainfrom
feat/io0-dual-asio-capture-feasibility-20261118
Nov 18, 2026
Merged

masarray merged 10 commits into
mainfrom
feat/io0-dual-asio-capture-feasibility-20261118

Conversation

@masarray

@masarray masarray commented Nov 17, 2026 •

Copy link
Copy Markdown
Owner

IO-0 native Dual-ASIO independent capture compatibility — real probe, not product multi-device routing

Scope: native C++ feasibility executable for pinned Windows JUCE ASIO, alongside one existing primary ASIO class. This milestone is IO-0 ONLY, not IO-1/IO-2/IO-3. It answers whether vendor-A ASIO remains open and producing callbacks while vendor-B ASIO opens as capture-only with zero physical output channels. Test harness never processes PCM through FX/VST3; primary is intentionally SILENT and no mixer or GUI session is changed. Physical dual-vendor success is unproven until owner-authorized hardware test returns actual callback and signal evidence.

Concrete delivered source

  • tools/dual_asio_capture_probe.cpp: opt-in --probe "A ASIO" "B ASIO" 48000 256 5000 real JUCE AudioIODeviceType device opens, TWO explicit hardware callbacks from distinct ASIO factories, primary outputs cleared to zero and secondary capture-only reads finite/live signal; no second DSP graph, no default manager initialise/reopen, ASIO class registry attestation before/after, exact device/pin/rate/period readback, explicit failure on wrong device, driver refusal or output-channel substitution. --self-test is hardware free and the ONLY CTest mode.
  • engine/device/DualAsioCaptureProbePolicy.h: pure verified ASIO class + exact endpoint/pin masks physical admissibility predicate (no new PCM ring/ASRC or device state owner).
  • tests/dual_asio_capture_probe_policy_test.cpp: deterministic failures for missing/ambiguous/matching class, wrong endpoint, lost input/stereo out, unexpected secondary outputs, period/rate errors and all 9 combinations of 44.1/48/96 kHz using existing ClockBridgeSizing; existing AdaptiveClockBridge synthetic jitter/underflow/drift tests remain untouched.
  • CMakeLists.txt: Windows JUCE probe and native CTest with mandatory --self-test, pure cross-platform policy CTest.

Reuse: existing AsioRegistryIdentityProbe, AsioRegistrationPolicy, AsioPriorityDeviceManager, ClockBridgeSizing, and current AdaptiveClockBridge test suite. No FIFOs, ASRC, additional main app AudioDeviceManager, render owners or UI/MVVM/CI workflow modifications. Existing #767 remains merged. Overlapping active draft #768 is GUI-only and is not edited or merged.

Limitations, deliberately not claimed: no additional capture audio is routed to ChannelId / .smix yet, no ASIO+WASAPI capture probe yet, no independent output sink, no app DLL/installer toggle; IO-1 capture-only SPSC/ASRC integration is the next milestone. The test executable cannot stand in for genuine installed mixer multi-device playback. Hardware-vendor A/B FAT requires two devices and a known nonzero audio source; never auto-arm speakers. Do not launch this probe while the live app is using an ASIO driver.

CI: Fast native tests and Windows exact-SHA MSVC/CTest PENDING, physical test NOT RUN at branch creation. Use one /arsonmix-ci native <sha> after fast native PASS, no FAT installer requested.

Owner report: HASIL = real independently-opened dual-ASIO compatibility probe implementation and deterministic rejection policy. STATUS = KODE DIBUAT, BELUM DIUJI on initial commit. AMAN DIPAKAI? BELUM as multi-device mixer. TINDAKAN ANDA = TIDAK PERLU MELAKUKAN APA-APA. LANGKAH BERIKUTNYA = exact-head CI, then IO-1 only after feasibility and no second render confirmed.

Current exact-source handoff, 2026-11-18

@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Nov 17, 2026 •

Copy link
Copy Markdown

Deploying arsonmix with  Cloudflare Pages  Cloudflare Pages

Latest commit: fbb9443
Status: ✅  Deploy successful!
Preview URL: https://2a4a4e31.arsonmix.pages.dev
Branch Preview URL: https://feat-io0-dual-asio-capture-f.arsonmix.pages.dev

View logs

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native e001211

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native 089ae02

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native 741afa3

masarray commented Nov 18, 2026 •

Copy link
Copy Markdown
Owner Author

IO-0 native dual-ASIO capture — 2026-11-18 exact-HEAD checkpoint

HASIL: PR #770 contains a real pinned-JUCE primary ASIO A + zero-output capture-only ASIO B compatibility probe, driver-class preflight, exact negotiated driver/pin/rate/period verification, distinct callback counters, finite/nonzero capture PCM evidence, and fail-closed rejection. Existing ClockBridgeSizing, AdaptiveClockBridge tests, ASIO registry probe reused. This executable does NOT route B to ChannelId or use mixer DSP/VST3.

STATUS: KODE DIBUAT + FAST NATIVE DIUJI; PR DRAFT, UNMERGED. Current exact HEAD fbb94438b7605687600708e8bdac4a0daf430d8f, base 3fb4c17cc4e8a6d4c23ee3fd229aceb67e216be9.

Reason for previous MSVC failure: native run 44201697331 FAIL at tools/dual_asio_capture_probe.cpp:187-188, C2662: JUCE getCurrentSampleRate() and getCurrentBufferSizeSamples() are non-const methods. Fix committed in fbb94438b7605687600708e8bdac4a0daf430d8f: change local const auto* a,b to auto* a,b, no behavior change. The previous run did not reach native CTest.

Exact-SHA CI: Fast native PASS 44207241855. Required quick gate PASS. Newly requested complete Windows MSVC/CTest 44207500185 IN PROGRESS, not PASS/FAIL as of checkpoint. Physical dual vendor ASIO FAT NOT RUN. Cancelled older Windows attempts are not pass evidence. No installer prepared or published.

AMAN DIPAKAI? BELUM sebagai multi-device mixer or hardware-qualified dual-ASIO. Existing primary path and approved /preview/ remain unchanged. Physical probe is isolated and opt-in; outputs zero PCM; no other driver fallback or automatic arm.

TINDAKAN ANDA: TIDAK PERLU MELAKUKAN APA-APA.

Next: fix any further actual Windows compile/CTest failure, verify full native tests and HEAD/main reconciliation before Ready/Merge. IO-1 is a separate next implementation milestone using original AdaptiveClockBridge: B capture producer + ASRC into single existing primary native ChannelId graph, explicit DeviceKey/physical pin + generation, no second renderer. IO-2 session binding and IO-3 secondary sinks remain NOT IMPLEMENTED.

CI audit (NO CI workflow changes in this PR): an older Fast UI run took ~36s and full Chromium ~665s; system dependencies dominated about 233s. No after-measurement or runner-minute saving exists; no cosmetic or weakening workflow patch.

Copy link
Copy Markdown
Owner Author

/arsonmix-ci native fbb9443

@masarray
masarray marked this pull request as ready for review November 18, 2026 01:57
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Nov 18, 2026 •

Copy link
Copy Markdown
Codex Review Summary: ✅ Completed

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-11-18T02:00:12.249165Z fbb9443 Draft marked ready
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@masarray
masarray merged commit 3d133d8 into main Nov 18, 2026
19 checks passed

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: fbb94438b7

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment on lines +195 to +198
const bool ok=verified==Policy::Verdict::ok&&
primary.playing()&&capture.playing()&&aCalls>0&&bCalls>0&&
bSignal>0&&capture.counters.nonfinite.load()==0&&
!primary.counters.violated.load()&&!capture.counters.violated.load();

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Require primary callback progress after starting capture

If opening capture B stops primary A's hardware callbacks, this probe can still report PHYSICAL_PROBE_PASS: aCalls includes callbacks received before B opened, and JUCE's isPlaying() only checks whether the ASIO object and callback pointer exist, not whether callbacks continue (JUCE 8.0.15 implementation). This incorrectly qualifies precisely the simultaneous-driver incompatibility the probe should detect. Record counter baselines after B starts and require both endpoints to keep advancing throughout the observation interval. AGENTS.md requires independent physical evidence for ASIO+ASIO success.

AGENTS.md reference: AGENTS.md:L37-L37

Useful? React with 👍 / 👎.

Comment on lines +49 to +51
if (r.primary.sameDriverClass(r.capture) ||
r.primaryName == r.captureName)
return Verdict::sameDriverClass;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P2 Badge Reject matching CLSIDs even when registry keys differ

When two differently named ASIO registrations point to the same CLSID, this preflight accepts them because Identity::sameDriverClass() requires both the registry key and CLSID to match. A local policy reproduction with different names/keys but identical CLSIDs returns IO0_EXACT_ASIO_READBACK. Such aliases instantiate the same driver class, so they do not satisfy this probe's distinct-class prerequisite and may produce misleading dual-vendor qualification. Compare canonical CLSIDs directly for this rejection, while retaining the stricter registration comparison for before/after identity checks. AGENTS.md requires driver identity verification and separately proven multi-device compatibility.

AGENTS.md reference: AGENTS.md:L37-L37

Useful? React with 👍 / 👎.

Copy link
Copy Markdown
Owner Author

IO-0 — OWNER CLOSURE / MERGED MAIN (18 November 2026, WIB)

HASIL: Executable Windows ARMixDualAsioCaptureProbe dan fail-closed dual-ASIO identity/pin/rate/period/callback policy sudah masuk main. Probe manual ini membuka driver ASIO utama A dan driver ASIO capture-only B secara eksplisit, memeriksa kedua callback serta sinyal masuk B, tanpa DSP/VST3 kedua, tanpa speaker output dari B, tanpa mengganti device otomatis. Existing ClockBridgeSizing & AdaptiveClockBridge dipakai kembali.

STATUS NYATA: KODE DIBUAT → KODE DIUJI → MERGED MAIN. PR #770 ditutup MERGED. Commit final main 3d133d8614ca6f2b4c231e96cdc2613bf23ddb90. Exact tested PR HEAD fbb94438b7605687600708e8bdac4a0daf430d8f.

BUKTI: Windows MSVC / Full native run 44207500185 PASS, 102/102 CTest including IO0DualVendorCaptureDriverIdentityAndPhysicalMasks and IO0DualAsioNativeProbeNeverOpensDriversInCI. Required merge gate SUCCESS before merge. Exact SHA read and stable main rechecked before merge, and main after merge verified identical to squash SHA. Physical two-vendor ASIO FAT NOT RUN. No updated installer / user-facing IO-1 capture routing was delivered. New main push native tests are separate post-merge checks and were not the pre-merge proof.

AMAN DIPAKAI? Existing single-device mixer unchanged and preserved; BELUM safe to claim dual-device mixer input support or different-vendor ASIO hardware success. IO-0 probe needs an attended 2-interface FAT and a known captured signal, with speakers disconnected/muted; no automatic speaker rearm.

TINDAKAN ANDA: TIDAK PERLU MELAKUKAN APA-APA at this stage.

LANGKAH BERIKUTNYA: IO-1 native capture producer-only adapter under separate milestone/PR: reuses preallocated AdaptiveClockBridge SPSC/ASRC, one secondary clock-domain device, primary callback the only ChannelId/DSP/VST3 render owner. IO-2 (DeviceKey+physical pin -> ChannelId, .smix offline intent), IO-3 additional output sinks, manufacturer-A/B FAT separately; never claim them completed from IO-0. No MVVM/GUI/CSS changes.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant