Package org.deepjava.flink.core
Class FlinkSubDevice
- java.lang.Object
-
- org.deepjava.flink.core.FlinkSubDevice
-
- All Implemented Interfaces:
FlinkDefinitions
public class FlinkSubDevice extends Object implements FlinkDefinitions
A flink subdevice realizes a special function in aFlinkDevice
.- Author:
- Urs Graf
-
-
Field Summary
Fields Modifier and Type Field Description int
baseAddress
FlinkBusInterface
busInterface
int
function
int
id
int
memSize
FlinkSubDevice
next
int
nofChannels
int
subType
int
uniqueID
int
version
-
Fields inherited from interface org.deepjava.flink.core.FlinkDefinitions
ANALOG_INPUT_INTERFACE_ID, ANALOG_OUTPUT_INTERFACE_ID, CHANNEL_OFFSET, COUNTER_INTERFACE_ID, GPIO_INTERFACE_ID, HEADER_SIZE, INFO_DEVICE_ID, INFO_DEVICE_SIZE, INTERFACE_TYPE_MASK, MOD_CONF_OFFSET, MOD_STATUS_OFFSET, PPWA_INTERFACE_ID, PWM_INTERFACE_ID, REGISTER_WIDTH, REGISTER_WIDTH_BIT, SIZE_OFFSET, SUBHEADER_SIZE, TOTAL_HEADER_SIZE, TYPE_OFFSET, UART_INTERFACE_ID, UNIQUE_ID_OFFSET, WD_INTERFACE_ID
-
-
Constructor Summary
Constructors Constructor Description FlinkSubDevice()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description int
getConfigReg()
Returns the configuration register of a flink subdevice.int
getStatusReg()
Returns the status register of a flink subdevice.int
read(int address)
Base method to read one register from a flink device.void
setConfigReg(int confReg)
Writes the configuration register of a flink subdevice.void
write(int address, int data)
Base method to write one register of a flink device.
-
-
-
Field Detail
-
next
public FlinkSubDevice next
-
function
public int function
-
subType
public int subType
-
version
public int version
-
memSize
public int memSize
-
nofChannels
public int nofChannels
-
baseAddress
public int baseAddress
-
uniqueID
public int uniqueID
-
id
public int id
-
busInterface
public FlinkBusInterface busInterface
-
-
Method Detail
-
read
public int read(int address)
Base method to read one register from a flink device.- Parameters:
address
- of the register which should be read- Returns:
- content of the register
-
write
public void write(int address, int data)
Base method to write one register of a flink device.- Parameters:
address
- of the register which should be writtendata
- to write
-
getConfigReg
public int getConfigReg()
Returns the configuration register of a flink subdevice.- Returns:
- content of configuration register
-
getStatusReg
public int getStatusReg()
Returns the status register of a flink subdevice.- Returns:
- content of status register
-
setConfigReg
public void setConfigReg(int confReg)
Writes the configuration register of a flink subdevice.- Parameters:
confReg
- content of configuration register
-
-