|
|
@@ -1,37 +1,58 @@
|
|
|
-# Prod2U CPLD Operating Rules
|
|
|
-
|
|
|
-This repository is the active `dev` branch for the Prod2U multi-project UART refactor.
|
|
|
-
|
|
|
-## Authority
|
|
|
-
|
|
|
-- `projects/<project_id>/project.json` is the only machine configuration source.
|
|
|
-- `projects/prod2u-door-temp/requirements.zh-CN.md` records the project requirements.
|
|
|
-- `docs/prod2u-door-temp-protocol.zh-CN.md` records the host-facing frame contract.
|
|
|
-- Generated files and the active ADC are derived outputs; do not hand-edit them independently.
|
|
|
-- Phase 1 covers the door-temperature project contract only. Production RTL, TD/top, hardware, and RTL/TD behavior tests remain outside this worktree ownership; Python contract tests are in scope.
|
|
|
-
|
|
|
-## Coordination
|
|
|
-
|
|
|
-- Root builds a dependency graph before delegation and only runs independent, clearly bounded work in parallel.
|
|
|
-- Normal concurrency is 2-4 agents; 6 is the hard upper bound.
|
|
|
-- Tasks marked `[DYNAMIC-NATIVE-MA]` use the current client's native coordination tools.
|
|
|
-- Root owns interface freezes, integration, conflict resolution, and final candidate selection.
|
|
|
-- Each temporary worktree or owned path has one coordinator-assigned owner.
|
|
|
-- Test agents do not modify production RTL. The coordinator does not modify tests owned by the test engineer.
|
|
|
-- The Harness must not start Codex, call model APIs, or create agent threads.
|
|
|
-
|
|
|
-## Phase boundaries
|
|
|
-
|
|
|
-- Phase 0 must not implement product functionality or modify RTL, project configuration, protocol, pins, TD, or product contracts.
|
|
|
-- Phase 0 established coordination, Git isolation, ownership validation, and minimal evidence.
|
|
|
-- Phase 1 freezes the 25 MHz / 115200 8N1 contract, project mappings, schema, generator, protocol reference model, generated artifacts, and active ADC.
|
|
|
-- Phase 2 owns production RTL, simulations, TD scripts, bitstreams, and broader verification.
|
|
|
-- Phase 1 must review every nested `AGENTS.md` and replace rules that conflict with the accepted product contract; this run audited them and kept non-conflicting rules unchanged.
|
|
|
-- Physical hardware access, programming, drivers, global PATH changes, and external model services are prohibited.
|
|
|
-
|
|
|
-## Safety and evidence
|
|
|
-
|
|
|
-- Keep source, offline simulation, formal, TD, package, and physical-hardware evidence separate.
|
|
|
-- Blocked, dry-run, fixture, and partial evidence is not a pass.
|
|
|
-- Preserve unrelated dirty changes and ignored generated evidence.
|
|
|
-- Every run uses one 32-character lowercase hexadecimal `run_id`.
|
|
|
+# Prod2U CPLD Final Convergence Rules
|
|
|
+
|
|
|
+This checkout implements the Prod2U door-temperature controller. The active product
|
|
|
+contract is defined by `projects/prod2u-door-temp/project.json`,
|
|
|
+`projects/prod2u-door-temp/requirements.zh-CN.md`, and
|
|
|
+`docs/prod2u-door-temp-protocol.zh-CN.md`. Generated contracts, constraints, source
|
|
|
+manifests, tests, TD inputs, and packages must derive from that contract.
|
|
|
+
|
|
|
+## Coordination and ownership
|
|
|
+
|
|
|
+- Root builds the dependency graph, freezes interfaces, assigns exclusive paths,
|
|
|
+ integrates changes, stages, commits, and selects the final candidate.
|
|
|
+- Agents may edit only their assigned paths. No agent stages or commits in a shared
|
|
|
+ worktree. A path has one owner at a time; overlapping assignments are rejected.
|
|
|
+- `cpld_engineer` owns assigned production RTL, generator, build/package/receipt
|
|
|
+ implementation, and production `tools/*.py` paths.
|
|
|
+- `cpld_test_engineer` owns assigned `tests/**`, formal wrappers, cocotb, fixtures,
|
|
|
+ and test receipt logic. A test finding in production tools is reported to Root and
|
|
|
+ fixed by `cpld_engineer`.
|
|
|
+- Reviewers and explorers are read-only and must verify tracked paths before and
|
|
|
+ after their task.
|
|
|
+- The Harness runs ordinary commands with explicit `cwd`; it never starts Codex,
|
|
|
+ calls model APIs, or creates agent threads.
|
|
|
+
|
|
|
+## Execution and model policy
|
|
|
+
|
|
|
+- `MODEL_POLICY=unconstrained`.
|
|
|
+- `REASONING_EFFORT_POLICY=unconstrained`.
|
|
|
+- `MODEL_OR_EFFORT_IS_ACCEPTANCE_GATE=false`.
|
|
|
+- Observed model, effort, or selection source may be `not_exposed`; none is an
|
|
|
+ acceptance gate.
|
|
|
+- Protected repositories and dirty developer worktrees are read-only. All writes,
|
|
|
+ builds, receipts, TD roots, candidate worktrees, and packages use an explicitly
|
|
|
+ assigned isolated worktree or external root.
|
|
|
+
|
|
|
+## Product and evidence boundaries
|
|
|
+
|
|
|
+- UART is 25 MHz, 115200 8N1, 217 clocks/bit, with A5 5A framing and CRC-16/
|
|
|
+ CCITT-FALSE. Supported types are SET_ALL, GET_TEMPERATURE, and TEMPERATURE_DATA.
|
|
|
+- SET_ALL is 14 bytes: 8 PTC values, 4 FAN values, and X/Y motor commands.
|
|
|
+- PTC/FAN mapping, ADC order, motor, watchdog, PWM, and temperature behavior come
|
|
|
+ only from the project contract. Do not restore legacy protocol or hardware
|
|
|
+ behavior. Host rejects duty values above 100; RTL behavior for 0x65..0xFF is
|
|
|
+ unspecified.
|
|
|
+- Distinguish source, simulation, formal, TD, package, and physical-hardware
|
|
|
+ evidence. `fail`, `blocked`, `not_run`, placeholder, and exploratory evidence are
|
|
|
+ never pass evidence.
|
|
|
+- Receipts bind the run ID, exact full commit, project hash, source-manifest hash,
|
|
|
+ command, tool version, status, and applicable bitstream hash.
|
|
|
+
|
|
|
+## Protected operations
|
|
|
+
|
|
|
+- Never access COM or JTAG, program hardware, install drivers, modify global PATH,
|
|
|
+ or create ChatGPT Adviser artifacts.
|
|
|
+- Never use reset, clean, stash, restore, destructive checkout, silent overwrite,
|
|
|
+ automatic merge, or branch movement on a protected developer repository.
|
|
|
+- Hardware validation is separate from offline verification and remains `not_run`
|
|
|
+ unless explicitly authorized in a future task.
|