This part is for members
Membership opens soon. Leave your email and we'll tell you the day it does. Founding members get the launch price.
Keep watching the free partsProduct contract 1: one entry, eleven files
The product contract (contract/), part one: one parameter is written down five times in this repo: the firmware field in data_param.h (made by code_generate_tool.exe), the CANopen dictionary SlaveOD.eds (CANFestival), the CiA402 conversion callbacks (by hand), the host tool's tables (another repo), and one JSON entry in contract/schema. It opens with the whole episode on one framework page: each parameter is written once, by meaning; contract_tool.py checks the entry by the contract's own rules, then writes it into eleven files (C ID and alias headers, compact JSON, four host tables, a CANopen object table and EDS fragment, golden vectors, a manifest); the firmware is not one of them, and its three copies are only checked (29b). A correction to 28b: the contract doesn't generate the CANopen dictionary; it writes a fragment and checks the real one. Running example: 0x60FF target velocity, motion.target_velocity (id 0x2000E; product float32 rpm, wire int32 counts/s; parameterized_linear, formula load_pps_to_rpm, golden context 524,288). The bench, sil-mac/ep29: build_contract.py unpacks 94fc13d into build/contract/base (servohub untouched); trace_tool.py runs the tool's own main and records the lines it ran. Six stops: the entry (parameters.json is one line; shown indented, and labelled); load and merge (main → load_contract: exactly four includes, diagnostics split into errors and warnings, five paths kept for the manifest; 15 parameters + 8 signals = 23 items, ours is parameter 15); validate (only what the entry says, never the firmware: id and name new, types known, volatile agrees with the old flag, an unspecified range must not invent limits, the firmware source named, address 0x60FF:0 free; validate_conversion takes the parameterized branch; the real run's trace: identity 5, linear 4, parameterized 6, unverified 8); eleven texts (render_outputs: the ID line SERVO_CONTRACT_MOTION_TARGET_VELOCITY = 0x0002000E, a 35-column row in the parameter table, the EDS fragment's [60FF] with DataType 0x0004, whose header says it is not a standalone device EDS); the golden vector (by hand 60/524,288 = 0.00011444, wire 1000 → 0.11444091796875 rpm, bytes E8030000, back to 1000; 15 verified items → 15 vectors); the manifest and the write (git_blob_sha matches git ls-tree, product_contract.json 6f7c1a7; before the write all eleven texts were identical to the committed files; PASS). Then, does the firmware agree: set_Target_velocity multiplies the wire value by get_app_Load_pps_2_rpm (60 over the load encoder's resolution, set at power-up); 524,288 is a test value no motor header uses; the bench conv29 calls the real callback after AppParamInit, and on the gim6010 (2,097,152) 1000 → 0.0286102294921875 rpm, read back 1000: the same formula. Not covered: the other commands and what they catch → 29b; the CANopen write path → episode 30; data_param.h's generator → 28b; the error and warning tables are not yet checked against the firmware. Your turn: golden context 2,097,152 → three files stale (compact JSON, vectors, manifest; the host table has no column for it), 1000 → 0.0286102294921875 rpm, the firmware's own number.