mirror of https://github.com/nymea/nymea.git
512 lines
21 KiB
JSON
512 lines
21 KiB
JSON
{
|
|
"name": "Mock Devices",
|
|
"idName": "MockDevice",
|
|
"id": "727a4a9a-c187-446f-aadf-f1b2220607d1",
|
|
"paramTypes": [
|
|
{
|
|
"name": "configParamInt",
|
|
"type": "int",
|
|
"defaultValue": 42,
|
|
"minValue": 1,
|
|
"maxValue": 50
|
|
},
|
|
{
|
|
"name": "configParamBool",
|
|
"type": "bool",
|
|
"defaultValue": true
|
|
}
|
|
],
|
|
"vendors": [
|
|
{
|
|
"name": "guh",
|
|
"idName": "guh",
|
|
"id": "2062d64d-3232-433c-88bc-0d33c0ba2ba6",
|
|
"deviceClasses": [
|
|
{
|
|
"deviceClassId": "753f0d32-0468-4d08-82ed-1964aab03298",
|
|
"idName": "mock",
|
|
"name": "Mock Device",
|
|
"deviceIcon": "Tune",
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator",
|
|
"Gateway"
|
|
],
|
|
"createMethods": ["user", "discovery"],
|
|
"discoveryParamTypes": [
|
|
{
|
|
"name": "resultCount",
|
|
"type": "int",
|
|
"defaultValue": 2,
|
|
"allowedValues": [1, 2]
|
|
}
|
|
],
|
|
"paramTypes": [
|
|
{
|
|
"name": "httpport",
|
|
"type": "int"
|
|
},
|
|
{
|
|
"name": "async",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"readOnly": true
|
|
},
|
|
{
|
|
"name": "broken",
|
|
"type": "bool",
|
|
"defaultValue": false
|
|
}
|
|
],
|
|
"stateTypes": [
|
|
{
|
|
"id": "80baec19-54de-4948-ac46-31eabfaceb83",
|
|
"name": "Dummy int state",
|
|
"defaultValue": 10,
|
|
"type": "int"
|
|
},
|
|
{
|
|
"id": "9dd6a97c-dfd1-43dc-acbd-367932742310",
|
|
"name": "Dummy bool state",
|
|
"defaultValue": false,
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"eventTypes": [
|
|
{
|
|
"id": "45bf3752-0fc6-46b9-89fd-ffd878b5b22b",
|
|
"name": "Mock Event 1"
|
|
},
|
|
{
|
|
"id": "863d5920-b1cf-4eb9-88bd-8f7b8583b1cf",
|
|
"name": "Mock Event 2",
|
|
"paramTypes": [
|
|
{
|
|
"name": "mockParamInt",
|
|
"type": "int",
|
|
"defaultValue": 10
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"actionTypes": [
|
|
{
|
|
"id": "dea0f4e1-65e3-4981-8eaa-2701c53a9185",
|
|
"name": "Mock Action 1 (with params)",
|
|
"paramTypes": [
|
|
{
|
|
"name": "mockActionParam1",
|
|
"type": "int"
|
|
},
|
|
{
|
|
"name": "mockActionParam2",
|
|
"type": "bool"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "defd3ed6-1a0d-400b-8879-a0202cf39935",
|
|
"name": "Mock Action 2 (without params)"
|
|
},
|
|
{
|
|
"id": "fbae06d3-7666-483e-a39e-ec50fe89054e",
|
|
"idName": "mockAsync",
|
|
"name": "Mock Action 3 (async)"
|
|
},
|
|
{
|
|
"id": "df3cf33d-26d5-4577-9132-9823bd33fad0",
|
|
"idName": "mockFailing",
|
|
"name": "Mock Action 4 (broken)"
|
|
},
|
|
{
|
|
"id": "bfe89a1d-3497-4121-8318-e77c37537219",
|
|
"idName": "mockAsyncFailing",
|
|
"name": "Mock Action 5 (async, broken)"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "ab4257b3-7548-47ee-9bd4-7dc3004fd197",
|
|
"idName": "mockDeviceAuto",
|
|
"name": "Mock Device (Auto created)",
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator",
|
|
"Gateway"
|
|
],
|
|
"createMethods": ["auto"],
|
|
"deviceIcon": "Tune",
|
|
"paramTypes": [
|
|
{
|
|
"name": "httpport",
|
|
"type": "int"
|
|
},
|
|
{
|
|
"name": "async",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"readOnly": true
|
|
},
|
|
{
|
|
"name": "broken",
|
|
"type": "bool",
|
|
"defaultValue": false
|
|
}
|
|
],
|
|
"stateTypes": [
|
|
{
|
|
"id": "80baec19-54de-4948-ac46-31eabfaceb83",
|
|
"name": "Dummy int state",
|
|
"defaultValue": 10,
|
|
"type": "int"
|
|
},
|
|
{
|
|
"id": "9dd6a97c-dfd1-43dc-acbd-367932742310",
|
|
"name": "Dummy bool state",
|
|
"defaultValue": false,
|
|
"type": "bool"
|
|
}
|
|
],
|
|
"eventTypes": [
|
|
{
|
|
"id": "45bf3752-0fc6-46b9-89fd-ffd878b5b22b",
|
|
"name": "Mock Event 1"
|
|
},
|
|
{
|
|
"id": "863d5920-b1cf-4eb9-88bd-8f7b8583b1cf",
|
|
"name": "Mock Event 2",
|
|
"paramTypes": [
|
|
{
|
|
"name": "mockParamInt",
|
|
"type": "int",
|
|
"defaultValue": 10
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"actionTypes": [
|
|
{
|
|
"id": "dea0f4e1-65e3-4981-8eaa-2701c53a9185",
|
|
"name": "Mock Action 1 (with params)",
|
|
"paramTypes": [
|
|
{
|
|
"name": "mockActionParam1",
|
|
"type": "int"
|
|
},
|
|
{
|
|
"name": "mockActionParam2",
|
|
"type": "bool"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"id": "defd3ed6-1a0d-400b-8879-a0202cf39935",
|
|
"name": "Mock Action 2 (without params)"
|
|
},
|
|
{
|
|
"id": "fbae06d3-7666-483e-a39e-ec50fe89054e",
|
|
"name": "Mock Action 3 (async)"
|
|
},
|
|
{
|
|
"id": "df3cf33d-26d5-4577-9132-9823bd33fad0",
|
|
"name": "Mock Action 4 (broken)"
|
|
},
|
|
{
|
|
"id": "bfe89a1d-3497-4121-8318-e77c37537219",
|
|
"name": "Mock Action 5 (async, broken)"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "9e03144c-e436-4eea-82d9-ccb33ef778db",
|
|
"idName": "mockPushButton",
|
|
"name": "Mock Device (Push Button)",
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator",
|
|
"Gateway"
|
|
],
|
|
"createMethods": ["discovery"],
|
|
"setupMethod": "pushButton",
|
|
"deviceIcon": "Tune",
|
|
"pairingInfo": "Wait 3 second before you continue, the push button will be pressed automatically.",
|
|
"discoveryParamTypes": [
|
|
{
|
|
"name": "resultCount",
|
|
"type": "int",
|
|
"defaultValue": 2,
|
|
"allowedValues": [1, 2]
|
|
}
|
|
],
|
|
"stateTypes": [
|
|
{
|
|
"id": "20dc7c22-c50e-42db-837c-2bbced939f8e",
|
|
"idName": "color",
|
|
"name": "color",
|
|
"type": "QColor",
|
|
"defaultValue": "#000000",
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "72981c04-267a-4ba0-a59e-9921d2f3af9c",
|
|
"idName": "percentage",
|
|
"name": "percentage",
|
|
"type": "int",
|
|
"unit": "Percentage",
|
|
"defaultValue": 0,
|
|
"minValue": 0,
|
|
"maxValue": 100,
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "05f63f9c-f61e-4dcf-ad55-3f13fde2765b",
|
|
"idName": "allowedValues",
|
|
"name": "allowed values",
|
|
"type": "QString",
|
|
"defaultValue": "String value 2",
|
|
"possibleValues": [
|
|
"String value 1",
|
|
"String value 2",
|
|
"String value 3",
|
|
"String value 4"
|
|
],
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "53cd7c55-49b7-441b-b970-9048f20f0e2c",
|
|
"idName": "double",
|
|
"name": "double value",
|
|
"type": "double",
|
|
"defaultValue": 0.0,
|
|
"minValue": -100.0,
|
|
"maxValue": 100.0,
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "e680f7a4-b39e-46da-be41-fa3170fe3768",
|
|
"idName": "bool",
|
|
"name": "bool value",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"writable": true
|
|
}
|
|
],
|
|
"actionTypes": [
|
|
{
|
|
"id": "54646e7c-bc54-4895-81a2-590d72d120f9",
|
|
"idName": "timeout",
|
|
"name": "Timeout action"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "296f1fd4-e893-46b2-8a42-50d1bceb8730",
|
|
"idName": "mockDisplayPin",
|
|
"name": "Mock Device (Display Pin)",
|
|
"deviceIcon": "Tune",
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator",
|
|
"Gateway"
|
|
],
|
|
"createMethods": ["discovery"],
|
|
"setupMethod": "displayPin",
|
|
"pairingInfo": "Please enter the secret which normaly will be displayed on the device. For the mockdevice the pin is 243681.",
|
|
"discoveryParamTypes": [
|
|
{
|
|
"name": "resultCount",
|
|
"type": "int",
|
|
"defaultValue": 2,
|
|
"allowedValues": [1, 2]
|
|
}
|
|
],
|
|
"paramTypes": [
|
|
{
|
|
"name": "pin",
|
|
"type": "QString",
|
|
"inputType": "TextLine",
|
|
"defaultValue": "243681",
|
|
"readOnly": true
|
|
}
|
|
],
|
|
"stateTypes": [
|
|
{
|
|
"id": "20dc7c22-c50e-42db-837c-2bbced939f8e",
|
|
"idName": "color",
|
|
"name": "color",
|
|
"type": "QColor",
|
|
"defaultValue": "#000000",
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "72981c04-267a-4ba0-a59e-9921d2f3af9c",
|
|
"idName": "percentage",
|
|
"name": "percentage",
|
|
"type": "int",
|
|
"unit": "Percentage",
|
|
"defaultValue": 0,
|
|
"minValue": 0,
|
|
"maxValue": 100,
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "05f63f9c-f61e-4dcf-ad55-3f13fde2765b",
|
|
"idName": "allowedValues",
|
|
"name": "allowed values",
|
|
"type": "QString",
|
|
"defaultValue": "String value 1",
|
|
"possibleValues": [
|
|
"String value 1",
|
|
"String value 2",
|
|
"String value 3",
|
|
"String value 4"
|
|
],
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "53cd7c55-49b7-441b-b970-9048f20f0e2c",
|
|
"idName": "double",
|
|
"name": "double value",
|
|
"type": "double",
|
|
"defaultValue": 0.0,
|
|
"minValue": -100.0,
|
|
"maxValue": 100.0,
|
|
"writable": true
|
|
},
|
|
{
|
|
"id": "e680f7a4-b39e-46da-be41-fa3170fe3768",
|
|
"idName": "bool",
|
|
"name": "bool value",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"writable": true
|
|
}
|
|
],
|
|
"actionTypes": [
|
|
{
|
|
"id": "54646e7c-bc54-4895-81a2-590d72d120f9",
|
|
"idName": "timeout",
|
|
"name": "Timeout action"
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "a71fbde9-9a38-4bf8-beab-c8aade2608ba",
|
|
"idName": "mockParent",
|
|
"name": "Mock Device (Parent)",
|
|
"deviceIcon": "Tune",
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator",
|
|
"Gateway"
|
|
],
|
|
"createMethods": ["user"],
|
|
"stateTypes": [
|
|
{
|
|
"id": "d24ede5f-4064-4898-bb84-cfb533b1fbc0",
|
|
"idName": "boolValue",
|
|
"name": "bool value",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"writable": true
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "40893c9f-bc47-40c1-8bf7-b390c7c1b4fc",
|
|
"idName": "mockChild",
|
|
"name": "Mock Device (Child)",
|
|
"createMethods": ["auto"],
|
|
"basicTags": [
|
|
"Device",
|
|
"Actuator"
|
|
],
|
|
"paramTypes": [
|
|
{
|
|
"name": "parent uuid",
|
|
"type": "QUuid",
|
|
"readOnly": true
|
|
}
|
|
],
|
|
"stateTypes": [
|
|
{
|
|
"id": "d24ede5f-4064-4898-bb84-cfb533b1fbc0",
|
|
"idName": "boolValue",
|
|
"name": "bool value",
|
|
"type": "bool",
|
|
"defaultValue": false,
|
|
"writable": true
|
|
}
|
|
]
|
|
},
|
|
{
|
|
"deviceClassId": "515ffdf1-55e5-498d-9abc-4e2fe768f3a9",
|
|
"idName": "mockInputType",
|
|
"name": "Mock Device (InputTypes)",
|
|
"deviceIcon": "Tune",
|
|
"basicTags": [
|
|
"Device"
|
|
],
|
|
"createMethods": ["user"],
|
|
"paramTypes": [
|
|
{
|
|
"name": "Text line",
|
|
"type": "QString",
|
|
"inputType": "TextLine",
|
|
"defaultValue": "This is a text line"
|
|
},
|
|
{
|
|
"name": "Text area",
|
|
"type": "QString",
|
|
"inputType": "TextArea",
|
|
"defaultValue": "This is a text area"
|
|
},
|
|
{
|
|
"name": "Password text",
|
|
"type": "QString",
|
|
"inputType": "Password",
|
|
"defaultValue": "secret"
|
|
},
|
|
{
|
|
"name": "Search text",
|
|
"type": "QString",
|
|
"inputType": "Search",
|
|
"defaultValue": "Search text..."
|
|
},
|
|
{
|
|
"name": "Mail address",
|
|
"type": "QString",
|
|
"inputType": "Mail",
|
|
"defaultValue": "name@example.com"
|
|
},
|
|
{
|
|
"name": "IPv4 address",
|
|
"type": "QString",
|
|
"inputType": "IPv4Address",
|
|
"defaultValue": "127.0.0.1"
|
|
},
|
|
{
|
|
"name": "IPv6 address",
|
|
"type": "QString",
|
|
"inputType": "IPv6Address",
|
|
"defaultValue": "::1"
|
|
},
|
|
{
|
|
"name": "URL",
|
|
"type": "QString",
|
|
"inputType": "Url",
|
|
"defaultValue": "http://guh.guru"
|
|
},
|
|
{
|
|
"name": "Mac address",
|
|
"type": "QString",
|
|
"inputType": "MacAddress",
|
|
"defaultValue": "11:22:33:aa:bb:cc"
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|