Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

simplebeep

macrumors member
Original poster
Sep 28, 2007
43
0
SLC
Hello all. I am using AppleScript Studio to write an application that speaks text. I want to be able to get the application to speak on a remote computer, even if only on a local network, over Remote Apple Events.

I have been somewhat successful, in that, on my Leopard computer, I can speak to another Leopard computer; and I have built a preliminary "release" version, ran it on Tiger, and it could speak to my Leopard computer. But, no matter what I try, I cannot speak to a Tiger computer. :confused: All parties involved have Remote Apple Events sharing turned on.

Here's the code, in part (given the machine address, theAddress (e.g. eppc://compy.local); the text to speak, mrSay; and the voice to speak it with, mrVoice):

Code:
using terms from application "Finder"
    tell application "Finder" of machine theAddress			
        try
            say mrSay using mrVoice
        on error
            say mrSay
        end try  [I]--Since mrVoice is user-defined, this is a simple failsafe.[/I]
    end tell
end using terms from

The code works, as I have said, but when I try to speak to a Tiger computer, I get the error
Finder got an error: "Text To Speak" doesn’t understand the «event sysottos» message. (-1708)​

Thanks in advance for any help/workarounds.
By the way, I want to avoid ssh solutions, and stick to the AppleScript.
 

foidulus

macrumors 6502a
Jan 15, 2007
904
1
Just for debugging purposes

I would try to launch it on Tiger and have it speak to itself(ie enter the address in as 127.0.0.1) and see if that works. May help to narrow down the problem.
 

simplebeep

macrumors member
Original poster
Sep 28, 2007
43
0
SLC
It worked… sort of.

…have it speak to itself…

Thank you, foidulus. Your question led to the solution.

First, I ran the application on the Tiger computer, and tried to get it to remotely speak to itself; first, I entered the Bonjour name (hal.local), and the app just beachballed, without any official error message. Then, I looked up the IP address of the computer (10.0.1.3), entered that, and then it could speak to itself no-problem.

Finally, I tried speaking to the Tiger computer from Leopard with the IP, which I had not previously done. Amazingly, it worked! :D Apparently, the actual numerical address is necessary.

But that leads me to a new (albeit less critical) question: How can I get it to work with the hal.local-type address?
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.