Kodi Community Forum

Full Version: "Android TV Remote" not working correctly after update to LEIA on SHEILD
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Prior to the update this morning to LEIA 18.0, I used the "Android TV Remote Control" virtual app remote to manage my shield and KODI.  After the upgrade all the buttons work except the 'select' button on the virtual app.  I tried to "configure controllers" in the system settings but all the buttons work except for hte 'select' button.  Interestingly enough when I use the 'SHIELD REMOTE' virtual app all the buttons work but I need to use the 'android tv remote' virtual remote.  Any advice?
Noticed the same thing here. Haven't been able to figure it out just yet.
When I go into the Android TV Android app, nothing actually works for me at all. 17.6 to 18.0 auto upgrade. I can use the Kore app but I don't want two apps. 

Looks like an oversight. Worked great on 17.6.
That is what happened at first but if you go into 'controller configurations' in kodi settings, you can get all the buttons working EXCEPT the select button.  I'm not sure where that data  is stored.  If I did, we can probably get it working again.
Slightly import button. Smile

Where is the controller settings by chance? I can't seem to find it.
Well.  I updated this:

userdata/addon_data/peripheral.joystick/resources/buttonmaps/xml/android/virtual-remote_23b.xml

With this data:
Code:
<?xml version="1.0" ?>
<buttonmap>
    <device name="virtual-remote" provider="android" buttoncount="23">
        <controller id="game.controller.default">
            <feature name="b" button="6" />
            <feature name="down" button="20" />
            <feature name="left" button="21" />
            <feature name="right" button="19" />
            <feature name="a" button="22" />
            <feature name="up" button="18" />
        </controller>
    </device>
</buttonmap>

and the remote is working.  The virtual keyboard isn't... Yet.  Also disclaimer that I have no idea if this is how this is 'supposed' to be done.  Use at your own risk.
The "official" way to do it is to add an xml file (something.xml, where what you set as "something" doesn't actually matter - any and all valid xml files in that folder will get read and implemented in alphabetical order) into the keymaps sub-folder in your userdata (wiki) folder with that in it. That will overwrite the default one (which is what you changed) and should work in the same way.

Or alternatively you can use the keymap editor add-on (from the official repo) which is designed to help with this kind of thing.
Thanks, I'll give it a whirl later!
Thank-you.  So what you're saying is to add a file in 

userdata/addon_data/peripheral.joystick/resources/buttonmaps/xml/android

with any name like 'androidtvremote.xml'

and retain the original 'default' one so it isn't overwritten.  

Is that correct?
No, add the file in the keymaps subfolder of the user data (wiki) folder. So on Android it would be

Android/data/org.xbmc.kodi/files/.kodi/userdata/keymaps/androidtvremote.xml

Look at the wiki link for keymaps (wiki) for more details
Thanks.  

My mapping isn't quite correct anyway.  The 'a' button doesn't act like a 'select' when playing a video.  Im not sure why the word 'select' isn't working.
You might want enter rather than select? If not look in the wiki link in my previous post as that has a fairly good list of commands, actions and functions.

Give the keymap editor add-on a try, it's usually easier than doing it manually.
The keymap editor doesn't recognize the center button on the remote.  The only way I can get it to respond is by modifying the file in 

userdata/addon_data/peripheral.joystick/resources/buttonmaps/xml/android

and when I do that, it won't accept 'select' or 'enter' as a "<feature name="XXXXXX" button="22" />"

I can use 'a' which represents the 'a' button on the nvidia game controller.  I'm not sure where to go from here to map that button to something like it should be.  I looked at the kodi log and it shows this:

14:52:30.464 T:23608   DEBUG: Android Key AKEYCODE_DPAD_CENTER (23) pressed
14:52:30.464 T:23674   DEBUG: BUTTON [ 22 ] on "virtual-remote" pressed
14:52:30.464 T:23674   DEBUG: FEATURE [ a ] on game.controller.default pressed (ignored)
14:52:30.558 T:23608   DEBUG: Previous line repeats 1 times.
14:52:30.558 T:23608   DEBUG: Android Key AKEYCODE_DPAD_CENTER (23) released
14:52:30.561 T:23674   DEBUG: BUTTON [ 22 ] on "virtual-remote" released
14:52:30.561 T:23674   DEBUG: FEATURE [ a ] on game.controller.default released
14:52:30.778 T:23610   DEBUG: Previous line repeats 1 times.

I realize Im updating the location you said not to but I can't figure out how to do it from within the 'keymaps' directory and I can't get the resources/buttonmaps to do what I want.
Simplest way is to take the file you've been editing, copy it to the keymaps folder I mentioned above and edit it there.

The default one should ideally be reset to it's original content.

I was going to suggest using the debug log (wiki) to see what Kodi was actually receiving, but you're ahead of me already Wink
Hmm.  The root of the problem seems to be that kodi is now detecting the virtual remote as a joystick.  It isn't a joystick.  

I saw this mention in the forums and disabled joystick support and viola.  Back to a perfectly working remote without any file modifications.

https://forum.kodi.tv/showthread.php?tid=302835&page=3
Pages: 1 2