Skip to content

analog M4e-offset: the +6.7 mV the converter needs is not the comparator -- find and model its source #10888

Open

Description

@gHashTag

Goal

M4e (PR #10854) matches the golden run's codes 30 of 31 only with two fitted numbers, one of them a +6.7 mV decision offset. M4b-psp (PR #10884) shows it is not the comparator's: the golden dynamic_comparator on PSP103 is mirror-symmetric and flips at 0 (+-0.12 uV in ngspice and in the model); dynamic_comparator_top flips at -0.153 mV, the opposite sign of the +2.5 to +3.1 mV read from the golden run's own decisions. Find what produces the offset the converter sees, and model it, so M4e's offset is predicted.

Requirements

  • FR-001: Each candidate is tested by an ngspice + PSP103 experiment on the golden deck with one thing changed at a time (e.g. the two DAC halves' loading or switching order, the bottom-plate logic, the tracking switches' charge injection on VDP vs VDN, comparator kickback onto unequal top-plate capacitance, the timing of the comparator clock against DAC settling), each experiment a committed wrapper deck that .includes the run-time deck (never its text).
  • FR-002: The cause is named with its measured size; the M4e model gains it from the netlist or from a PSP103 table, not from a fit.

Scenarios

  • Given the golden deck with one candidate removed or symmetrised, When the first decisions of a conversion are read, Then the effective offset moves by the measured amount.
  • Given the identified mechanism in the M4e model with no fitted offset, When the 31 conversions run, Then the match count is stated and compared with the fitted 30 of 31.

Boundary

  • New decks under specs/analog/decks/, specs/analog/sar_adc.t27 (the converter model), and whichever block spec owns the mechanism.

Success Criteria

  • A table of experiments in the PR body: candidate, change, offset moved by (mV).
  • t27c test-report specs/analog/sar_adc.t27 0 vacuous with the offset taken from the identified mechanism (no OFFSET fit), match count stated.

Part of #10818

Success Criteria

  • A table of experiments is committed to specs/analog/decks/ with columns: candidate, change, offset moved by (mV) — 5 rows minimum.
  • t27c test-report specs/analog/sar_adc.t27 exits 0 with 0 vacuous tests and the match count printed as "31 conversions: N matches" where N ≥ 30.
  • The identified mechanism's block spec (under specs/analog/) exposes the offset as a PSP103 table parameter with measured value in mV.

Activity

  1. added
    shape-refusedClosed by the issue-shape gate (specs/policy/issue_shape.t27); a passing edit reopens it
    on Oct 19, 2026
  2. github-actions commented on Oct 19, 2026

    @github-actions
    Contributor

    Closed by the issue-shape gate (specs/policy/issue_shape.t27, #7498): an issue must have the template's sections. Edit the body; an edit that passes reopens it.

    • missing: ## Success Criteria -- an outcome a machine can settle: a number with a unit, a backticked file, exit 0, or a backticked command
  3. removed
    shape-refusedClosed by the issue-shape gate (specs/policy/issue_shape.t27); a passing edit reopens it
    on Oct 19, 2026
  4. gHashTag commented on Oct 19, 2026

    @gHashTag
    OwnerAuthor

    Reopened by the self-heal of #11007. The issue-shape gate closed this issue with a queued run that judged an older body from its event payload; the current body passes gen/c/policy/issue_shape.c, and the gate's own contract is that a passing body stays open. If the work is in fact finished or obsolete, close it as completed.

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

Metadata

Metadata

Assignees

No one assigned

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions