Package cbsw.adept
Class JniAdeptDepp.dmgr
- java.lang.Object
-
- cbsw.adept.JniAdeptDepp.dmgr
-
- Enclosing class:
- JniAdeptDepp
public static class JniAdeptDepp.dmgr extends java.lang.Object
Native interface wrappers to Digilent Adept DMGR API.
-
-
Constructor Summary
Constructors Constructor Description dmgr()
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static int
close(int hif)
Closes the device.static int
enumerate()
Enumerates devices.static java.lang.String
getCapabilities(int idx)
Gets the capabilities of an enumerated device.static java.lang.String
getEnumeratedDevice(int idx)
Gets the connection name of an enumerated device.static int
getLastError()
Gets the last error code.static java.lang.String
getLastErrorDescription(int erc)
Gets the last error description.static java.lang.String
getLastErrorName(int erc)
Gets the last error name.static int
open(java.lang.String dev)
Opens a device by connection name.
-
-
-
Method Detail
-
open
public static int open(java.lang.String dev)
Opens a device by connection name.
Native wrapper.
- Parameters:
dev
- The connection name of the device- Returns:
- The device handle
-
close
public static int close(int hif)
Closes the device.
Native wrapper.
- Parameters:
hif
- Internal device handle- Returns:
- Return code (always 1)
-
enumerate
public static int enumerate()
Enumerates devices.
Native wrapper.
- Returns:
- Number of devices found
-
getEnumeratedDevice
public static java.lang.String getEnumeratedDevice(int idx)
Gets the connection name of an enumerated device.
Native wrapper.
- Parameters:
idx
- Enumeration index- Returns:
- The connection name
-
getCapabilities
public static java.lang.String getCapabilities(int idx)
Gets the capabilities of an enumerated device.
Native wrapper.
- Parameters:
idx
- Enumeration index- Returns:
- Capabilities string
-
getLastError
public static int getLastError()
Gets the last error code.
Native wrapper.
- Returns:
- Error code
-
getLastErrorName
public static java.lang.String getLastErrorName(int erc)
Gets the last error name.
Native wrapper.
- Parameters:
erc
- Numeric code of message name- Returns:
- Error name
-
getLastErrorDescription
public static java.lang.String getLastErrorDescription(int erc)
Gets the last error description.
Native wrapper.
- Parameters:
erc
- Numeric code of message name- Returns:
- Error description
-
-