Skip to content

Instantly share code, notes, and snippets.

@spicydog
Last active January 19, 2025 14:52
Show Gist options
  • Save spicydog/c57db3f4d2ceef86402438bcab844f1f to your computer and use it in GitHub Desktop.
Save spicydog/c57db3f4d2ceef86402438bcab844f1f to your computer and use it in GitHub Desktop.
2025-01-19 Node-RED - WiCAN - Ora Good Cat Configuration
[
{
"id": "98b1bf097bdd05e6",
"type": "tab",
"label": "mqtt_wican",
"disabled": false,
"info": "",
"env": []
},
{
"id": "658f913256d958d5",
"type": "junction",
"z": "98b1bf097bdd05e6",
"x": 1460,
"y": 840,
"wires": [
[
"7f6271cb6ee00d54",
"e0bad1a558cb1871"
]
]
},
{
"id": "d1cfa7f97de75f03",
"type": "junction",
"z": "98b1bf097bdd05e6",
"x": 340,
"y": 280,
"wires": [
[
"0f9c0780a1996528",
"b4716d91d9838913",
"3d27a7b7e513df51",
"86e41428db703a90",
"14e2d71dd9b54b10",
"7a0addfeb138de77"
]
]
},
{
"id": "8937164f2b998fe9",
"type": "junction",
"z": "98b1bf097bdd05e6",
"x": 340,
"y": 340,
"wires": [
[
"0f9c0780a1996528",
"b4716d91d9838913",
"3d27a7b7e513df51"
]
]
},
{
"id": "08c12d683c4228e5",
"type": "junction",
"z": "98b1bf097bdd05e6",
"x": 340,
"y": 400,
"wires": [
[
"7a0addfeb138de77",
"14e2d71dd9b54b10",
"86e41428db703a90"
]
]
},
{
"id": "a56bc299e74640c2",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "inject simulation",
"props": [
{
"p": "topic",
"vt": "str"
},
{
"p": "payload"
},
{
"p": "dry_run",
"v": "true",
"vt": "bool"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "wican/xxxxxxxxxxxx/can/rx",
"payload": "{\"bus\":\"0\",\"type\":\"rx\",\"ts\":7982,\"frame\":[{\"id\":1994,\"dlc\":8,\"rtr\":false,\"extd\":false,\"data\":[7,98,208,98,3,111,0,0]}]}",
"payloadType": "json",
"x": 260,
"y": 700,
"wires": [
[
"bd9a167725458950"
]
]
},
{
"id": "67efdce1f97e3534",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(hv_voltage)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\nconst output = (((b[4]*256)+b[5])/10)-450.5;\nmsg.output = output\nmsg.rx_type = 'hv_voltage'\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1140,
"y": 900,
"wires": [
[
"68a06f3057b7ac17",
"658f913256d958d5"
]
]
},
{
"id": "68a06f3057b7ac17",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat HV Battery Voltage)",
"entityConfig": "f67ac2c47dc31fd1",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1900,
"y": 900,
"wires": [
[]
]
},
{
"id": "bd9a167725458950",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "get(rx_type)",
"func": "const RX_TYPES = {\n 'soc': [7,98,208,98],\n // 'soe': [7, 98, 208, 98],\n\n 'hv_battery': [7,98,208,97],\n // 'hv_bus_current': [7,98,208,97],\n // 'hv_power': [7,98,208,97],\n // 'hv_voltage': [7,98,208,97],\n\n 'coolant_temperature': [7,98,208,49],\n\n 'mileage': [6,98,208,4],\n\n 'tire_pressure_front': [16,11],\n 'tire_pressure_rear': [33],\n};\n\nfunction get_rx_type(bytes) {\n for (const type in RX_TYPES) {\n const typeBytes = RX_TYPES[type];\n if (typeBytes.every((b, i) => bytes[i] === b)) {\n return type;\n }\n }\n return 'unknown';\n}\n\nmsg.type = 'unknown';\nif (msg.payload['type'] === 'rx') {\n const data = msg.payload[\"frame\"][0][\"data\"]\n msg.type = get_rx_type(data);\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 480,
"y": 780,
"wires": [
[
"f6cda5bdaa0923a2"
]
]
},
{
"id": "f6cda5bdaa0923a2",
"type": "switch",
"z": "98b1bf097bdd05e6",
"name": "switch(rx_type)",
"property": "type",
"propertyType": "msg",
"rules": [
{
"t": "eq",
"v": "soc",
"vt": "str"
},
{
"t": "eq",
"v": "hv_battery",
"vt": "str"
},
{
"t": "eq",
"v": "mileage",
"vt": "str"
},
{
"t": "eq",
"v": "coolant_temperature",
"vt": "str"
},
{
"t": "eq",
"v": "tire_pressure_front",
"vt": "str"
},
{
"t": "eq",
"v": "tire_pressure_rear",
"vt": "str"
}
],
"checkall": "true",
"repair": false,
"outputs": 6,
"x": 730,
"y": 780,
"wires": [
[
"b702623c6c53bfff",
"87a30a48a7bf0683"
],
[
"8eb310ed054c2512",
"8e6acb58343ceb0d",
"67efdce1f97e3534"
],
[
"251a8d6a284241af"
],
[
"e69d73f821f00c17"
],
[
"3920097a34f05a41",
"d4e9111b819f8e16"
],
[
"34ec062ff83f8864",
"9742bea25ce34979"
]
]
},
{
"id": "e69d73f821f00c17",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(coolant_temperature)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\nconst output = ((b[6]*256+b[7])-400)/10;\nmsg.output = output\nmsg.rx_type = 'coolant_temperature'\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1170,
"y": 1140,
"wires": [
[
"c70a8094bdc9f6d0",
"658f913256d958d5"
]
]
},
{
"id": "8e6acb58343ceb0d",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(hv_power)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\nconst output = -(((b[4]*256+b[5])*0.03425743)-274.108-0.05);\nmsg.output = output\nmsg.rx_type = 'hv_power'\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1140,
"y": 660,
"wires": [
[
"b0e52355f993252e",
"658f913256d958d5"
]
]
},
{
"id": "8eb310ed054c2512",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(hv_bus_current)",
"func": "var b = msg.payload[\"frame\"][0][\"data\"]\nvar output = -((b[4]*256) + b[5] - 8000)/10;\nmsg.output = output\nmsg.rx_type = 'hv_bus_current'\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1150,
"y": 780,
"wires": [
[
"a813de560d22cfcf",
"658f913256d958d5"
]
]
},
{
"id": "b702623c6c53bfff",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(soc)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\nconst output = ((b[4]*256) + b[5])/10;\nmsg.output = output\nmsg.rx_type = 'soc'\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1120,
"y": 540,
"wires": [
[
"a57dc230c443fb6c",
"658f913256d958d5"
]
]
},
{
"id": "251a8d6a284241af",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(mileage)",
"func": "var b = msg.payload[\"frame\"][0][\"data\"]\n\nmsg.rx_type = 'mileage'\nconst output = ((b[5]*256) + b[6]);\nif (output > 0) {\n msg.output = output\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1130,
"y": 1020,
"wires": [
[
"277e7f1971d7afbf",
"658f913256d958d5"
]
]
},
{
"id": "c70a8094bdc9f6d0",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Coolant Temperature)",
"entityConfig": "3c0951e0861b1a48",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1910,
"y": 1140,
"wires": [
[]
]
},
{
"id": "277e7f1971d7afbf",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Mileage)",
"entityConfig": "5e701cfbe29d1f94",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1870,
"y": 1020,
"wires": [
[]
]
},
{
"id": "b0e52355f993252e",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat HV Power)",
"entityConfig": "feecd6930e965964",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1870,
"y": 660,
"wires": [
[]
]
},
{
"id": "a813de560d22cfcf",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Bus Current)",
"entityConfig": "4fa38a80040891bb",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1880,
"y": 780,
"wires": [
[]
]
},
{
"id": "a57dc230c443fb6c",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat State of Charge)",
"entityConfig": "bd866571f94932fc",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1890,
"y": 540,
"wires": [
[]
]
},
{
"id": "530ac445acaf87d1",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "generate tx_payload",
"func": "const TX_TYPES = {\n \"soc\": {\n \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [3,34,208,98,170,170,170,170]\n },\n \"mileage\": {\n \"id\": 1931, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [3,34,208,4,170,170,170,170]\n },\n \"hv_battery\": {\n \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [3,34,208,97,170,170,170,170]\n },\n // \"hv_bus_current\": {\n // \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n // \"data\": [3,34,208,97,170,170,170,170]\n // },\n // \"hv_power\": {\n // \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n // \"data\": [3,34,208,97,170,170,170,170]\n // },\n // \"hv_voltage\": {\n // \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n // \"data\": [3,34,208,97,170,170,170,170]\n // },\n \"coolant_temperature\": {\n \"id\": 1930, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [3,34,208,49,170,170,170,170]\n },\n\n \"tire_pressure_front\": {\n \"id\": 1900, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [3,34,2,16,170,170,170,170]\n },\n\n \"tire_pressure_rear\": { // Not working!!\n \"id\": 1900, \"dlc\": 8, \"rtr\": false, \"extd\": false,\n \"data\": [48,0,0,170,170,170,170,170]\n },\n}\n\n\nfunction get_tx_payload(type) {\n const ts = Date.now();\n const payload = {\n \"bus\": \"0\",\n \"type\": \"tx\",\n \"tx_type\": msg.tx_type,\n \"ts\": ts,\n \"frame\": [\n TX_TYPES[type]\n ],\n };\n return payload;\n}\n\nmsg.tx_payload = get_tx_payload(msg.tx_type);\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1000,
"y": 300,
"wires": [
[
"3fbb9b509185c96a",
"024b3d44607aef17"
]
]
},
{
"id": "3fbb9b509185c96a",
"type": "debug",
"z": "98b1bf097bdd05e6",
"name": "debug(tx_payload)",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 1250,
"y": 240,
"wires": []
},
{
"id": "0f9c0780a1996528",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(soc)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "soc",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 570,
"y": 220,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "b4716d91d9838913",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(hv_battery)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "hv_battery",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 590,
"y": 280,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "3d27a7b7e513df51",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(coolant_temperature)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "coolant_temperature",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 620,
"y": 340,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "86e41428db703a90",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(mileage)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "mileage",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 580,
"y": 400,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "11f7a4e913d11ff6",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "trigger_every(10s)",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "10",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "every_10s",
"payload": "",
"payloadType": "date",
"x": 190,
"y": 340,
"wires": [
[
"8937164f2b998fe9"
]
]
},
{
"id": "9d4785880ab9226f",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "trigger_all",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "terigger_all",
"payload": "",
"payloadType": "date",
"x": 220,
"y": 280,
"wires": [
[
"d1cfa7f97de75f03"
]
]
},
{
"id": "47263bb7549bfcf8",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "trigger_every(60s)",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "60",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "every_60s",
"payload": "",
"payloadType": "date",
"x": 190,
"y": 400,
"wires": [
[
"08c12d683c4228e5"
]
]
},
{
"id": "da04a0ac278e19e5",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "trigger_once",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "trigger_once",
"payload": "",
"payloadType": "date",
"x": 210,
"y": 460,
"wires": [
[]
]
},
{
"id": "322c582e3d51ddea",
"type": "mqtt out",
"z": "98b1bf097bdd05e6",
"name": "mqtt_send(payload)",
"topic": "wican/xxxxxxxxxxxx/can/tx",
"qos": "0",
"retain": "false",
"respTopic": "",
"contentType": "",
"userProps": "",
"correl": "",
"expiry": "",
"broker": "8b0a417f59f61cf9",
"x": 1700,
"y": 300,
"wires": []
},
{
"id": "024b3d44607aef17",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "payload=tx_payload",
"rules": [
{
"t": "set",
"p": "payload",
"pt": "msg",
"to": "tx_payload",
"tot": "msg",
"dc": true
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 1260,
"y": 300,
"wires": [
[
"322c582e3d51ddea"
]
]
},
{
"id": "e0bad1a558cb1871",
"type": "debug",
"z": "98b1bf097bdd05e6",
"name": "debug(rx_payload)",
"active": false,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "true",
"targetType": "full",
"statusVal": "",
"statusType": "auto",
"x": 1610,
"y": 820,
"wires": []
},
{
"id": "7befa6f3093cc7fb",
"type": "mqtt in",
"z": "98b1bf097bdd05e6",
"name": "mqtt_recv",
"topic": "wican/xxxxxxxxxxxx/can/rx",
"qos": "0",
"datatype": "auto-detect",
"broker": "8b0a417f59f61cf9",
"nl": false,
"rap": true,
"rh": 0,
"inputs": 0,
"x": 280,
"y": 780,
"wires": [
[
"bd9a167725458950"
]
]
},
{
"id": "7f6271cb6ee00d54",
"type": "debug",
"z": "98b1bf097bdd05e6",
"name": "debug(output)",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "rx_type & ': ' & output",
"targetType": "jsonata",
"statusVal": "",
"statusType": "auto",
"x": 1600,
"y": 860,
"wires": []
},
{
"id": "87a30a48a7bf0683",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(soe)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\nconst output = ((b[6]*256) + b[7])/10;\n\nmsg.rx_type = 'soe'\nif (output > 0) {\n msg.output = output\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1120,
"y": 440,
"wires": [
[
"658f913256d958d5",
"b803329c8f68124a"
]
]
},
{
"id": "b803329c8f68124a",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat State of Energy)",
"entityConfig": "545669fd88c51a2e",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1890,
"y": 440,
"wires": [
[]
]
},
{
"id": "7c7dc633f4ef3f44",
"type": "mqtt in",
"z": "98b1bf097bdd05e6",
"name": "on WiCAN status changed",
"topic": "wican/xxxxxxxxxxxx/can/status",
"qos": "0",
"datatype": "auto-detect",
"broker": "8b0a417f59f61cf9",
"nl": false,
"rap": true,
"rh": 0,
"inputs": 0,
"x": 150,
"y": 140,
"wires": [
[
"d1cfa7f97de75f03"
]
]
},
{
"id": "3920097a34f05a41",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(tire_pressure_front_left)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\n\nmsg.rx_type = 'tire_pressure_front_left'\nconst output = b[5]*0.2-0.22;\nif (output > 10) {\n msg.output = output\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1180,
"y": 1240,
"wires": [
[
"658f913256d958d5",
"20b8af9a3536abfc"
]
]
},
{
"id": "d4e9111b819f8e16",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(tire_pressure_front_right)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\n\nmsg.rx_type = 'tire_pressure_front_right'\nconst output = b[7]*0.2-0.22;\nif (output > 10) {\n msg.output = output\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1180,
"y": 1320,
"wires": [
[
"658f913256d958d5",
"b202732538c873dc"
]
]
},
{
"id": "34ec062ff83f8864",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(tire_pressure_rear_left)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\n\nmsg.rx_type = 'tire_pressure_rear_left'\nconst output = b[2]*0.2-0.22;\nif (output > 10) {\n msg.output = output\n}\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1170,
"y": 1420,
"wires": [
[
"658f913256d958d5",
"8897cd78b4220754"
]
]
},
{
"id": "9742bea25ce34979",
"type": "function",
"z": "98b1bf097bdd05e6",
"name": "compute(tire_pressure_rear_right)",
"func": "const b = msg.payload[\"frame\"][0][\"data\"]\n\nmsg.rx_type = 'tire_pressure_rear_right'\nconst output = b[4]*0.2-0.22;\nif (output > 10) {\n msg.output = output\n}\n\nreturn msg;",
"outputs": 1,
"timeout": 0,
"noerr": 0,
"initialize": "",
"finalize": "",
"libs": [],
"x": 1180,
"y": 1500,
"wires": [
[
"658f913256d958d5",
"f93acc765bf42b0d"
]
]
},
{
"id": "20b8af9a3536abfc",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Front Left Tire Pressure)",
"entityConfig": "7f4eef0193b9666f",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1920,
"y": 1240,
"wires": [
[]
]
},
{
"id": "b202732538c873dc",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Front Right Tire Pressure)",
"entityConfig": "e7a7cfd3fa40f9a0",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1920,
"y": 1320,
"wires": [
[]
]
},
{
"id": "8897cd78b4220754",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Rear Left Tire Pressure)",
"entityConfig": "de57a198d65f3bd5",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1910,
"y": 1420,
"wires": [
[]
]
},
{
"id": "f93acc765bf42b0d",
"type": "ha-sensor",
"z": "98b1bf097bdd05e6",
"name": "sensor(Ora Good Cat Rear Right Tire Pressure)",
"entityConfig": "9ccac63f1148b7f9",
"version": 0,
"state": "output",
"stateType": "msg",
"attributes": [],
"inputOverride": "allow",
"outputProperties": [],
"x": 1920,
"y": 1500,
"wires": [
[]
]
},
{
"id": "14e2d71dd9b54b10",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(tire_pressure_front)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "tire_pressure_front",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 620,
"y": 460,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "7a0addfeb138de77",
"type": "change",
"z": "98b1bf097bdd05e6",
"name": "tx_type(tire_pressure_rear)",
"rules": [
{
"t": "set",
"p": "tx_type",
"pt": "msg",
"to": "tire_pressure_rear",
"tot": "str"
}
],
"action": "",
"property": "",
"from": "",
"to": "",
"reg": false,
"x": 620,
"y": 520,
"wires": [
[
"530ac445acaf87d1"
]
]
},
{
"id": "88db1c9e82b06cf8",
"type": "inject",
"z": "98b1bf097bdd05e6",
"name": "trigger_once",
"props": [
{
"p": "payload"
},
{
"p": "topic",
"vt": "str"
}
],
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"topic": "trigger_once",
"payload": "",
"payloadType": "date",
"x": 210,
"y": 520,
"wires": [
[]
]
},
{
"id": "f67ac2c47dc31fd1",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat HV Battery Voltage",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat HV Battery Voltage"
},
{
"property": "icon",
"value": "mdi:sine-wave"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "voltage"
},
{
"property": "unit_of_measurement",
"value": "V"
},
{
"property": "state_class",
"value": "measurement"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "3c0951e0861b1a48",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Coolant Temperature",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Coolant Temperature"
},
{
"property": "icon",
"value": "mdi:coolant-temperature"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "temperature"
},
{
"property": "unit_of_measurement",
"value": "°C"
},
{
"property": "state_class",
"value": "measurement"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "5e701cfbe29d1f94",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Mileage",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Mileage"
},
{
"property": "icon",
"value": "mdi:car-hatchback"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "distance"
},
{
"property": "unit_of_measurement",
"value": "km"
},
{
"property": "state_class",
"value": "total"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "feecd6930e965964",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat HV Power",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat HV Power"
},
{
"property": "icon",
"value": "mdi:flash"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "power"
},
{
"property": "unit_of_measurement",
"value": "kW"
},
{
"property": "state_class",
"value": "measurement"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "4fa38a80040891bb",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Bus Current",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Bus Current"
},
{
"property": "icon",
"value": "mdi:current-ac"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "current"
},
{
"property": "unit_of_measurement",
"value": "A"
},
{
"property": "state_class",
"value": ""
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "bd866571f94932fc",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat State of Charge",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat State of Charge"
},
{
"property": "icon",
"value": "mdi:battery-90"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "battery"
},
{
"property": "unit_of_measurement",
"value": "%"
},
{
"property": "state_class",
"value": "measurement"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "8b0a417f59f61cf9",
"type": "mqtt-broker",
"name": "Home Assistant",
"broker": "192.168.x.x",
"port": "1883",
"clientid": "",
"autoConnect": true,
"usetls": false,
"protocolVersion": "4",
"keepalive": "60",
"cleansession": true,
"autoUnsubscribe": true,
"birthTopic": "",
"birthQos": "0",
"birthRetain": "false",
"birthPayload": "",
"birthMsg": {},
"closeTopic": "",
"closeQos": "0",
"closeRetain": "false",
"closePayload": "",
"closeMsg": {},
"willTopic": "",
"willQos": "0",
"willRetain": "false",
"willPayload": "",
"willMsg": {},
"userProps": "",
"sessionExpiry": ""
},
{
"id": "545669fd88c51a2e",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat State of Energy",
"version": "6",
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat State of Energy"
},
{
"property": "icon",
"value": "mdi:battery-high"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "energy_storage"
},
{
"property": "unit_of_measurement",
"value": "kWh"
},
{
"property": "state_class",
"value": "measurement"
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "7f4eef0193b9666f",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Front Left Tire Pressure",
"version": 6,
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Front Left Tire Pressure"
},
{
"property": "icon",
"value": "mdi:tire"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "pressure"
},
{
"property": "unit_of_measurement",
"value": "psi"
},
{
"property": "state_class",
"value": ""
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "e7a7cfd3fa40f9a0",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Front Right Tire Pressure",
"version": 6,
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Front Right Tire Pressure"
},
{
"property": "icon",
"value": "mdi:tire"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "pressure"
},
{
"property": "unit_of_measurement",
"value": "psi"
},
{
"property": "state_class",
"value": ""
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "de57a198d65f3bd5",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Rear Left Tire Pressure",
"version": 6,
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Rear Left Tire Pressure"
},
{
"property": "icon",
"value": "mdi:tire"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "pressure"
},
{
"property": "unit_of_measurement",
"value": "psi"
},
{
"property": "state_class",
"value": ""
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "9ccac63f1148b7f9",
"type": "ha-entity-config",
"server": "20d978d.da24788",
"deviceConfig": "1aa47136988e77a3",
"name": "Ora Good Cat Rear Right Tire Pressure",
"version": 6,
"entityType": "sensor",
"haConfig": [
{
"property": "name",
"value": "Ora Good Cat Rear Right Tire Pressure"
},
{
"property": "icon",
"value": "mdi:tire"
},
{
"property": "entity_picture",
"value": ""
},
{
"property": "entity_category",
"value": ""
},
{
"property": "device_class",
"value": "pressure"
},
{
"property": "unit_of_measurement",
"value": "psi"
},
{
"property": "state_class",
"value": ""
}
],
"resend": false,
"debugEnabled": false
},
{
"id": "20d978d.da24788",
"type": "server",
"name": "Home Assistant",
"addon": true
},
{
"id": "1aa47136988e77a3",
"type": "ha-device-config",
"name": "Ora Good Cat",
"hwVersion": "2.0",
"manufacturer": "Node-RED",
"model": "Ora Good Cat",
"swVersion": "2.0"
}
]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment