Problem accessing IR port - Ubuntu 8.10

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • wizche
    New Member
    • Jul 2008
    • 6

    Problem accessing IR port - Ubuntu 8.10

    Hi,

    I'm currently trying to develop a IR Remote (TV consumer) listener in C under Linux.

    First of all I tried with an old notebook with an integrated IR peripheral (FIR)under Debian (kernel 2.6). All seems to work fine, I can also access directly with
    #cat /dev/ttyS1
    And my listener (written in C) work pretty fine.

    Problems came up with a newer notebook with Ubuntu 8.10.
    I set FIR in Bios like the older notebook. But trying to access with cat /dev/ttyS1 raise this error: read: Input/output error
    I took immediatly that something lock this device but, how can I see which process lock this resource?

    Running my program (a simple non canonical read from the /dev/ttyS1) give me NO data... Seems to be that nothing is coming through the IR port (despite I was trying clicking about an hundred buttons on 3 differents remote controllers :) ).
    I tried to unload all modules of irda and I disable UART setting with setserial, but nothing change.

    I'm pretty sure that problem came because of "something" who lock this device, but I have no idea how to patch it.

    Any suggestions?

    Thanks a lot

    Sergio
  • Nepomuk
    Recognized Expert Specialist
    • Aug 2007
    • 3111

    #2
    First thing I'd check is: Is /dev/ttyS1 really the correct device? Maybe this Laptop is wired slightly different than the Debian machine. I just checked on my machine (currently Xubuntu 8.04, going to install 8.10 soon) and I have ttyS0 - ttyS3. I don't know which of them is my IR device, but one of them will be. (I'm sure you can check that somehow, but don't know how to right now.)

    Greetings,
    Nepomuk

    Comment

    • wizche
      New Member
      • Jul 2008
      • 6

      #3
      Hi nepomoku!
      Thanks for reply...

      I'm sure that /dev/ttyS1 is the correct device...
      I checked the address and IRQ in the BIOS and is the exactly the same of the result from setserial /dev/ttyS1 and from dmesg ¦ grep tty

      You've tried to make a simple cat to your ir device? It works?

      Comment

      Working...