Announcement

Collapse
No announcement yet.

HS3 Plugin Samples

Collapse
This is a sticky topic.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    HS3 Plugin Samples

    [UPDATED 5/14/15]

    Here are 3 plug-in samples that show the 3 ways to configure a plugin. One is a standard sample, one is a more basic sample that has simple actions/triggers, and the third shows how to create a multi-instance plugin.

    http://homeseer.com/updates3/hs3_plugin_samples.zip

    10/19/13 Changes:

    * Modified multi-instance sample so it supports both single and multiple EXE modes properly
    💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

    #2
    please add a version number to the zip file name so we can keep them straight as they change.
    Mark

    HS3 Pro 4.2.19.5
    Hardware: Insteon Serial PLM | AD2USB for Vista Alarm | HAI Omnistat2 | 1-Wire HA7E | RFXrec433 | Dahua Cameras | LiftMaster Internet Gateway | Tuya Smart Plugs
    Plugins: Insteon (mine) | Vista Alarm (mine) | Omnistat 3 | Ultra1Wire3 | RFXCOM | HS MyQ | BLRadar | BLDenon | Tuya | Jon00 Charting | Jon00 Links
    Platform: Windows Server 2022 Standard, i5-12600K/3.7GHz/10 core, 16GB RAM, 500GB SSD

    Comment


      #3
      Can we have an example for dynamic (AJAX) webpages

      Originally posted by rjh View Post
      Here are 3 plug-in samples that show the 3 ways to configure a plugin. One is a standard sample, one is a more basic sample that has simple actions/triggers, and the third shows how to create a multi-instance plugin.

      ftp://ftp.homeseer.com/updates/Beta/...in_samples.zip
      Could you extend the sample, with an Ajax handler and put in a control that gets dynamically updated let's say every second (ex a counter).
      I agree with Mark, please give it a version number, hard to keep track of whether I have the latest.
      Thanks
      Dirk
      ps. the sample wouldn't run under Studio because it was missing an inherited declaration for the "SpeakIn" method, I fixed that on my setup and now I can debug the sample under 3.0.0.1 (or was it 2?)

      Comment


        #4
        That is what I did in the sample, it has an AJAX call that updates a div that is the time and date, so you can see it change in real time.

        The plugins I just uploaded are the very latest. I will update the post with a date when I change them.

        Originally posted by dcorsus View Post
        Could you extend the sample, with an Ajax handler and put in a control that gets dynamically updated let's say every second (ex a counter).
        I agree with Mark, please give it a version number, hard to keep track of whether I have the latest.
        Thanks
        Dirk
        ps. the sample wouldn't run under Studio because it was missing an inherited declaration for the "SpeakIn" method, I fixed that on my setup and now I can debug the sample under 3.0.0.1 (or was it 2?)
        💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

        Comment


          #5
          Originally posted by rjh View Post
          [UPDATED 6/7/2013]

          Here are 3 plug-in samples that show the 3 ways to configure a plugin. One is a standard sample, one is a more basic sample that has simple actions/triggers, and the third shows how to create a multi-instance plugin.

          ftp://ftp.homeseer.com/updates/Beta/...in_samples.zip
          Is this for developers only? Or this is a "how to" info?
          Hector
          ____________________________________
          Win.2003 OS, HS3
          BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
          BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
          MyTrigger,ACRF2,W800,Zwave
          AP800,Honeywell Stat

          Comment


            #6
            The samples are source code to 3 plugins. If you are not a programmer, I doubt they are of any use.

            Originally posted by Rotech View Post
            Is this for developers only? Or this is a "how to" info?
            💁‍♂️ Support & Customer Service 🙋‍♂️ Sales Questions 🛒 Shop HomeSeer Products

            Comment


              #7
              Kinda figured that, thks...
              Hector
              ____________________________________
              Win.2003 OS, HS3
              BLDSC,BLstat,BLRadar,BLRamdom,BLOccupied
              BLups,BLrain8,HSTouch,Ultrajones Weatherbug,
              MyTrigger,ACRF2,W800,Zwave
              AP800,Honeywell Stat

              Comment


                #8
                Originally posted by Rotech View Post
                Kinda figured that, thks...
                Hector... yes U and I have no business looking at them!!!!!!!

                let the guru's figure it out!!
                HW - i5 4570T @2.9ghz runs @11w | 8gb ram | 128gb ssd OS - Win10 x64

                HS - HS3 Pro Edition 3.0.0.435

                Plugins - BLRF 2.0.94.0 | Concord 4 3.1.13.10 | HSBuddy 3.9.605.5 | HSTouch Server 3.0.0.68 | RFXCOM 30.0.0.36 | X10 3.0.0.36 | Z-Wave 3.0.1.190

                Hardware - EdgePort/4 DB9 Serial | RFXCOM 433MHz USB Transceiver | Superbus 2000 for Concord 4 | TI103 X-10 Interface | WGL Designs W800 RF | Z-Net Z-Wave Interface

                Comment


                  #9
                  Originally posted by rjh View Post
                  The samples are source code to 3 plugins. If you are not a programmer, I doubt they are of any use.
                  Nice touch Rich, good to in an open forum that HST is trying to help those developers that are insterested pointing in the right direction.
                  sigpic
                  A founder member of "The HA Pioneer Group" otherwise known as the "Old farts club!"

                  Comment


                    #10
                    Is there a HOWTO or beginners guide to homeseer plugin/custom web page development? I've reviewed the SDK documentation and it makes assumptions about how to even start. (Yes, I'm a developer but of low level OS/drivers, but not web/java/scripts -- just starting there)

                    Comment


                      #11
                      If there is I haven't found it yet
                      The information you need is in the SDK and samples, there's just no overall design doc that show how it all fits together. I found the HSPI_SAMPLE to be the most useful albeit more than you might use. Another confusing thing for me was how the same process was coded slightly different in each example.

                      In the end i just slugged my way through it, it's just another language and/or API. If you can write low level drivers you shouldn't have a problem other than a lot more time to fill in the blanks.
                      Being a Beta doesn't help either as you're never sure if it's your misunderstanding something or just a bug

                      Have fun
                      Z

                      Comment


                        #12
                        I don't think my question is specific to ver 3. Please walk me though creating a simple custom page. I've added simple internal and extern URLs in the Tools->Setup->Custom->Custom Page 1 URL [e.g., test.html] but I don't see a new page. Added the test.html file to the homeseer html folder. How do I add a custom page?

                        Comment


                          #13
                          Sorry, HS3 is eating away at my brain

                          I'm assuming you entered in the page name in the URL section (It's homebased to /html already, so just the page name, ie test.html)

                          You'll get a new button on your header that has the title you gave it. You can access it from there.
                          Z

                          Comment


                            #14
                            Got it, thanks.

                            Comment


                              #15
                              I have some problem to get SAMPLE & SAMPLE_BASIC to work. I have not done any changes in the code yet.

                              Using Visiual Studio Express 2012

                              HSPI_SAMPLE (Can't build, 102 errors)

                              HSPI_SAMPLE_BASICMI (Works Perfect) I have made my own plugin with this, but don't want multiple instances.

                              HSPI_SAMPLE_BASIC (Build is working but I got error when activate the plugin, see error below)

                              Initializing plug-in(2): Sample-Basic Instance::Conversion from string "COM1" to type 'Long' is not valid.0STACK:Server stack trace: Exception rethrown at [0]: at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessag e(IMessage reqMsg, IMessage retMsg) at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(Mess ageData& msgData, Int32 type) at HomeSeerAPI.IPlugInAPI.InitIO(String port) at Scheduler.clsHSPI.CheckInterfaces()

                              Thanks
                              Please excuse any spelling and grammatical errors I may make.
                              --
                              Tasker Plugin / Speech Droid
                              Tonlof | Sweden

                              Comment

                              Working...
                              X