Author Topic: Problem installing a serial remote control  (Read 4036 times)

rafik24

  • Guru
  • ****
  • Posts: 158
    • View Profile
Problem installing a serial remote control
« on: October 08, 2007, 09:13:59 pm »

 Hi All,

 I have a Technisat Skystar 2 dvb-s card that comes with a serial infrared remote control that i tried installing in lmce.

 I had few issues to get it starting with lirc but it finnally works using irw.

 The remaining issue is that i can't get lmce to recognize the remote so when LIRC_DCE start i get the message "There are no remote controls -- LIRC will be dormant".

 I did the following config in lmce:

- Went to device templates -> added a remote control template for the manufacturer technisat called lircd.conf.technisat -> added a device data Configuration string in wich i did put the lircd.conf content that works with lirc.

- In MD menu added default infrared receiver (lirc works with default as driver),
  also added the lircd.conf.technisat remote

 When i start DCE_LIRC -d 89 (which is the device of the default infrared receiver)
 i get the message "There are no remote bla bla bla.

 So far i managed to get across many issues here and there but this one i can't come across.

 I would really apreciate any help and promise to release a howto on the wiki for serial and usb remotes if i get it to work.

 Thanks to all the contributors of this beautiful project.

Rafik Boulellou


darrenmason

  • Addicted
  • *
  • Posts: 529
    • View Profile
Re: Problem installing a serial remote control
« Reply #1 on: October 09, 2007, 07:47:04 am »
What you have done sounds about right, the only thing that stood out to me was that you mentioned "you" started LIRC_DCE. This sounds like you are explicitly starting the process rather than the Launch_Manager starting it. Is this correct? If Launch_manager is not at least trying to start it then you must still have an issue with your config.
Either way, go into web admin and look at your device tree. Check that the remote control device that you added (not the receiver) has a device parameter with exactly what you put in the template. If not add it in.

The code for LIRC_DCE gets teh config of all devices conforming to a certain device template and concatenates them together and uses as a config.
It also writes this as a file in /etc (from memory - not in front of it at the moment) so check what it has written here.

Hope some of this helps
Darren

rafik24

  • Guru
  • ****
  • Posts: 158
    • View Profile
Re: Problem installing a serial remote control
« Reply #2 on: October 11, 2007, 04:56:13 am »

  Hi Darren,

 In did you spoted right, i had to add the serial device in the remote control template recompile lirc sources
 and such of a sudden LIRC_DCE started behaving so i could attach to it with irw.

 Thank a lot for your input, i would never have tought the lirc input device would be there.

  As i promised in my first post a wrote a quick howto(ish) install a serial device in lmce.
 Dear All,

 I spent some time figuring out how infrared serial remote work with linuxmce (pluto),

 So i told my self this might help somebody else to get his remote working.

 Please let me know if it is not clear enough so i might add some details

##################################
#    Install a serial infrared remote control in linuxmce
  #
##################################

  ( Tested with a Technissat serial infrared remote TTS35AI )



   In order to setup a serial infrared remote control you will need to do the following:



1)   Linuxmce configuration.



   Go to linuxmce admin website ( http://dcerouter )



   Go to Advanced -> Configuration -> Device Templates.

   

   Choose Manufacturer Pluto, "Device Category Lirc Remote Controls < Remote Controls < Peripherals"



   Check if your manufacturer is listed, Otherwise just press "Add a manufacturer" and put the name of

   your remote.



   Press the reload button of your browser, select the new manufacturer you just created,



   select Device Category "Lirc Remote Controls < Remote Controls < Peripherals" press Add Device Template.



   Add the name of the needed configuration ( i called it lircd.conf.twinhan ).



   Now go to the "Device Data" section and add a Device of type string.



   In the the Comments field put remote device, in Default value put /dev/ttyS0 (! ttyS0 is the first serial port found on

   your mother board however in your case you it might be different /dev/ttyS1 ttyS2 or else (can't cover it all !).



   Know go to lirc website in order to get the keys configuration for your remote most of them are available at



   http://lirc.sourceforge.net/remotes/ (choose your manufacturer or model)



   Still in "Device Data"  add a new parameter Configuration pout any comment in "Comments"  know Insert the content of the

   lircd.conf file in Default Value.



   Press Save !



   Go to Wizard -> Devices -> Media Directors, scroll to the md you want to a the remote to,



   In infrared receivers select "default" then press "Add Remote" and select the remote control we previously created.



   We are know done with linuxmce configuration, Linuxmce will install the sofware on the MD and will ask you to reload the

   router.



2) Lirc config



   create a file /etc/lircd/hardware.conf and insert:



   ############################################################################

   # /etc/lirc/hardware.conf

   #

   # Arguments which will be used when launching lircd

   LIRCD_ARGS=""



   #Don't start lircmd even if there seems to be a good config file

   #START_LIRCMD=false



   #Try to load appropriate kernel modules

   LOAD_MODULES=true



   # Run "lircd --driver=help" for a list of supported drivers.

   DRIVER="default"

   # If DEVICE is set to /dev/lirc and devfs is in use /dev/lirc/0 will be

   # automatically used instead

   DEVICE="/dev/ttyS0"

   MODULES="lirc_serial"



   # Default configuration files for your hardware if any

   LIRCD_CONF="/etc/lirc/lircd.conf"

   LIRCMD_CONF=""

   #

   # END/etc/lirc/hardware.conf

   #############################################################################

   



   Copy the previously downloaded lircd.conf to /etc/lirc/



   sudo chmod 755 /etc/lirc/lircd.conf



   sudo apt-get install setserial



   sudo echo "/dev/ttyS0 uart none" > /etc/serial.conf



   sudo /etc/init.d/setserial restart



   sudo rmmod lirc_serial



   sudo rmmod lirc_dev



   sudo modprobe lirc_serial



   sudo /etc/init.d/lirc start



   At this point we can determine if something is happening using irw



   sudo irw



   Press your remote butons,



   If nothing happens and irw quits, check you have the right serial /dev/ttySX and



   If this does not work then we need to build lirc from source (which is my case).

   

   



3) Lirc install from source



  sudo dpkg build-dep lirc



  cd /usr/src



  sudo wget http://prdownloads.sourceforge.net/lirc/lirc-0.8.2.tar.bz2



  sudo tar -jxvf lirc-0.8.2.tar.bz2



  cd  lirc-0.8.2



  ./configure



  In 1 Driver Configuration Choose 1 Home-brew (16x50 UART compatible serial Port) -> choose your comport ->

 

  uncheck all "Driver specific Options" then choose 3 save configuration and exit.



  sudo make



  sudo make install



  sudo rmmod lirc_serial

  sudo rmmod lirc_dev



  sudo depmod -a



  sudo setserial /dev/ttyS0 uart none      ( in your case /dev/ttySX )



  modprobe lirc_serial



  know

 

  sudo /usr/local/sbin/lircd -H default -d /dev/ttyS0 /etc/lirc/lircd.conf



  sudo /usr/local/bin/irw



  Know you should be able to see the keys you press on your remote.



  Until this work linuxmce will not be able to use your remote



  I tried to cover most of the installation steps however lirc has many configurations



  and many devices have been used with it so.





   if irw works then your remote sould know be working in linux mce,



   if not  check the device number of the infrared receiver and use the command





   /usr/pluto/bin/LIRC_DCE -d  ENTER_YOUR_DEVICE_NUMBER
  ( In order to troubleshoot
 )


   

   I Hope This Help,





   Rafik Boulellou 


 


rafik24

  • Guru
  • ****
  • Posts: 158
    • View Profile
[SOLVED] Re: Problem installing a serial remote control
« Reply #3 on: October 11, 2007, 04:57:51 am »
please check the previous message in the post for solution