Mailing List archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[vdr] [ANNOUNCE] vdr-serial-0.0.0 and help request



Hi guys,

I think my VDR is perfect if it is usable without a remote. So I want to
implement frontpanel keys. I have no gameport so I decided to use the
secound serial port.

My aim is to create a plugin which enables me to poll buttons connected
to the serial line. Additional it will be possible to use two (perhaps
three) leds to use it as informations on the frontpanel (recording
active fe).

I am not a skilled programmer, beside some modifications of some
existing plugins. So please allow me some "silly" questions. I found
some neccessary peaces of software to combine them to get the
functionality I need. GPL is great ;-)).

I modified the source of sled (led and pushbutton controller) to get it
all working. The secound step was a bit mor difficult, because I have no
knowledge about the used classes within VDR. I had a look at the
joystick plugin and modified it to access the serial line.

What I already did:
You find a tarball at
http://www.vdr-portal.de/board/thread.php?threadid=3804&sid=

Within this tarball there is a /vdr-serial-0.0.0/tools directory. After
"make all" you find there a binary which polls the serial line and
prints which line (CTS, DSR, RNG or CAR) is high. So you can already use
15 buttons (2^4-1).

The secound step is to integrate this in a plugin enviroment. I had a
look at the joystick plugin which does extremly the same, but with the
gameport as input. Within the tarball there is a /vdr-serial/ directory.
Type "make libvdr-serial.so" and the plugin is build, BUT!

I tried to understand which classes the joystick plugin uses and tried a
copy&paste. Of course it produces no keypresses. So something with the
access of the /dev/ttyS0 mus be wrong.

My questions:
- must I use this classes (cFile::FileReady and safe_read) 
  to read from /dev/ttyS0, or is it possible to read as 
  in the serial.c from the tools directory?
- if so, how must I implement this exactly, or 
  better, where can I get the neccessary informations 
  about the classes? Within the VDR sources? Or are 
  there better places?
- if I am able to implement it like in tools/serial.c, 
  what are the drawbacks?

I am looking forward to your answers. Hopefully I will be able to
implement this within the next weeks.

TNX in advance.
--
Ralf.Klueber@Vodafone.com           Vodafone D2 GmbH
Group Leader 'Radio Network Planning Tools and Methods'
Radio Network Planning Department   phone : ++49 211 533 3422
Am Seestern 5, 40543 Duesseldorf    fax   : ++49 211 533 2124
 



-- 
Info:
To unsubscribe send a mail to ecartis@linuxtv.org with "unsubscribe vdr" as subject.



Home | Main Index | Thread Index