You can't install the MTCManager. apk as a user app; it's a system app that uses the sharedUid of "system" (i.e. root).
There's a code section that deals with the serial communication between the MCU and the Manager app. This is how it determines what physical button relates to which android keycode. This is also why some MCU firmwares tend to mess up button assignments.
What are you trying to achieve with multi-user? Different button assignments per-user?
Not different assignments, just want them to work. Right now it reverts to default android mode in multi user with a lock screen and a home button only.
There has to be something stupid messed up in the code as most of this file is working. The touchscreen works, the calls to irkey intents work, just not the buttons.
Guessing that part has something like user 0 in it. Second user is user 10. Something has to be wrong somewhere.
Right now I am using tasker to "push" the buttons for me in multi user. As the physical buttons mainly do nothing.
Since user 10 can instal different apps, I think an easy way to handle the problem without getting into a elaborate remapper is have an app that repoints the physical buttons at the irkeydownintents again, since they are already working. I think they would more or less respond as normal programmatically pushing them rather than a script waiting for su. I do not even think you would have to do overrides as they do not seem to be mapped to anything.
Although long term goal is better control of the buttons.
As far as the goal for multi user. There are multiple people driving the car for work. My work is 99% communication need related. So being at the end of my electronic gadget chain and having everyone working for me at the end of one also is required. I can work, and do work from the beach many days. Long as I can return the mail and answer the phone I am good.
Right now who's ever phone enters the car, it connects to their bluetooth shooting off tasker to wifi tether. Since bluetooth is actually a mcu thing tasker on the radio cannot pick up the connect. Once wifi connects it runs an am switch-user XX automatically depending on the user. Bringing up their corporate gmail, and default like music player.
A lock screen was important to us because the nature of our job. We deal with DNA testing and have hipaa requirements and ISO requirement about privacy.
If we could find the offending line of code. I can ask them to change it.
We really need the compilable source for this one app to change everything that is wrong....