ECU Definition Extension Files
Overview
ECU Definition Extension (EDX) Files augment ECU Definition Files with additional information that may not be possible to describe in the ECU Definition File itself.
For example, some features such as the ECU pinout / connector diagram is not possible to express in a standard A2L file. There may be other features that are not easy to add to A2L files if they are being generated from a tool.
Format
ECU Definition Extension Files have the file extension “gemsedx”. They are in an extended JSON (structured text) format that can be easily read and edited by humans, checked into source control tools and easily compared.
Installation
For ECU definition file authors with access to the ‘ginpkg’ tool, EDX files may be embedded in an ECU Definition File archive for automatic loading and installation.
Default EDX files may also be installed on disk in either the %PROGRAMDATA%/GEMS/GWv4/edx or %APPDATA%/GEMS/GWv4/edx directories. The edx file should be given the same name as the ECU, with or without the version as it appears in the ECU Installations dialog, accessible via the action .
e.g. possible file names:
- %PROGRAMDATA%/GEMS/GWv4/edx/DEMO.gemsedx
- %APPDATA%/GEMS/GWv4/edx/DEMO-01X01.gemsedx
EDX files will only be loaded from these locations if the ECU Definition File does not already embed one.
Only 1 EDX file will be loaded from disk, in order of preference:
- %APPDATA%, with full version name (e.g. DEMO-01X01)
- %APPDATA%, name without version (e.g. DEMO)
- %PROGRAMDATA%, with full version name (e.g. DEMO-01X01)
- %PROGRAMDATA%, name without version (e.g. DEMO)
Inheritance
ECU Definition Files may embed multiple EDX files, which will be loaded in the order they are embedded. This allows for a base EDX file to be embedded in a common ECU Definition File, with additional EDX files for specific variants or versions. EDX files will be merged based upon elements with unique keys or appended to existing lists.
If EDX files are embedded into the calibration file, they will be loaded in the order they are embedded, after any EDX files embedded in the ECU Definition File or from disk default. This allows calibrations files to override things like wire colours for connector pins on the pinout diagram.
Embedding EDX Files in the Calibration File
EDX files may be embedded / removed / re-prioritized in the calibration file, using the
action:

Name Pattern Matching
For some elements in the EDX file, name pattern matching is possible (e.g. to identify options that are an output pin number and should offer an alternative selector in the application UI).
Possible Wildcard patterns:
- $N: any decimal number of any length.
- $*: 0 or more characters of any length.
- $+: 1 or more characters of any length.
- $?: any single character.
- $$: match a literal ‘$’.
Name matching is case insensitive and will also check ‘old names’ if they are present in the ECU Definition File; some items may be renamed in new versions of the ECU Definition File, with a record of their prior name.
Note also that for items that are matched for things like output pin numbers, any aliased items will also be considered a match.
For example, the option Out Oil Feed 1 may be aliased with the option
Oil Feed 1 Out. If the EDX file contains a rule that matches
Out Oil Feed 1, then
Oil Feed 1 Out would also be matched.
Using wildcard matches simplifies maintenance of EDX files when the ECU Definition File is updated if naming conventions are consistent.
Name pattern exclusions are also possible. For example, consider the following:
{
// This clause will match all options starting with the string "Out ",
// followed by any sequence of characters.
//
// For this ECU, this would also match PWM module outputs (which are NOT output pin numbers).
// These items are excluded by the "out_pin_options_exclude" clause below.
"out_pin_options": [
"Out $*",
],
// Exclude specific PWM module outputs that are not output pin numbers but would
// otherwise match the "Out $*" clause above:
"out_pin_options_exclude": [
"Out $* PWM",
"Out $* PWM$N", // e.g. exclude Out Idle PWM1
"Out $* PWM#$N", // e.g. exclude Out VVC#1 PWM#1
],
}
Formulas
Formulas can be used in a number of places. These follow A2L formula rules with some additional extensions.
A2L formulas closely follow C expressions and use the same operator precedence.
<% vendor %> Extensions
Extension | Purpose |
---|---|
Relational operators ( ==, !=, <, <=, >, >= ) | Compare two values, resulting in 0 or 1. |
Ternary operator a ? b : c |
If ‘a’ is true the ‘b’ is executed, otherwise ‘c’ is executed. |
arg(i) function | Selects input argument ‘i’ (zero based) from input arguents list. Can be used for selectors. |
option(name) function | Select an option object by name. |
table(name) function | Select a table object by name. |
map(name) function | Select a map object by name. |
channel(name) function | Select a channel object by name. |
Example EDX File
In future a JSON schema will be developed for easier editing in tools that support JSON schema validation.
For the time being, the following is an example EDX file that describes a connector with multiple sections, each with multiple pins, some of which have specific functions and conditions for use.
There are also some examples of wire colours and patterns that may be used in the connector diagram.
Also, output pins / switch inputs / A2Ds etc may be identified.
Note that an extended (JSONX) format is used so that comments are allowed and additionally some relaxations to the strict JSON format are allowed (e.g. trailing commas / missing commas, unquoted keys etc).
For the purpose of integration with external tools it is generally recommended to stick to strict JSON format where possible.
Editors such as Visual Studio Code can be extended to support the ‘jsonc’ format (JSON with comments) which is a good compromise.
// Comments may be included in EDX files.
{
"ecu_family": [
"DEMO"
],
// Default shape / size for pins in the connector diagram:
"default_pin": {
"shape": "circle",
"size": [2,2]
},
// Describe the ECU connectors and any predefined functions.
"connectors": [
{
"id": "AB",
"part": "6437288-3",
"comment": "Mates with: 3-1437290-7 (26P), 4-1437290-0 (34P)",
"pos": [50, 0],
"size": [75, 24.6],
"sections": [
{
"id": "A",
"pos": [0, 0],
"pin_offset": [6.2, 6.2],
"size": [38.4, 24.6],
"diagram": [
{
"shape": "round_rect",
"radius": 2,
"pos": [5, 5],
"size": [28.4, 14.6],
},
{
"shape": "round_rect",
"radius": 6,
"pos": [1, 1],
"size": [36.4, 22.6],
},
{
"shape": "round_rect",
"radius": 7,
"pos": [0, 0],
"size": [38.4, 24.6],
},
],
"pins": [
// row 1, 9 pins, pitch 3mm
{
"id": "A1",
"func": "BRGB2",
"dir": "O", // I / O / IO
"out_pin": 9,
"pwm": 2,
"throttle": 2,
"pos": [0, 0], // x,y position on connector diagram
"wire": {
"colour": ["#FF0000","#00DD00"], // Colour(s) of the wire, some may be striped with multiple colours. Could be a single colour with no array.
"width": [1, 1], // Width of the stripes (optional)
"pattern": "D", // D: diagonal, T: transverse, L: longitudinal (optional)
"text": "Red/Green"
},
"comment": "Act Throttle 2",
"used_if": [ // Conditions that lead to this output being used (overrides / conflicts with use of out_pin)
{
"func": "Act Throttle 2",
"expr": "option('BridgeB Enable') && option('Act Throttle 2') && !option('Act T 2 No Drive')",
}
]
},
{
"id": "A2",
"func": "BRGB1",
"dir": "O", // I / O / IO
"out_pin": 8,
"pwm": 1,
"throttle": 2,
"pos": [3, 0], // x,y position on connector diagram
"wire": {
"colour": ["#00DD00","#3333DD"], // Colour(s) of the wire, some may be striped with multiple colours. Could be a single colour with no array.
"width": [1, 1], // Width of the stripes (optional)
"pattern": "T", // D: diagonal, T: transverse, L: longitudinal (optional)
"text": "Green/Blue"
},
"comment": "Act Throttle 2",
"used_if": [
{
"func": "Act Throttle 2",
"expr": "option('BridgeB Enable') && option('Act Throttle 2') && !option('Act T 2 No Drive')",
}
]
},
{
"id": "A3",
"func": "IGSWT",
"a2d": 13,
"pos": [6, 0],
"comment": "5V to turn on MAIN RELAY",
"wire": {
"colour": ["#FFFFFF","#000000"], // Colour(s) of the wire, some may be striped with multiple colours. Could be a single colour with no array.
"width": [1, 1], // Width of the stripes (optional)
"pattern": "line", // D: diagonal, T: transverse, L: longitudinal, line (optional)
"text": "White/Black"
},
},
{
"id": "A4",
"func": "Fuel8",
"out_pin": 24,
"pos": [9, 0],
"comment": "Fuel Injector 8",
"used_if": [
{
"func": "Fuel 8",
"expr": "option('Fuel 8')"
}
]
"wire": {
"colour": ["#FF7F00","#000000"], // Colour(s) of the wire, some may be striped with multiple colours. Could be a single colour with no array.
"width": [1, 1], // Width of the stripes (optional)
"pattern": "L", // D: diagonal, T: transverse, L: longitudinal (optional)
"text": "Orange/Black"
},
},
{
"id": "A5",
"func": "Fuel7",
"out_pin": 25,
"pos": [12, 0],
"comment": "Fuel Injector 7",
"used_if": [
{
"func": "Fuel 7",
"expr": "option('Fuel 7')"
}
]
},
{
"id": "A6",
"func": "Fuel6",
"out_pin": 26,
"pos": [15, 0],
"comment": "Fuel Injector 6",
"used_if": [
{
"func": "Fuel 6",
"expr": "option('Fuel 6')"
}
]
},
{
"id": "A7",
"func": "Fuel5",
"out_pin": 27,
"pos": [18, 0],
"comment": "Fuel Injector 5",
"used_if": [
{
"func": "Fuel 5",
"expr": "option('Fuel 5')"
}
]
},
{
"id": "A8",
"func": "Fuel4",
"out_pin": 28,
"pos": [21, 0],
"comment": "Fuel Injector 4",
"used_if": [
{
"func": "Fuel 4",
"expr": "option('Fuel 4')"
}
]
},
{
"id": "A9",
"func": "Fuel3",
"out_pin": 29,
"pos": [24, 0],
"comment": "Fuel Injector 3",
"used_if": [
{
"func": "Fuel 3",
"expr": "option('Fuel 3')"
}
]
},
// Row 2, 8 pins
{
"id": "A10",
"func": "PWR",
"a2d": 14,
"pos": [1.5, 3.2],
"comment": "1st Power IN",
},
{
"id": "A11",
"func": "12VOUT",
"pos": [4.5, 3.2],
"comment": "12V Battery 100mA sensor supply"
},
{
"id": "A12",
"func": "IGN1",
"out_pin": 56,
"mux": "IGMUX11", // Multiplexor (used for ignition mux)
"pos": [7.5, 3.2],
"comment": "CoilA IGN1&3 TTL ignition multiplex",
"used_if": [
{
"func": "Ign 1",
"expr": "option('Ign 1')"
}
]
},
{
"id": "A13",
"func": "IGN4",
"out_pin": 58,
"mux": "IGMUX21",
"pos": [10.5, 3.2],
"comment": "CoilB IGN2&4 TTL ignition multiplex",
"used_if": [
{
"func": "Ign 4",
"expr": "option('Ign 4')"
}
]
},
{
"id": "A14",
"func": "IGN3",
"out_pin": 57,
"mux": "IGMUX12",
"pos": [13.5, 3.2],
"comment": "CoilA IGN1&3 TTL ignition multiplex",
"used_if": [
{
"func": "Ign 3",
"expr": "option('Ign 3')"
}
]
},
{
"id": "A15",
"func": "IGN2",
"out_pin": 59,
"mux": "IGMUX22",
"pos": [16.5, 3.2],
"comment": "CoilB IGN2&4 TTL ignition multiplex",
"used_if": [
{
"func": "Ign 2",
"expr": "option('Ign 2')"
}
]
},
{
"id": "A16",
"func": "IGN5",
"out_pin": 3,
"pos": [19.5, 3.2],
"comment": "TTL",
"used_if": [
{
"func": "Ign 5",
"expr": "option('Ign 5')"
}
]
},
{
"id": "A17",
"func": "IGN6",
"out_pin": 4,
"pos": [22.5, 3.2],
"comment": "TTL",
"used_if": [
{
"func": "Ign 6",
"expr": "option('Ign 6')"
}
]
},
// Row 3, 8 pins
{
"id": "A18",
"func": "PWR2",
"a2d": 14,
"pos": [1.5, 7],
"comment": "2nd Power IN",
},
{
"id": "A19",
"func": "Crank",
"timer": 1,
"pos": [4.5, 7],
"pullup": "option('T1 Pull-Up') ? 1000 : 0",
"comment": "VR Filter"
},
{
"id": "A20",
"func": "Cam",
"timer": 2,
"swt": 32,
"pos": [7.5, 7],
"pullup": "option('T2 Pull-Up') ? 1000 : 0",
"comment": "VR Filter"
},
{
"id": "A21",
"func": "T3",
"timer": 3,
"swt": 25,
"pos": [10.5, 7],
"pullup": "option('T3 Pull-Up') ? 1000 : 0",
"comment": "VR"
},
{
"id": "A22",
"func": "T4",
"timer": 4,
"swt": 26,
"pos": [13.5, 7],
"pullup": "option('T4 Pull-Up') ? 1000 : 0",
"comment": "VR"
},
{
"id": "A23",
"func": "T5",
"timer": 5,
"swt": 27,
"pos": [16.5, 7],
"pullup": "4700",
},
{
"id": "A24",
"func": "T7",
"timer": 7,
"swt": 29,
"pos": [19.5, 7],
"pullup": "4700",
"comment": "Logic only"
},
{
"id": "A25",
"func": "T8",
"timer": 8,
"swt": 30,
"pos": [22.5, 7],
"pullup": "4700",
"comment": "Logic only"
},
// row 4, 9 pins RTL, pitch 3mm
{
"id": "A26",
"func": "PGND2",
"pos": [0, 10.2],
},
{
"id": "A27",
"func": "CAN2L",
"pos": [3, 10.2],
"comment": "8TX",
},
{
"id": "A28",
"func": "CAN2H",
"pos": [6, 10.2],
"comment": "8TX",
},
{
"id": "A29",
"func": "TX",
"pos": [9, 10.2],
"comment": "Serial Comms Transmit (TTL)",
},
{
"id": "A30",
"func": "S5V2",
"pos": [12, 10.2],
"comment": "5V 100mA",
},
{
"id": "A31",
"func": "RX",
"pos": [15, 10.2],
"comment": "Serial Comms Receive (TTL)",
},
{
"id": "A32",
"func": "T9",
"timer": 9,
"swt": 9,
"pos": [18, 10.2],
"pullup": "4700",
"comment": "Logic only"
},
{
"id": "A33",
"func": "T10",
"timer": 10,
"swt": 10,
"pos": [21, 10.2],
"pullup": "4700",
"comment": "Logic only"
},
{
"id": "A34",
"func": "TGND",
"pos": [24, 10.2],
"comment": "signal 100mA"
},
]
},
{
"id": "B",
"pos": [40, 0],
"pin_offset": [6.2, 6.2],
"size": [32.4, 24.6],
"diagram": [
{
"shape": "round_rect",
"radius": 2,
"pos": [5, 5],
"size": [22.4, 14.6],
},
{
"shape": "round_rect",
"radius": 6,
"pos": [1, 1],
"size": [30.4, 22.6],
},
{
"shape": "round_rect",
"radius": 7,
"pos": [0, 0],
"size": [32.4, 24.6],
},
],
// 26 pin connector 7,6,6,7
"pins":[
// Row 1, 7 pins
{
"id": "B1",
"func": "Fuel2",
"out_pin": 30,
"pos": [18, 0],
"comment": "Fuel Injector 2",
"used_if": [
{
"func": "Fuel 2",
"expr": "option('Fuel 2')"
}
]
},
{
"id": "B2",
"func": "Fuel1",
"out_pin": 31,
"pos": [15, 0],
"comment": "Fuel Injector 1",
"used_if": [
{
"func": "Fuel 1",
"expr": "option('Fuel 1')"
}
]
},
{
"id": "B3",
"func": "PWM3",
"pwm": 3,
"out_pin": 10,
"pos": [12, 0],
},
{
"id": "B4",
"func": "PWM4",
"pwm": 4,
"out_pin": 11,
"pos": [9, 0],
},
{
"id": "B5",
"func": "PWM7",
"pwm": 7,
"out_pin": 14,
"pos": [6, 0],
},
{
"id": "B6",
"func": "PWM8",
"pwm": 8,
"out_pin": 15,
"pos": [3, 0],
},
{
"id": "B7",
"func": "MAINRLY",
"pos": [0, 0],
"comment": "(IGNSWT)",
},
// Row 2, 6 pins
{
"id": "B8",
"func": "IGN7",
"out_pin": 5,
"pos": [16.5, 3.2],
"comment": "TTL",
"used_if": [
{
"func": "Ign 7",
"expr": "option('Ign 7')"
}
]
},
{
"id": "B9",
"func": "IGN8",
"out_pin": 6,
"pos": [13.5, 3.2],
"comment": "TTL",
"used_if": [
{
"func": "Ign 8",
"expr": "option('Ign 8')"
}
]
},
{
"id": "B10",
"func": "ACTTP1",
"a2d": 10,
"swt": 51,
"pos": [10.5, 3.2],
"pullup": "47000",
"comment": "Act Throttle 1 position 1st",
"channels":[
"Act T1 raw",
"Analog 10"
],
"used_if": [
{
"option": "Act T1 Active"
}
]
},
{
"id": "B11",
"func": "ACTTP2",
"a2d": 9,
"swt": 50,
"pos": [7.5, 3.2],
"pullup": "47000",
"comment": "Act Throttle 1 position 2nd",
"channels":[
"Act T2 raw",
"Analog 09"
],
"used_if": [
{
"option": "Act T2 Active"
}
]
},
{
"id": "B12",
"func": "ACTTP3",
"a2d": 18,
"swt": 59,
"pos": [4.5, 3.2],
"pullup": "47000",
"comment": "Act Throttle 2 position 1st",
"channels":[
"Act T3 raw",
"Analog 18"
],
"used_if": [
{
// Alternative to using an expression + a function name.
"option": "Act T3 Active"
}
]
},
{
"id": "B13",
"func": "ACTTP4",
"a2d": 19,
"swt": 60,
"pos": [1.5, 3.2],
"pullup": "47000",
"comment": "Act Throttle 2 position 2nd",
"channels":[
"Act T4 raw",
"Analog 19"
],
"used_if": [
{
"option": "Act T4 Active"
}
]
},
// 3rd row, 6 pins
{
"id": "B14",
"func": "OXHEATB",
"out_pin": 33,
"pos": [16.5, 7],
"comment": "Lambda Sensor Heater B (white to gray)",
},
{
"id": "B15",
"func": "AGND2",
"pos": [13.5, 7],
"comment": "signal 100mA",
},
{
"id": "B16",
"func": "OXB1",
"pos": [10.5, 7],
"comment": "Yellow VM",
},
{
"id": "B17",
"func": "OXB2",
"a2d": 23,
"pos": [7.5, 7],
"comment": "Lambda, red APE IP",
},
{
"id": "B18",
"func": "OXB3",
"a2d": 20,
"pos": [4.5, 7],
"comment": "Ri, black UN RE",
},
{
"id": "B19",
"func": "OXB4",
"pos": [1.5, 7],
"comment": "Violet IA trim resistor",
},
// Row4, 7 pins
{
"id": "B20",
"func": "AGND3",
"pos": [18, 10.2],
"comment": "2R6",
},
{
"id": "B21",
"func": "S5V3",
"pos": [15, 10.2],
"comment": "5V 100mA",
},
{
"id": "B22",
"func": "T11",
"timer": 11,
"swt": 11,
"pos": [12, 10.2],
"pullup": "4700",
"comment": "Logic only"
},
{
"id": "B23",
"func": "T12",
"timer": 12,
"swt": 12,
"pos": [9, 10.2],
"pullup": "4700",
"comment": "Logic only"
},
{
"id": "B24",
"func": "KNOCKN",
"swt": 43,
"a2d": 2,
"pos": [6, 10.2],
},
{
"id": "B25",
"func": "KNOCKP",
"a2d": 2,
"pos": [3, 10.2],
},
{
"id": "B26",
"func": "PGND",
"pos": [0, 10.2],
}
]
}
]
},
{
"id": "C",
"part": "6437288-2",
"comment": "Mates with: 4-1437290-1",
"pos": [0, 0],
"size": [38.4, 24.6],
"sections": [
{
"id": "C",
"pos": [0, 0],
"pin_offset": [6.2, 6.2],
"size": [38.4, 24.6],
"diagram": [
{
"shape": "round_rect",
"radius": 2,
"pos": [5, 5],
"size": [28.4, 14.6],
},
{
"shape": "round_rect",
"radius": 6,
"pos": [1, 1],
"size": [36.4, 22.6],
},
{
"shape": "round_rect",
"radius": 7,
"pos": [0, 0],
"size": [38.4, 24.6],
},
],
"pins":[
// row 1, 9 pins RTL, pitch 3mm
{
"id": "C1",
"func": "PWM10",
"pwm": 10,
"out_pin": 17,
"pos": [0, 0],
"comment": "No recirculation diode",
},
{
"id": "C2",
"func": "PWM11",
"pwm": 11,
"out_pin": 18,
"pos": [3, 0],
"comment": "No recirculation diode",
},
{
"id": "C3",
"func": "PWM12",
"pwm": 12,
"out_pin": 19,
"pos": [6, 0],
"comment": "No recirculation diode",
},
{
"id": "C4",
"func": "PWM13",
"pwm": 13,
"out_pin": 20,
"pos": [9, 0],
},
{
"id": "C5",
"func": "PWM14",
"pwm": 14,
"out_pin": 21,
"pos": [12, 0],
},
{
"id": "C6",
"func": "PWM15",
"pwm": 15,
"out_pin": 22,
"pos": [15, 0],
},
{
"id": "C7",
"func": "PWM16",
"pwm": 16,
"out_pin": 23,
"pos": [18, 0],
},
{
"id": "C8",
"func": "BRGA1",
"out_pin": 12,
"pwm": 5,
"throttle": 2,
"pos": [21, 0],
"comment": "Act Throttle 1",
"used_if": [
{
"func": "Act Throttle 1",
"expr": "option('BridgeA Enable') && option('Act Throttle 1') && !option('Act T 1 No Drive')",
}
]
},
{
"id": "C9",
"func": "BRGA2",
"out_pin": 13,
"pwm": 6,
"throttle": 2,
"pos": [24, 0],
"comment": "Act Throttle 1",
"used_if": [
{
"func": "Act Throttle 1",
"expr": "option('BridgeA Enable') && option('Act Throttle 1') && !option('Act T 1 No Drive')",
}
]
},
// row2, 8 pins, offset 1.5mm
{
"id": "C10",
"func": "PWM9",
"out_pin": 16,
"pwm": 9,
"pos": [1.5, 3.2],
"comment": "No recirculation diode",
},
{
"id": "C11",
"func": "ACCEL1",
"a2d": 7,
"swt": 48,
"pullup": 47000,
"pos": [4.5, 3.2],
"comment": "Pedal Position 1",
"used_if": [
{
"option": "Pedal1 Active",
}
]
},
{
"id": "C12",
"func": "ACCEL2",
"a2d": 6,
"swt": 47,
"pullup": 47000,
"pos": [7.5, 3.2],
"comment": "Pedal Position 2",
"used_if": [
{
"option": "Pedal2 Active",
}
]
},
{
"id": "C13",
"func": "AN15",
"a2d": 15,
"swt": 56,
"pullup": 4700,
"pos": [10.5, 3.2],
},
{
"id": "C14",
"func": "AN16",
"a2d": 16,
"swt": 57,
"pullup": 4700,
"pos": [13.5, 3.2],
},
{
"id": "C15",
"func": "AN17",
"a2d": 17,
"swt": 58,
"pullup": 4700,
"pos": [16.5, 3.2],
},
{
"id": "C16",
"func": "AIT",
"a2d": 8,
"swt": 49,
"pullup": 4700,
"pos": [19.5, 3.2],
"comment": "Air Intake Temperature",
},
{
"id": "C17",
"func": "CTEMP",
"a2d": 11,
"swt": 52,
"pullup": 2200,
"pos": [22.5, 3.2],
"comment": "Coolant Temperature",
},
// Row 3, 8 pins
{
"id": "C18",
"func": "OXHEATA",
"out_pin": 32,
"pos": [1.5, 7],
"comment": "Lambda Sensor Heater A",
},
{
"id": "C19",
"func": "OXA1",
"pos": [4.5, 7],
"comment": "Yellow VM",
},
{
"id": "C20",
"func": "OXA2",
"a2d": 21,
"pos": [7.5, 7],
"comment": "Lambda, red APE IP",
},
{
"id": "C21",
"func": "OXA3",
"a2d": 22,
"pos": [10.5, 7],
"comment": "Ri, black UN RE",
},
{
"id": "C22",
"func": "OXA4",
"pos": [13.5, 7],
"comment": "Violet trim resistor",
},
{
"id": "C23",
"func": "AGND4",
"pos": [16.5, 7],
"comment": "signal 100mA",
},
{
"id": "C24",
"func": "OX1",
"a2d": 4,
"swt": 45,
"pullup": 47000,
"pos": [19.5, 7],
"comment": "1V25 bias 47K",
},
{
"id": "C25",
"func": "OX2",
"a2d": 3,
"swt": 44,
"pullup": 47000,
"pos": [22.5, 7],
"comment": "1V25 bias 47K",
},
// row 4, 9 pins RTL, pitch 3mm
{
"id": "C26",
"func": "PGND1",
"pos": [0, 10.2],
},
{
"id": "C27",
"func": "KNOCK2P",
"a2d": 1,
"pos": [3, 10.2],
},
{
"id": "C28",
"func": "KNOCK2N",
"a2d": 1,
"swt": 42,
"pos": [6, 10.2],
},
{
"id": "C29",
"func": "AGND1",
"pos": [9, 10.2],
"comment": "signal 100mA",
},
{
"id": "C30",
"func": "MAF",
"a2d": 12,
"swt": 53,
"pullup": 47000,
"pos": [12, 10.2],
"comment": "MAF sensor",
},
{
"id": "C31",
"func": "MAP",
"a2d": 5,
"swt": 46,
"pullup": 47000,
"pos": [15, 10.2],
"comment": "MAP sensor",
},
{
"id": "C32",
"func": "S5V1",
"pos": [18, 10.2],
"comment": "5V 100mA",
},
{
"id": "C33",
"func": "CAN1L",
"pos": [21, 10.2],
"comment": "8TX",
},
{
"id": "C34",
"func": "CAN1H",
"pos": [24, 10.2],
"comment": "8TX",
},
]
}
],
}
],
"timers": [ // For timer selector channels
{
"id": 1,
"name": "T1",
"channels": [
"T1 overflow count",
"T1 Period H",
"T1 Period",
"T1 counter",
"T1 Time H",
"T1 Time",
"T1 Period Old",
]
},
{
"id": 2,
"name": "T2",
"channels": [
"T2 overflow count",
"T2 Period H",
"T2 Period",
"T2 counter",
"T2 Time H",
"T2 Time",
"T2 - T1 Time",
"T2 T1 Period",
"T2 F Tooth",
]
},
{
"id": 3,
"name": "T3",
"channels": [
"T3 overflow count",
"T3 Period H",
"T3 Period",
"T3 counter",
"T3 Time H",
"T3 Time",
"T3 - T1 Time",
"T3 T1 Period",
"T3 F Tooth",
]
},
{
"id": 4,
"name": "T4",
"channels": [
"T4 overflow count",
"T4 Period H",
"T4 Period",
"T4 counter",
"T4 Time H",
"T4 Time",
"T4 - T1 Time",
"T4 T1 Period",
"T4 F Tooth",
]
},
{
"id": 5,
"name": "T5",
"channels": [
"T5 overflow count",
"T5 Period H",
"T5 Period",
"T5 counter",
"T5 Time H",
"T5 Time",
"T5 - T1 Time",
"T5 T1 Period",
"T5 F Tooth",
]
},
{
"id": 6,
"name": "T6",
"channels": [
"T6 overflow count",
"T6 Period H",
"T6 Period",
"T6 counter",
"T6 Time H",
"T6 Time",
"T6 - T1 Time",
"T6 T1 Period",
"T6 F Tooth",
]
},
{
"id": 7,
"name": "T7",
"channels": [
"T7 overflow count",
"T7 Period H",
"T7 Period",
"T7 counter",
"T7 Time H",
"T7 Time",
"T7 - T1 Time",
"T7 T1 Period",
"T7 F Tooth",
]
},
{
"id": 8,
"name": "T8",
"channels": [
"T8 overflow count",
"T8 Period H",
"T8 Period",
"T8 counter",
"T8 Time H",
"T8 Time",
"T8 - T1 Time",
"T8 T1 Period",
"T8 F Tooth",
]
},
{
"id": 9,
"name": "T9",
"channels": [
"T9 overflow count",
"T9 Period H",
"T9 Period",
"T9 counter",
"T9 Time H",
"T9 Time",
"T9 - T1 Time",
"T9 T1 Period",
"T9 F Tooth",
]
},
{
"id": 10,
"name": "T10",
"channels": [
"T10 overflow count",
"T10 Period H",
"T10 Period",
"T10 counter",
"T10 Time H",
"T10 Time",
"T10 - T1 Time",
"T10 T1 Period",
"T10 F Tooth",
]
},
{
"id": 11,
"name": "T11",
"channels": [
"T11 overflow count",
"T11 Period H",
"T11 Period",
"T11 counter",
"T11 Time H",
"T11 Time",
"T11 - T1 Time",
"T11 T1 Period",
"T11 F Tooth",
]
},
{
"id": 12,
"name": "T12",
"channels": [
"T12 overflow count",
"T12 Period H",
"T12 Period",
"T12 counter",
"T12 Time H",
"T12 Time",
"T12 - T1 Time",
"T12 T1 Period",
"T12 F Tooth",
]
},
{
"id": 13,
"name": "T2 Rise",
"tc_alias": 2,
"channels": [
"T2R overflow count",
"T2R Period H",
"T2R Period",
"T2R counter",
"T2R Time H",
"T2R Time",
"T2R - T1 Time",
"T2R T1 Period",
"T2R F Tooth",
]
},
{
"id": 14,
"name": "T2 Fall",
"tc_alias": 2,
"channels": [
"T2F overflow count",
"T2F Period H",
"T2F Period",
"T2F counter",
"T2F Time H",
"T2F Time",
"T2F - T1 Time",
"T2F T1 Period",
"T2F F Tooth",
]
},
{
"id": 15,
"valid": false
},
{
"id": 16,
"valid": false
},
],
"timer_options": [
"Sync Channel T",
"Duty detect Rise T",
"Duty detect Fall T",
"VVC1 source T",
"VVC2 source T",
"VVCX1 source T",
"VVCX2 source T",
],
"timer_options_exclude": [],
// Describe how the switches are generated; there are a variety of ways that they are made.
// Some are bits coming from input pins, some from control routines, some from comparators, some from timers.
// some are from indirect channels (comcodes).
// Some of this can be auto-generated from the GIN file where channels are aliased with Switches#1, Switches#2 etc.
"switches": [
// Switches#2
{
"id": 9,
"channel": "PIN T9"
},
{
"id": 10,
"channel": "PIN T10"
},
{
"id": 11,
"channel": "PIN T11"
},
{
"id": 12,
"channel": "PIN T12"
},
{
"id": 13,
"valid": false
},
{
"id": 14,
"valid": false
},
{
"id": 15,
"valid": false
},
{
"id": 16,
"valid": false
},
// Switches#4
{
"id": 25,
"channel": "PIN T3"
},
{
"id": 26,
"channel": "PIN T4"
},
{
"id": 27,
"channel": "PIN T5"
},
{
"id": 28,
"valid": false
},
{
"id": 29,
"channel": "PIN T7"
},
{
"id": 30,
"channel": "PIN T8"
},
{
"id": 31,
"valid": false
},
{
"id": 32,
"channel": "PIN T2"
},
],
// Augment options
"options": [
{
"id": "Switches 10 Source",
"outputs": "Switches#10",
},
{
"id": "User Message1 Source",
"outputs": ["User Message1"]
},
{
"id": "User Message2 Source",
"outputs": ["User Message2"] // will also apply to aliases (e.g. Switches)
},
// TODO Gear Message Source?
{
"id": "Comparator1 Source",
"outputs": ["Comparator1"]
},
{
"id": "Comparator2 Source",
"outputs": ["Comparator2"]
},
{
"id": "Comparator3 Source",
"outputs": ["Comparator3"]
},
{
"id": "Comparator4 Source",
"outputs": ["Comparator4"]
},
{
"id": "Comparator5 Source",
"outputs": ["Comparator5"]
},
{
"id": "Comparator6 Source",
"outputs": ["Comparator6"]
},
],
// Identify any options that should be interpreted as switch selectors.
// Generally the GIN file should define these but they can be overridden here in case of
// errors in the GIN file.
"switch_inputs": [
"yellow switch", // In relation to FIA yellow flag on course.
"act t limiter switch a",
"act t limiter switch b",
"gear+ pot start pin",
"gear- pot start pin",
"gear+ retard in",
"gear+ act t lift pin",
"gear- blip in pin",
"gear- advance retard pin",
"time switch1 pin",
"time switch2 pin",
"swt tb input",
"log switch input",
"act t swt pin",
"fans inhibit pin",
"valve lift on input",
"rain light input switch",
"power steer in pin",
"a/c in pin",
"fuel pump switch",
"alt function input",
"als in pin",
"als mild in pin",
"launch in pin",
"ic auto/man pin",
"ic spray now pin",
"ignition fixed switch",
"cal1 select in pin",
"cal2 select in pin",
"cal3 select in pin",
"cal4 select in pin",
"cal5 select in pin",
"cal6 select in pin",
"cal7 select in pin",
"cal8 select in pin",
"road speed limit in pin no cal no",
"road speed in pin no cal no",
"oil pressure switch in pin",
"oil pressure pin",
"road speed limit defeat in pin",
"start pulse pin",
"main relay input",
"brake front switch",
"brake rear switch",
"foot brake in pin",
"hand brake in pin",
],
"switch_inputs_exclude":[],
// Identify any options that should be interpreted as A2D input selectors.
"a2d_options": [
"AIT source",
"Plenum Temp source",
"Coolant source",
"Baro source",
"Throttle source",
"MAP source",
"MAP2 source"
],
"a2d_options_exclude":[],
// Indicate any fixed-functions of A2D channels / pullups etc.
// This information is defaulted from the physical_pins section.
"a2ds": [
{ "id":0, "channel": "Analog 00", "name": "Knock 2", "pullup": 0 },
{ "id":1, "channel": "Analog 01", "name": "Knock 2", "pullup": 0 },
{ "id":2, "channel": "Analog 02", "name": "Knock", "pullup": 0 },
{ "id":3, "channel": "Analog 03", "name": "Oxygen 2", "pullup": 47000 },
{ "id":4, "channel": "Analog 04", "name": "Oxygen 1", "pullup": 47000 },
{ "id":5, "channel": "Analog 05", "name": "MAP", "pullup": 47000 },
{ "id":6, "channel": "Analog 06", "name": "Pedal 2", "pullup": 47000 },
{ "id":7, "channel": "Analog 07", "name": "Pedal 1", "pullup": 47000 },
{ "id":8, "channel": "Analog 08", "name": "Air Intake Temperature", "pullup": 4700 },
{ "id":9, "channel": "Analog 09", "name": "Active Throttle 2", "pullup": 47000 },
{ "id":10, "channel": "Analog 10", "name": "Active Throttle 1", "pullup": 47000 },
{ "id":11, "channel": "Analog 11", "name": "Coolant Temperature", "pullup": 2200 },
{ "id":12, "channel": "Analog 12", "name": "MAF", "pullup": 47000 },
{ "id":13, "channel": "Analog 13", "name": "IGSWT", "pullup": 0 },
{ "id":14, "channel": "Analog 14", "name": "PWR", "pullup": 0 },
{ "id":15, "channel": "Analog 15", "name": "", "pullup": 4700 },
{ "id":16, "channel": "Analog 16", "name": "", "pullup": 4700 },
{ "id":17, "channel": "Analog 17", "name": "", "pullup": 4700 },
{ "id":18, "channel": "Analog 18", "name": "Active Throttle 3", "pullup": 47000 },
{ "id":19, "channel": "Analog 19", "name": "Active Throttle 4", "pullup": 47000 },
{ "id":20, "channel": "Analog 20" },
{ "id":21, "channel": "Analog 21" },
{ "id":22, "channel": "Analog 22" },
{ "id":23, "channel": "Analog 23" },
{ "id":24, "channel": "Analog 24" },
{ "id":25, "channel": "Analog 25" },
{ "id":26, "channel": "Analog 26" },
{ "id":27, "channel": "Analog 27" },
{ "id":28, "channel": "Analog 28" },
{ "id":29, "channel": "Analog 29" },
{ "id":30, "channel": "Analog 30" },
{ "id":31, "channel": "Analog 31" }
],
// Identify options that route PWM numbers to virtual output 'pins'.
// not all PWM channels are routable.
"pwms": [
// options are auto assigned, if option starts with "PWM10".
// otherwise could be overridden here?
// PWM10 (on/off)
// PWM10 Period
// PWM10 Invert
{
"id": 1,
"out_pin": 8
},
{
"id": 2,
"out_pin": 9
},
{
"id": 3,
"out_pin": 10
},
{
"id": 4,
"out_pin": 11
},
{
"id": 5,
"out_pin": 12
},
{
"id": 6,
"out_pin": 13
},
{
"id": 7,
"out_pin": 14
},
{
"id": 8,
"out_pin": 15
},
{
"id": 9,
"out_pin": 16
},
{
"id": 10,
"out_pin": 17
},
{
"id": 11,
"out_pin": 18
},
{
"id": 12,
"out_pin": 19
},
{
"id": 13,
"out_pin": 20
},
{
"id": 14,
"out_pin": 21
},
{
"id": 15,
"out_pin": 22
},
{
"id": 16,
"out_pin": 23
},
],
// Identify any options that should be interpreted as PWM selectors.
"pwm_options": [
"Out $* PWM",
"Out $* PWM$N", // e.g. Out Idle PWM1
"Out $* PWM#$N", // e.g. Out VVC#1 PWM#1
],
"pwm_options_exclude":[],
// Identify options that route to virtual output 'pins'.
// Note: exclusions are processed before inclusions.
"out_pin_options_exclude": [
"Out $* PWM",
"Out $* PWM$N", // e.g. exclude Out Idle PWM1
"Out $* PWM#$N", // e.g. exclude Out VVC#1 PWM#1
],
"out_pin_options": [
"Out $*", // Note this also would match PWM module outputs, they are excluded by the "out_pin_options_exclude" clause.
"Oil Feed $N Out",
],
}