If you’re sure there’s no other clients another possibility is that the plugin is trying to open a connection too soon after it was closed.
Try increasing the closeConnectionDelay setting by 100 ms
If you’re sure there’s no other clients another possibility is that the plugin is trying to open a connection too soon after it was closed.
Try increasing the closeConnectionDelay setting by 100 ms
Went and reset the module, have reset the router.
As mentioned, no issues with other commands, just setting the temperature:
[9/22/2020, 1:42:43 PM] [RinnaiTouchPlatform] Found: Rinnai Touch module [192.168.1.127:27847]
[9/22/2020, 1:42:43 PM] [RinnaiTouchPlatform] TCP Connection: Open
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] Found: Heater
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] Found: Evaporative Cooler
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] Found Zone(s): Common
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] Operation Mode: Single Temperature Set Point
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Broker connected [mqtt://192.168.1.173:1883]
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/hvac/fan_mode/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/hvac/mode/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/hvac/temperature/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/zone/a/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/zone/b/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/zone/c/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/zone/d/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/heat/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/cool/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/evap/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/fan/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/manual/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/manual/a/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/manual/b/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/manual/c/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Subscribe: brivis/switch/manual/d/set
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/action/get, Payload: {"U":"off"}
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/current_temperature/get, Payload: {}
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/fan_mode/get, Payload: high
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/mode/get, Payload: off
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/heat/get, Payload: off
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/cool/get, Payload: off
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/evap/get, Payload: off
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/fan/get, Payload: off
[9/22/2020, 1:42:45 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/manual/get, Payload: off
[9/22/2020, 1:42:50 PM] [RinnaiTouchPlatform] TCP Connection: Closed
[9/22/2020, 1:43:27 PM] [Config] Changes to config.json saved.
[9/22/2020, 1:43:40 PM] [RinnaiTouchPlatform] MQTT: Received: brivis/hvac/temperature/set, Payload: 20.0
[9/22/2020, 1:43:40 PM] [RinnaiTouchPlatform] TCP Connection: Open
[9/22/2020, 1:43:42 PM] [RinnaiTouchPlatform] Sending Command: N000002{"HGOM":{"GSO":{"SP":"20"}}}
[9/22/2020, 1:43:52 PM] [RinnaiTouchPlatform] Command failed. Attempt 1 of 3
[9/22/2020, 1:44:02 PM] [RinnaiTouchPlatform] Command failed. Attempt 2 of 3
[9/22/2020, 1:44:12 PM] [RinnaiTouchPlatform] Command failed. Attempt 3 of 3
[9/22/2020, 1:44:17 PM] [RinnaiTouchPlatform] TCP Connection: Closed
[9/22/2020, 1:44:53 PM] [RinnaiTouchPlatform] MQTT: Received: brivis/hvac/mode/set, Payload: fan_only
[9/22/2020, 1:44:53 PM] [RinnaiTouchPlatform] TCP Connection: Open
[9/22/2020, 1:44:55 PM] [RinnaiTouchPlatform] Sending Command: N000003{"HGOM":{"OOP":{"ST":"Z"}}}
[9/22/2020, 1:44:57 PM] [RinnaiTouchPlatform] Command succeeded. Took 2010 ms
[9/22/2020, 1:44:57 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/action/get, Payload: {"U":"fan"}
[9/22/2020, 1:44:57 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/mode/get, Payload: fan_only
[9/22/2020, 1:44:57 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/fan/get, Payload: on
[9/22/2020, 1:45:02 PM] [RinnaiTouchPlatform] MQTT: Received: brivis/hvac/mode/set, Payload: off
[9/22/2020, 1:45:02 PM] [RinnaiTouchPlatform] Sending Command: N000004{"HGOM":{"OOP":{"ST":"F"}}}
[9/22/2020, 1:45:03 PM] [RinnaiTouchPlatform] Command succeeded. Took 1245 ms
[9/22/2020, 1:45:03 PM] [RinnaiTouchPlatform] TCP Connection: Closed
[9/22/2020, 1:45:04 PM] [RinnaiTouchPlatform] TCP Connection: Open
[9/22/2020, 1:45:06 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/action/get, Payload: {"U":"off"}
[9/22/2020, 1:45:06 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/mode/get, Payload: off
[9/22/2020, 1:45:06 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/fan/get, Payload: off
[9/22/2020, 1:45:11 PM] [RinnaiTouchPlatform] TCP Connection: Closed
Interesting. That time you didn’t get the Connection error. Looks like the module is not accepting the command.
EDIT: What controller do you have?
From the logs it looks like the controller was in the OFF mode. You can can only set the temp if the unit is in the HEAT (or COOL) mode
Controller is NC-6.
It seems to be working better now (maybe because of the not setting the temp outside of mode as mentioned.
Finding another issue now though, which is that if I turn it on via the app, then turn it off manually at the NC-6, Homebridge doesn’t update and send an MQTT command stating it was turned off.
For the life of me, I can’t specifically remember if this was how it worked before or if my functionality is dipping out? Can you confirm?
I have to say, I deleted the Rinnai app from my phone once I got it working in HomeBridge/Home-Assistant
Literally no need for it now it’s working on my own platform.
As for turning the NC-6 off at the NC-6… I did that and was able to happily turn it back on via MQTT.
Maybe you’re having issues because the App isn’t properly disconnecting from the WiFi unit?
My recommendation - Kill the app with fire!!!
oh - I should mention - I’m using the ALWAYS ON connection… once my Homebridge gets the connection to the WiFi unit, it KEEPS it!! Makes life simpler and the WiFi unit seems to handle the always on connection without any issues.
Hi @Hass10
Glad to hear that one issue is resolved. As for the new one, the plugin should pickup any changes you make via the controller directly. What are your MQTT settings? Do you have a publish interval defined? Or do you use the “always on” connection?
I publish:
[X] When status has changed
[ ] At regular intervals: ___ seconds
[X] Publish all topics even if payload has not changed
Are you stating that I need to have regular intervals for it to receive NC-6 updates? Like I said I can’t remember how it worked before but thought it would update even with the above settings.
Logs below with my highlighted action in ##ACTION## :
##Turned on via Home Assistant MQTT##
[9/23/2020, 6:52:12 PM] [RinnaiTouchPlatform] TCP Connection: Closed
[9/23/2020, 6:55:28 PM] [RinnaiTouchPlatform] MQTT: Received: brivis/hvac/mode/set, Payload: heat
[9/23/2020, 6:55:28 PM] [RinnaiTouchPlatform] TCP Connection: Open
[9/23/2020, 6:55:29 PM] [RinnaiTouchPlatform] Sending Command: N000010{"HGOM":{"OOP":{"ST":"N"}}}
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] Command succeeded. Took 1984 ms
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/action/get, Payload: {"U":"idle"}
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/current_temperature/get, Payload: {}
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/fan_mode/get, Payload: high
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/mode/get, Payload: heat
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/temperature/get, Payload: 20
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/heat/get, Payload: on
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/cool/get, Payload: off
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/evap/get, Payload: off
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/fan/get, Payload: off
[9/23/2020, 6:55:31 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/manual/get, Payload: on
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/action/get, Payload: {"U":"heating"}
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/current_temperature/get, Payload: {}
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/fan_mode/get, Payload: high
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/mode/get, Payload: heat
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/hvac/temperature/get, Payload: 20
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/heat/get, Payload: on
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/cool/get, Payload: off
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/evap/get, Payload: off
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/fan/get, Payload: off
[9/23/2020, 6:55:33 PM] [RinnaiTouchPlatform] MQTT: Publish: brivis/switch/manual/get, Payload: on
[9/23/2020, 6:55:34 PM] [RinnaiTouchPlatform] TCP Connection: Closed
##Changed temperature on NC-6 to 18deg, no output message to MQTT##
##Turned off Heater on NC-6, no ouptut to MQTT##
##Home Assistant still showing Heater as "On" at "20degrees"##
Yep, the plugin needs to receive the status from the Rinnai module to pick up any changes that may have been made from the controller.
As mentioned there are 2 ways you can do that:
Hope that helps
So sorry! I mustn’t have copied over my connection close setting!
Works a treat now after choosing Option 2.
Thanks again you absolute legend for spending the time to help me (as always)!
No worries. Happy to help
Hi, I am enjoying your work and the ability to integrate into homeassistant.
I do have one question / feature suggestion though.
Given we just changed to daylight savings, but I find the thermostat still running on non DST. I would have hoped the wifi module to have smarts to set the clock!
But I notice early on in this topic, that STM is a command to Set Time and Day, could this be implemented by your plugin somehow, or even better, to have the plugin sync the time from the homebridge system time, so that it automatically adjusts when Daylight savings starts and ends?
It is my secret aim to never have to change a clock ever again
Hi @groutley, I too was hoping I could set the time of the controller via the Rinnai Touch module. I found my controller’s clock is a little fast so every couple of months I need to adjust the time.
I did explore the STM command but couldn’t get it to work. There’s also no mention of this command in the API document so I suspect it was never fully implement by Rinnai.
Version 3.1.0 of the plugin has been released. This version contains the following changes:
I found a way to prevent the WiFi module from disconnecting after 5 minutes by sending a blank command to it every minute. This allows the connection to remain open at all times so I decided to ditch the option of having the TCP/IP connection only open when a request is made. This has simplified the code for handling the connection.
Making this change has several advantages:
The only risk I can find is if Homebridge is not shutdown gracefully (eg. a crash) which may leave the connection open and prevent the plugin reconnecting on restart. As always in this case you need to restart the module or router to fix.
This turned out to be a fairly extensive change so if you find any bugs please let me know and I’ll fix ASAP.
Hi everyone, thanks for the work on this plugin, particularly Mantorok for its development.
I’ve followed through the thread as best I can. I have homebridge and the rinnai plugin installed as per some of the instructions posted here and as far as I can see the bridge is working OK.
The problem I am having is that while the accessories are displayed in homebridge and via the home app it won’t control those entities. I can run up the various functions (in the Rinnai Touch app) and can see the displays on homebridge updating to reflect the status, but it won’t accept commands from either directly on homebridge or via the home app. I see the following in the homebridge logs:
Command failed. Attempt 1 of 3
Command failed. Attempt 2 of 3
Command failed. Attempt 3 of 3
I did have it working briefly and it has gone back to not accepting commands.
I’ve done the things suggested in some of the posts here: ie
a. restart router,
b. restart homebridge,
c. restart the Rinnai Bridge itself
d. various re-installations.
Could it have something to do with the Rinnai Touch app itself? Would be awesome if someone could point me in the right direction.
Thanks again for all the contributions here.
Hi @currest2620
Thanks for the appreciation. Sorry it’s not working correctly for you. Let’s try to get it sorted out. It’s sounds like there’s no connectivity issues as the status is updating ok. The messages you posted indicate that the command being sent is not being acknowledged by the Rinnai module. When this happens the plugin will try sending the command 3 times before giving up
In the logs do you see a message like “Sending:” followed by the actual command being sent? Could post a copy of this
Also could you supply the following details:
Thank you Mantorok, that’s appreciated.
{
"bridge": {
"name": "Homebridge on Evatt",
"username": "0E:D5:1E:C4:6A:B6",
"port": 51419,
"pin": "356-93-073"
},
"accessories": [],
"platforms": [
{
"name": "Config",
"port": 8080,
"platform": "config"
},
{
"name": "Rinnai Touch",
"controllerType": "T",
"zoneType": "S",
"showFan": true,
"showAuto": true,
"showAdvanceSwitches": false,
"showManualSwitches": true,
"showHomebridgeEvents": true,
"showModuleEvents": true,
"clearCache": false,
"mqtt": {
"host": "mqtt://192.168.1.24",
"username": "[UID]",
"password": "[password]",
"topicPrefix": "rinnai",
"formatHomeAssistant": true,
"publishStatusChanged": true,
"publishIntervals": true,
"showMqttEvents": true
},
"platform": "RinnaiTouchPlatform"
}
]
}
My HVAC (I assume this to be the unit installed): Its a one zone evap cooler. Brivis.
Logs:
Here is a log sample. In this case, I clicked the “Manual” switch on the homebridge accessories page on the homebridge server.
[10/12/2020, 4:53:14 PM] [Rinnai Touch] ManualSwitch U: Getting characteristic 'On'
[10/12/2020, 4:53:14 PM] [Rinnai Touch] Pump: Getting characteristic 'Active'
[10/12/2020, 4:53:14 PM] [Rinnai Touch] Pump: Getting characteristic 'InUse'
[10/12/2020, 4:53:16 PM] [Rinnai Touch] ManualSwitch U: Setting characteristic 'On' to 'true'
[10/12/2020, 4:53:16 PM] [Rinnai Touch] Sending: N000227{"ECOM":{"GSO":{"OP":"M"}}}
[10/12/2020, 4:53:26 PM] [Rinnai Touch] Command failed. Attempt 1 of 3
[10/12/2020, 4:53:36 PM] [Rinnai Touch] Command failed. Attempt 2 of 3
[10/12/2020, 4:53:46 PM] [Rinnai Touch] Command failed. Attempt 3 of 3
[10/12/2020, 4:53:46 PM] [Rinnai Touch] ManualSwitch U: Getting characteristic 'On'
Hope this is what you are after. Thanks again for the help.
Thanks @currest2620, that’s what I was after. So you don’t have a heater, just an evap cooler? I’m not sure I’ve encountered that setup before
Does setting the Thermostat accessory to OFF work?
Could you also supply a copy of the status that the module sends to the plugin. You can see it in the logs when homebridge is started in DEBUG mode
Yeah, its a pretty simple setup. Manual on/off, fan on/off pump on/off and an auto mode where a “comfort level” can be set. I assume that’s the thermostat part.
I find I need to exit auto mode by selecting manual again on the app. I can home bridge buttons switch off but won’t switch back on.
There’s a ton of stuff in the logs, not sure what to look for. Is this it?
[10/12/2020, 5:59:12 PM] [Rinnai Touch] RinnaiSession receiveMessage 58:[{"SYST": {"CFG": {"MTSP": "N", "NC": "00", "DF": "N", "TU": "C", "CF": "1", "VR": "0183", "CV": "0010", "CC": "043", "ZA": " ", "ZB": " ", "ZC": " ", "ZD": " " }, "AVM": {"HG": "N", "EC": "Y", "CG": "N", "RA": "N", "RH": "N", "RC": "N" }, "OSS": {"DY": "MON", "TM": "17:58", "BP": "Y", "RG": "Y", "ST": "N", "MD": "E", "DE": "N", "DU": "N", "AT": "999", "LO": "N" }, "FLT": {"AV": "N", "C3": "000" } } },{"ECOM": {"CFG": {"ZUIS": "Y", "ZAIS": "N", "ZBIS": "N", "ZCIS": "N", "ZDIS": "N", "TP": "N" }, "GSO": {"SW": "F" }, "GSS": {"PW": "N", "BY": "N", "PO": "N", "FO": "N", "SN": "N", "MT": "999", "ZUAE": "N", "ZAAE": "N", "ZBAE": "N", "ZCAE": "N", "ZDAE": "N" }, "PSU": {"AV": "N", "SNE": "N" } } }]
Yep that’s what I was after. That status shows the cooler is off. Sorry, need a couple more things from you:
EDIT: I’ve had a closer look at the API doc and from what I can tell the Evap mode has 2 operation states:
Using the Rinnai Touch app on your phone, is it possible to set manual/auto while the unit is OFF?
Also, can you turn the fan ON & set its speed while the unit is OFF? I know this can be done with for heating & add-on cooling but from what I can make out for Evap cooling the unit must be ON before the fan can be used. Is that correct?