I’m glad I could help! I’m interested in your security system and valves - these are things that don’t seem to have been explored much at this point.
On to your NEST - I don’t have one of these so I can’t be a TON of help but I have suggestions on how to go into your troubleshooting. First will be to add debugs on everything. If you hover over the output in the debug pane - the debug node it came from will “light up” with a red dashed border so you can see what’s happening. This is so important because it breaks everything down and you can see which parts are working and which aren’t.
I looked at your setup and my first thought is I bet your temperature state and setpoints are in the format of “66.0° F” and you’re sending on to HomeKit like that. HomeKit wants just a number 0 through 100 in 0.1 increments in degrees celsius. (I looked it up in Apple’s HomeKit Accessory Protocol document, let me know in PM if you want a copy )
You’ll need to do more maths for that one to work.
The HomeKit Protocol document is EXTREMELY helpful. Once you know what you can send “into” homekit you just search that to see what format things are.
As for the mode setting, it seems to me like your NEST_State should work (output of the function OH to HK 4 looks good). But there may be some other disconnect.
I made a new version of your nodes with a nice collection of debug nodes. A good one to watch is Debug9 - if anything shows up in that one it means the HomeKit item is accepting your changes.
[
{
"id": "ef8712b5.09cef8",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug1",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 340,
"y": 220,
"wires": []
},
{
"id": "5c888732.2decd8",
"type": "openhab2-in",
"z": "98730e47.019298",
"name": "",
"controller": "72ae56dd.4e7628",
"itemname": "A_HVAC_NEST_Temp",
"x": 140,
"y": 160,
"wires": [
[
"754d2615.a29928",
"ef8712b5.09cef8"
],
[]
]
},
{
"id": "754d2615.a29928",
"type": "function",
"z": "98730e47.019298",
"name": "OH to HK 1",
"func": "var input = msg.payload;\n\nmsg.payload = {\n \"CurrentTemerature\": input,\n };\nreturn msg;",
"outputs": 1,
"noerr": 0,
"x": 450,
"y": 160,
"wires": [
[
"167cad32.ec0f6b",
"206b78c7.3b3fb"
]
]
},
{
"id": "167cad32.ec0f6b",
"type": "homekit-service",
"z": "98730e47.019298",
"bridge": "96b48eda.5d5498",
"name": "NEST",
"serviceName": "Thermostat",
"manufacturer": "Default Manufacturer",
"model": "Default Model",
"serialNo": "Default Serial Number",
"characteristicProperties": "{}",
"x": 870,
"y": 340,
"wires": [
[
"2e31c716.007f28"
]
]
},
{
"id": "206b78c7.3b3fb",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug5",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 620,
"y": 200,
"wires": []
},
{
"id": "3c005bc9.ac0ec4",
"type": "function",
"z": "98730e47.019298",
"name": "OH to HK 3",
"func": "if (msg.payload == \"HEAT\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": \"heating\"\n };\n} else if (msg.payload == \"COOL\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": \"cooling\"\n };\n} else if (msg.payload == \"OFF\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": \"off\"\n };\n}\nreturn msg;",
"outputs": 1,
"noerr": 0,
"x": 450,
"y": 360,
"wires": [
[
"167cad32.ec0f6b",
"764d3608.4df2e8"
]
]
},
{
"id": "83849fb3.ad7848",
"type": "function",
"z": "98730e47.019298",
"name": "OH to HK 2",
"func": "var input = msg.payload;\n\nmsg.payload = {\n \"TargetTemerature\": input,\n };\nreturn msg;",
"outputs": 1,
"noerr": 0,
"x": 450,
"y": 260,
"wires": [
[
"167cad32.ec0f6b",
"24fbcd78.4ef962"
]
]
},
{
"id": "cae80c0f.65ac6",
"type": "function",
"z": "98730e47.019298",
"name": "OH to HK 4",
"func": "if (msg.payload == \"HEATING\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": 1\n };\n} else if (msg.payload == \"COOLING\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": 2\n };\n} else if (msg.payload == \"OFF\") {\n msg.payload = {\n \"CurrentHeatingCoolingState\": 0\n };\n \n}\nreturn msg;",
"outputs": 1,
"noerr": 0,
"x": 450,
"y": 460,
"wires": [
[
"167cad32.ec0f6b",
"97e9ffa4.ca311"
]
]
},
{
"id": "4114d757.70e33",
"type": "inject",
"z": "98730e47.019298",
"name": "",
"topic": "",
"payload": "{\"Break\":\"HomeKit\"}",
"payloadType": "json",
"repeat": "",
"crontab": "",
"once": false,
"onceDelay": 0.1,
"x": 710,
"y": 100,
"wires": [
[
"167cad32.ec0f6b"
]
]
},
{
"id": "2e31c716.007f28",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug9",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 1060,
"y": 400,
"wires": []
},
{
"id": "a9a7a3bd.73709",
"type": "openhab2-in",
"z": "98730e47.019298",
"name": "",
"controller": "72ae56dd.4e7628",
"itemname": "A_HVAC_NEST_Mode",
"x": 140,
"y": 360,
"wires": [
[
"3c005bc9.ac0ec4",
"aa4abc1c.5e5bf8"
],
[]
]
},
{
"id": "764d3608.4df2e8",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug7",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 620,
"y": 400,
"wires": []
},
{
"id": "7cab863b.f69c",
"type": "openhab2-in",
"z": "98730e47.019298",
"name": "",
"controller": "72ae56dd.4e7628",
"itemname": "A_HVAC_NEST_SP",
"x": 130,
"y": 260,
"wires": [
[
"83849fb3.ad7848",
"a56f1c2a.8c0ad"
],
[]
]
},
{
"id": "24fbcd78.4ef962",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug6",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 620,
"y": 300,
"wires": []
},
{
"id": "35d19b57.12d994",
"type": "openhab2-in",
"z": "98730e47.019298",
"name": "",
"controller": "72ae56dd.4e7628",
"itemname": "A_HVAC_NEST_State",
"x": 140,
"y": 460,
"wires": [
[
"cae80c0f.65ac6",
"2f79fc07.5526ec"
],
[]
]
},
{
"id": "97e9ffa4.ca311",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug8",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 620,
"y": 500,
"wires": []
},
{
"id": "aa4abc1c.5e5bf8",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug3",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 340,
"y": 400,
"wires": []
},
{
"id": "a56f1c2a.8c0ad",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug2",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 340,
"y": 300,
"wires": []
},
{
"id": "2f79fc07.5526ec",
"type": "debug",
"z": "98730e47.019298",
"name": "Debug4",
"active": true,
"tosidebar": true,
"console": false,
"tostatus": false,
"complete": "payload",
"x": 360,
"y": 500,
"wires": []
},
{
"id": "72ae56dd.4e7628",
"type": "openhab2-controller",
"z": "",
"name": "openHAB Archon",
"protocol": "http",
"host": "192.168.1.80",
"port": "8080",
"path": "",
"username": "",
"password": ""
},
{
"id": "96b48eda.5d5498",
"type": "homekit-bridge",
"z": "",
"bridgeName": "node-RED",
"pinCode": "111-11-111",
"port": "",
"manufacturer": "Default Manufacturer",
"model": "Default Model",
"serialNo": "Default Serial Number"
}
]