Overview
Basically what happens is, when Freevo starts up, it checks if it can initialize pylirc. If it can, it tries to open /etc/freevo/lircrc (or whatever the variable LIRCRC in local_conf.py is set to). It then uses these strings in the freevo code to perform actions.
First check if Lirc is working with your remote before attempting to get it to work with freevo.
(NOTE:: Check the remote section under supported hardware for stuff on specific remotes with lirc)
User recommended remotes
The remotes listed here are recommended by users because they not only work well with LIRC, but also fit into the freevo control philosophy.
- Skymaster Universal Remote 10in1
- all buttons used in freevo can be assigned to a button on this remote
- good layout, especially of the up/down/left/right/ok/exit buttons
- fast key repeat
- cheap
- the one disadvantage: DVD options (subtitle, lang, ...) have to be assigned to the "TV options" buttons (videotext, display, etc.)
- set it up to emulate a Philips TV remote, you'll then even have key repeat
- found: in Germany at Fegro and ALDI
- User comment: After a week-long search for a remote with a good layout for freevo, this one striked me as "this is it!"
- Microsoft MCE Remote
- easy to setup
- NOTE: only buy the remote, the MCE keyboard is not supported with Linux
Install steps
- Install Lirc (remote control receiver software)
http://www.lirc.org/Download and install lirc.
http://www.lirc.org/html/configure.html#lircrc_format (for more details on the .lircrc file format)
insmod any lirc modules you need (i.e. lirc_serial)
Create the /dev/lirc and /dev/lircd devices
N.B. /dev/lirc is not required if your device does not use a lirc kernel module (e.g. IRman)
Use irrecord to record your IR frequencies and associate them with names.
Copy the resulting file to /etc/lircd.conf or /etc/lirc/lircd.conf (depends on distro used)
This is my lircd.conf for a grey/black Hauppauge remote: lircd.conf
And this is my config for the same remote to control Xine. Save it as ~/.lircrc: lircrc
lircd of an other(newer) pvr350 remote on the freevo2 wiki
- Install pylirc (python-lirc library)
Download pylirc and install.
- Start the lirc daemon
/etc/init.d/lircd start
Run the lirc app irw to check the function of the remote control. you should see the names from your lircd.conf showing up when pressing those buttons.
Create a new file: /etc/freevo/lircrc. Use freevo makelircrc -w to produce a base lircrc file. See below for file format and how ot enhance it.
Test the remote using lirc's ircat application:
ircat --config=/etc/freevo/lircrc freevo
You should see the new freevo button names appear instead of those defined in lircd.conf
- Now try it with freevo.
File format
Essential commands:
LEFT, RIGHT, UP, DOWN, SELECT, ENTER, EXIT, DISPLAY
Recommended commands:
REC, REW, PLAY, FFWD, PAUSE, STOP, CH+, CH-
Format of file is:
begin prog = freevo button = <name from lircd> config = <freevo name> end
for example one section would be:
begin prog = freevo button = RECALL config = REC end
A more elaborate example is:
begin prog=freevo remote=hauppaugegrey button=GO repeat=1 delay=2 config=ENTER end
the file consists of many of the above sections separated by a blank line. For a listing of all available commands and how they are mapped within the different events (Playing Audio, Video, TV, etc...) look at freevo/src/event.py.
Create a personnal mapping rule.
It can be usefull to create a personnal mapping rule for example to manage the subtitle delay. To add this, edit the /etc/freevo/local_conf.py if no /etc/freevo/src/event.py is present and add a comportment link to a message. For example:
EVENTS['video']['SUB+'] = Event(VIDEO_SEND_MPLAYER_CMD, arg='sub_delay 0.1')
After this, add the correspondant comportment in /etc/freevo/lircrc
#change subtitle syncing (delay video) begin prog = freevo button = KEY_CHANNELUP config = SUB+ repeat = 1 end
To see the mapping rule of mplayer, show /etc/mplayer/input.conf