There are times that computers can be the most amazing devices; capable of automating mundane tasks, enabling communication with colleagues, friends and family or simply opening access to the great storehouse of knowledge represented by the interwebs.
Then there are times you just want to have a little fun. I've mentioned before that Alex is one of the best synthetic voices I've ever heard, complete with pauses and breaths that make it sound much more natural than the cyborg sounding voices of the past. What I love about Alex is that you can read off sentences directly from the command line. Just open up Terminal and enter:
say "This is coming from Alex"
It may take a second but shortly you will hear Alex's voice emanating from your speakers. The ability to speak text directly from the command line is incredibly cool, but invaluable when you combine it with the ability to SSH into a machine.
SSH and Remote Access
SSH—which stands for Secure Shell—allows you to remotely access most Linux or Unix based machines, including Macs running OS X. First you need to make sure it's enabled on the machine you want to remotely access. Go into System Preferences / Sharing and enable Remote Login. You will also want to make sure you have a named account on the remote machine.
You can connect to a remote machine by simply entering the following from a terminal prompt:
For me that's:
I won't go into too much detail on how this works; that's beyond the scope of this blog post. There is a lot of information on how you can get SSH working properly between two machines though. Google will help.
Once you've logged into the remote machine you can run command line applications. This is the method I use to access remote logs on my Macs and see if Time Machine has failed while I was away—which it invariably has.
If however you enter a "say" command while remotely accessing a machine Alex's voice will emanate from the remote machine's speakers, even if someone else is logged in and actively using the machine.
Remember that laptop that I gave my youngest daughter? Well, I still have an account on that machine. The sheer joy of logging into that machine while she is using it and having it say things is simply priceless.
"Daddy! My machine is talking to me!!!"
Of course, she's a really smart kid. Within minutes she figured it had to be me and wanted to know how I did it so that she could do it to her sister.
Now all I need is a decent SSH client for my iPod Touch and I'm in the portable ventriloquist business.
say "Mooo ha ha ha"