Announcement

Collapse
No announcement yet.

Twinkly.vb - Christmas tree lights with predefined and custom animations

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

    #16
    This is probably something I should see, but I don't. I have scripting references set. Newtonsoft.Json.dll is in the HomeSeer HS3/ the HomeSeer HS3/bin and about a dozen other places in the /bin subdirectory. When I launch the script calling the subroutine setup, I get these errors (newest on top).



    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: class 'TwinklyAuthentication' and class 'TwinklyAuthentication' conflict in class 'VBWrapper'.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'debug' is already declared as 'Private debug As Boolean' in this class.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'IP' is already declared as 'Private Const IP As String = "192.168.2.214"' in this class.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function ConvertByteArrayToString(bytes() As Byte) As String' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function ConvertStringToByteArray(input As String) As Byte()' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Private Function GetRandomString(length As Integer) As Object' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function GetRandomCode([forceNew As Boolean = False]) As String' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Private Function RunAPIraw(urlFunction As String, [bytes() As Byte = Nothing]) As Byte()' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Private Function RunAPI(urlFunction As String, [query As String = ""]) As String' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function Login(challenge As String, [forceNew As Boolean = False]) As TwinklyAuthentication' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function Verify() As Boolean' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function GetAuthentication() As TwinklyAuthentication' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub SetMode(mode As String)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub SetMovieFull(octetString As String)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub GetMovieFull()' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub GetMovieConfig()' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub SetMovieConfig(frameDelay As Integer, numberOfLEDs As Integer, framesNumber As Integer, loopType As Integer)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub AddDeviceButtons(device_ref As String)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub Setup(not_used As String)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Function DoCmd(command As String) As Boolean' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub ButtonPress(input As Object)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Public Sub Main(something As Object)' has multiple definitions with identical signatures.
    Nov-28 10:05:49 AM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: Namespace or type specified in the Imports 'System.Core' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.
    HS4 Pro, 4.2.19.16 Windows 10 pro, Supermicro LP Xeon

    Comment


      #17
      I would be very interested in this too!
      Made changes to the settings.ini file as per previous post.
      I get the same error message as posted by rprade albeit not the very top one re 'TwinklyAuthentication'.
      Using HS4 Pro.
      Any help would be appreciated.
      Thanks!

      Comment


        #18
        Just jumping on this also as I have a TON of Twinkly lights and it would be great to have them integrated into Homeseer. I am getting the same error as others are reporting:
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: 'Newtonsoft' is not declared. It may be inaccessible due to its protection level.
        Dec-04 8:33:20 PM Error Compiling script C:\Program Files (x86)\HomeSeer HS3\scripts\Twinkly.vb: Namespace or type specified in the Imports 'System.Core' doesn't contain any public member or cannot be found. Make sure the namespace or the type is defined and contains at least one public member. Make sure the imported element name doesn't use any aliases.
        Appreciate any help getting this working!


        Comment


          #19
          , I'm not sure what's going on. The script should work on Windows and LInux, as long as the Newtonsoft.Json.dll is correctly referenced.
          HSPro 3.0.0.458, Z-NET with Z-wave plugin 3.0.1.190, RFXCOM + 2x RFXtrx433E, HSTouch, Squeezebox plugin, iTach IP/WF2IR & GC-100-6 with UltraGCIR, BLDenon, NetcamStudio, Jon00s Webpage builder, Harmony Hub plugin, SCSIP (with FreePBX), Arduino plugin, IFTTT, Pushalot plugin, Device History plugin.
          Running on Windows 10 (64) virtualized
          on ESXi (Fujitsu Primergy TX150 S8).
          WinSeer (for Win10) - TextSeer - FitbitSeer - HSPI_MoskusSample

          Are you Norwegian (or Scandinavian) and getting started with HomeSeer? Read the "HomeSeer School"!

          Comment


            #20
            Got by that last error, now getting the declared error that fx12002 is getting HS4

            could it be different versions of newtonsoft.json

            Comment


              #21
              further, when ever I restart HS4, it deletes the line I added in settings.ini

              Comment


                #22
                OK fixed that error. In order to make changes to settings.ini, HS4 has to NOT be running. The path to newtonsoft.json and newtonsoft.dll needs to be spot on.

                C:\Program Files (x86)\HomeSeer HS3\Bin\homeseer\newtonsoft.json in my case.

                Comment


                  #23
                  How do you add or change the modes? I have the Christmas Tree lights in two strings joined. The script only controls one string instead of one joined...

                  Comment


                    #24
                    Originally posted by mattdb View Post
                    How do you add or change the modes? I have the Christmas Tree lights in two strings joined. The script only controls one string instead of one joined...
                    Yeah, I don't know if that is supported by the API. I haven't researched it.
                    HSPro 3.0.0.458, Z-NET with Z-wave plugin 3.0.1.190, RFXCOM + 2x RFXtrx433E, HSTouch, Squeezebox plugin, iTach IP/WF2IR & GC-100-6 with UltraGCIR, BLDenon, NetcamStudio, Jon00s Webpage builder, Harmony Hub plugin, SCSIP (with FreePBX), Arduino plugin, IFTTT, Pushalot plugin, Device History plugin.
                    Running on Windows 10 (64) virtualized
                    on ESXi (Fujitsu Primergy TX150 S8).
                    WinSeer (for Win10) - TextSeer - FitbitSeer - HSPI_MoskusSample

                    Are you Norwegian (or Scandinavian) and getting started with HomeSeer? Read the "HomeSeer School"!

                    Comment


                      #25
                      Thanks Moskus, my Christmas tree is connected to HS now .
                      The only thing is that the devices won't show up when creating an event and that the devices are gone after a HS restart.
                      Any ideas?

                      Comment


                        #26
                        Originally posted by Broes View Post
                        Thanks Moskus, my Christmas tree is connected to HS now .
                        The only thing is that the devices won't show up when creating an event and that the devices are gone after a HS restart.
                        Any ideas?
                        Yes, this is a typical error. Select to show all device types.
                        HSPro 3.0.0.458, Z-NET with Z-wave plugin 3.0.1.190, RFXCOM + 2x RFXtrx433E, HSTouch, Squeezebox plugin, iTach IP/WF2IR & GC-100-6 with UltraGCIR, BLDenon, NetcamStudio, Jon00s Webpage builder, Harmony Hub plugin, SCSIP (with FreePBX), Arduino plugin, IFTTT, Pushalot plugin, Device History plugin.
                        Running on Windows 10 (64) virtualized
                        on ESXi (Fujitsu Primergy TX150 S8).
                        WinSeer (for Win10) - TextSeer - FitbitSeer - HSPI_MoskusSample

                        Are you Norwegian (or Scandinavian) and getting started with HomeSeer? Read the "HomeSeer School"!

                        Comment


                          #27
                          Oh man! Somehow I managed to miss this thread for a year and a half. Wish I hadn't seen it at all!!! Now I have to have these lights! Ugh!
                          .

                          Comment


                            #28
                            Sorry to revive an old thread folks but I need a little help here.

                            Thanks to Moskus, I have been able to add the Twinkly light to my HS4. And, using the controls that his script has provided, the lights respond appropriately.

                            My issue is that the device created by the script does not appear in the device dropdown list during the event creation process.

                            I see a similar issue posted above by Broes in Dec 2020, to which Moskus replied "Select to show all device types," though I don't understand what he is referring to there.

                            Any tips anyone?

                            Thank you.

                            Comment


                              #29
                              Sounds like HS4 beta issues. Try the latest which corrected this issue: https://docs.homeseer.com/display/HSPI/HS4+Beta+4.2.2.0
                              Jon

                              Comment


                                #30
                                I don't want to discourage any progress with this script. I just want to make aware of WLED that has a plethora of animations for lights and is supported in HS by the mcsMQTT plugin.

                                Comment

                                Working...
                                X