Get the IR CODE
- Enable IR Driver Debug Information
1 | root@Khadas:/home/khadas# echo 1 > /sys/class/remote/amremote/debug_enable |
Press the button on the remote controller and check the kerenl log to get the remote controller IR code.
Here is an example of the Khadas
remote controller, press the OK
button of the remote controller, you can check the kernel log:
1 | # dmesg | grep "meson-remote" |
You can find framecode=0xf807ff00
is the key value we need.
Set Custom IR CODE
You can set the IR CODE
in uboot command line, there are two custom buttons that can be used.
Write IR CODE
- Custom customer1
1 | kvim#kbi ircode customer1 w 0xf807ff00 |
- Custom customer2
1 | kvim#kbi ircode customer2 w 0xf807ff00 |
Read IR CODE
- Read customer1
1 | kvim#kbi ircode customer1 r |
- Read customer2
1 | kvim#kbi ircode customer2 r |
Verify
Power off the system
In u-boot
1 | kvim#kbi poweroff |
- In Ubuntu
1 | khadas@Khadas:~$ sudo poweroff |
Long press the
power
button to power offPower on with remote control
If everything work well, you can use OK
button to wakeup the board.