{
  "$schema": "https://raw.githubusercontent.com/nobrega8/mbmap-library/main/schema/mbmap-2.schema.json",
  "mbmap": 2,
  "vendor": "Unipi Technology",
  "model": "UniPi 1.1",
  "models": ["Unipi 1.1", "UniPi 1.1"],
  "vendor_website": "www.unipi.technology",
  "description": "Unipi 1.1 controller: 12 digital inputs, 8 relay outputs, 1 analog output, 2 analog inputs",
  "revision": 3,
  "revised": "2026-11-10",
  "source": "unipi-11-modbus-map.xlsx, Unipi knowledge base page https://kb.unipi.technology/en:hw:04-extensions:downloads",
  "sources": [
    {"title": "Unipi 1.1 Modbus map (unipi-11-modbus-map.xlsx)", "url": "https://kb.unipi.technology/_media/files:products:unipi1:unipi-11-modbus-map.xlsx", "note": "Sheets Registers, Coils and Description; listed on https://kb.unipi.technology/en:hw:04-extensions:downloads"}
  ],
  "notes": [
    "Configuration is not permanently saved: the Description sheet states it is set on each power-on. Defaults: counters 0, debounce 0 ms, outputs OFF.",
    "Multi-register values (counters, floats) are taken as big-endian (most significant register first), as in the other Unipi maps; the spreadsheet only says bit 0 is the LSB and bit 15 the MSB.",
    "The spreadsheet does not state the transport or default unit id, so the format defaults (tcp+rtu, unit 1) are kept.",
    "Coils repeat the relay outputs that also appear as bits of holding register 1.",
    "Analog Output 1 is documented as 'int16, 0..4000 ~ 0..10V': mapped as int16 with 0.0025 V per count and a 0-10 V write range. The unit of the analog input floats is not stated in the spreadsheet, so none is set.",
    "The counter of Digital Input 12 is a uint16 (one register) in the spreadsheet; the other counters are uint32."
  ],
  "byte_order": "big",
  "word_order": "big",
  "address_base": 0,
  "x_status": "official",
  "registers": [
    {"name": "Digital Input 1", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 0},
    {"name": "Digital Input 2", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 1},
    {"name": "Digital Input 3", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 2},
    {"name": "Digital Input 4", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 3},
    {"name": "Digital Input 5", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 4},
    {"name": "Digital Input 6", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 5},
    {"name": "Digital Input 7", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 6},
    {"name": "Digital Input 8", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 7},
    {"name": "Digital Input 9", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 8},
    {"name": "Digital Input 10", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 9},
    {"name": "Digital Input 11", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 10},
    {"name": "Digital Input 12", "group": "Digital inputs", "area": "holding", "address": 0, "type": "bool", "bit": 11},
    {"name": "Relay Output 1", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 0, "access": "RW"},
    {"name": "Relay Output 2", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 1, "access": "RW"},
    {"name": "Relay Output 3", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 2, "access": "RW"},
    {"name": "Relay Output 4", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 3, "access": "RW"},
    {"name": "Relay Output 5", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 4, "access": "RW"},
    {"name": "Relay Output 6", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 5, "access": "RW"},
    {"name": "Relay Output 7", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 6, "access": "RW"},
    {"name": "Relay Output 8", "group": "Relay outputs", "area": "holding", "address": 1, "type": "bool", "bit": 7, "access": "RW"},
    {"name": "Analog Output 1", "group": "Analog outputs", "area": "holding", "address": 2, "type": "int16", "access": "RW", "scale": 0.0025, "unit": "V", "write_min": 0, "write_max": 10, "description": "Raw 0..4000 corresponds to 0..10 V"},
    {"name": "Analog Input 1", "group": "Analog inputs", "area": "holding", "address": 3, "type": "float32"},
    {"name": "Analog Input 2", "group": "Analog inputs", "area": "holding", "address": 5, "type": "float32"},
    {"name": "Counter of Digital Input 1", "group": "Counters", "area": "holding", "address": 7, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 2", "group": "Counters", "area": "holding", "address": 9, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 3", "group": "Counters", "area": "holding", "address": 11, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 4", "group": "Counters", "area": "holding", "address": 13, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 5", "group": "Counters", "area": "holding", "address": 15, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 6", "group": "Counters", "area": "holding", "address": 17, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 7", "group": "Counters", "area": "holding", "address": 19, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 8", "group": "Counters", "area": "holding", "address": 21, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 9", "group": "Counters", "area": "holding", "address": 23, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 10", "group": "Counters", "area": "holding", "address": 25, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 11", "group": "Counters", "area": "holding", "address": 27, "type": "uint32", "access": "RW"},
    {"name": "Counter of Digital Input 12", "group": "Counters", "area": "holding", "address": 29, "type": "uint16", "access": "RW"},
    {"name": "Debounce time (in 100us) for DI 1", "group": "Debounce", "area": "holding", "address": 1010, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 2", "group": "Debounce", "area": "holding", "address": 1011, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 3", "group": "Debounce", "area": "holding", "address": 1012, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 4", "group": "Debounce", "area": "holding", "address": 1013, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 5", "group": "Debounce", "area": "holding", "address": 1014, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 6", "group": "Debounce", "area": "holding", "address": 1015, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 7", "group": "Debounce", "area": "holding", "address": 1016, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 8", "group": "Debounce", "area": "holding", "address": 1017, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 9", "group": "Debounce", "area": "holding", "address": 1018, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 10", "group": "Debounce", "area": "holding", "address": 1019, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 11", "group": "Debounce", "area": "holding", "address": 1020, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Debounce time (in 100us) for DI 12", "group": "Debounce", "area": "holding", "address": 1021, "type": "uint16", "access": "RW", "scale": 100, "unit": "µs"},
    {"name": "Analog Output PWM frequency", "group": "Analog outputs", "area": "holding", "address": 1022, "type": "uint16", "access": "RW"},
    {"name": "Analog Input 1 resolution", "group": "Analog inputs", "area": "holding", "address": 1023, "type": "uint16", "access": "RW", "description": "Resolution in bits; default 18"},
    {"name": "Analog Input 2 resolution", "group": "Analog inputs", "area": "holding", "address": 1024, "type": "uint16", "access": "RW", "description": "Resolution in bits; default 18"},
    {"name": "Relay Output 1 (coil)", "group": "Relay outputs", "area": "coil", "address": 0, "type": "bool", "access": "RW"},
    {"name": "Relay Output 2 (coil)", "group": "Relay outputs", "area": "coil", "address": 1, "type": "bool", "access": "RW"},
    {"name": "Relay Output 3 (coil)", "group": "Relay outputs", "area": "coil", "address": 2, "type": "bool", "access": "RW"},
    {"name": "Relay Output 4 (coil)", "group": "Relay outputs", "area": "coil", "address": 3, "type": "bool", "access": "RW"},
    {"name": "Relay Output 5 (coil)", "group": "Relay outputs", "area": "coil", "address": 4, "type": "bool", "access": "RW"},
    {"name": "Relay Output 6 (coil)", "group": "Relay outputs", "area": "coil", "address": 5, "type": "bool", "access": "RW"},
    {"name": "Relay Output 7 (coil)", "group": "Relay outputs", "area": "coil", "address": 6, "type": "bool", "access": "RW"},
    {"name": "Relay Output 8 (coil)", "group": "Relay outputs", "area": "coil", "address": 7, "type": "bool", "access": "RW"}
  ]
}
