Trying to get IrDA working


Forum: Other Help Topics
Topic: Trying to get IrDA working
started by: Juanito

Posted by Juanito on Dec. 08 2006,12:37
I've been trying to get IrDA working under DSL - I've managed to make things work on the same system under DSL-N - but have hit a problem.

Things go well to start with:

# apt-get install setserial
# setserial /dev/ttyS1 uart none
# modprobe smc-ircc ircc_irq=3 ircc_dma=3 ircc_sir=0x2f8 ircc_fir=0x280
# dmesg
...
Overriding FIR address 0x0280
Overriding SIR address 0x02f8
SMC IrDA Controller found
IrCC version 2.0, firport 0x280, sirport 0x2f8 dma=3, irq=3
IrDA: Registered device irda0
# apt-get install irda-utils

Then, under DSL-N (and according to Google under 2.4.x was well) the next command is:

# irattach irda0 -s

However, DSL really, really doesn't like this and hangs with the caps lock/scroll lock lights flashing - in all time I've been blundering around in DSL, I never managed to do this before  :O

The /etc/modutils/irda-utils file contains the line "alias irda0 smc-ircc" so I tried the following:

# mknod /dev/irda0 c 160 0 [from Google]
# irattach irda0 -s

Which also results in DSL hanging

"ls /dev/ir* turns up ircomm0, ircomm1,  irlpt0, irlpt1 & irnet and searching on irda0 using gtkfind from / and all subdirectories finds nothing.

Does anyone have an idea what the problem might be?

Posted by ^thehatsrule^ on Dec. 08 2006,13:45
Quote
However, DSL really, really doesn't like this and hangs with the caps lock/scroll lock lights flashing - in all time I've been blundering around in DSL, I never managed to do this before  :O
You have encountered your first kernel panic!

Though I have no experience with IrDA, perhaps you should compile these tools just to be thorough (since you're probably familiar with it now :p)

Posted by Juanito on Dec. 08 2006,15:01
"...perhaps you should compile these tools just to be thorough"

What tools do you mean?

Posted by ^thehatsrule^ on Dec. 08 2006,15:10
Instead of using apt-get that is...
If no other help/info else shows up I usually end up trying everything like that.

Posted by Juanito on Nov. 25 2007,17:44
So, after a brief pause, I had another look at this - it seems it's possible to start an irda device without irda-utils:
Code Sample
$ sudo ln -s /dev/ttyS1 /dev/irda0
$ sudo insmod irda
$ sudo ifconfig irda0 up
$ ifconfig irda0
irda0     Link encap:IrLAP  HWaddr a7:c5:1c:32  
         UP RUNNING NOARP  MTU:2048  Metric:1
         RX packets:0 errors:0 dropped:0 overruns:0 frame:0
         TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
         collisions:0 txqueuelen:8
         RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
# echo -n 1 >/proc/sys/net/irda/discovery [note terminal as root]
$ cat /proc/net/irda/discovery
IrLMP: Discovery log:

nickname: P900, hint: 0x9325, saddr: 0xa7c51c32, daddr: 0x1770890c
i.e. dsl can see another irda device.

If I disable the serial port emulation and try to use the ir port directly:
Code Sample
$ sudo setserial /dev/ttyS1 UART none
$ sudo rmmod serial
$ sudo mknod -m 664 /dev/irda0 c 160 0
$ sudo insmod irda
$ sudo insmod irport io=0x2f8 irq=3
$ dmesg | grep irda0
IrDA: Registered device irda0
$ sudo ifconfig irda0 up
$ ifconfig irda0
irda0     Link encap:IrLAP  HWaddr bb:59:77:82  
         UP RUNNING NOARP  MTU:2048  Metric:1
         RX packets:0 errors:0 dropped:0 overruns:0 frame:0
         TX packets:1 errors:0 dropped:0 overruns:0 carrier:0
         collisions:0 txqueuelen:8
         RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
         Interrupt:3 Base address:0x2f8
# sudo echo -n 1 > /proc/sys/net/irda/discovery
- dsl hangs

Note that this also happens if I replace "$ sudo mknod -m 664 /dev/irda0 c 160 0"with "$ sudo ln -s /dev/ircomm0 /dev/irda0"

Does anybody have an idea what the problem might be?

Edit: I should maybe add that the reason behind this is that obexftp will not work when the ir port emulates a serial port so I would like to get the full ir port functionality and speed (4Mbits vs 115,000).

Powered by Ikonboard 3.1.2a
Ikonboard © 2001 Jarvis Entertainment Group, Inc.