The following description was written having receivers in mind that deliver IR signals as pulses and spaces. So some of this will not be relevant for receivers that work at a higher abstraction layer as e.g. the Irman or TV card receivers. Using irdb-get(1), lirc-lsremotes(1) or the remotes database you can check if an existing remote has timing info.
There is a growing database of config files for remote controls available at the lirc-remotes homepage. If your remote control is not available yet you can use irrecord to create a config file for it. If you want to use more than one remote control you have to create a separate file for each remote. If your remote control is able to control different devices it is often wise to create separate config files for each functional unit of the remote control.You can use many files simultaneosly by adding them to the /etc/lirc/lircd.conf.d directory.
Before using irrecord you should start mode2 and have a look at the signals that your receiver supplies. If you can see random pulses without pushing any buttons on your remote control your receiver is picking up ambient light. So, if your receiver has no ambient light filter try to add one. A good strategy might also be to create a config file in a dark room and to turn off all fluorescent lamps or any other devices that may cause IR noise.
If decoding of IR commands does not work reliably you can try to modify the eps and aeps values in the lircd config file to adjust the tolerance of signal lengths. aeps is an absolute value while eps is a relative value expressed in percent. Also if repeats do not work you should complain. E. g., if you hold down a button the output of irw should look like this:
0000000000f40bf0 00 1_DOWN ANIMAX
0000000000f40bf0 01 1_DOWN ANIMAX
0000000000f40bf0 02 1_DOWN ANIMAX
0000000000f40bf0 03 1_DOWN ANIMAX
0000000000f40bf0 04 1_DOWN ANIMAX
0000000000f40bf0 05 1_DOWN ANIMAX
Note how the second field gets incremented. It is important this does works correctly.
If you want to use a config file to send IR commands you should try to vary the modulation frequency of the signals. The default frequency is 38000 Hz. It cannot be detected automatically because the receiver hardware only gives us the demodulated signals. Using the correct modulation frequency will increase range significantly. You can set the modulation frequency for a remote control by adding the line
frequency <freq>
to the according section of the config file where freq stands for the modulation frequency in Hertz. Usually values from 34000 to 44000 are good choices.
As creating new config files sometimes is difficult and irrecord often cannot detect all features of the remote control please send new config files to lirc@bartelmus.de. Other people will appreciate this very much. Sometimes they cannot create such a config file themselves because their original remote control is broken or has been lost. Some devices that are capable of IR come without a remote control. Some people also only want to build a transmitter and if you make a config file available for them they won't need to build a receiver, too. Please add all information you can get concerning the remote control as a comment to the config file, see the [Checklist].
If you still have difficulties to create a working config file send a message to the mailing list or file a ticket at the lirc sourceforge space. Try to provide the following info: