Announcement

Collapse
No announcement yet.

Google Calender script from HS2 to HS3

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

    #76
    Hi Adam,

    Cut and pasted scripts as you suggested, I now get the following error and no speech! Any suggestions ?

    Click image for larger version

Name:	ImageUploadedByTapatalk1419757238.304211.jpg
Views:	1
Size:	70.8 KB
ID:	1175704


    Cheers

    Steve
    Steve

    Comment


      #77
      morning Steve, I am not sure if that is actually a problem in the script or not because the TTS seems to go out of the script OK (and in the format expected by the way the script is written) and it is then something in the speaker client that is complaining. Can you try just sending some other TTS to it from an event or something? If that works please can you go into the control panel and run this line:

      &hs.speak("You have no appointments tomorrow", True, "$SONOS$TTS")

      and see whether it speaks OK

      Comment


        #78
        Morning Adam, thanks. I am out at the moment but will try when I get home. I can confirm that other tts are working fine.

        Will let you know
        Steve

        Comment


          #79
          Hi Adam,
          I can confirm that pasting you suggestion into the command panel gives the same error in the log.

          However, I copied and pasted this from the original Google calendar script and it works

          hs.speak("Steve, here are your appointments for tomorrow <silence msec='600' />", True, "$SONOS$TTS$")

          I take it that I just need to amend other parts of the script with this too?

          Cheers
          Steve

          Comment


            #80
            Not sure what has caused the error really because this hs.speak("You have no appointments tomorrow", True, "$SONOS$TTS") if it errors is a standard TTS command with nothing special in it. What I would say is mess about and see what you can do, you are unlikely to break anything and if you do keep a backup you can revert to. The reason I put all the speech into one string and then spoke it was because I think that the Sonos is speaking this to a file and then sending this file to the speaker, if you do

            hs.speak("This is")
            hs.speak("only a")
            hs.speak("test")

            then I understand that is three files (perhaps more work the PC has to do, more network traffic) but if you see no ill effects from having more than one hs.speak line then use it.

            Comment


              #81
              Originally posted by mrhappy View Post
              Hope it works OK for anyone that needs it...
              Brilliant, thank you.

              I have modified your original script to pick up three Google Calendars and populate three virtual Devices (Today, Tomorrow and Future) then show in HSTouch. I had this working until V3 but this fixes it.

              Thanks again

              Scott

              Comment


                #82
                No worries glad it works for you. I do similar I have it writing to a device with a HTML table for tomorrows calendar entry (I don't think this will populate over to HSTouch though). I would contemplate writing this as a bit more of a package but a lot of people will want different things I think it would be a bit of a nightmare for me, it is a fairly easy library thankfully to manipulate.
                Last edited by mrhappy; January 20, 2015, 10:19 AM.

                Comment


                  #83
                  Thanks Adam

                  I am back at work now. I will endeavour to see if I can get it working over the New Year. Will let you know how I get on.

                  Thanks for your support on this .


                  Cheers

                  Steve
                  Steve

                  Comment


                    #84
                    Originally posted by Stevieboy View Post
                    Thanks Adam

                    I am back at work now. I will endeavour to see if I can get it working over the New Year. Will let you know how I get on.

                    Thanks for your support on this .


                    Cheers

                    Steve
                    Drop me an email if you are still having issues and I will try and get to the bottom of it, I think I need to look through it and test to see why the error comes up. It could be something that the Sonos plugin is not liking as I can't see why it would error otherwise.

                    Comment


                      #85
                      Thanks Adam.

                      I have asked Dirk to take a look and see if he can work out the speech . I believe you are correct in that it writes to file first and then announces it.

                      Will let you know [emoji2]
                      Steve

                      Comment


                        #86
                        Hi Adam, how's the Sonos TTS coming along ?


                        Cheers

                        Steve
                        Steve

                        Comment


                          #87
                          I didn't to be absolutely honest but I have not tried, it will be a while until I have a full Sonos install and other than a bit of testing no reason to worry now so I will figure it out when I have the complete install.

                          Did you manage to sort yours out, if not as I say drop me an email and I will try and figure out what is up.

                          Comment


                            #88
                            Hi Adam

                            Nope, not heard back from Dirk, still it is holiday time so I guess he taking a well deserved break from the keyboard !

                            Not sure what your e mail address is ?

                            Shall I forward you the whole script ?

                            I broke HS3 over Xmas so been trying to get it back to normal [emoji2]

                            Would appreciate your expertise .

                            I posted in the HS 3 forum regarding an error I now get after I accidentally switched off PC . Of I turn off the log the error is not present on startup . Still, one thing at a time !
                            Steve

                            Comment


                              #89
                              I've sent you a PM...

                              Comment


                                #90
                                Originally posted by mrhappy View Post
                                Drop me an email if you are still having issues and I will try and get to the bottom of it, I think I need to look through it and test to see why the error comes up. It could be something that the Sonos plugin is not liking as I can't see why it would error otherwise.
                                mrhappy, thank you so much for this. I looked into the v3 API, and it does look pretty involved for read-only. I have my own scheduling scripts, and your find/sample code was invaluable to me!

                                I like this guy's iCal library. The documentation looks like it hasn't been updated in a few builds, as members/methods seem to have changed slightly. But, it's working, and simple enough to deal with.

                                Thank you!!

                                Comment

                                Working...
                                X