How do I register a non-canon hardware controller as an input device in Android?

my problem is a little tricky. I have to connect an external controller to android system and make it available to third party apps. Unfortunately, the controller just sends 3 kinds of signals: accelerometer, pressure and of course the battery level. I used to suggest that I look for a joystick for something else. I'm trying, but due to the nature of this controller, I'm not really sure if it will work this way. Infact, the controller speaks to the phone via WIFI ad-hoc network and doesn't send any control signal to try to connect as a game controller for example.

I searched inside the source and I saw a class that might come in handy: InputDevice. As far as I can see, it has a lot of predefined profile, but I can't find a way to "register" my controller as a new InputDevice.

hope the problem is clear enough

I'm sorry I wasn't more specific, but this is a business project and I signed an NDA

+3


source to share





All Articles