|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--de.wagner_ibw.iow.i2c.AbstractI2CDevice | +--de.wagner_ibw.iow.i2c.PCF8570
This is the implementation of the PCF8570P device, "256 x 8-bit static low-voltage RAM".
Field Summary | |
static int |
CLASS
Group 1 part of slave address for PCF8570 (PCF8570 device specific constant). |
static java.lang.String |
NAME
PCF8570 device specific constants. |
int |
RAM_SIZE
Capacity of this RAM. |
Fields inherited from class de.wagner_ibw.iow.i2c.AbstractI2CDevice |
MAX_I2C_LENGTH |
Constructor Summary | |
PCF8570(int deviceAddress)
Constructor |
Method Summary | |
boolean |
equals(java.lang.Object o)
Indicates whether some other PCF8570 object is "equal to" this one. |
void |
fillRam(int pattern)
Fills the whole ram with the specified pattern. |
int |
hashCode()
Returns a hash code value for this PCF8570 object. |
int |
read(int address)
|
int[] |
readPage(int address,
int length)
|
void |
setIowDevice(AbstractIowDevice iow)
Sets the reference to an IO-Warrior device for write report operations. |
java.lang.String |
toString()
Returns Information about this PCF8570 as String. |
void |
write(int address,
int data)
|
void |
writePage(int address,
int[] data)
|
Methods inherited from class de.wagner_ibw.iow.i2c.AbstractI2CDevice |
getI2cAddress, getName, readI2C, reportReceived, setMonitor, writeI2C |
Methods inherited from class java.lang.Object |
getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
public static final java.lang.String NAME
public final int RAM_SIZE
public static final int CLASS
Constructor Detail |
public PCF8570(int deviceAddress) throws java.lang.Exception
deviceAddress
- Group 2 part of slave address (possible values 0...7).
java.lang.Exception
- If anything goes wrong.Method Detail |
public int read(int address) throws java.lang.Exception, java.lang.IllegalArgumentException
address
-
java.lang.Exception
- If any transmission error occurred.
java.lang.IllegalArgumentException
public void write(int address, int data) throws java.lang.Exception, java.lang.IllegalArgumentException
address
- data
-
java.lang.Exception
- If any transmission error occurred.
java.lang.IllegalArgumentException
public void writePage(int address, int[] data) throws java.lang.Exception, java.lang.IllegalArgumentException
address
- data
-
java.lang.Exception
- If any transmission error occurred.
java.lang.IllegalArgumentException
public int[] readPage(int address, int length) throws java.lang.Exception, java.lang.IllegalArgumentException
java.lang.Exception
java.lang.IllegalArgumentException
public void fillRam(int pattern) throws java.lang.Exception
pattern
- Pattern that fills the ram.
java.lang.Exception
- If any transmission error occurred.public void setIowDevice(AbstractIowDevice iow)
I2CDevice
setIowDevice
in interface I2CDevice
setIowDevice
in class AbstractI2CDevice
iow
- Instance of an IO-Warrior device.public java.lang.String toString()
toString
in class AbstractI2CDevice
public boolean equals(java.lang.Object o)
equals
in class AbstractI2CDevice
public int hashCode()
hashCode
in class AbstractI2CDevice
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |