Important: Please read the Qt Code of Conduct - https://forum.qt.io/topic/113070/qt-code-of-conduct
How to use Smartphone Hardware in Qt Android App ?
Domo93 last edited by
I have to create three small Android Apps in Qt using the hardware of a smartphone (GPS, Camera, OrientationSensor). I tried it by myself doing this examlpe https://doc.qt.io/qtcreator/qt-creator-accelbubble-example.html# creating UI worked but when i configured the Sensor and try to run it, the App crashed (I tested it on my real device Android 9). It is so frustrating, I dont find good explanation in the internet. I created already Apps with Android Studio and if you want to acces the sensors for example you have to request Permission, i wondered if you need not do this in Qt cause the Example didnt say something like it.
So my Question is, can you please describe me how i can acces the hardware module which i mentioned above. Please tell me all important steps, and it would be nice if you give me some example code, i have real Problems in App Development in Qt and i dont find any good Tutorials about it.
Hi and welcome to devnet,
Yes you have to request the same permissions.
See this thread to get started.
Tom_H last edited by
@domo93 You clearly haven't read the Qt documentation or looked at the examples, because everything you asked for is there.