Okay, jetzt funktioniert alles. Hier nochmal der aktualisierte Flow.
[
{
"id": "f6f2187d.f17ca8",
"type": "tab",
"label": "Flow 1",
"disabled": false,
"info": ""
},
{
"id": "3cc11d24.ff01a2",
"type": "comment",
"z": "f6f2187d.f17ca8",
"name": "WARNING: please check you have started this container with a volume that is mounted to /data\\n otherwise any flow changes are lost when you redeploy or upgrade the container\\n (e.g. upgrade to a more recent node-red docker image).\\n If you are using named volumes you can ignore this warning.\\n Double click or see info side panel to learn how to start Node-RED in Docker to save your work",
"info": "\nTo start docker with a bind mount volume (-v option), for example:\n\n```\ndocker run -it -p 1880:1880 -v /home/user/node_red_data:/data --name mynodered nodered/node-red\n```\n\nwhere `/home/user/node_red_data` is a directory on your host machine where you want to store your flows.\n\nIf you do not do this then you can experiment and redploy flows, but if you restart or upgrade the container the flows will be disconnected and lost. \n\nThey will still exist in a hidden data volume, which can be recovered using standard docker techniques, but that is much more complex than just starting with a named volume as described above.",
"x": 350,
"y": 80,
"wires": [ ]
},
{
"id": "4ae7cfad.ef2f9",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/get_status",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 130,
"y": 280,
"wires": [ [ "7151f9b3.64a868" ] ]
},
{
"id": "80b490f1.a70b5",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/stop_ac",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 120,
"y": 1000,
"wires": [ [ "35e227cd.4f7fc8" ] ]
},
{
"id": "2722c4a8.0a071c",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/start_ac",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 120,
"y": 920,
"wires": [ [ "183e42b8.b4fc8d" ] ]
},
{
"id": "7151f9b3.64a868",
"type": "car-status",
"z": "f6f2187d.f17ca8",
"name": "Get status",
"dorefresh": true,
"parsed": false,
"bluelinky": "57d6beca.e51cc",
"x": 410,
"y": 200,
"wires": [ [ "478f506c.59b44", "8c0e1278.48eeb", "1e89420e.7d352e", "3072f27c.87c05e", "f86a0cc1.73cb7", "3a80f56c.0836fa", "b0d6fbd7.64da38", "863a07ce.085bd8", "e7b544a.406a8b8", "49d564f1.3e30ac", "b2af16e1.8e9e48" ] ]
},
{
"id": "a2f10779.7ad2c8",
"type": "start-car",
"z": "f6f2187d.f17ca8",
"name": "Start car",
"bluelinky": "57d6beca.e51cc",
"x": 460,
"y": 920,
"wires": [ [ "478f506c.59b44" ] ],
"inputLabels": [ "airTempvalue: 19.0" ],
"info": "19"
},
{
"id": "35e227cd.4f7fc8",
"type": "stop-car",
"z": "f6f2187d.f17ca8",
"name": "Stop car",
"bluelinky": "57d6beca.e51cc",
"x": 460,
"y": 1000,
"wires": [ [ "478f506c.59b44" ] ]
},
{
"id": "478f506c.59b44",
"type": "debug",
"z": "f6f2187d.f17ca8",
"name": "",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"targetType": "msg",
"statusVal": "",
"statusType": "auto",
"x": 770,
"y": 920,
"wires": [ ]
},
{
"id": "4a75fc2f.1e51e4",
"type": "unlock-car",
"z": "f6f2187d.f17ca8",
"name": "Unlock car",
"bluelinky": "57d6beca.e51cc",
"x": 470,
"y": 1080,
"wires": [ [ "478f506c.59b44", "a10b38ae.94e5d8" ] ]
},
{
"id": "2eef0961.a65396",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/unlock_car",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 130,
"y": 1080,
"wires": [ [ "4a75fc2f.1e51e4" ] ]
},
{
"id": "250acff4.b367",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/lock_car",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 120,
"y": 1160,
"wires": [ [ "19c514c7.ca8aab" ] ]
},
{
"id": "19c514c7.ca8aab",
"type": "lock-car",
"z": "f6f2187d.f17ca8",
"name": "Lock car",
"bluelinky": "57d6beca.e51cc",
"x": 460,
"y": 1160,
"wires": [ [ "478f506c.59b44", "a10b38ae.94e5d8" ] ]
},
{
"id": "cbdfadee.54f1c",
"type": "car-location",
"z": "f6f2187d.f17ca8",
"name": "Get car location",
"bluelinky": "57d6beca.e51cc",
"x": 480,
"y": 1240,
"wires": [ [ "2e394950.ce9296", "478f506c.59b44" ] ]
},
{
"id": "421c6f20.cb61f",
"type": "car-odometer",
"z": "f6f2187d.f17ca8",
"name": "Get car odometer",
"bluelinky": "57d6beca.e51cc",
"x": 450,
"y": 780,
"wires": [ [ "478f506c.59b44", "c85df5a1.7c67f8" ] ]
},
{
"id": "ae4a76ba.d1b7e8",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/get_odometer",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 140,
"y": 780,
"wires": [ [ "421c6f20.cb61f" ] ]
},
{
"id": "a10b38ae.94e5d8",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/doors",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 740,
"y": 1160,
"wires": [ ]
},
{
"id": "3493be44.5a6802",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/odometer",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 870,
"y": 780,
"wires": [ ]
},
{
"id": "cc998b60.1f7408",
"type": "mqtt in",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "cmnd/bluelinky/get_location",
"qos": "2",
"datatype": "auto",
"broker": "36dd9767.956ae8",
"x": 140,
"y": 1240,
"wires": [ [ "cbdfadee.54f1c" ] ]
},
{
"id": "2e394950.ce9296",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/location",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 750,
"y": 1240,
"wires": [ ]
},
{
"id": "47d9808d.1454b",
"type": "inject",
"z": "f6f2187d.f17ca8",
"name": "Every 12h",
"props": [
{ "p": "payload" },
{
"p": "topic",
"vt": "str"
}
],
"repeat": "43200",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "",
"payloadType": "date",
"x": 110,
"y": 200,
"wires": [ [ "7151f9b3.64a868" ] ]
},
{
"id": "8c0e1278.48eeb",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "doorLock",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.doorLock",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 800,
"y": 160,
"wires": [ [ "4a2701d1.43ed1" ] ]
},
{
"id": "4a2701d1.43ed1",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/doorLock",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1010,
"y": 160,
"wires": [ ]
},
{
"id": "c85df5a1.7c67f8",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "odometer",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.value",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 680,
"y": 780,
"wires": [ [ "3493be44.5a6802" ] ]
},
{
"id": "f0bdbf6f.5a26c",
"type": "inject",
"z": "f6f2187d.f17ca8",
"name": "Every 24h",
"props": [
{ "p": "payload" },
{
"p": "topic",
"vt": "str"
}
],
"repeat": "86400",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "",
"payload": "",
"payloadType": "date",
"x": 110,
"y": 720,
"wires": [ [ "421c6f20.cb61f" ] ]
},
{
"id": "1e89420e.7d352e",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "engine",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.engine",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 790,
"y": 220,
"wires": [ [ "aa799088.efbc5" ] ]
},
{
"id": "aa799088.efbc5",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/engine",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1000,
"y": 220,
"wires": [ ]
},
{
"id": "3072f27c.87c05e",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "airCtrlOn",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.airCtrlOn",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 800,
"y": 280,
"wires": [ [ "f5d01011.764f6" ] ]
},
{
"id": "f5d01011.764f6",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/airCtrlOn",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1010,
"y": 280,
"wires": [ ]
},
{
"id": "f86a0cc1.73cb7",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "trunkOpen",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.trunkOpen",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 810,
"y": 340,
"wires": [ [ "e603126b.6a562" ] ]
},
{
"id": "e603126b.6a562",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/trunkOpen",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1020,
"y": 340,
"wires": [ ]
},
{
"id": "3a80f56c.0836fa",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "hoodOpen",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.hoodOpen",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 810,
"y": 400,
"wires": [ [ "5a7d883c.e56228" ] ]
},
{
"id": "5a7d883c.e56228",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/hoodOpen",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1020,
"y": 400,
"wires": [ ]
},
{
"id": "863a07ce.085bd8",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "batteryStatus",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.evStatus.batteryStatus",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 810,
"y": 460,
"wires": [ [ "b7ab78d8.2186c8" ] ]
},
{
"id": "b7ab78d8.2186c8",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/batteryStatus",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1020,
"y": 460,
"wires": [ ]
},
{
"id": "49d564f1.3e30ac",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "defrost",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.defrost",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 790,
"y": 640,
"wires": [ [ "6309573b.8b5f08" ] ]
},
{
"id": "6309573b.8b5f08",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/defrost",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1000,
"y": 640,
"wires": [ ]
},
{
"id": "e7b544a.406a8b8",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "acc",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.scc",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 790,
"y": 580,
"wires": [ [ "8b622bcc.94d9d8" ] ]
},
{
"id": "8b622bcc.94d9d8",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/acc",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 990,
"y": 580,
"wires": [ ]
},
{
"id": "b0d6fbd7.64da38",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "batteryCharge",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.evStatus.batteryCharge",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 820,
"y": 520,
"wires": [ [ "35d69904.5e8b16" ] ]
},
{
"id": "35d69904.5e8b16",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/batteryCharge",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1030,
"y": 520,
"wires": [ ]
},
{
"id": "b2af16e1.8e9e48",
"type": "change",
"z": "f6f2187d.f17ca8",
"name": "range",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "payload.status.evStatus.drvDistance[0].rangeByFuel.evModeRange.value",
"tot": "msg"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 790,
"y": 700,
"wires": [ [ "1e875e4.f7566a2" ] ]
},
{
"id": "1e875e4.f7566a2",
"type": "mqtt out",
"z": "f6f2187d.f17ca8",
"name": "",
"topic": "bluelinky/range",
"qos": "",
"retain": "",
"broker": "36dd9767.956ae8",
"x": 1000,
"y": 700,
"wires": [ ]
},
{
"id": "183e42b8.b4fc8d",
"type": "json",
"z": "f6f2187d.f17ca8",
"name": "",
"property": "payload",
"action": "",
"pretty": false,
"x": 310,
"y": 920,
"wires": [ [ "a2f10779.7ad2c8" ] ]
},
{
"id": "36dd9767.956ae8",
"type": "mqtt-broker",
"name": "mosquitto",
"broker": "<IP>",
"port": "1883",
"clientid": "",
"usetls": false,
"compatmode": false,
"keepalive": "60",
"cleansession": true,
"birthTopic": "",
"birthQos": "0",
"birthPayload": "",
"closeTopic": "",
"closeQos": "0",
"closePayload": "",
"willTopic": "",
"willQos": "0",
"willPayload": ""
},
{
"id": "57d6beca.e51cc",
"type": "bluelinky",
"username": "<Username>",
"password": "<password>",
"region": "EU",
"pin": "<pin>",
"vin": "<vin>"
}
]