Posted on Sep 01, 2024 | Read time: 36 minutes | 4753
This article provides a detailed guide on how to port any IR remote control to a rooted Android TV. The process involves enabling debug mode, creating and configuring a new remote tab file, and applying the configuration to make the remote work with your Android TV.
By following these steps, you can customize your TV experience by integrating various remote controls, such as universal remote control, with your device.
Open /vendor/etc/remote.conf or /vendor/etc/remote.cfg, edit 0 to 1 in this line:
work_mode = 0x1repeat_enable = 1debug_enable = 1
It will be like this:
I'm using Mixplorer on my TV, so enable root and reate a file in /vendor/etc/, name it remote.tabX. X can be 1 if tab1 is not exist
Connect your TV with ADB (wireless or wired if avaiable), run:
adb shellsu
Click your remote OK button repeatedly and check the trigger on the box by this command:
dmesg -c
Look at invalid custom:0xb649ff00, it was my remote code.
Let's split your code with this digit: 0xXXYYZZZZ
We only need ZZZZ code only (the last of 4 code)
My remote code is 0xb649ff00, so the real code is ff00.
And final result is 0xff00.
custom_name can be any of your desire name, custom_code is your remote code, release_delay default is 80, so use it.
custom_name = amlogic-remotecustom_code = 0xfe01release_delay = 80
Replace X to your tab number and use with this command to apply it:
/vendor/bin/remotecfg -c /vendor/etc/remote.cfg -t /vendor/etc/remote.tabX
dmesg -cÂ
The result from invalid custom, will become scancode XX undefined.
If your dmesg will be like this, congrats then!
Open your text editor, append newline and add this line:
cursor_ok_scancode = 0x49
Change 0x49 to your OK button response from step 6 dmesg:
receive scancode=0x49
fn_key_scancode = 0xf1cursor_left_scancode = 0x51cursor_right_scancode = 0x50cursor_left_scancode = 0x51cursor_up_scancode = 0x16cursor_down_scancode = 0x1a
Add this line on our text editor:
key_begin0x49 28 #ENTER/OKkey_end
Change 0x49 to your OK button, also use step 7 to get result.Also change 28 to your response button.
Reference response button are in: /vendor/usr/keylayout/Generic.kl
Hello, Anonymous! Want log in?