[lircd] uinput

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

[lircd] uinput

Nicolas Adenis-Lamarre
Hi,

i'm using lircd on a raspberry via buildroot.
It's not the last lirc version.
But perhaps you can help me.
Perhaps the problem occurs with the last version.

When running :
1) mode2 and pressing buttons, i get signal
2) lircd and irw and pressing buttons : i get buttons pressed
3) lircd --uinput and irw, or evtest and pressing buttons : nothing

I've debugged, and find a cause in lircd.c :
- related to the macro use_hw()
- related to a new client connection
- related to the select() function

until a first client is connected, current_driver->initialize is not called.
the select() function is waiting only on new client connection => normal.

At the first connection,
in case of no-uinput :
if(!use_hw) // returns true, and the driver is initiliazed
the select function waits on new client connection, and the driver (/dev/lirc0 in my case)

in case of uinput :
if(!use_hw) // returns false, and the driver is initiliazed
the select() function doesn't wait on the driver (/dev/lirc0) file.

By removing this check (or changing the use_hw function), i get irw displaying events. But i don't exactly know which fix is supposed to be the best.

Nicolas Adenis-Lamarre




------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741551&iu=/4140
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate

Re: [lircd] uinput

Alec Leamas
On 23/11/15 09:30, Nicolas Adenis-Lamarre wrote:

> Hi,
>
> i'm using lircd on a raspberry via buildroot.
>
> LIRC_TOOLS_VERSION = 0.9.2
> https://github.com/digitalLumberjack/recalbox-buildroot/tree/unified/package/lirc-tools
>
> It's not the last lirc version.
> But perhaps you can help me.
> Perhaps the problem occurs with the last version.
>
> When running :
> 1) mode2 and pressing buttons, i get signal
> 2) lircd and irw and pressing buttons : i get buttons pressed
> 3) lircd --uinput and irw, or evtest and pressing buttons : nothing
>
> I've debugged, and find a cause in lircd.c :
> - related to the macro use_hw()
> - related to a new client connection
> - related to the select() function
>
> until a first client is connected, current_driver->initialize is not called.
> the select() function is waiting only on new client connection => normal.
>
> At the first connection,
> in case of no-uinput :
> if(!use_hw) // returns true, and the driver is initiliazed
> the select function waits on new client connection, and the driver
> (/dev/lirc0 in my case)
>
> in case of uinput :
> if(!use_hw) // returns false, and the driver is initiliazed
> the select() function doesn't wait on the driver (/dev/lirc0) file.
>
> By removing this check (or changing the use_hw function), i get irw
> displaying events. But i don't exactly know which fix is supposed to be
> the best.
>
> Nicolas Adenis-Lamarre
>

hm... this might need some thinking. Could you please file a bug - bugs
are easier to track, especially since I cannot look into this right now?

Cheers!

--alec


------------------------------------------------------------------------------
Go from Idea to Many App Stores Faster with Intel(R) XDK
Give your users amazing mobile app experiences with Intel(R) XDK.
Use one codebase in this all-in-one HTML5 development environment.
Design, debug & build mobile apps & 2D/3D high-impact games for multiple OSs.
http://pubads.g.doubleclick.net/gampad/clk?id=254741551&iu=/4140
Loading...