Skip to content

File formats

The editors' files are JSON, written deterministically (blocks by id, wires sorted, coordinates rounded), so that they read, diff and merge like source code. Fields the editors do not know are kept.

A circuit: name.intrepyd.json

{
  "format": "intrepyd-diagram",
  "version": 3,
  "circuit": {
    "nodes": [
      { "id": 1, "kind": "input", "name": "in1", "type": "bool" },
      { "id": 2, "kind": "gate", "name": "not1", "op": "not" },
      { "id": 3, "kind": "output", "name": "out1" }
    ],
    "edges": [
      { "from": 1, "to": 2, "port": "in" },
      { "from": 2, "to": 3, "port": "in" }
    ]
  },
  "layout": { "blocks": { "1": { "x": 40, "y": 40 }, "2": { "x": 190, "y": 30 }, "3": { "x": 330, "y": 40 } } }
}
  • circuit is the netlist, in the schema of intrepyd's exporter (intrepyd.export), with a few fields of the editor's: Out blocks, library components, Assertion, Target and Assume ("kind": "assumption") blocks, subsystems; inputs, the number of inputs of a gate that has more than two; fromPort on a wire, the output of a block with several that it leaves from; parent on a block inside a subsystem, the subsystem's id.
  • A wire {from, to, port} drives input port of block to with the output of block from. Ids are unique in the whole file, and a wire joins two blocks of one level. A wire into a subsystem names its pin by the In block's name; a wire out of one gives the index of its Out block, in id order.
  • layout is only the drawing: where each block is (blocks), and the corners of the wires routed by hand (wires).

Optional sections follow: simulation (the steps and the stimuli), verification (the engine, the timeout, the depth, the certificates), testgen (the MC/DC decisions and settings), and requirement, the copy of the circuit's row of its table:

"requirement": {
  "id": "LLR-012",
  "title": "Alarm on occlusion",
  "text": "The pump shall raise the occlusion alarm when …",
  "signals": { "pressure": "int16" },
  "formula": "(pressure > 300 and infusing) or door_open",
  "built": { "circuit": "…", "formula": "…" }
}

built holds fingerprints of the circuit last built from the formula and of what it was built from: it tells a circuit still the formula's from one edited by hand since.

A requirements table: name.requirements.json

{
  "format": "intrepyd-requirements",
  "version": 1,
  "signals": [
    { "name": "pressure", "type": "int16", "description": "the line pressure, in mmHg" }
  ],
  "requirements": [
    {
      "id": "LLR-012",
      "title": "Alarm on occlusion",
      "text": "The pump shall raise the occlusion alarm when …",
      "formula": "(pressure > 300 and infusing) or door_open",
      "circuit": "pump/LLR-012.intrepyd.json"
    }
  ]
}

circuit is the path of a row's circuit, relative to the table, set when the circuit is first made.

MC/DC tests: name.mcdc.json

Next to a circuit, the MC/DC tests generated for it: the date, the versions of intrepyd and of the intrepid library that generated them, the longest test and the timeout, the results, and a key of the circuit and its decisions they are for. The editors call them out of date when the circuit or its decisions have changed since.

CSV

  • Stimuli (Import CSV…, in the Stimuli tab): a column per input, named in the header, and a row per step; or a row per input.
  • Requirements (Import CSV…, Export CSV…, in the table): a header row, the columns id, title, text (or requirement, or description), formula and signals (name: type, separated by commas), separated by commas or semicolons.
  • MC/DC tests (Export table…, Export tests…): the table of a decision, and the tests' inputs step by step.