Cannot use keyboard within Qt app without sudo












3














I have an embedded Qt application crosscompiled that runs on BeagleBone Black. It works Ok, but one thing- It doesn't accept keyboard input if I won't run in directly on BeagleBone Black preceeding with sudo. This is a problem because:




  • I cannot remote debug application and use connected keyboard, as it doesn't work,

  • I cannot use keyboard when the app is in rc.local file to boot at startup (even though sudo is used there).


My /etc/enviroment content is here:



QWS_MOUSE_PROTO=IntelliMouse:/dev/input/mouse0
QWS_KEYBOARD=LinuxInput:/dev/tty
TSLIB_CONFFILE=/etc/ts.conf
TSLIB_PLUGINDIR=/usr/lib/ts


Although I have tried many different configurations for QWS_KEYBOARD. The keyboard I would like to use is /dev/input/event1.



Here are my persmissions:
My application rights are:



-rwxrwxrwx 1 root root  353100 Mar  2  2015 OvenViewer


And the input device rights are:



crwxrwxrwt 1 root root 13, 65 Mar  1 21:45 event1


I have set the rights in a file /etc/udev/rules.d/85-pure-data.rules:



KERNEL=="event1", MODE="777"









share|improve this question
























  • What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
    – Basile Starynkevitch
    Jul 1 '15 at 14:46












  • I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
    – Toby Speight
    Jul 1 '15 at 14:48










  • Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
    – Bremen
    Jul 1 '15 at 14:56










  • I have added some comments to the question
    – Bremen
    Jul 2 '15 at 6:08
















3














I have an embedded Qt application crosscompiled that runs on BeagleBone Black. It works Ok, but one thing- It doesn't accept keyboard input if I won't run in directly on BeagleBone Black preceeding with sudo. This is a problem because:




  • I cannot remote debug application and use connected keyboard, as it doesn't work,

  • I cannot use keyboard when the app is in rc.local file to boot at startup (even though sudo is used there).


My /etc/enviroment content is here:



QWS_MOUSE_PROTO=IntelliMouse:/dev/input/mouse0
QWS_KEYBOARD=LinuxInput:/dev/tty
TSLIB_CONFFILE=/etc/ts.conf
TSLIB_PLUGINDIR=/usr/lib/ts


Although I have tried many different configurations for QWS_KEYBOARD. The keyboard I would like to use is /dev/input/event1.



Here are my persmissions:
My application rights are:



-rwxrwxrwx 1 root root  353100 Mar  2  2015 OvenViewer


And the input device rights are:



crwxrwxrwt 1 root root 13, 65 Mar  1 21:45 event1


I have set the rights in a file /etc/udev/rules.d/85-pure-data.rules:



KERNEL=="event1", MODE="777"









share|improve this question
























  • What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
    – Basile Starynkevitch
    Jul 1 '15 at 14:46












  • I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
    – Toby Speight
    Jul 1 '15 at 14:48










  • Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
    – Bremen
    Jul 1 '15 at 14:56










  • I have added some comments to the question
    – Bremen
    Jul 2 '15 at 6:08














3












3








3







I have an embedded Qt application crosscompiled that runs on BeagleBone Black. It works Ok, but one thing- It doesn't accept keyboard input if I won't run in directly on BeagleBone Black preceeding with sudo. This is a problem because:




  • I cannot remote debug application and use connected keyboard, as it doesn't work,

  • I cannot use keyboard when the app is in rc.local file to boot at startup (even though sudo is used there).


My /etc/enviroment content is here:



QWS_MOUSE_PROTO=IntelliMouse:/dev/input/mouse0
QWS_KEYBOARD=LinuxInput:/dev/tty
TSLIB_CONFFILE=/etc/ts.conf
TSLIB_PLUGINDIR=/usr/lib/ts


Although I have tried many different configurations for QWS_KEYBOARD. The keyboard I would like to use is /dev/input/event1.



Here are my persmissions:
My application rights are:



-rwxrwxrwx 1 root root  353100 Mar  2  2015 OvenViewer


And the input device rights are:



crwxrwxrwt 1 root root 13, 65 Mar  1 21:45 event1


I have set the rights in a file /etc/udev/rules.d/85-pure-data.rules:



KERNEL=="event1", MODE="777"









share|improve this question















I have an embedded Qt application crosscompiled that runs on BeagleBone Black. It works Ok, but one thing- It doesn't accept keyboard input if I won't run in directly on BeagleBone Black preceeding with sudo. This is a problem because:




  • I cannot remote debug application and use connected keyboard, as it doesn't work,

  • I cannot use keyboard when the app is in rc.local file to boot at startup (even though sudo is used there).


My /etc/enviroment content is here:



QWS_MOUSE_PROTO=IntelliMouse:/dev/input/mouse0
QWS_KEYBOARD=LinuxInput:/dev/tty
TSLIB_CONFFILE=/etc/ts.conf
TSLIB_PLUGINDIR=/usr/lib/ts


Although I have tried many different configurations for QWS_KEYBOARD. The keyboard I would like to use is /dev/input/event1.



Here are my persmissions:
My application rights are:



-rwxrwxrwx 1 root root  353100 Mar  2  2015 OvenViewer


And the input device rights are:



crwxrwxrwt 1 root root 13, 65 Mar  1 21:45 event1


I have set the rights in a file /etc/udev/rules.d/85-pure-data.rules:



KERNEL=="event1", MODE="777"






linux keyboard c++ input qt






share|improve this question















share|improve this question













share|improve this question




share|improve this question








edited 3 hours ago









Rui F Ribeiro

39.2k1479130




39.2k1479130










asked Jul 1 '15 at 14:42









Bremen

1216




1216












  • What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
    – Basile Starynkevitch
    Jul 1 '15 at 14:46












  • I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
    – Toby Speight
    Jul 1 '15 at 14:48










  • Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
    – Bremen
    Jul 1 '15 at 14:56










  • I have added some comments to the question
    – Bremen
    Jul 2 '15 at 6:08


















  • What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
    – Basile Starynkevitch
    Jul 1 '15 at 14:46












  • I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
    – Toby Speight
    Jul 1 '15 at 14:48










  • Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
    – Bremen
    Jul 1 '15 at 14:56










  • I have added some comments to the question
    – Bremen
    Jul 2 '15 at 6:08
















What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
– Basile Starynkevitch
Jul 1 '15 at 14:46






What are the permissions on /dev/input/event1 ? Are you using udev ? Please edit the question to improve it
– Basile Starynkevitch
Jul 1 '15 at 14:46














I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
– Toby Speight
Jul 1 '15 at 14:48




I'm guessing this is Qt 4.x, given the QWS_* variables? This is definitely version-dependent.
– Toby Speight
Jul 1 '15 at 14:48












Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
– Bremen
Jul 1 '15 at 14:56




Yes this is Qt version 4.8. @BasileStarynkevitch I have created a rule in /etc/udev/rules.d/ where i added line KERNEL=="event1", GROUP="keyboard", MODE="666". Then I added both user debian and root to group keyboard. didnt help :/
– Bremen
Jul 1 '15 at 14:56












I have added some comments to the question
– Bremen
Jul 2 '15 at 6:08




I have added some comments to the question
– Bremen
Jul 2 '15 at 6:08










0






active

oldest

votes











Your Answer








StackExchange.ready(function() {
var channelOptions = {
tags: "".split(" "),
id: "106"
};
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function() {
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled) {
StackExchange.using("snippets", function() {
createEditor();
});
}
else {
createEditor();
}
});

function createEditor() {
StackExchange.prepareEditor({
heartbeatType: 'answer',
autoActivateHeartbeat: false,
convertImagesToLinks: false,
noModals: true,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
imageUploader: {
brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
allowUrls: true
},
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
});


}
});














draft saved

draft discarded


















StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f213328%2fcannot-use-keyboard-within-qt-app-without-sudo%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown

























0






active

oldest

votes








0






active

oldest

votes









active

oldest

votes






active

oldest

votes
















draft saved

draft discarded




















































Thanks for contributing an answer to Unix & Linux Stack Exchange!


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.





Some of your past answers have not been well-received, and you're in danger of being blocked from answering.


Please pay close attention to the following guidance:


  • Please be sure to answer the question. Provide details and share your research!

But avoid



  • Asking for help, clarification, or responding to other answers.

  • Making statements based on opinion; back them up with references or personal experience.


To learn more, see our tips on writing great answers.




draft saved


draft discarded














StackExchange.ready(
function () {
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f213328%2fcannot-use-keyboard-within-qt-app-without-sudo%23new-answer', 'question_page');
}
);

Post as a guest















Required, but never shown





















































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown

































Required, but never shown














Required, but never shown












Required, but never shown







Required, but never shown







Popular posts from this blog

濃尾地震

How to rewrite equation of hyperbola in standard form

No ethernet ip address in my vocore2