Announcement

Collapse
No announcement yet.

SaveState RestoreState

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

    SaveState RestoreState

    Heyya to you all !

    Something to fix !

    Lemme explain all of this

    We have 5 speakers installed on our AB8SS lets say they are all named "1" to "5".

    Our use in "5" don't want to have the normal radio that is coming through our speakers, so we want it to be always off BUT when someone call we want it to be on since we announce it through those speakers.

    I tried many thing with those Savestate and Restorestate function, but I seems to be unable to make any of those work properly.

    Soo... right now, 1,2,3,4 are on, 5 is off. When someone call everyone get the call info, thats top notch. When the call infos stop, each speakers get to on.

    Heres our script when someone calls us, it activates Yacseer


    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%"><TBODY><TR><TD class=tablecellscript width=160 noWrap align=right></TD><TD class=tablecellscript align=left>
    speakon_general.vb
    </TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellwav width=160 noWrap align=right>Play WAV and wait:</TD><TD class=tablecellwav align=left>doorbell.wav</TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellhstouch_server width=160 noWrap align=right>HSTouch Server:</TD><TD class=tablecellhstouch_server colSpan=8 align=left>Set the text property of an element:
    Client: DomoNOD on DomoNOD
    Element: main:talker
    URL: http://192.168.2.5:81/talking.html
    </TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellscript width=160 noWrap align=right>Run script:</TD><TD class=tablecellscript align=left>&hs.speak hs.plugin("ROC-Rnd").random("callerid"), true, "domonod:*"</TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellwait width=160 noWrap align=right>Wait:</TD><TD class=tablecellwait align=left>10 seconds</TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellhstouch_server width=160 noWrap align=right>HSTouch Server:</TD><TD class=tablecellhstouch_server colSpan=8 align=left>Set the text property of an element:
    Client: DomoNOD on DomoNOD
    Element: main:talker
    URL: http://192.168.2.5:81/standby.html
    </TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%" align=center><TBODY><TR><TD class=tablecellscript width=160 noWrap align=right>Run script:</TD><TD class=tablecellscript align=left>speak_end.vb</TD></TR></TBODY></TABLE>
    <TABLE border=0 cellSpacing=0 cellPadding=0 width="100%"><TBODY><TR><TD class=tablecellhstouch_server width=160 noWrap align=right></TD><TD class=tablecellhstouch_server colSpan=8 align=left>
    Simulate a Press of an Element:
    Client: DomoNOD on DomoNOD
    Element: main:Label 021
    </TD></TR></TBODY></TABLE>


    SPEAKON_GENERAL.VB
    Public Sub Main(ByVal strDeviceRef As Object)
    hs.plugin("AB8SS").SaveSpkrState()
    hs.plugin("AB8SS").InputAB("A") //our input to get the callers id
    hs.plugin("AB8SS").AllSpkrOn() //All speakers for call
    hs.plugin("AB8SS").SpkrOff("spk-entree")
    End Sub

    SPEAK_END.VB
    Public Sub Main(ByVal strDeviceRef As Object)
    hs.plugin("AB8SS").AllSpkrOn()
    hs.plugin("AB8SS").InputAB("B") //our input for radio
    hs.plugin("AB8SS").RestoreSpkrState() //trying "ON" all but the 5
    End Sub



    Do you see something that shouldnt be done this way ?

    Thanks for your time

    #2
    I just back from a trip, so let me investigate for you.
    -Larry

    A member of "The HA Pioneer Group", MyWebSite

    Plugins:
    VWS, AB8SS, lrpSpeak, Calendar, Arduino, Harmony, BlueIris, Sprinklers, ZipBackup...

    Hardware:
    Intel NUC8i7BEH1 running Windows 10 Pro headless, HS3 Pro, Plex running on Synology dual High Availability DS-1815+ NAS (24Tb each), Synology Surveillance Station running on DS-416 Slim (8Tb), Samsung SmartThings, Google Home, Alexa, Hubitat Elevation, ZNET, Ubiquiti UniFi Network, Davis Vantage Pro II Weather Station. Whole house speaker system using a couple of AB8SS switches. Vantage Pro II Weather Station, Rain8Net Sprinklers, Hubitat Elevation, Google Home, Alexa, DSC Security System, Ubiquiti UniFi Network.

    Comment


      #3
      Ab8ss

      Thx Ipitman !
      Very appreciated, some of the staff are annoyed by the background radio and it keeps coming back everytime there is a general speak action

      Comment


        #4
        I am sending version 2.2.0.22 to the updater, hopefully will help your problem...please delete your current AB8SS.ini file in the "C:\Your-HS-Directory\Config" directory and restart the HS after performing update.

        The new ini file changes some of the default fields and needs to be replaced...you should rename orginal so you still have access to saved names of speakers.

        Let me know how things work.
        -Larry

        A member of "The HA Pioneer Group", MyWebSite

        Plugins:
        VWS, AB8SS, lrpSpeak, Calendar, Arduino, Harmony, BlueIris, Sprinklers, ZipBackup...

        Hardware:
        Intel NUC8i7BEH1 running Windows 10 Pro headless, HS3 Pro, Plex running on Synology dual High Availability DS-1815+ NAS (24Tb each), Synology Surveillance Station running on DS-416 Slim (8Tb), Samsung SmartThings, Google Home, Alexa, Hubitat Elevation, ZNET, Ubiquiti UniFi Network, Davis Vantage Pro II Weather Station. Whole house speaker system using a couple of AB8SS switches. Vantage Pro II Weather Station, Rain8Net Sprinklers, Hubitat Elevation, Google Home, Alexa, DSC Security System, Ubiquiti UniFi Network.

        Comment


          #5
          Ab8ss

          Awsome !
          Thx a lot Ipitman !

          I do not see the update yet but it's probably a matter of getting it approved trough HS webmasters, will try again tomorrow...

          Thx again ! Long live Homeseer and it's comunity of developpers !

          Comment


            #6
            Originally posted by loowee View Post
            Awsome !
            Thx a lot Ipitman !

            I do not see the update yet but it's probably a matter of getting it approved trough HS webmasters, will try again tomorrow...

            Thx again ! Long live Homeseer and it's comunity of developpers !
            Hi again Ipitman !

            Sorry I havnt given news earlier, we have had crazy rushy days @ the office !!

            I have done the update and completely overwritten my AB8SS ini file but now, the plugin makes homeseer lag as soon as a script is launched with any ab8ss arguments ( savespkrstate, etc ). I had to disable plugin to save our homeseer integrity, lag really kills the CPU which runs @ 100% starting on the first event that had a ab8ss action script.

            Note that manual control of the ab8ss works fine and it seems to be a scripting problem.
            I also noticed that homeseer did not change the speaker names back to original names like on the new ini file, this might be a cause of the problem.

            Our script is the same as before.

            Any idea ? Thx !

            Comment


              #7
              Make sure which state is selected in the config screen...ie Restore previous state, or Default state, or all off state.

              Previous state -- should save position of relays and return to that state.

              Default state -- return to the on-offs for each device as configured.

              All OFF state -- just returns all relays off after speaking.

              You could turn on debug for me and post the AB8SS.log file it produces, so I can see what is happening on your system.

              Oh, if you could please post a copy of your scripts, so I can check them as well.

              Thanks.
              -Larry

              A member of "The HA Pioneer Group", MyWebSite

              Plugins:
              VWS, AB8SS, lrpSpeak, Calendar, Arduino, Harmony, BlueIris, Sprinklers, ZipBackup...

              Hardware:
              Intel NUC8i7BEH1 running Windows 10 Pro headless, HS3 Pro, Plex running on Synology dual High Availability DS-1815+ NAS (24Tb each), Synology Surveillance Station running on DS-416 Slim (8Tb), Samsung SmartThings, Google Home, Alexa, Hubitat Elevation, ZNET, Ubiquiti UniFi Network, Davis Vantage Pro II Weather Station. Whole house speaker system using a couple of AB8SS switches. Vantage Pro II Weather Station, Rain8Net Sprinklers, Hubitat Elevation, Google Home, Alexa, DSC Security System, Ubiquiti UniFi Network.

              Comment


                #8
                Sorry for the past weeks we put this aside...

                Here's our log on whats happening now.


                <TABLE border=0 cellSpacing=2 cellPadding=0 width="100%"><TBODY><TR><TD class=LOGDateTime1 noWrap align=left>06/05/2010 9:53:55 AM </TD><TD class=LOGType1 colSpan=3 align=left>Error </TD><TD class=LOGEntry1 colSpan=8 align=left></TD></TR></TBODY></TABLE>


                If you have any idea, any directives to give us, go ahead, we'll comply.

                Thanks !

                Comment


                  #9
                  Any suggestion for us Ipitman?
                  We really are missing this nifty plugin !
                  Thx !

                  Comment


                    #10
                    Originally posted by lpitman View Post
                    Make sure which state is selected in the config screen...ie Restore previous state, or Default state, or all off state.

                    Previous state -- should save position of relays and return to that state.

                    Default state -- return to the on-offs for each device as configured.

                    All OFF state -- just returns all relays off after speaking.

                    You could turn on debug for me and post the AB8SS.log file it produces, so I can see what is happening on your system.

                    Oh, if you could please post a copy of your scripts, so I can check them as well.

                    Thanks.
                    Please follow these instructions and attach the AB8SS.log file... the log entry you posted has no reference to my plug-in at least what I could recognize...If you enable debug as mention before...then debug and consequent log file it generates will be more useful to me...especially since this plug-in is in use at many other locations without error.
                    -Larry

                    A member of "The HA Pioneer Group", MyWebSite

                    Plugins:
                    VWS, AB8SS, lrpSpeak, Calendar, Arduino, Harmony, BlueIris, Sprinklers, ZipBackup...

                    Hardware:
                    Intel NUC8i7BEH1 running Windows 10 Pro headless, HS3 Pro, Plex running on Synology dual High Availability DS-1815+ NAS (24Tb each), Synology Surveillance Station running on DS-416 Slim (8Tb), Samsung SmartThings, Google Home, Alexa, Hubitat Elevation, ZNET, Ubiquiti UniFi Network, Davis Vantage Pro II Weather Station. Whole house speaker system using a couple of AB8SS switches. Vantage Pro II Weather Station, Rain8Net Sprinklers, Hubitat Elevation, Google Home, Alexa, DSC Security System, Ubiquiti UniFi Network.

                    Comment


                      #11
                      Attached Files

                      Comment


                        #12
                        Ab8ss

                        any news for us Ipitman ?
                        seem like the lag start because of a script loop that is declared as soon as a script event is triggered.

                        One liners script works just fine but as soon as we use the scriping window / external files ( see example below ), lag starts right away and CPU gets clogged to 100%

                        Public Sub Main(ByVal strDeviceRef As Object)
                        hs.plugin("AB8SS").InputAB("A")
                        End Sub


                        HELP US ... ANYONE ???

                        Comment


                          #13
                          I examined the AB8SS.log file and did not find any errors...in fact everything appears to be working good from the plugins perspective. Could you also include a copy of your AB8SS.ini file? Seems like the speaker name is not recognized from your previous post.

                          Thanks.
                          -Larry

                          A member of "The HA Pioneer Group", MyWebSite

                          Plugins:
                          VWS, AB8SS, lrpSpeak, Calendar, Arduino, Harmony, BlueIris, Sprinklers, ZipBackup...

                          Hardware:
                          Intel NUC8i7BEH1 running Windows 10 Pro headless, HS3 Pro, Plex running on Synology dual High Availability DS-1815+ NAS (24Tb each), Synology Surveillance Station running on DS-416 Slim (8Tb), Samsung SmartThings, Google Home, Alexa, Hubitat Elevation, ZNET, Ubiquiti UniFi Network, Davis Vantage Pro II Weather Station. Whole house speaker system using a couple of AB8SS switches. Vantage Pro II Weather Station, Rain8Net Sprinklers, Hubitat Elevation, Google Home, Alexa, DSC Security System, Ubiquiti UniFi Network.

                          Comment


                            #14
                            Hi lpitman,

                            We found the problem... this line is not working...

                            hs.plugin("AB8SS").InputAB("A")

                            But when we change to input B, it works fine.

                            Any idea what it could be ?

                            Thank in advance.

                            Here's the .ini file :


                            [Config]
                            Debug=true
                            [Delays]
                            PostDelay=200
                            [SpkrNames]
                            Relay1=Speaker-1
                            Relay2=Speaker-2
                            Relay3=Speaker-3
                            Relay4=Speaker-4
                            Relay5=Speaker-5
                            Relay6=Speaker-6
                            Relay7=Speaker-7
                            Relay8=Speaker-8
                            [SpkrDefState]
                            Speaker-1=False
                            Speaker-2=False
                            Speaker-3=False
                            Speaker-4=False
                            Speaker-5=False
                            Speaker-6=False
                            Speaker-7=False
                            Speaker-8=False
                            [DefaultState]
                            Input=A
                            Output=1



                            EDIT : We also updated the .net framework to 4 and it's still not working for this command.
                            Last edited by loowee; July 6, 2010, 02:24 PM.

                            Comment


                              #15
                              Is anyone got an idea what it could be?

                              We tried a lot of things

                              Comment

                              Working...
                              X