Loading custom mouse driver
-
Developed custom mouse driver and generated libourmousedriver.so. copied that to plugin directory where qt was installed.
Developed a application to get those mouse events but not able to get see any output as well as events from custom mouse driver.
I did:
export QWS_MOUSE_PROTO=ourmousedriver:/dev/input/event0.
Please help me on this.
-
Hi and welcome to devnet,
Which version of Qt are you using ?
-
You should start your application with the
QT_DEBUG_PLUGINS
environment variable set to 1 to see what is happening with your plugin.One a side note, are you locked to that old version of Qt ? If locked to Qt 4 then please at least upgrade to Qt 4.8.7 which is the latest and last release of the Qt 4 series otherwise you should seriously consider moving to Qt 5.
-
You should start your application with the
QT_DEBUG_PLUGINS
environment variable set to 1 to see what is happening with your plugin.One a side note, are you locked to that old version of Qt ? If locked to Qt 4 then please at least upgrade to Qt 4.8.7 which is the latest and last release of the Qt 4 series otherwise you should seriously consider moving to Qt 5.
-
Can you share the .pro file of your plugin project ?
-
QT += core gui
TARGET = mousedriver
TEMPLATE = lib
CONFIG += pluginDESTDIR = ~/home/
SOURCES+= mousedriver.cpp
HEADERS+= mousedriver.h
INSTALLS+ = target
mousedriver.cpp:
class mousehandler: public qobject, public QWSMouseHandler {
}
class mousehandlerdriverplugin: public QMouseDriverPlugin {
}
Q_EXPORT_PLUGIN2(mymousedriver, mousehandlerdriverplugin)
keys function:
QStringList() << "mymousedriver"; -
Maybe a silly question but did you install the plugin properly ?
-
created a home directory
and copied plugins, necessary library needed for qt application.
my application runs..mouse pointer not moving and now trying to add my mouse driver plugin.
since my device is space constraint so only copied gui, core, qt, network.so files and plugins
-
Where did you copy your custom mouse input plugin ?
-
Why not install it along the other Qt plugins ?
-
Did you check again with
QT_DEBUG_PLUGINGS
set to 1 ? What did you get ?