FAILURE MAP
← Case archive

FA-49966 / PCM sample encoding / Open access

Pcm i2s delayed capture: one clock delay · case 01

Serial PCM captures the clock-delay bit as sample MSB.

Verified by executionVariant 1 · 8 checks per implementationDownload source bundle ↓JSON ↗

ROOT CAUSE

Serial PCM captures the clock-delay bit as sample MSB.

VERIFIED REPAIR

Use the stated conversion contract at one clock delay.

Unsuccessful approach: Skipping two clocks shifts away the actual sample sign bit.

Case contract

Capture a stipulated I2S-like slot with one delay clock, MSB-first signed PCM payload and explicit trailing slot bits; reject incomplete slots.

Why this case matters

Offline PCM interchange uses these exact bounded packet and sample representation decisions.

1 / The failure

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(slots, payload_bits, slot_bits):
    out=[]
    for bits in slots:
        field=bits[:payload_bits]
        if len(bits)<slot_bits or len(field)!=payload_bits:
            out.append(None)
            continue
        code=sum(bit<<(payload_bits-1-i) for i,bit in enumerate(field))
        sample=code-(1<<payload_bits) if field[0] else code
        tail=bits[1+payload_bits:slot_bits]
        out.append([sample,tail])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6)), [[-6, [0]], [7, [0]]])
check('oracle 2', solve(*([[0, 0, 0, 1, 1]], 3, 5)), [[1, [1]]])
check('oracle 3', solve(*([[1, 1, 1, 1]], 3, 5)), [None])
check('oracle 4', solve(*([], 4, 6)), [])
check('oracle 5', solve(*([[1, 0, 0, 0, 1, 1, 1]], 4, 6)), [[1, [1]]])
check('oracle 6', solve(*([[0, 1, 0]], 1, 3)), [[-1, [0]]])
check('oracle 7', solve(*([[0, 0, 1, 0, 0, 1]], 3, 5)), [[2, [0]]])
if N == 1: check('variant packet 1', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 2: check('variant packet 2', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 3: check('variant packet 3', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 4: check('variant packet 4', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 5: check('variant packet 5', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
oracle 1[[5, [0]], [-5, [0]]][[-6, [0]], [7, [0]]]Failed
oracle 2[[0, [1]]][[1, [1]]]Failed
oracle 3[None][None]Passed
oracle 4[][]Passed
oracle 5[[-8, [1]]][[1, [1]]]Failed
oracle 6[[0, [0]]][[-1, [0]]]Failed
oracle 7[[1, [0]]][[2, [0]]]Failed
variant packet 1[[5, [0]], [-5, [0]], [5, [0]], [-5, [0]]][[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]]Failed

SHA-256 / 6dd0b542b9ae2500cbd21f96a33b41e16f074b0911b6abb33a89aa8e64bdd7c6

2 / The unsuccessful fix

Exit 1
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(slots, payload_bits, slot_bits):
    out=[]
    for bits in slots:
        field=bits[2:2+payload_bits]
        if len(bits)<slot_bits or len(field)!=payload_bits:
            out.append(None)
            continue
        code=sum(bit<<(payload_bits-1-i) for i,bit in enumerate(field))
        sample=code-(1<<payload_bits) if field[0] else code
        tail=bits[1+payload_bits:slot_bits]
        out.append([sample,tail])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6)), [[-6, [0]], [7, [0]]])
check('oracle 2', solve(*([[0, 0, 0, 1, 1]], 3, 5)), [[1, [1]]])
check('oracle 3', solve(*([[1, 1, 1, 1]], 3, 5)), [None])
check('oracle 4', solve(*([], 4, 6)), [])
check('oracle 5', solve(*([[1, 0, 0, 0, 1, 1, 1]], 4, 6)), [[1, [1]]])
check('oracle 6', solve(*([[0, 1, 0]], 1, 3)), [[-1, [0]]])
check('oracle 7', solve(*([[0, 0, 1, 0, 0, 1]], 3, 5)), [[2, [0]]])
if N == 1: check('variant packet 1', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 2: check('variant packet 2', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 3: check('variant packet 3', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 4: check('variant packet 4', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 5: check('variant packet 5', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
oracle 1[[4, [0]], [-2, [0]]][[-6, [0]], [7, [0]]]Failed
oracle 2[[3, [1]]][[1, [1]]]Failed
oracle 3[None][None]Passed
oracle 4[][]Passed
oracle 5[[3, [1]]][[1, [1]]]Failed
oracle 6[[0, [0]]][[-1, [0]]]Failed
oracle 7[[-4, [0]]][[2, [0]]]Failed
variant packet 1[[4, [0]], [-2, [0]], [4, [0]], [-2, [0]]][[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]]Failed

SHA-256 / 6f510f603fa181e3aeafef96fb92146a29e8e016f3d3c96dd53713685665b256

3 / The verified repair

Exit 0
"""Failure Map reference implementation. Python standard library only."""
import json

N = 1
observations = []
def solve(slots, payload_bits, slot_bits):
    out=[]
    for bits in slots:
        field=bits[1:1+payload_bits]
        if len(bits)<slot_bits or len(field)!=payload_bits:
            out.append(None)
            continue
        code=sum(bit<<(payload_bits-1-i) for i,bit in enumerate(field))
        sample=code-(1<<payload_bits) if field[0] else code
        tail=bits[1+payload_bits:slot_bits]
        out.append([sample,tail])
    return out
def check(label, actual, expected):
    observations.append({"check": label, "actual": actual, "expected": expected, "passed": actual == expected})
check('oracle 1', solve(*([[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6)), [[-6, [0]], [7, [0]]])
check('oracle 2', solve(*([[0, 0, 0, 1, 1]], 3, 5)), [[1, [1]]])
check('oracle 3', solve(*([[1, 1, 1, 1]], 3, 5)), [None])
check('oracle 4', solve(*([], 4, 6)), [])
check('oracle 5', solve(*([[1, 0, 0, 0, 1, 1, 1]], 4, 6)), [[1, [1]]])
check('oracle 6', solve(*([[0, 1, 0]], 1, 3)), [[-1, [0]]])
check('oracle 7', solve(*([[0, 0, 1, 0, 0, 1]], 3, 5)), [[2, [0]]])
if N == 1: check('variant packet 1', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 2: check('variant packet 2', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 3: check('variant packet 3', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 4: check('variant packet 4', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
if N == 5: check('variant packet 5', solve(*[[[0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0], [0, 1, 0, 1, 0, 0], [1, 0, 1, 1, 1, 0]], 4, 6]), [[-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]], [-6, [0]], [7, [0]]])
print(json.dumps({"observations": observations, "passed": all(x["passed"] for x in observations)}, ensure_ascii=False))
raise SystemExit(0 if all(x["passed"] for x in observations) else 1)
Boundary fixtureActualExpectedOutcome
oracle 1[[-6, [0]], [7, [0]]][[-6, [0]], [7, [0]]]Passed
oracle 2[[1, [1]]][[1, [1]]]Passed
oracle 3[None][None]Passed
oracle 4[][]Passed
oracle 5[[1, [1]]][[1, [1]]]Passed
oracle 6[[-1, [0]]][[-1, [0]]]Passed
oracle 7[[2, [0]]][[2, [0]]]Passed
variant packet 1[[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]][[-6, [0]], [7, [0]], [-6, [0]], [7, [0]]]Passed

SHA-256 / c02033517ac1c68106ee95b9a277ec9286001c78ae30e3f34579e5b8496ed32d

Verification & scope

Stipulated finite model; no claim of hardware timing or full file-format conformance. This reproducer isolates one failure mechanism. Results cover the supplied fixtures. Variants within a family share a test contract and should remain grouped when constructing evaluation splits. Related mechanisms with a shared evaluation_group must also remain together; these controlled models are not independent production incidents.

Observations recorded using Python 3.12.14 at 2026-09-29T14:45:04.843282+00:00.

Case digest / b68d96552dc516700444996e58d88156bf55fc027c6edeb9d9942b91df58edc4