Announcement

Collapse
No announcement yet.

speak a email attached mp3 file

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

    speak a email attached mp3 file

    I'm looking at guidance on how I could have HS3 "speak" a mp3 file that would be recieved via email on my windows HS3 server

    I already installed and configured Jon00email plugin so I can now send and receive emails BUT I need two more part in my puzzle:

    1- how can I automatically detach a file from a received email ?
    2- I would need a hint on how I could write a script that would detect the mp3 file so I could set an event to "speak" my mp3 file ?

    thanks for any help

    evidently, my goal is to send spoken messages with my own voice via my Sonos plugin (I already set hstouch to speak a text I enter in a text box via scripting but this does not give the same results as if it would be my own voice)

    #2
    You really should have posted this in my forum under my email thread.

    It should be fairly straightforward provided you have setup the application to run Jon00EmailUser.vb (search the docs for this file to understand how to set this up).

    Questions:

    1) Does the MP3 have the same filename each time?
    2) would you want this mp3 played on receipt of the email?
    Jon

    Comment


      #3
      Hi Jon

      sorry for the misplacement, to answer to your 2 questions

      1- yes I can manage to always have the same filename
      2- Yes I would want the file played on reception

      I will look further in the Jon00email documentation to try to understand how to use j0n00emailuser.vb

      thanks

      Comment


        #4
        OK, if you get it working, you will see each received email details in the log.

        Add the following code under the '***do not edit above this line***':

        Code:
        Dim FilePath As String = hs.GetAppPath & "\html\TempEmail\MB" & MailBoxNumber & "\" & MessageNumber & "\test.mp3"
        If System.IO.File.Exists(FilePath) Then
            hs.SpeakEx(0,FilePath, False,"*:*")
        End if
        Change the test.mp3 to the name of your mp3 filename.

        You will need to change the speaker client/instance from "*:*" to "$SONOS$ALL$" or whatever Sonos device you want to point to.

        You may also need to disable any per-announcement chimes as that will override the mp3 playing.
        Jon

        Comment


          #5
          GREAT thank you so much, all I have to do now is configure my setting so emails are checked every minutes.

          Comment

          Working...
          X