The mobile phone does what you think it does.
Anyremote gives you a way to control a PC with a mobile phone or PDA via Bluetooth, IR or a plain cable. Read about it, it’s cool. In setting up a MythTV box (more on it later), I was a bit stuck for how to control the thing – eventually I’ll dig an IR receiver out of somewhere, and train it to use a DVD remote control or something, but until then I had a USB keyboard with a very short cable. Or until I actually made practical use of my phone’s Bluetooth capabilities and made a remote control out of that instead.
Besides, controlling your computer with your mobile phone is really really cool.
There’s two parts to it: The server runs on a PC, and the Java client (anyRemoteClient-2.12.tar/anyRemoteClient/bin/anyRemote.jar) runs on your phone (obviously your phone has to support both Java and being conveniently connectable to a useful PC). I don’t know how it is with other brands, but Nokia forces you to use their big fat Windows-only ergoware to add Java apps to a phone; just sending it the .jar like any other file won’t work (it’ll lie and say it doesn’t know what to do with that filetype).
Once it’s on your phone, connect the phone to the computer running the server, “Search” for addresses, then just connect. The button icons will show up, and away you go.
Installing anyremote can be quick and easy, or it can be a downright pain. The choice is yours: either you install alien and convert the .rpm to a .deb and install it like any other package, or you can try compiling the thing from source. I gave up on the latter course when it started looking for header files in places Ubuntu doesn’t keep them.
Configuring anyremote is a… unique… experience. Once you figure out it tries to open .anyremote.cgf in your home directory if you don’t specify a file with
anyremote -f config.cfg, there’s a pile of example config files (the useful ones to me were in cfg-examples/Server-mode/) to get you started. There’s configs for XMMS, Amarok, Banshee, Totem and a few other players, and a ton of others that do other cool things – one lets you lock your desktop session from your phone, there are file manager utilities, one was showing me dmesg output on my phone). I started with mouse.cfg.
The idea is that you can redefine the number keys and * and # on your phone to run certain commands on the PC. These commands can be complicated scripts that do a thousand things at once, or they can be as simple as emulating keyboard or mouse actions. The default mouse.cfg gives you phone control of your mouse cursor including clicks and scrolling, including using the phone’s joystick/D-pad for directional movement. I modified it to use xte (son of xautomation) to emulate particular MythTV keyboard shortcuts, including menu navigation, volume control and pause/play control of video (seeking is done via left/right/up/down in MythTV’s default internal player):
1=Exec(xte ‘key Escape’)
2=Exec(xte ‘key Up’)
4=Exec(xte ‘key Left’)
5=Exec(xte ‘key Return’)
6=Exec(xte ‘key Right’)
7=Exec(xte ‘key p’)
8=Exec(xte ‘key Down’)
9=Exec(xte ‘key 9’)
*=Exec(xte ‘key [‘)
0=Exec(xte ‘key 0’)
#=Exec(xte ‘key ]’)
The phone’s anyremote GUI uses preset icons:
0 and 9 are 0 and 9 because MythDVD uses them for particular things. I liked the + and – icons more than the volume up/down ones, and the 3 button just sets off the vibrator because I couldn’t think of a use for it. Possibly I’ll find a keyboard shortcut to go to a DVD’s root menu and use it for that. Also I’m not sure if anyremote is even a practical control for actually watching TV; I don’t yet have a tuner card for that box.
I might write something up about Bluetooth phones and Linux at some point. For now I’m waiting for the fix for a related bug to release.