Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[input] add WETEK remote to peripherals #8290

Closed
wants to merge 1 commit into from
Closed

Conversation

da-anda
Copy link
Member

@da-anda da-anda commented Oct 25, 2015

this has been lying around in my repo for some time. It adds the USB ID of the WETEK remote to our peripherals system which allows to ship customized keymaps for the WETEK remote while they only apply when the remote is present (just like for Nyxboard).

I'm happy to add a suiteable default keymap to this PR if somebody points me to one. @NedScott do you consider the keymap in the wiki as good?
I don't have a WETEK Core box, so was not able to add it's USB ID. If somebody can grab it, I'll add it.

@da-anda da-anda added Type: Feature non-breaking change which adds functionality v16 Jarvis labels Oct 25, 2015
@hudokkow
Copy link
Member

Wiki keyboard layout is fine. At least I'm using it.

@NedScott
Copy link
Contributor

I think that keymap works out really well with the small Wetek remote. It's what I've been using on mine.

@ksooo
Copy link
Member

ksooo commented Oct 26, 2015

wetek.openelec comes with remote that looks differentvthan the one that comes with wetek.play Don't know whether it's actually a different device.

Just wanted to mention this.

@NedScott
Copy link
Contributor

It seems that the larger OpenELEC remote dongle uses the same USB product and vender IDs. However, I think a keymap could be made for both. At a quick glance, some of the modifications from the wiki keymap looks like it will fit both without conflict. I'll try to update it today, if it needs it.

@da-anda
Copy link
Member Author

da-anda commented Oct 26, 2015

@NedScott thanks. I suppose you have a OE WETEK box then? :)
When you check the keymap - maybe also think about longpress. I'll also dig up my custom keymap and compare it with the one on Wiki.

@sraue
Copy link
Member

sraue commented Oct 26, 2015

Both remotes are using the same dangle an can be paired on both devices. Sadly some buttons are printed wrong on the other remote so it's not possible to map they for both devices together. Please check the last commits on OpenELEC master there we added a kernel patch to support all buttons and some Kodi patches to map the remote in kodi. I will try to send the kernel patch upstream. Then only patches from OpenELEC master are needed to map the remotes best as possible

@da-anda
Copy link
Member Author

da-anda commented Oct 26, 2015

@sraue from what I see in your patches a optimized keymap for the original WETEK remote is still needed.

@sraue
Copy link
Member

sraue commented Oct 26, 2015

How optimized? I think only the epg button on the WeTek and the suspend button on the OpenELEC remote don't match with other buttons on the other remote (can look later today)

@NedScott
Copy link
Contributor

At least for a basic keymap, I think we can find a middle ground for both that will be better than default. For example, SMS-text entry and SMS-jump is an easy one.

These are what keys the remotes show my computer when I checked just now: https://dl.dropboxusercontent.com/u/2340692/XBMC_stuff/Wetek_remotes.jpg

@da-anda
Copy link
Member Author

da-anda commented Oct 26, 2015

@sraue - the WETEK remote has "play/pause" printed on the "select" button - so when something is playing you actually expect it to play and pause the movie and not trigger the OSD or channel list. And some other improvements in this direction.

@NedScott
Copy link
Contributor

This is what I've come up with so far: http://kodi.wiki/view/Alternative_keymap_for_WeTek_Play_remote#Keymap_2

There's a couple of conflicts, but they don't actually conflict because they are keys that aren't really used at the same time. For example, F2 is shift on the virtual keyboard because that makes sense for large remote, but it shouldn't be an issue for the small remote. F2 will globally will open the EPG grid, which doesn't make sense on the big remote, but that button wasn't doing anything globally anyways.

@da-anda
Copy link
Member Author

da-anda commented Oct 28, 2015

included the keymap from the wiki now, but haven' tested it yet.

@da-anda da-anda added the WIP PR that is still being worked on label Oct 28, 2015
@NedScott
Copy link
Contributor

I based the SMS keys on remote.xml, and it turns out that both this keymap and remote.xml are missing numeric input for a few PVR windows. This is because the default is jumpSMS instead of direct number input, which requires specific windows to be mapped for numbers.

I've updated the wiki keymap with that correction and with a couple of other minor adjustments.

I've been trying to use this daily and it seems to be working very well. I will do a PR to fix remote.xml with the SMS/numeric input corrections later, since that should also be updated.

@NedScott
Copy link
Contributor

NedScott commented Nov 2, 2015

github won't let me make a PR to your fork fork for some reason, but here's the keymap: https://github.com/NedScott/xbmc/blob/wetek/system/keymaps/wetek-play/keyboard.xml

@MartijnKaijser
Copy link
Member

ping @da-anda

@stefansaraev
Copy link
Contributor

stefansaraev commented Apr 28, 2016

ping @da-anda

@sraue what's your opinion, does it make handling wetek remote easier for you ?

cc @codesnake

@codesnake
Copy link
Contributor

Good idea 👍

@stefansaraev
Copy link
Contributor

stefansaraev commented Apr 28, 2016

not sure how to proceed, as there are issues with openelec wetek remote (same usb id, different codes sent for same buttons, wrong printed buttons), iirc openelec is using own kernel hid driver now, so this is up to @sraue

EDIT: I prefer not pushing a change in behaviour if he says "no", if all works fine on OE/LE. no idea how's it handled on droid

@NedScott
Copy link
Contributor

NedScott commented Apr 29, 2016

They do all use the same USB ID, but there really isn't a conflict between buttons. I have tested all three of WeTek's currently shipping remotes using this keymap and it works fine for all of them. I've been meaning to recommend to WeTek to include it by default for their own WeTek Media center as well.

This is the most up to date version of that keymap: http://kodi.wiki/view/Alternative_keymap_for_WeTek_Play_remote#Keymap_1

@NedScott
Copy link
Contributor

Oh, and Android should not be affected at all. Android doesn't see different USB IDs (at least, as of Kodi v16), so it defaults to the generic keyboard keymap.

@codesnake
Copy link
Contributor

codesnake commented Apr 29, 2016

@NedScott There's really conflict of WeTek Play and OE box remotes. Some buttons have the same IDs but different purpose.

@NedScott
Copy link
Contributor

@codesnake Yes, but my keymap avoids those :)

The only keys that are mapped are safe.

@NedScott
Copy link
Contributor

NedScott commented May 9, 2016

I've made a blog post for WeTek about this keymap, which has a picture to help explain what is happening:

http://wetek.com/blog/view/56/wetek-showcase-how-to-improve-your-remote-in-kodi
https://dl.dropboxusercontent.com/u/2340692/WeTek/WeTek_remotes.jpg

Only real overlap is with F2 and F4/F7.

On the OpenELEC remote this means two buttons (F4 and F7) will both open the context menu, but by default both buttons don't do anything, so I see that as a minor issue.

F2 is labeled as "EPG" on the Play1 remote. However, F2 is also used on the OpenELEC remote with an icon that looks like "shift". To compromise, F2 globally opens the EPG window, except when the on-screen-keyboard is up, and then it will do "shift".

F1 is also used on two of the remotes, but F1 is only used when the on-screen-keyboard is up, for "backspace". Globally, the key on both remotes will do nothing.

Also, do note that this keymap would not be loaded by default for Android. Users will really only see this in OpenELEC/LibreELEC, or other linux-based systems (or if they take the remote dongle out of the WeTek and use it on another computer ;) )

@NedScott
Copy link
Contributor

Poke poke? Any chance we can get the PR updated with the new keymap, or just merge this PR and I'll make another for the updated keymap?

@NedScott
Copy link
Contributor

See #10169

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Type: Feature non-breaking change which adds functionality WIP PR that is still being worked on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

8 participants