IRATTACH(8)
π«Ά IRATTACH(8) π«Ά
aka the manual page for irattach, straight outta section 8 (the admin/system-commands section, iykyk)
β¨ NAME β¨
irattach β binds the Linux-IrDA stack to a IrDA port
yes bestie that is literally the whole job, and it is lowkey the most important step π
π SYNOPSIS π
irattach [ <dev> ] [ -s ] [ -d dongle ] [ -v ] [ -h ]
πΈ DESCRIPTION πΈ
okay so. irattach binds the Linux-IrDA stack to an IrDA port. What that means fr is it configures the low level of the Linux-IrDA stack in the kernel. And bestie, you usually gotta do this <em>before</em> you (or literally any application) can touch the higher layer of the IrDA stack. No skip step, no shortcut, periodt.
The irattach command loads the necessary Linux-IrDA driver β which is what actually configures your IrDA hardware β and then configures the IrDA stack to operate on that brand new IrDA port. And guess what, you can activate multiple IrDA ports by just running multiple irattach commands. Slay.
By default irattach uses the irtty driver. The irtty driver connects to the Linux TTY subsystem and uses the standard Linux serial driver. This works great for most machines and configs, but it caps the baud rate at 115200bps (that's IrDA SIR mode, btw). This mode of operation plays nice with most FIR hardware (like the stuff found in laptops β they give you serial emulation) and most serial dongles (as long as you specify the proper dongle type), which honestly makes it the safe choice. safe choice queen. BUT β and this is the tea β USB dongles and a few FIR hardware pieces don't support serial emulation, so they can't be used with the irtty driver. Sorry bestie, that's just how it is π.
irattach can <em>also</em> use one of the Linux FIR drivers (USB dongle drivers included) instead of irtty. Most FIR drivers need proper configuration of module parameters β don't worry, it's documented below. FIR drivers let you use higher baud rates, generally up to 4Mbps β¨. In general though, Linux FIR support is not as stable and mature as we'd want, due to lack of time and documentation. It's giving "we tried our best", ngl.
irattach must be run as root or installed setuid root, because it requires root privileges. Full stop. If you compiled the IrDA stack as modules (which is the recommended way btw), then you'll need to edit the /etc/modules.conf file. See the Infrared-HOWTO for the deets.
π OPTIONS π
<dev>β this is the name of a TTY, an IrDA interface or an IrDA driver.irattachdecides whether to use theirttydriver or one of the FIR drivers based on this argument. Three flavours, three vibes:- TTY name β this is the serial port to be configured using the
irttydriver, such as/dev/ttyS0.irattachwill use theirttydriver, so only SIR will be available. You need to check your serial configuration or BIOS to figure out which serial port is the IrDA port that needs to be passed toirattach. - interface name β this is the device name of an IrDA interface, such as
irda0.irattachwill use one of the FIR drivers (USB dongle drivers included). The selected FIR driver must be loaded prior to the call toirattach, or the proper alias for the device name must be set in/etc/modules.conf. - module name β this is the name of an FIR driver module, such as
nsc-ircc(see the list below). All new IrDA interfaces created after loading the module will be configured, so this won't work if the module is already loaded. Heads up: this feature is still experimental π§ͺ.
- TTY name β this is the serial port to be configured using the
-sβ starts discovery of remote IrDA devices. (note that the form"-s 1"is no longer supported, bestie, we moved on)-vβ shows version information. (this happens when no option is given, too, so it's the default vibe)-hβ shows help information.-d dongleβ attaches an additional dongle driver to the IrDA port.
You need a dongle driver if you have an infrared device that connects to your computer's serial port (the normal 9-pin serial port connector). These devices are called dongles, and they can currently be used by any SIR driver (IrTTY or irport). > This option is not compatible with FIR drivers, and only works with the irtty and irport drivers. Don't try it with FIR, it's not that girl.
The currently known (serial) dongles are:
esiβ Extended Systems JetEye PC ESI-9680tekramβ Tekram IrMate IR-210B dongleactisysβ ACTiSYS IR-220L dongleactisys+β ACTiSYS IR-220L+ donglegirbilβ Greenwich GIrBIL donglelitelinkβ Parallax LiteLink dongle & Extended Systems JetEye PC ESI-9680Bairportβ N.N.old_belkinβ Belkin (old) SmartBeam dongle or any dongle only capable of 9600 baudsep7211β IR port driver for the Cirrus Logic EP7211 processor (ARM based)mcp2120β Dongles based on the MCP2120 (Microchip)act200lβ ACTiSYS Ir-200L donglesma600β Mobile Action ma600 donglestoim3232β Vishay/Temic TOIM3232 and TOIM4232 based dongles
π₯ FIR DRIVER MODULES π₯
If you're one of the lucky people who has a FIR chipset or USB dongle supported by one of the Linux-IrDA drivers, you can use irattach with the interface name of the IrDA port you want to configure. You'll need to configure /etc/conf.modules appropriately, with at least an alias of irda0 to the driver name, or just load the driver manually beforehand. Either way works, do you boo.
You don't strictly need to use irattach with FIR drivers β you could use modprobe to load the driver, ifconfig to bring up the interface, and set the various sysctl by hand. But irattach offers a convenient way to do it, so likeβ¦ why would you π.
Of course you need to know which FIR driver applies to your hardware. You may use findchip to get information about the FIR chip. If that doesn't help, the Infrared-HOWTO shows other means to retrieve this data.
Also, you often need to configure the Linux-serial driver to ignore the IrDA port, otherwise both drivers will conflict. This can usually be done with setserial /dev/ttySx uart none. (yes, remember this one, it comes back later π)
The currently known FIR drivers are:
ali-irccβ ALi FIR Controller Driver for ALi M5123 (options:io,irq,dma). This driver supports SIR, MIR and FIR (4Mbps) speeds. This chipset is used by e.g.:
The ALi M5123 FIR Controller is embedded in ALi M1543C, M1535, M1535D, M1535+, M1535D South Bridge.
irda-usbβ IrDA-USB device driver, for USB devices/dongles that comply with the official IrDA-USB class specification. Note: USB 2.0 is not yet tested. (options:qos_mtt_bitsint, description "Minimum Turn Time"). This is used, for e.g.:
ACTiSYS ACT-IR2000U
KC Technology KC-180
Extended Systems XTNDAccess ESI-9685
Note that there is another USB driver for those devices calledir-usbwhich is NOT compatible with the IrDA stack and conflicts withirda-usb. Because it always loads first, you have to removeir-usbcompletely. bye β
Devices based on the SigmaTel chip are not not compliant with the IrDA-USB class specification and therefore not supported by this driver. (yes the original says "not not", we keep it, it's iconic π)
nsc-irccβ NSC IrDA device driver (options:io,irq,dma,dongle_id,qos_mtt_bits). This chipset is used by e.g.:
IBM ThinkPad dongle_id=0x09
HP OmniBook 6000 dongle_id=0x08
sa1100_irβ Infrared driver for devices based on the StrongARM SA1100 embedded microprocessor (options:power_level,tx_lpm). This driver may support FIR on devices that can do it. This chipset is used by e.g.:
Samsung YOPY, COMPAQ iPAQ, SHARP Zaurus SL5000/5500
smc-irccβ SMC IrCC controller driver (options:ircc_dma,ircc_irq). This chipset is used by e.g.:
Fujitsu-Siemens Lifebook 635t Sony PCG-505TX
w83977af_irβ Winbond W83977AF IrDA device driver (options:io,irq,qos_mtt_bits). This chipset is used by e.g.:
Corel NetWinder
toshoboeβ Toshiba OBOE IrDA device driver, supports Toshiba Type-O IR chipset. (options:max_baud). This chipset is used by e.g.:
Toshiba Libretto 100CT., and many more old Toshiba laptops.
donauboeβ is a new version oftoshoboeand has better FIR support and compability with the Donauoboe chip http://libxg.free.fr/lib-irda.html (options:..). This chipset is used by e.g.:
Toshiba Libretto 100CT., Tecra 8100, Portege 7020 and many more Toshiba laptops.
vlsi_irβ VLSI 82C147 SIR/MIR/FIR device driver. This chipset is used by e.g.:
HP Omnibook 800
(options: ..).
clksrcint, description "clock input source selection"ringsizeint array (min = 1, max = 2), description "tx, rx ring descriptor size"sirpulseint, description "sir pulse width tuning"mtt_bitsint, description "IrLAP bitfield representing min-turn-time"
π¦ EXAMPLES π¦
Attach the IrDA stack to the second serial port (integrated IrDA port using serial emulation) and start discovery:
irattach /dev/ttyS1 -s
Attach the IrDA stack to the first serial port where you have an external ACTiSYS serial dongle and start discovery:
irattach /dev/ttyS0 -d actisys+ -s
Attach the IrDA stack to the first IrDA-USB dongle and start discovery:
modprobe irda-usb ; irattach irda0 -s
Attach the IrDA stack to the NSC FIR (4Mbps) device driver on a Thinkpad laptop:
modprobe nsc-ircc dongle_id=0x9 ; irattach irda0 -s.
Attach the IrDA stack to the NSC FIR (4Mbps) device driver on a Thinkpad laptop:
irattach irda0 -s.
This assume that you have added the following entries to /etc/conf.modules:
options nsc-ircc dongle_id=0x09
alias irda0 nsc-ircc
π CAVEATS π
The following hints are a very short introduction into the configuration of Linux/IrDA. If this doesn't help, read the Linux/IrDA-Tutorial and/or the Infrared-HOWTO. Before configuring Linux/IrDA, make sure whether you want to configure SIR or FIR. It's recommended to try SIR first, unless your device is not compatible with SIR (for example USB dongles). SIR first, always, it's the safe queen π.
To get the SIR "serial" device, have a look into the BIOS. Then run dmesg | grep tty to get a survey of tty devices supported by your machine. Now try to choose the one which is probably the IrDA device, and use irattach /dev/ttySx -s.
If you don't succeed with SIR (which seems a rare case) you may try FIR. First look up the BIOS. Then run findchip to get information about the IrDA controller chip. Use setserial /dev/ttySx uart none to avoid conflicts with the serial driver. > Note: don't use setserial if you configure SIR. Now you may use irattach.
Finally irdadump should show at least your computer itself. If it doesn't, start at the beginning. no skipping, bestie.
This man page deals only with the low level of the IrDA stack (IrDA ports and IrDA drivers). After this step is done, you usually need to set up your favorite application to access the high level IrDA stack (via IrCOMM, IrLPT, IrNET, IrLAN or IrSOCK), which is documented elsewhere.
This man page doesn't document the usage of the irport driver. The irport driver supports the same hardware as the irtty driver, but is configured like a FIR driver. (so like, same hardware, different setup energy β¨)
π DIAGNOSTICS π
This section currently contains the raw error messages from source code only. (fr fr, no extra context, just the receipts)
"ioctl(TIOCGETD): %m""irattach: tty: set_disc(%d): %s""tcsetattr: %m""Failed to open %s: %m""Couldn't get device fd flags: %m""Couldn't set device to non-blocking mode: %m"
π BUGS π
N.N.
π SEE ALSO π
ok so if you wanna keep the rabbit hole going (and bestie, you know you do), go peek at these:
and like, the actual sources, the lore, the β¨canonβ¨:
- Linux/IrDA Project β http://irda.sourceforge.net
- Linux/IrDA-Tutorial β http://www.hpl.hp.com/personal/Jean_Tourrilhes/IrDA/index.html
- Infrared-HOWTO β http://tuxmobil.org/howtos.html
- Infrared-Hardware-Survey β http://tuxmobil.org/ir_misc.html
obsessed with a project that just links you to four other websites tbh. very "the real manual was the friends we made along the way" energy. πΈ
π«Ά AUTHOR π«Ά
This manual page is written by Werner Heuser <wehe@tuxmobil.org>. It's based on the READMEs from irda-utils by the Linux/IrDA Project and the Linux/IrDA-Tutorial. Then Jean Tourrilhes <jt@hpl.hp.com> came through and updated and modified it. β¨
like okayyy two-author collab, we love a shared credit moment π
Β©οΈ COPYRIGHT Β©οΈ
Copyright (c) 2001 Werner Heuser
Copyright (c) 2002 Jean Tourrilhes
Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License (GFDL), Version 1.1 or any later version published by the Free Software Foundation; with no Invariant Sections, no Front-Cover Texts and no Back-Cover Texts.
no invariant sections, no front-cover texts, no back-cover texts. she said keep it clean bestie π
and that's the whole page, you made it, congrats, main character behaviour fr fr π
this absolute icon of a manpage is from IRATTACH(8), dated 03 July 2006 β yes bestie, 2006, it's giving vintage, it's giving heritage, it's giving "still works though". go touch some infrared. π¦
π¦ where this page comes from
- fedora 43: irda-utils 0.9.18-52.fc43 Β· GPL-2.0-or-later
- fedora 44: irda-utils 0.9.18-53.fc44 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms