Universal Remote Card - Buttons, Touchpads, Sliders, and Keyboards for Multiple Platforms

There’s your problem. Long press only works on Android TV because it’s sending a long press center command, not a menu command. Kodi and other devices are not guaranteed to process long press commands the same way that Android TV does. I can make the long press remappable in the next release.

@extremeaudio I’ve made long clicks on the touchpad remappable in v.1.4.6. Try putting this in your config:

long_click_keycode: menu
custom_keys:
  menu:
    service: kodi.call_method
    service_data:
      entity_id: media_player.kodi
      method: Input.ContextMenu # May be incorrect, I found this online but don't use Kodi
1 Like

I’m really excited to announce that seamless keyboard input has been added in v1.5.1! Now instead of opening a prompt, the keyboard button opens the on screen keyboard and sends anything you type straight to Android TV. If you prefer the prompt use the textbox button instead.

2 Likes

@Nerwyn

Is there a way that you can also implement this for an Apple TV?

BTW: Who is using android :sweat_smile: :joy:

Nope. This card is primarily for Android TV, support for other devices is extra. It doesn’t look like there’s a known way to send text to Apple TVs outside of the official closed source Apple ones. It may be possible to implement it for Kodi though, if there’s interest in that.

1 Like

This long_click_keycode: menu does work to open the command but then also appears to create a loop of enters or returns. SO is not usable yet, at least here. Yes this is on iPhone with the known shortcomings for swipe gestures, but maybe some day in the future ! :wink:

1 Like

Shoot my bad, I must have not tested thoroughly enough on my new old iPhone. Just tried it and can confirm center is firing after lifting up on the long touchpad click. I’ll have to fix that.

Also, remember to make feature request issues for the other touchpad commands we talked about! I hope to get to them in the future, after a bunch of other refactors and porting to TypeScript.

@houser long clicks should be fixed on iOS in v1.5.3

2 Likes

I can confirm that long press menu is working in 1.5.3, Thanks, very very useful!

I have added a feature request here for complete swipe gesture support in the future and hope that is what you needed.

1 Like

Would it be possible to add an image centered as an overlay on the touchpad?
Without affecting the touch functionality of course…
If so, could you please suggest how that is done most elegantly?
Preferably with sizing and positioning, but a hard centered way would also work.
Many thanks-

Card mod!

card_mod:
  style: |
    toucharea {
      background-image: url("https://i.insider.com/60c3a81023393a00188e2b96");
      background-size: cover;
      opacity: 0.5;
    }

image

1 Like

Excellent, again!
Do you happen to know the css to center and resize the image on this card?
I suck badly at css and can not achieve this so far with my limited skillset and it looks like
it needs some kind of override?
Apart from that, this is perfect!

I would be very interested in that if it is possible,

I’m a backend engineer by trade, so a lot of what I’m doing here for HTML and CSS is stuff I’m googling as I go. Try the options available on this page. I’ve also updated the examples you shared near in the README near the bottom. And Kodi keyboard is in the backlog, since I’ll have to setup and configure Kodi before I can test it.

I’m happy to announce that I’ve ported this project to TypeScript and released v2!

As part of this, I’ve soft-deprecated creating rows by creating keys including _row in them in favor of a rows string array key. Old configs will continue to work but won’t be able to take advantage of the new columns feature which lets you nest columns into rows and rows into those columns, and the ability to put volume sliders and navigation touchpads in the same row as buttons and each other. Like this:

type: custom:android-tv-card
remote_id: remote.google_chromecast
media_player_id: media_player.google_chromecast
adb_id: media_player.google_chromecast_adb
title: Example
rows:
  - - back
    - power
    - home
  - - keyboard
    - search
    - volume_slider
  - - - netflix
      - null
      - youtube
      - null
      - spotify
    - navigation_touchpad
  - - previous
    - play_pause
    - next

3 Likes

Great update! I can confirm that it’s really easy to switch over to the rows string array. Works as expected

1 Like

Mind testing Kodi keyboard support for me? It seems fine from the testing I’ve done but I don’t really use Kodi.

Edit: merged to main and released as v2.1.0

1 Like

Hi guys!
Did anyone tried to add only “select” button? I mean, like “OK” ,“confirm”… you know - that one at the center between up/down/left/right arrows? It can be made visible by selecting “navigation_buttons”, but i’d like to have it separately (i’d like to position navigation buttons differently) ? None of known commands seem to work (like select, confirm, ok…)
Any suggestions? Or is a custom service only way?

Also : is there any commands/buttons list available?

Here is a list of the default keys. The one you’re looking for is called center.

1 Like

Aaa… center… i’d never thought of that… many thanks!
And, maaany thanks for this card! I was already started to prepare myself for painfull programming of tons of “custom:button-card’s” to make myself a decent remote. With this card all is so much simpler!

When i’m browsing through channels i mostly use “yellow” (for bring channel list up) then “up”, “down” and “center” (confirm selection), so i’ll put them in an easy accessible location.

1 Like

Is there a way to show the current playing title from netflix, apple tv, prime, disney etc… ?

On this card no. You’d have to put the media player created by either the Android TV remote or Android ADB integrations in a tile or media player card.

1 Like