View unanswered posts    View active topics

All times are UTC - 6 hours





Post new topic Reply to topic  [ 28 posts ] 
Go to page Previous  1, 2

Print view Previous topic   Next topic  
Author Message
Search for:
 Post subject:
PostPosted: Tue Nov 18, 2008 3:02 pm 
Offline
Joined: Sun May 02, 2004 7:04 pm
Posts: 53
I don't know if you're still working on this, but I have been having a similar problem for a long time and have finally gotten fed up enough to fix it! My problem is that when pressing a given remote button, it sometimes "bounces" - i.e. it will send more than one command code for a single button press. This results in mythtv occasionally skipping through various screens, playing programs, etc. when i don't want it to.

I think your remote might be doing the same thing, only one command code is sent when you press down on the button, and another is sent when you relase it.

The real problem here is that for some reason lirc is not interpretting the 2nd button press as a repeat, but a new event. The repeat and delay settings in the lircrc file only work when the button press is regarded by lirc as a repeat. This is reflected by the fact that your irw output shows '00' in the 2nd column every button press.
Code:
000000000001006c 00 down /etc/lirc/lircd.conf
000000000001006c 00 down /etc/lirc/lircd.conf
000000000001006c 00 down /etc/lirc/lircd.conf
000000000001006c 00 down /etc/lirc/lircd.conf
0000000000010067 00 up /etc/lirc/lircd.conf
0000000000010067 00 up /etc/lirc/lircd.conf
0000000000010067 00 up /etc/lirc/lircd.conf
0000000000010067 00 up /etc/lirc/lircd.conf

If it were regarding subsequent button presses as repeats, that number would be incrementing...
Code:
000000000001006c 00 down /etc/lirc/lircd.conf
000000000001006c 01 down /etc/lirc/lircd.conf
000000000001006c 02 down /etc/lirc/lircd.conf
000000000001006c 03 down /etc/lirc/lircd.conf
0000000000010067 00 up /etc/lirc/lircd.conf
0000000000010067 01 up /etc/lirc/lircd.conf
0000000000010067 02 up /etc/lirc/lircd.conf
0000000000010067 03 up /etc/lirc/lircd.conf

or something like that. FYI this is just my working theory right now, not a known fact.

So if this is the case then I feel like there should be a parameter somewhere in lircd.conf that will fix this. Unfortunately I haven't found it yet, and I've experimneted with gap, repeat, and min_repeat.

Anyone on the forum know lircd.conf files well enough to help?? I've checked out the lirc documentation but it's a little technical for me:
http://winlirc.sourceforge.net/technicaldetails.html

This is something that's gotta be covered in LIRC already, no?
Thanks, --scott


Top
 Profile  
 
 Post subject:
PostPosted: Fri Nov 21, 2008 6:21 pm 
Offline
Joined: Tue Mar 22, 2005 9:18 pm
Posts: 1422
Location: Brisbane, Queensland, Australia
That is exactly what is happening in my case. Whilst I have not had time to work on this any more over the last month or so (much to my Father in Law's dismay) it is still to be addressed. To alleviate our problem have you looked at slowtolearn's post that I have quoted here:

slowtolearn wrote:
Although I don't see that it deals with the Up/Down keys specifically, I wonder if this code is in your version of lirc? (Not running a 5.5 box ATM so I can't check)

_________________
Girkers


Top
 Profile  
 
 Post subject:
PostPosted: Sun Apr 19, 2009 11:22 pm 
Offline
Joined: Sun May 02, 2004 7:04 pm
Posts: 53
FYI I did eventually solve my remote bouncing problem for those interested. The following is an excerpt from my correspondence with the LIRC mailing list.


Quote:
So I'm showing my EE geek tendencies here, but I decided to hook an o-scope up to me receiver and see how the signal levels looked on the receiver. Everything looks fine, but I did see a different problem. It looks like normally the remote sends a long IR string when pressing down on the button, and a short IR string when holding or releasing the button. For some reason, my remote occasionally sends two long IR strings when pressing down on the button, hence the bouncing.

The patch to lircd.c below fixes my problem. Sorry to bastardize your code, as it is almost assuredly the wrong way to do this, but that's probably becuase I have a combined total of about 2 hours of experience with this source. Anyway, this hack works for me becuase my remote should never be broadcasting the exact same string twice in a row as far as I can tell.


debounce.diff
Code:
--- lircd.c.orig        2009-04-19 21:28:42.000000000 -0600
+++ lircd.c     2009-04-19 22:16:52.000000000 -0600
@@ -1743,7 +1743,8 @@

 void broadcast_message(const char *message)
 {
-       int len,i;
+       int len,i,compare;
+        static char prev_message[PACKET_SIZE+1] = "";
        const char *release_message;

        release_message = check_release_event();
@@ -1753,7 +1754,11 @@
        }

        len=strlen(message);
-
+       compare=strcmp(message,prev_message);
+       strcpy(prev_message,message);
+
+        if(compare == 0) return;
+
        for (i=0; i<clin; i++)
        {
                LOGPRINTF(1,"writing to client %d",i);


to apply:
Code:
patch /usr/src/lirc-0.8.4a/daemons/lircd.c < debounce.diff


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 20, 2009 11:25 am 
Offline
Joined: Mon Dec 24, 2007 9:47 am
Posts: 535
Location: Ottawa, Canada
just seeing this now. Unless there is somethign strange, can't you just adjust the entries in lircrc to increase the value of the "repeat" parameter?

I know that is how I've solved this problem before.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Apr 20, 2009 3:42 pm 
Offline
Joined: Sun May 02, 2004 7:04 pm
Posts: 53
Quote:
just seeing this now. Unless there is somethign strange, can't you just adjust the entries in lircrc to increase the value of the "repeat" parameter?


Unfortunately not. LIRC is not recognizing the remote button bouncing as repeat events, but as entirely new events. So in other words LIRC isn't recognizing that the same button is being hit multiple times, so doesn't use the "repeat = N" setting.


Top
 Profile  
 
 Post subject:
PostPosted: Sun Jul 19, 2009 7:10 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
If anyone is following this thread, you may be interested to know that R6 (upgraded using pacman -Syu) now supports the Dvico Dual Digital 4 rev 2 out of the box including the remote. The double key press problem is not an issue anymore.

I have tested the upgraded packages that make this possible by manually installing them. Im just building a new iso to confirm that the remote is auto detected and the tuners auto populated when installing from a CD.

Edit: Yep. it works great. the only problem is the remote doesnt work in the installer, but after the install completes it works out of the box. The only thing i had to do to after the install completed was scan channels and then set the start channel for both input connections (which I did with the remote). Then stratight into live tv and it works like a charm.

Edit: I forgot that I had posted this. The remote works in the installer now too.


Last edited by Greg Frost on Sun Aug 23, 2009 2:25 am, edited 1 time in total.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Aug 22, 2009 9:55 pm 
Offline
Joined: Tue Mar 22, 2005 9:18 pm
Posts: 1422
Location: Brisbane, Queensland, Australia
I have found a minor flaw in that the lircrc.dvico-dual-digital4 file used is for the Revision 1 remote. I am trying to track down Rev. 2 version of the file.

The remotes are similar and that is why it works, but not all of the buttons work as I expected them too.

_________________
Girkers


Top
 Profile  
 
 Post subject:
PostPosted: Sun Aug 23, 2009 2:23 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
What is a revision 1 and revision 2 remote?

I thought that the revision was a revision 1/2 referred to the tuner card.

Dual Digital 4 revision 1 looks like this:Image

Dual Digital 4 revision 2 looks like this:Image

The remote that comes with the rev 2 looks like this:Image


Top
 Profile  
 
 Post subject:
PostPosted: Tue Aug 25, 2009 4:44 am 
Offline
Joined: Fri Feb 03, 2006 11:36 pm
Posts: 63
Location: Melbourne
I've had a problem in the past where I had two entries in the lircrc file for the same button. It meant that when I pressed the button with the duplicate, the action would be performed twice.


Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 27, 2009 3:38 am 
Offline
Joined: Tue Mar 22, 2005 9:18 pm
Posts: 1422
Location: Brisbane, Queensland, Australia
Greg you have posted a picture of the Rev2 remote but as I stated the lircrc is for Rev.1. as it talks about the "top wheel"

_________________
Girkers


Top
 Profile  
 
 Post subject:
PostPosted: Thu Aug 27, 2009 3:25 pm 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
I dont know what remote comes with the revision 1 card. Is it this one? Image


Top
 Profile  
 
 Post subject:
PostPosted: Mon Aug 31, 2009 7:36 am 
Offline
Joined: Mon May 10, 2004 8:08 pm
Posts: 1891
Location: Adelaide, Australia
Girkers wrote:
Greg you have posted a picture of the Rev2 remote but as I stated the lircrc is for Rev.1. as it talks about the "top wheel"
It may be for the rev1, but all of the Rev2 buttons function correctly, so I dont see what the problem is. Perhaps the remotes use the same codes.


Top
 Profile  
 
 Post subject:
PostPosted: Mon Jan 25, 2010 8:50 am 
Offline
Joined: Mon Jan 25, 2010 8:49 am
Posts: 1
Fantastic!! I'm Denny Stout ..I'm new here and I Just want to share this quote as my first post here...

"The less you can live on, the more chance your idea will succeed. This is true even after you’ve 'made it.'.

Make it a Great day people...


Top
 Profile  
 

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



All times are UTC - 6 hours




Who is online

Users browsing this forum: Bing [Bot] and 29 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