View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 21 posts ] 
Go to page 1, 2  Next

Print view Previous topic   Next topic  
Author Message
Search for:
PostPosted: Sat Jan 27, 2007 12:54 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
I got this remote with the DVICO FusionHDTV5 Lite card for Christmas. The problem is occasionally it will repeat the last command it was sent when it receives any other IR signal. For example, if I press the Play button on the DVICO remote I see the correct key code in irw then I can use any other remote to send and IR signal and irw will see it as the Play key code again. Usually it will only misread the IR signal once but sometimes it does it multiple times. This is an intermittent problem and I can discern no particular pattern of when it will or won't misinterpret the IR signal. At first I thought that it might be that the particular codes might be very close but that doesn't seem to be it as when it does repeat the other IR signals have been from 3 different remotes for different components and all different brands. It seems like LIRC may be caching the last command and when it senses any IR it repeats it. I don't know much about LIRC but it this possible? Is it a hardware problem? I have used this remote in both R5D1 & R5E50 and have seen the same problem.

Any suggestions?

Thanks,
Britney


Top
 Profile  
 
 Post subject:
PostPosted: Sat Jan 27, 2007 2:45 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I have the same problem. If anyone knows what is going on, it would be nice to know.

I have two of those remotes and they both do it. One is even occasionally triggered by bright flashes on the TV (when the room is dark). It once got into an endless loop because it triggered on a bright flash and the last button press was skip-back, so it just kept repeating the last 5 seconds, getting to the bright flash again and then skipping back and repeating it again.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 02, 2007 2:52 pm 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Greg, give this a try. In your lircd.conf change the aeps entry to 50. I did this about a day ago have experienced only 1 instance of it repeating. That is an improvement for me. I am going to try and lower it further and see if I get more improvement. I would be curious if you see any improvement.

Have you been able to use irrecord with this remote? Everytime I try it gives me an error and suggests killing lirc which I have already done. I was going to try and record a new .conf file but I can't get irrecord to work.

Britney


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 02, 2007 4:02 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I suspect that irrecord doesnt make sense with this remote. I think the dongle only recognises the codes from the dvico remote.

I'm away from home on a work trip at the moment. When I return I will give the aeps thing a go.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jun 25, 2007 7:43 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I finally got around to trying to make my remote more reliable and I remembered this post.

After doing some testing I don't believe that eps/aeps has anything to do with the button repeating issue. I would have been surprised if it did because those parameters relate to the way lirc decodes the IR pulse train to determine which buttons have been pressed. With a DVICO remote, this decoding is done by hardware in the USB dongle. All lirc needs to do is to read and interpret the USB serial data that the dongle sends.

The button repeating issue seems to be related to when the dongle receives an IR pulse that it can't recognise. This can be because you didn't point the remote properly. It can also occur when the donglf falsely triggers on a command from another remote.

Here's how I tested it:
Press a button mapped to a key that toggles something (like P for play/pause) so that you can easily see if it gets a spurious button repeat.
Get another remote for a different device and press a button on it very briefly (so that it only sends a single code) when not pointed directly at the DVICO receiver. Repeat a number of times until the DVICO registers a spurious button press.

Using that procedure, I could fairly reliably repeat the problem, so I was in a position to determine if any change had any effect. I couldn't notice any difference to the regularity of spurious button presses by changing eps or aeps.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jun 25, 2007 8:29 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
To follow this up, It looks like the problem is in the dongle itself. If you run the following command, it will print the data sent by the dongle, one button per line:
Code:
cat /dev/usb/hiddev0 | od -x -w16 -v

I get something like this when I press and briefly hold the buttons 1, 2 then 3:
Quote:
0000000 0001 0009 0000 0000 0046 0001 11f9 0000
0000020 0001 0009 0000 0000 0046 0001 91f9 0000
0000040 0001 0009 0000 0000 0046 0001 91f9 0000
0000060 0001 0009 0000 0000 0046 0001 91f9 0000
0000100 0001 0009 0000 0000 0046 0001 91f9 0000
0000120 0001 0009 0000 0000 0046 0001 91f9 0000
0000140 0001 0009 0000 0000 0046 0001 12f9 0000
0000160 0001 0009 0000 0000 0046 0001 92f9 0000
0000200 0001 0009 0000 0000 0046 0001 92f9 0000
0000220 0001 0009 0000 0000 0046 0001 92f9 0000
0000240 0001 0009 0000 0000 0046 0001 92f9 0000
0000260 0001 0009 0000 0000 0046 0001 92f9 0000
0000300 0001 0009 0000 0000 0046 0001 92f9 0000
0000320 0001 0009 0000 0000 0046 0001 13f9 0000
0000340 0001 0009 0000 0000 0046 0001 93f9 0000
0000360 0001 0009 0000 0000 0046 0001 93f9 0000
0000400 0001 0009 0000 0000 0046 0001 93f9 0000
0000420 0001 0009 0000 0000 0046 0001 93f9 0000
0000440 0001 0009 0000 0000 0046 0001 93f9 0000
Notice that the column with the bolded entries shows the buttons being pressed and the rest of the entries are button repeats that occur when the button is held down.
The thing is, when I grab the remote for my video, point it somewhere that is not directly at the dvico receiver dongle and press buttons briefly, I get the following output:
Quote:
0000460 0001 0009 0001 0000 0046 0001 93f9 0000
0000500 0001 0009 0001 0000 0046 0001 93f9 0000
0000520 0001 0009 0001 0000 0046 0001 93f9 0000
0000540 0001 0009 0001 0000 0046 0001 93f9 0000
This indicates that the dongle is sending a code to say that it is getting a repeat of the last DVICO button pressed. So the problem clearly lies with the dongle, but perhaps the lirc code could be enhanced to ignore any "repeats" if they occur too long after the first button was pressed.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 26, 2007 9:53 am 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Greg, great detective work! After about a week I noticed that I wasn't getting any less of the repeating after changing the eps or aeps either.

So do you know how to modify the lirc code to ignore "repeats"?

Britney


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 26, 2007 4:20 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
The more annoying thing is that if you press a button then you cover the transmitter on the remote with your hand and press and hold another button, then take your hand away whilst still holding the button, the dongle sends a code indicating that the first button is repeating. This means that if the receiver happens to miss the first code transmission and only sees the repeats, there is no way to know what button is being pressed. Unless this is a bug in the hiddev driver in the kernel, there's nothing that can be done about it (other than totally ignoring the second button press which I guess would be better than nothing.)

I am considering building a serial receiver to use instead of the DVICO dongle.

I have asked about this problem on the lirc mailing list.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 26, 2007 8:08 pm 
Offline
Joined: Mon Feb 06, 2006 5:11 pm
Posts: 353
Location: Brisbane, Australia
Hi All,

I had this problem as well. I found the problem was even worse when i took the PCB out of the housing. To fix this i wrapped the IR sensor (three legged greenish blackish thing) in a small piece of ISO200 negative film. This slightly attenuates the IR signal (and stops all other light) that the IR receiver picks up. This improved things significantly.

NB: I initially tried ISO800 but this attenuated the signal too much and reduced my IR range to about 3 meters.

BigB.

PS. Prior to fixing this my TV would trigger the IR when it transitioned from a black picture to a white picture, talk about difficult to troubleshoot.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jun 26, 2007 8:55 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
BigB, can you try the test I outlined in my previous post and report back whether it is a problem for you too. I would be surprised if it wasn't, but I've been surprised before.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 27, 2007 5:23 am 
Offline
Joined: Mon Feb 06, 2006 5:11 pm
Posts: 353
Location: Brisbane, Australia
Hi Greg,

I conducted your test (forging repeats of button A by using button B) and I do get the same results as you describe. The modification i detailed above has effectively removed the trouble associated with this remote, namely interference from foreign remotes and spurious light signals (strobe effects from TVs).

BigB.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 03, 2007 6:09 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I have worked out how to patch lirc to ignore the spurious repeats from the DVICO remote.

You first need to fetch the lirc source code:
Code:
cd /usr/src
wget http://www.blushingpenguin.com/mark/lmilk/lirc-0.8.2-CVS-pvr150.tar.bz2
tar xvfj lirc-0.8.2-CVS-pvr150.tar.bz2

Then apply this patch:
Code:
diff -ru lirc-0.8.2-CVS-pvr150/daemons/hw_hiddev.c lirc-0.8.2-CVS-pvr150-new/daemons/hw_hiddev.c
--- lirc-0.8.2-CVS-pvr150/daemons/hw_hiddev.c   2007-03-18 20:38:54.000000000 +1030
+++ lirc-0.8.2-CVS-pvr150-new/daemons/hw_hiddev.c       2007-07-03 21:29:07.000000000 +0930
@@ -172,6 +172,7 @@
        /* Remotec Mediamaster specific */
        static int wheel_count = 0;
        static int x_movement = 0;
+       static struct timeval time_of_last_code;
        int y_movement=0;
        int x_direction=0;
        int y_direction=0;
@@ -198,8 +199,30 @@
         *
         */
        if (event.hid == 0x10046) {
+               struct timeval now;
                repeat_flag = (main_code & dvico_repeat_mask);
                main_code = (main_code & ~dvico_repeat_mask);
+
+               gettimeofday (&now, NULL);
+
+               /* The hardware dongle for the dvico remote sends spurious */
+               /* repeats of the last code received it it gets a false    */
+               /* trigger from some other IR source, or if it misses      */
+               /* receiving the first code of a new button press. To      */
+               /* minimise the impact of this hardware bug, ignore any    */
+               /* repeats that occur more than half a second after the    */
+               /* previous valid code because it is likely that they are  */
+               /* spurious.                                               */
+
+               if (repeat_flag)
+               {
+                 if (((now.tv_sec - time_of_last_code.tv_sec) +
+                      (1.0e-6 * (now.tv_usec - time_of_last_code.tv_usec))) >
+                     0.5)
+                   return NULL;
+               }
+
+               time_of_last_code = now;
                return decode_all(remotes);
 #if 0
                /* the following code could be used to recreate the
by making a file containing the code above and doing the following:
Code:
cd lirc-0.8.2-CVS-pvr150
patch -p1 < the_patch_file

Then, configure make and install lirc
Code:
./configure --with-driver=dvico --prefix=/usr --with-transmitter
make
make install

Then reboot so that everything starts properly and you should have a spurious immune lirc.


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 03, 2007 10:43 am 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Greg,

I will try this in a few minutes. Thanks for looking into it.

Have you submitted it back for inclusion in the next version of LIRC or is this something we will have to do with every upgrade?

Britney


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 03, 2007 11:06 am 
Offline
Joined: Fri Jul 21, 2006 11:12 pm
Posts: 1194
Location: SC
Greg,

When I did:
Code:
patch -p1 < the_patch_file
I got:
Code:
patch: **** strip count l is not a number
Is that a problem?

Thanks,
Britney


Top
 Profile  
 
 Post subject:
PostPosted: Tue Jul 03, 2007 9:22 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
Did you do -p1 or -pl? it should be 1 the numeral not l the letter.

I am discussing the change on the lirc mailing list. Hopefully they will accept a patch. If not, I may be able to organise something with cesman.


Top
 Profile  
 

Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 21 posts ] 
Go to page 1, 2  Next



All times are UTC - 6 hours




Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Jump to:  
cron
Powered by phpBB® Forum Software © phpBB Group

Theme Created By ceyhansuyu