RoboJDETM v2.0

com.ridgesoft.robotics.sensors
Class SonyIrRemote

java.lang.Object
  extended by com.ridgesoft.robotics.sensors.SonyIrRemote
All Implemented Interfaces:
IrRemote

public class SonyIrRemote
extends Object
implements IrRemote

Class interfaces with an infrared demodulator to receive data from a Sony infrared home electronics remote control.


Constructor Summary
SonyIrRemote(IrReceiver irReceiver)
          Constructs an object to receive data from a Sony infrared remote contol.
 
Method Summary
 int read()
          Reads the next value received from the remote control.
 
Methods inherited from class java.lang.Object
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait
 

Constructor Detail

SonyIrRemote

public SonyIrRemote(IrReceiver irReceiver)
Constructs an object to receive data from a Sony infrared remote contol.

Parameters:
irReceiver - reference to the IR demodulator to receive data from
Method Detail

read

public int read()
Reads the next value received from the remote control.

For Sony remote controls, the lower 8 bits of the value are the key code and the next 3 most significant bits are the device code (TV, VCR, etc).

Specified by:
read in interface IrRemote
Returns:
value received from the remote control or -1 if no data has been received

RoboJDETM v2.0

Copyright (c) 2003-2009 RidgeSoft, LLC. All rights reserved.
www.ridgesoft.com