uinput: How to use force feedback?

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

 



Hello,

I have an existing uinput driver, which itself sits on an open device with a blocking read(), waiting for events to come in. Every event is translated to a key code and then sent to uinput.

My next step would be to pass through force feedback information, but I don't really understand how I should do this.

As far as I can see, the "uninput device" itself sends events in this case. But my main loop is already blocked by the "read", I use to get device events.

I see two possible solutions:
- "Somehow", I should be able to get "blocking read" from two open devices. As far as I found out, so far, "select" should be the right command to do this? - I could start two threads. One blocked by the "device events" and one by the "uinput events".

Which one would you recommend? Is uinput/ioctl thread safe? Is the second thread a good idea or is the communication, coming from uinput, such "low traffic", that it doesn't delay key handling in a relevant way?

Thank you very much in advance

Manuel

--
To unsubscribe from this list: send the line "unsubscribe linux-input" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Linux Media Devel]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Linux Wireless Networking]     [Linux Omap]

  Powered by Linux