Thursday 29 July 2010

Remote Control

I eventually gave up on the idea of trying to prod the serial port on my Astro STB and bought a cheap IR transceiver from some guy in Hong Kong via ebay. My first attempts at learning the remote codes were frustrating - irrecord complained about something being wrong after incorrectly guessing the settings, and when I finally got some codes learned, I found that a lot of the buttons had the same code, so 2, 6 and 8 were all being detected as KEY_2. Eventually I started trying to manually configure the basic settings based on some of the standard protocols, and eventually hit on RCMM-32, which learned all the codes and can reliably detect them when I press the buttons on the remote.

So now the codes are learned, along with the codes for the extra buttons for controlling a Panasonic DVD player on the bottom of my TV remote, which have now found a use giving basic control of Freevo in case the wireless keyboard, bluetooth equipped mobile phone or one of many wifi equipped gadgets is not close at hand.

Next step is to go the other way and send the codes out to the STB. The transceiver doesn't seem to be sending anything out at all. I still haven't narrowed down the problem, it may be a faulty IR LED, or an incompatibility between the transceiver (MCEUSB gen 1) and the software driving it (LIRC 0.86). Now that I have the remote codes, it might also be a good time to go back to trying the serial link, but that'll have to wait for another night. For now, I'll just post up the Astro remote codes, in case anyone else is struggling to get them working with LIRC.




# brand:                       ASTRO
# model no. of remote control: 
# devices being controlled by this remote:
#   Astro Satellite Decoder STB (Malaysia) [Philips DSR4201/68]

begin remote

  name  ASTRO
  bits            8
  flags RCMM|CONST_LENGTH
  eps             2
  aeps          100

  header        417   278
  three         167   778
  two           167   611
  one           167   444
  zero          167   278
  ptrail        167
  pre_data_bits   24
  pre_data       0x225027
  gap          99817
  toggle_bit_mask 0x0

      begin codes
          KEY_0                    0x00
          KEY_1                    0x01
          KEY_2                    0x02
          KEY_3                    0x03
          KEY_4                    0x04
          KEY_5                    0x05
          KEY_6                    0x06
          KEY_7                    0x07
          KEY_8                    0x08
          KEY_9                    0x09
          KEY_RED                  0x6D
          KEY_GREEN                0x6E
          KEY_YELLOW               0x6F
          KEY_BLUE                 0x70
          KEY_KPASTERISK           0xF6
          KEY_TEXT                 0x3C
          KEY_MENU                 0x54
          KEY_SHOP                 0xAA
          KEY_EXIT                 0x83
          KEY_BACK                 0xA9
          KEY_EPG                  0xCC
          KEY_INFO                 0x0F
          KEY_UP                   0x58
          KEY_DOWN                 0x59
          KEY_LEFT                 0x5A
          KEY_RIGHT                0x5B
          KEY_OK                   0x5C
          KEY_VOLUMEUP             0x10
          KEY_VOLUMEDOWN           0x11
          KEY_CHANNELUP            0x20
          KEY_CHANNELDOWN          0x21
          KEY_AUDIO                0x4E
          KEY_SUBTITLE             0x4B
          KEY_MUTE                 0x0D
          KEY_MAIL                 0xF3
          KEY_FAVORITES            0x84
          KEY_HELP                 0x81
          KEY_POWER                0x0C
      end codes

end remote


3 comments:

Anonymous said...

Hi Jason
I just want to tell you that I used your lirc.conf for the Phillips remote and i am very happy that I found your blog, thank you very much.
Br
Jon

Anonymous said...

Jason,
Can dsr4201 controlling dvb850s decoder? TQ

Jason Rumney said...

I haven't found any way for the dsr4201 to control or be controlled by anything.