Author Topic: lirc and setserial  (Read 4268 times)

archived

  • Hello, I'm new here
  • Posts: 0
    • View Profile
lirc and setserial
« on: October 09, 2006, 03:58:17 am »
On a particular media directer I hav constructed the basic serial port infrared receiver and added a couple of remote controls. After noticing errors on startup of the lirc device and checking the log it was having problems accessing the serial port.

A bit of googling reveals a solution. I needed to free the serial port before modprobing the lirc_serial driver. After that the lirc device fixes itself and the remotes work as expected.

The command to free the serial port is;
setserial /dev/ttyS0 uart none

At the moment I have to go to a console window and execute this command after the machine boots. Obviously this is a pain when the machine gets rebooted.

I have tried various rc scripts and creating serial.conf files to get this to run at startup. All with no success.

Has anyone encountered the same problem and solved it so that it works after a reboot?

archived

  • Hello, I'm new here
  • Posts: 0
    • View Profile
Re: lirc and setserial
« Reply #1 on: October 09, 2006, 10:28:10 am »
Quote from: "darrenmason"
On a particular media directer I hav constructed the basic serial port infrared receiver and added a couple of remote controls. After noticing errors on startup of the lirc device and checking the log it was having problems accessing the serial port.

A bit of googling reveals a solution. I needed to free the serial port before modprobing the lirc_serial driver. After that the lirc device fixes itself and the remotes work as expected.

The command to free the serial port is;
setserial /dev/ttyS0 uart none

At the moment I have to go to a console window and execute this command after the machine boots. Obviously this is a pain when the machine gets rebooted.

I have tried various rc scripts and creating serial.conf files to get this to run at startup. All with no success.

Has anyone encountered the same problem and solved it so that it works after a reboot?

Hi,

same problem here - I also need to run few scripts to setup my ADSL connection. I've described it here

http://plutohome.com/wiki/index.php/How_to_setup_ADSL_access%3F

http://plutohome.com/wiki/index.php/ASUS_DIGIMatrix#Power_ON.2FOFF_from_remote_control_.21.21.21

but it would be nice to have some empty, user editable script that runs on boot, poweroff or restart, so user can put in commands he needs (it would be best that this would be setting over web-admin that would stay permanently in database)...

Regards,

Rob.

archived

  • Hello, I'm new here
  • Posts: 0
    • View Profile
lirc and setserial
« Reply #2 on: October 10, 2006, 02:32:33 pm »
Hi,

Just to update. The problem is now solved.

It was done by creating a file in the /etc/modprobe.d directory which allows modprobe configuration for each module.

The files contents were
Code: [Select]
options lirc_serial irq=4 io=0x3f8
install lirc_serial /bin/setserial /dev/ttyS0 uart none ;\
    /sbin/modprobe --ignore-install lirc_serial


Hope this helps someone else out.

Regards
Darren