public final class LircMode2 extends Object implements IHarcHardware, ICapture, IReceive
| Constructor and Description |
|---|
LircMode2(String[] cmdArray,
boolean verbose,
int beginTimeout,
int maxLearnLength,
int endTimeout) |
LircMode2(String cmd,
boolean verbose,
int beginTimeout,
int maxLearnLength,
int endTimeout) |
| Modifier and Type | Method and Description |
|---|---|
ModulatedIrSequence |
capture()
Listens to the device and returns a sequence.
|
void |
close() |
String |
getVersion()
Returns the hardware version (not the version of the driver software).
|
boolean |
isAlive() |
boolean |
isValid()
Tries to identify instances that are not valid.
|
static void |
main(String[] args) |
void |
open()
Opens the device with previously set parameters.
|
IrSequence |
receive()
Listens to the device and returns a sequence.
|
void |
reset() |
void |
setCommand(String command) |
void |
setDebug(int debug)
Sets a debug parameter.
|
void |
setTimeout(int timeout)
Set timeout in milliseconds.
|
void |
setTimeout(int beginTimeout,
int maxLearnedLength,
int endTimeout) |
void |
setVerbosity(boolean verbose)
Sets a verbosity flag, causing commands to be executed verbosely.
|
boolean |
stopCapture()
Signals the capturing device that it should stop capturing.
|
boolean |
stopReceive()
Signals the receiving device that it should stop receiving.
|
public LircMode2(String cmd, boolean verbose, int beginTimeout, int maxLearnLength, int endTimeout)
cmd - verbose - beginTimeout - maxLearnLength - endTimeout - public LircMode2(String[] cmdArray, boolean verbose, int beginTimeout, int maxLearnLength, int endTimeout)
cmdArray - verbose - beginTimeout - maxLearnLength - endTimeout - public String getVersion()
IHarcHardwaregetVersion in interface IHarcHardwarepublic void setVerbosity(boolean verbose)
IHarcHardwaresetVerbosity in interface IHarcHardwareverbose - on or offpublic void setDebug(int debug)
IHarcHardwaresetDebug in interface IHarcHardwarepublic void setCommand(String command)
public boolean isValid()
IHarcHardwareisValid in interface IHarcHardwarepublic void close()
close in interface Closeableclose in interface AutoCloseablepublic void open()
throws IOException
IHarcHardwareopen in interface IHarcHardwareIOExceptionpublic ModulatedIrSequence capture() throws HarcHardwareException, IOException, IrpMasterException
ICapturecapture in interface ICaptureHarcHardwareException - if the device is not in valid/open state.IOExceptionIrpMasterExceptionpublic boolean stopCapture()
ICapturestopCapture in interface ICapturepublic boolean isAlive()
public void setTimeout(int beginTimeout,
int maxLearnedLength,
int endTimeout)
setTimeout in interface ICapturepublic void setTimeout(int timeout)
IHarcHardwaresetTimeout in interface IHarcHardwaresetTimeout in interface IReceivetimeout - Timeout in milliseconds.public IrSequence receive() throws HarcHardwareException
IReceivereceive in interface IReceiveHarcHardwareException - if the device is not in valid/open state.public void reset()
public boolean stopReceive()
IReceivestopReceive in interface IReceivepublic static void main(String[] args)
Copyright © 2015. All rights reserved.