|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.wagner_ibw.iow.smx.SwitchMatrix
This is the implementation of the IO Warrior 40 key matrix special mode function.
(unfinished!)
Nested Class Summary | |
(package private) class |
SwitchMatrix.NotifierThread
|
Field Summary | |
private sun.misc.Queue |
currentMatrixStatus
|
private boolean |
doScan
|
private AbstractIowDevcie |
iow
Reference to the underlying IOW device. |
private java.util.Hashtable |
keyMap
|
private java.util.Vector |
listeners
|
private int[] |
matrix
Current state of the switch matrix. |
(package private) static java.lang.String |
name
Name of this special mode function. |
private int[] |
oldMatrix
|
Fields inherited from interface de.wagner_ibw.iow.SpecialModeFunction |
SMF_CPS_ID, SMF_I2C_ID, SMF_LCD_ID, SMF_LED_ID, SMF_RC5_ID, SMF_SMX_ID, SMF_SPI_ID |
Constructor Summary | |
SwitchMatrix()
Constructor |
Method Summary | |
void |
addSwitchMatrixChangeListener(SwitchMatrixChangeListener smcl)
|
java.lang.String |
checkCompatibility(int id,
int rev,
int specialModes)
Checks if it is possible to activate this special mode function. |
int[] |
getDisableReport()
Returns the report that disables the special mode function. |
int[] |
getEnableReport()
Returns the report that enables the special mode function. |
int[] |
getIowSpecialBits(int deviceIdentifier)
Returns an array of bitmask(s) for port 0...1 or 0...3 if this special mode function runs on this iow device. |
long[] |
getLongValue()
|
java.lang.String |
getName()
Returns the name of the special mode function. |
int[] |
getReportIds()
Returns the report id(s) which the implementation is interested in. |
int |
getSpecialModeFuncionId()
Returns the special mode function for this implementation. |
boolean |
matchReportId(int reportId)
Checks if this implementation is interested in this report. |
void |
removeSwitchMatrixChangeListener(SwitchMatrixChangeListener smcl)
|
void |
reportReceived(int[] readBuffer)
Callback method is called when a matching report was received. |
int[] |
scanMatrix()
|
void |
setIowDevice(AbstractIowDevcie iow)
Sets the reference to an iow device for write report operations. |
private void |
setMatrix(int[] readBuffer)
|
java.lang.String |
toString()
Returns Information about the switch matrix as String. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
static final java.lang.String name
private java.util.Vector listeners
private AbstractIowDevcie iow
private int[] matrix
private int[] oldMatrix
private sun.misc.Queue currentMatrixStatus
private boolean doScan
private java.util.Hashtable keyMap
Constructor Detail |
public SwitchMatrix()
Method Detail |
public void addSwitchMatrixChangeListener(SwitchMatrixChangeListener smcl)
public void removeSwitchMatrixChangeListener(SwitchMatrixChangeListener smcl)
public java.lang.String toString()
toString
in class java.lang.Object
public int[] getDisableReport()
SpecialModeFunction
getDisableReport
in interface SpecialModeFunction
public int[] getEnableReport()
SpecialModeFunction
getEnableReport
in interface SpecialModeFunction
public int[] getIowSpecialBits(int deviceIdentifier)
SpecialModeFunction
getIowSpecialBits
in interface SpecialModeFunction
deviceIdentifier
- Iow device identifier (AbstractIowDevcie.IOW24ID or AbstractIowDevcie.IOW40ID).
public int[] getReportIds()
SpecialModeFunction
getReportIds
in interface SpecialModeFunction
public int getSpecialModeFuncionId()
SpecialModeFunction
getSpecialModeFuncionId
in interface SpecialModeFunction
public boolean matchReportId(int reportId)
SpecialModeFunction
matchReportId
in interface SpecialModeFunction
reportId
- Report id of the received report.
public void reportReceived(int[] readBuffer)
SpecialModeFunction
reportReceived
in interface SpecialModeFunction
readBuffer
- Read buffer from a received report.public void setIowDevice(AbstractIowDevcie iow)
SpecialModeFunction
setIowDevice
in interface SpecialModeFunction
iow
- Instance of an iow device.public java.lang.String checkCompatibility(int id, int rev, int specialModes)
SpecialModeFunction
checkCompatibility
in interface SpecialModeFunction
id
- Id of the current iow device.rev
- Rev of the current iow device.specialModes
- Special modes from the current iow device.
public java.lang.String getName()
SpecialModeFunction
getName
in interface SpecialModeFunction
public int[] scanMatrix()
public long[] getLongValue()
private void setMatrix(int[] readBuffer)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |