Announcement

Collapse
No announcement yet.

Venstar Thermostat Integration

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Venstar Thermostat Integration

    This is a continuation of the thread started in the General Discussion area https://forums.homeseer.com/forum/ho...plugin-for-hs3 to discuss the mcsMQTT implementation of the integration.

    At this point with version 6.1.0.0 of HS4 plugin, a full, albeit initial implementation. The delta files from the version 6 mcsMQTT plugin available from the HS4 Updater is at http://mcsSprinklers.com/MCSMQTTHS4_6100.zip. Unzip all files into the \bin\mcsMQTT subfolder of HS. The HS version will not show a change, but the MQTT Page, General tab, top header will show the version of the .dll that is being run. There is one .html file and it should be placed in \html\mcsMQTT subfolder.

    The setup interface is on the Local Page, HVAC Tab of mcsMQTT plugin. This tab was previously labeled Intesis/Daikin, but has been renamed to handle a third type of local HVAC/Thermostat integration. The new label is in Local.html, but it only cosmetic.

    When the plugin starts it will do a SSDP request to find Venstar thermostats on the network. Those found will be used to populate the Local Page, HVAC Tab, Venstar Table. The discovery can also be done using the button on the Local Page, HVAC tab. If none are found then it is still possible to manually enter the IP on this table. The other entry that is need on the this page's setup is the polling rate to refresh the status of information from the thermostat. It defaults to 0 (disabled). Reasonable values such as 60000 or every minute or larger should be used.

    mcsMQTT will poll four endpoints of each thermostat. Data returned from /info, /sensors and /alerts will result in the Association Table of the MQTT Page, Association Tab showing the decoded data. It will also result in a HS Device being created for each Thermostat and the Features setup for each property advertised. The /runtimes will also be polled, but no HS Features created automatically. If one desires to see any of the runtimes in HS then use the "a" column checkbox from the Association table of the MQTT Page.

    Controls are setup for the Features that can be controlled. When commanded via HS Devices page, Event Action or Script the request will be delivered to the Venstar thermostat. It will first be checked for compliance on heat and cool setpoints and delta constraint for these. HS Log will reflect out of bounds requests. The last received cool and/or heat setpoints will be used to satisfy the requirement that these always be provided in a request along with the other property that is being commanded.

    Alerts are itemized and shown as either Active or Inactive. Sensors are shown with temperature measurement and humidity measurement if available. If the humidity reported is not zero and additional humidity properties are available such as setpoint then they will be included as HS Features.

    I have not yet updated mcsMQTT.pdf or the HS3 plugin. I would prefer to get some feedback on the HS4 implementation before taking this step to minimize rework.



    Click image for larger version  Name:	0.jpg Views:	0 Size:	63.2 KB ID:	1595216
    Attached Files

    #2
    At dinner this evening I remembered I had not removed the test code that allows any SSDP IP to be seen as a venstar. I reuploaded now the same file that looks only for venstar reports.

    Comment


      #3
      wow.. lots happened.. I got tied up in a bunch of serious work projects and am now just getting back to homeseer..
      first off i have 4 Venstar Tstats set up in a Lab environment from old to new..
      I have colortouch 5900,7900, 8850, and a new T4950-IAQ, I am running the latest HS4 PRO.

      I need to get up to speed and get updated and then can test anything you need Tested.

      one thing to note is that going forward Venstar tech support told me all products will be communicated in degrees C vs degrees F regardless of what they have set in the settings and on the screen.. the API will be all degree C.. pretty much on the half (.5)degree C to show a degree F on the screen or setpoint..

      the colortouch units i have still get communicated with in the degree unit that you have selected.. in my case F
      my T4950-IAQ I must talk to in C with the API regardless of my C or F setting (the screen on the stat is in C or F)

      the older colortouch stuff would accept GET or POST for requests.. it didnt care which method you used regardless of the docs
      the new gen stuff requires the request method be as documented.. GET for reading status, POST for operating settings.

      UPDATE YOUR FIRMWARE.. there were broken things in the API in older versions.. yes its a PITA on the older colortouch as they dont do OTA, you need to use an SD card.. the new gen will do OTA when you register it to SKyport.

      Skyport works along with the API so you can have both turned on, however skyport isnt required to use the local API.

      -Christopher

      P.S. i got aprilaire to send me the 8840 API

      PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

      Comment


        #4
        Just let me know if anything needs to change or should be added.

        In the JSON provided there is a TempUnits (F vs C) entry. I use it to know what suffix to put in the HS status. There are various integrations where I look at the HS setting for C vs. F and then do conversions as necessary to show the value in the units that the user has specified in the HS setup. I do not now do it with Venstar. It seems like there may be some work in this area with new API.

        Does HS now have a Aprilaire plugin? I believe I saw one in the past.

        Comment


          #5
          Yes there is an aprilaire plugin for hs3, but, it could be better.

          Comment


            #6
            installed this plugin.. thank you! for working on this..

            the discovery fails.. i get an "unable to find IPV4 address of this computer" popup...

            I typed in the IP of my first venstar and set a polling rate.. im purposely polling often(15000) to see what kind of system load we get.. this machine has HS2,HS4, and my VB.NET HVAC program running on it.. so far load is minimal..

            the plugin read the thermostat and populated it correctly..

            when I try to add a second one. I type the IP into the Forum address field, and when i click another box in the page.. the new IP address replaces the Home position and I lose the original IP..

            the stat I did add is a colortouch 8950. the humidity setpoints seem off.. I need to look at those a little closer and get back to you.. all the other settings appear to read perfectly. the settings work and reflect in skyporrt and on the local screen.

            next will be to try my IAQ4950, for some reason I cant find the local IP.. ill need to reboot it so it hits my DHCP server.. it may be on a different VLAN in my network.. it is in skyport..

            the 4950 is using Venstar's "Next Gen" tech as they call it.


            -Christopher
            PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

            Comment


              #7
              the discovery fails.. i get an "unable to find IPV4 address of this computer" popup...
              MQTT Page, General Tab at the top has a Debug checkbox. When enabled it will produce a file in \Data\mcsMQTT\mcsMQTT Debug.txt. This contains the SSDP response. I did it to ask for everything rather than a specific property to confirm what the thermostat was returning. It will be useful to see what is being returned on the wildcard request.

              when I try to add a second one. I type the IP into the Forum address field, and when i click another box in the page.. the new IP address replaces the Home position and I lose the original IP..​
              I will take a look

              Comment


                #8
                I found what the humidity issue is.. (humidity is only on the commercial series colortouch) and on the IAQ models.. the humidity setpoints should be in % and not in degrees f or c. you set the target percentage and the thermostat will control a 24 VAC humidifier.. the dehumification setpoint is a target to turn on a dehumidifier (or uses the A/C if programmed to do so.)
                PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                Comment


                  #9
                  the debug log doesnt contain any SSDP data.. when I click discover.. I get the unable to get IPV4 address error and nothing in the debug log related to SSDP.. theres thermostat queries..

                  here is an example query from my IAQ-4950 thermostat

                  {"name":"BUSBOY","mode":0,"state":0,"activestage":0,"fan":1, "fanstate":0,"tempunits":0,"schedule":0,"schedulepart":3,"ho liday":0,"override":0,"overridetime":0,"forceunocc":0,"space temp":22.0,"heattemp":21.0,"cooltemp":23.5,"cooltempmin":1.5 ,"cooltempmax":37.0,"heattempmin":1.5,"heattempmax":37.0,"se tpointdelta":2,"hum":22,"availablemodes":1}

                  for some reason the humidity setpoints are missing in the query on this one.. I need to figure out if I have something set up wrong.

                  and here is the sensors query.. notice all the queries are in degrees C even though my display is set to degrees F.. according to venstar this is on purpose..

                  {"sensors": [{"name":"Thermostat","temp":21.5,"hum":23,"intensity":22,"ia q":62.36,"co2":649.44},{"name":"Space Temp","temp":21.5}]


                  and below is a query from my T8900 for reference.

                  {"name":"GREATROOM","mode":0,"state":0,"fan":0,"fanstate":0, "tempunits":0,"schedule":0,"schedulepart":255,"away":0,"spac etemp":71.0,"heattemp":70.0,"cooltemp":70.0,"cooltempmin":35 .0,"cooltempmax":99.0,"heattempmin":35.0,"heattempmax":99.0, "holiday":0,"override":0,"overridetime":0,"forceunocc":0,"ac tivestage":0,"hum_active":0,"hum":42,"hum_setpoint":35,"dehu m_setpoint":99,"setpointdelta":2.0,"availablemodes":1}

                  PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                  Comment


                    #10
                    the debug log doesnt contain any SSDP data.
                    It is likely because of the failure to get IP address. I have restricted the valid local IP to subnets 10. and 192. I suspect this was done to restrict the search to a single network when multiple are present. What subnet will your IP be located?

                    FYI,

                    SSDP is executed as part of the background initialization process on every plugin start. As a minimum there will be the request in the debug. Mine looks like below with some additional feedback during the asynchronous SSDP activity. I have nothing interesting returned, but at least something.

                    Code:
                    3/18/2023 8:26:41 AM    33669    | SSDP Request M-SEARCH * HTTP/1.1
                    HOST: 239.255.255.250:1900\r\nST: ssdp:all\r\nMAN: "ssdp:discover"
                    MX: 3
                    
                    
                    ...........3/18/2023 8:26:41 AM    33670    | mcsMQTT Debug Background Init Done
                    ...........3/18/2023 8:26:41 AM    33671    | ActOnMessageForTrigger QueueSize=1 ,Topic Hubspace/response,Payload {"exit":"received exit command","pid":40780}  
                    ...........3/18/2023 8:26:41 AM    33674    | ActOnMessageForTrigger QueueSize=1 ,Topic Hubspace/LWT,Payload {"Online":false,"pid":40780}  
                    3/18/2023 8:26:43 AM    35276    | SSDP Received HTTP/1.1 200 OK
                    CACHE-CONTROL: max-age=86400
                    DATE: Fri, 15 Apr 2016 04:56:29 GMT
                    EXT:
                    LOCATION: http://192.168.0.70:80/setup.xml
                    OPT: "http://schemas.upnp.org/upnp/1/0/"; ns=01
                    01-NLS: b9200ebb-736d-4b93-bf03-835149d13983
                    SERVER: Unspecified, UPnP/1.0, Unspecified
                    ST: upnp:rootdevice
                    USN: uuid:Socket-1_0-201612K003B0313::upnp:rootdevice
                    X-User-Agent: redsonic
                    
                    
                    3/18/2023 8:26:44 AM    36692    | SSDP Complete  
                    ​

                    the humidity setpoints should be in % and not in degrees f or c
                    I suspect you are commenting on the screenshot at the start of the thread. The code will use % for humidity. I found that early, but did not update the screenshot.


                    and here is the sensors query.. notice all the queries are in degrees C even though my display is set to degrees F.. according to venstar this is on purpose..
                    Can I assume it will always be in C for all models? If so I can do the conversion to F when appropriate.

                    and below is a query from my T8900 for reference.
                    Do I need to make any changes based upon this data?

                    Comment


                      #11
                      I use 172.16 as my internal subnet for the Venstars. I have multiple networks on 172.16 (I think I have about 10 VLANS)technically 172.16 through 172.31 are private IP networks. for me to piut my HS machine and thermostats on a 10. or 192. network would be a big project..


                      10. anything is a private network
                      192.168 anything is a private network
                      anything outside of those ranges is fiar game for routable public IP's so no one uses them for internals (unless they dont know networking)

                      can I add a thermostat by editing the INI file and adding the IP for it? or does that break an onboarding routine?

                      on my screen it shows my room humidity is in % like it should, but the humidity setpoint and dehumidify setpoint are both in degrees and not %, those are actual setpoints for the humidifier / dehumidifer relative humidity %. when you set them on the actual themostat itself they come up as % and my humidifier output call basses on percent.

                      so this is a bit of a PITA when it coems to the newer and older models.. my T8900 you can send a query and set the heatsetpoint at say 72, and send 72 to the API as the heatset and it takes it.. everything workds perfect that ive found on the T8900

                      if I do that to my IAQ4950 it wont take it.. its an out of bounds number as it assumes *ALL* degrees are C even though the stat is set to F for its display on the stat and on skyport.. they use a bastardized lookup table assuming 0.5 degree C equals 1f even though thats not the 100% correct conversion.. degrees C is what it shows for current temps and sensors.. even though tempunits is sert to 0, (which means display everything in F) you still have to read it as C and send setpoints as C.
                      ill make a chart of what it expects for degrees C to equal degrees F setpoint if that will help. I think they just use a lookup table really..

                      as you can see in the IAQ there are a couple new "sensors" which are a CO2 sensor and an "air quality" sensor.. these are only found on the IAQ models (which are hard to get right now.. I got a Couple Cases of them last fall and now they are backorder everywhere)(im working on a low income apartment project where they want to monitor air quality so I have a bunch of them for now.. LOL...).

                      I dont think we are going to use Homeseer in the apartments.. the HVAC guy is kind of a PITA.. one of the project's founders a buddy of mine is all about the cool techie stuff and the HVAC contractor is about as old school as it gets.. (he wanted a natural gas hooded boiler and a chiller and fan coil..).. least efifcient way to go.. this project needs to be energy-star and green.. the political overtones driving it "require" it.. we are doing Fujitsu heatpumps with back up high eff gas hydronic reheat.. controlled by intesis devices and the Venstars as the control heads.. anyway thats off topic for this thread..


                      PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                      Comment


                        #12
                        here is a F to C table that Venstar uses for its IAQ models. in the API you always send the C value (and read it in sensors) regardless of the tempunits setting on the stat...

                        PHP Code:

                         F  C
                        35 1.5
                        36 2
                        37 3
                        38 3.5
                        39 4
                        40 4.5
                        41 5
                        42 5.5
                        43 6
                        44 6.5
                        45 7
                        46 8
                        47 8.5
                        48 9
                        49 9.5
                        50 10
                        51 10.5
                        52 11
                        53 11.5
                        54 12
                        55 13
                        56 13.5
                        57 14
                        58 14.5
                        59 15
                        60 15.5
                        61 16
                        62 16.5
                        63 17
                        64 18
                        65 18.5
                        66 19
                        67 19.5
                        68 20
                        69 20.5
                        70 21
                        71 21.5
                        72 22
                        73 23
                        74 23.5
                        75 24
                        76 24.5
                        77 25
                        78 25.5
                        79 26
                        80 26.5
                        81 27
                        82 28
                        83 28.5
                        84 29
                        85 29.5
                        86 30
                        87 30.5
                        88 31
                        89 31.5
                        90 32
                        91 33
                        92 33.5
                        93 34
                        94 34.5
                        95 35
                        96 35.5
                        97 36
                        98 36.5
                        99 37​​ 
                        PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                        Comment


                          #13
                          to answer your question.. it looks like on the Colortouch models that you need to follow the tempunits parameter for whether to use C or F...
                          so I set my T8900 to degrees C and did a query.

                          I get
                          PHP Code:
                          [root@VMX-Devel-2022 /]# curl http://172.16.1.217/query/info
                          {"name":"GREATROOM","mode":0,"state":0,"fan":0,"fanstate":0"tempunits":1,"schedule":0,"schedulepart":255,"away":0,"spac etemp":23.0,"heattemp":21.0,"cooltemp":16.0,"cooltempmin":1. 5,"cooltempmax":37.0,"heattempmin":1.5,"heattempmax":37.0,"h oliday":0,"override":0,"overridetime":0,"forceunocc":0,"acti vestage":0,"hum_active":0,"hum":37,"hum_setpoint":35,"dehum_ setpoint":99,"setpointdelta":2.0,"availablemodes":1}[ 
                          notice tempunits is '1' for C

                          when I set the display back to F on the stat itself.. the query gets.

                          PHP Code:
                          root@VMX-Devel-2022 /]# curl http://172.16.1.217/query/info
                          {"name":"GREATROOM","mode":0,"state":0,"fan":0,"fanstate":0"tempunits":0,"schedule":0,"schedulepart":255,"away":0,"spac etemp":73.0,"heattemp":70.0,"cooltemp":61.0,"cooltempmin":35 .0,"cooltempmax":99.0,"heattempmin":35.0,"heattempmax":99.0"holiday":0,"override":0,"overridetime":0,"forceunocc":0,"ac tivestage":0,"hum_active":0,"hum":37,"hum_setpoint":35,"dehu m_setpoint":99,"setpointdelta":2.0,"availablemodes":1}[root@VMX-Devel-2022 /]#​ 
                          notice tempunits 0 for degrees F

                          so on the colortouch models you follow the tempunits when sending and receiving form the API
                          for the IAQ models you always work in degrees C when talking to the API regardless of the tempunits parameter
                          im guessing this was done for consistency...
                          PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                          Comment


                            #14
                            another tidbit out there for those working with this.. doing a base query on a thermostat update to at least version 5 firmware will show the model of the thermostat enough to at least identify how to talk to it...

                            here is a COlortouch updated to 6.93 (this one is a T8900)
                            PHP Code:
                            [root@VMX-Devel-2022 /]# curl http://172.16.1.217/
                            {"api_ver":9,"type":"commercial","model":"COLORTOUCH","firmw are":"6.93"
                            here is my IAQ4950
                            PHP Code:
                            [root@VMX-Devel-2022 /]# curl http://172.16.1.19/
                            {"api_ver"7"type""commercial""model""T4950C""firmware""5.12"
                            and finally this is a T7850 i just found in a drawer.. ive had it for awhile.. just hooked it up and and paired it to the WIFI. 4.08 is VERY OLD
                            firmware..

                            PHP Code:
                            [root@VMX-Devel-2022 /]# curl http://172.16.1.203
                            {"api_ver":5,"type":"residential"}​ 
                            as you can see the reply is short.. once I can get multiuple stats in the plugin ill add this one on its old firmware.

                            any of those with short replies appear to require you to follow the 'tempunits' parameter when talking to the API..
                            PerfecTemp - the Most advanced HVAC system I've ever Built - and its in my House

                            Comment


                              #15
                              Excellent set of data and analysis. It will need to be in the AM to assess what should be done in the plug-in.

                              Comment

                              Working...
                              X