This is to announce a new emacspeak module called Piglets that brings together Emacs and Firefox to create a powerful framework for authoring Web interaction wizards.
Why Piglets?
You might well ask Why Piglets?
,
and might conjecture that PIGLETS might stand for
Powerful Internet Gadgets for a Light-Weight Talking
System.
You might conjecture that the Emacspeak mascot likes pig-ears; or
you might even think of attributing it to the fact that my
friend and colleague Charles Chen and creator
of Fire Vox was born in the year of the pig.
But you'd be mostly wrong in all of the above.
Piglets on the Emacspeak desktop are the result of having two large (and powerful) software pigs connect over a socket. A few months ago, I blogged here about MozREPL and how it allows me to Put The Fox In A Box. Piglets mark the completion of the Emacs/Firefox integration that started with Firebox. Once you install Fire Vox, the free self-voicing extension for Firefox, piglets become a versatile means to leverage the self-voicing Fire-Vox/Firefox DOM from the comfort of the emacspeak environment.
What You Need
Caveat: ALL of this is early experimental software --- and you'll need to tweak things for your environment to get things working.
- A version of Emacspeak from the subversion repository.
- Check the installation of the
servers/python
files in your Emacspeak installation. - Confirm that the
HTTP
wrapper for the TTS servers works. You can most easily do this by running:# Start the HTTPspeech server # from emacspeak/servers/python python HTTPSpeaker.py outloud 2222 & # you can replace outloud with dtk-exp # but the bindings to other TTS servers is not defined for now # Run wget to test the speech server: wget --post-data='speak:hello world' localhost:2222
If all is well, you should here the TTS engine sayHello World
Do not proceed if the above does not work.
- Install Fire-Vox and configure it to use the Emacspeak TTS
server.
You can do this with ORCA providing the feedback.
Alternatively, once you have installed Fire-Vox, shutdown
Firefox and then edit your
~/.mozilla/firefox/default/prefs.js
user_pref("firevox.LastWorkingTTS", 4);
- The above sets up Fire-Vox to use the running HTTP speech server you started earlier.
Loading And Running Piglets
The Piglets framework is implemented in module
emacspeak-piglets.el
. There is a Fire-Vox binding in
module emacspeak-firevox.el
and a binding to the JawBreaker
game in emacspeak-jawbreaker.el
.
How Does It Work?
When you get the various pieces configured and working, here is how things work:
- Piglets place you in a special interaction buffer in Emacs.
- Typing keys in this buffer go to Firefox.
- Control keys send commands to Firefox using MozREPL.
- The latter is most useful in conjunction with Web 2.0 applications that have been AxsJAXed.
- Additional commands give access to FireFox features such as
the URL bar. As an example, hit
C-w
and type the phrase you'd like to go into the address bar --- either a URL or a search term. As an example, try typing XKCDComic. This will automatically do a Google Lucky Search (thanks to FireFox magic) and open the XKCD site. - But wait, there's more! Because XKCD has been
AxsJAXed, you
will hear Fire-Vox automatically speak the comic strip and its
associated transcript. Hit
?
in the FireFox interaction buffer to hear the available keystrokes for this AxsJAXed application; in general,?
brings up keyboard help for AxsJAXed applications.
ToDos:
These are some todos that I plan to get to eventually --- if you have coding cycles to contribute, feel free to work on these.
- Create an HTTP binding to the TTS servers using TCL and the TCL HTTP libraries. This will eliminate the dependency on the Python wrapper I originally wrote for ORCA in fall 2005.
- Write more Piglets.
- Make installation and configuration simpler.
- Test installation and configuration of the various pieces.