How to: setup wakeup with your IR remote control 看全部

Great news.
  • 7# andreq
  • 2016-10-19 08:35:06
What a good timing! I was digging online for any answer and didn't realize everything was lay right here on the forum .

Thanks, it worked after a couple of try as my pre_data was 0xFF  but actualy it's 0xFF00 which ended up being 65280 (decimal). I'm using a cheap A20 android box remote control, so I was able to fetch the script.bin in there and find out the needed power key and addr_code!
Edited by giaur500 at 2016-10-20 00:22

Not working for me. My pre_data from lircd.conf = 0x202, so:
  1. pre_data 0x202 = 000 0010 0000 0010 => bit_reversed 0100 0000 0100 0000 => 0x4040


KEY_POWER is 0xB24D, so:
  1. KEY_POWER 0xB24D => code 0xB2 => 1011 0010 => bit_reversed 0100 1101 => 0x4D
fex:
  1. [s_cir0]
  2. ir_used = 1
  3. ir_rx = port:PL11<2><1><default><default>
  4. ir_power_key_code0 = 0x4D
  5. ir_addr_code0 = 0x4040


I converted it back to script.bin, replaced original file and nope, my device won't wake up on power key press. Also tried to change KEY_POWER to KEY_SLEEP, still not working. I have OrangePI PC. Any ideas? Should it be working on OrangePI PC?
  • 9# jernej
  • 2016-10-20 00:24:03
quote: giaur500 replied at 2016-10-19 17:14
Not working for me. My pre_data from lircd.conf = 0x202, so:

Your math seems ok. Just one stupid question, did you reboot it first? Those settings are transfered to ARISC only at boot. Otherwise please post full lircd.conf.

Edited by giaur500 at 2016-10-20 00:37

What do you mean by reboot? It was booted after sd card inserted after replacing script.bin on PC. My lirc.conf:


  1. # Please make this file available to others
  2. # by sending it to <lirc@bartelmus.de>
  3. #
  4. # this config file was automatically generated
  5. # using lirc-0.9.1-git(default) on Sun Jun 12 13:38:31 2016
  6. #
  7. # contributed by
  8. #
  9. # brand:                       /storage/.config/lircd.conf
  10. # model no. of remote control:
  11. # devices being controlled by this remote:
  12. #

  13. begin remote

  14.   name  /storage/.config/lircd.conf
  15.   bits           16
  16.   flags SPACE_ENC
  17.   eps            30
  18.   aeps          100

  19.   header       8979  4495
  20.   one           555  1696
  21.   zero          555   571
  22.   ptrail        555
  23.   repeat       8980  2260
  24.   pre_data_bits   16
  25.   pre_data       0x202
  26.   gap          79385
  27.   repeat_gap   129096
  28.   toggle_bit_mask 0x0

  29.       begin codes
  30.           KEY_SLEEP                0xB24D
  31.           KEY_VOLUMEUP             0xA857
  32.           KEY_VOLUMEDOWN           0x38C7
  33.           KEY_MUTE                 0xC23D
  34.           KEY_E                    0xCA35
  35.           KEY_O                    0x58A7
  36.           KEY_LEFT                 0x08F7
  37.           KEY_UP                   0xD02F
  38.           KEY_RIGHT                0x8877
  39.           KEY_DOWN                 0x708F
  40.           KEY_ENTER                0xB04F
  41.           KEY_ESC                  0x42BD
  42.           KEY_I                    0xA25D
  43.           KEY_PREVIOUS             0x9A65
  44.           KEY_SPACE                0x1AE5
  45.           KEY_NEXT                 0xB847
  46.           KEY_STOP                 0x22DD
  47.           KEY_0                    0x00FF
  48.           KEY_1                    0x807F
  49.           KEY_BACKSPACE            0xC837
  50.           KEY_2                    0x40BF
  51.           KEY_3                    0xC03F
  52.           KEY_4                    0x20DF
  53.           KEY_5                    0xA05F
  54.           KEY_6                    0x609F
  55.           KEY_7                    0xE01F
  56.           KEY_8                    0x10EF
  57.           KEY_9                    0x906F
  58.       end codes

  59. end remote

Also, to be sure I tried to decode back my new script.bin and I can see my new values are there (but provided in dec, not hex).
1234.. 11NextPage