|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.amx.duet.tools.util.NetLinxUtil
Class containing NetLinx API java equivalent methods. If you are not extending
this class, then calls should be used like so:
NetLinx.SendLevel(nlDev, nLevel, nValue)
Note: Most methods are using camel case as apposed to the mixed case or upper case method used by NetLinx. Also, the underscore has been removed.
Field Summary | |
static int |
FIRST_LOCAL_PORT
|
static int |
FIRST_VIRTUAL_DEVICE
|
static int |
TIMELINE_ONCE
|
static int |
TIMELINE_REPEAT
|
Constructor Summary | |
NetLinxUtil()
|
Method Summary | |
static void |
CancelWait(WaitTimer timer)
This method cancels the specified wait timer. |
static int |
getPulseTime()
The function returns the current duration of PULSE as set by setPulseTime() . |
static long |
MaxValue(long lvar1,
long lvar2)
This routine takes two variables and compares for the highest value. |
static long |
MinValue(long lvar1,
long lvar2)
This routine takes two variables and compares for the lowest value. |
static int |
Off(com.amx.duet.da.NetLinxDevice nlDev,
int nChan)
Send the feedback off state to the device. |
static int |
On(com.amx.duet.da.NetLinxDevice nlDev,
int nChan)
Send the feedback on state to the device. |
static int |
Pulse(com.amx.duet.da.NetLinxDevice nlDev,
int nChan)
Send a pulse command to the device. |
static int |
Push(com.amx.duet.da.NetLinxDevice nlDev,
int nChan)
Send a push command to the device. |
static int |
RandomNumber(int number)
This function returns a random number X in the range 0 <= X < number. |
static int |
Release(com.amx.duet.da.NetLinxDevice nlDev,
int nChan)
Send a release command to the device. |
static int |
SendCommand(com.amx.duet.da.NetLinxDevice nlDev,
java.lang.String str)
Send the command to the device. |
static int |
SendLevel(com.amx.duet.da.NetLinxDevice nlDev,
int nLevel,
float fValue)
Send the level value to the device. |
static int |
SendLevel(com.amx.duet.da.NetLinxDevice nlDev,
int nLevel,
int nValue)
Send the level value to the device. |
static int |
SendString(com.amx.duet.da.NetLinxDevice nlDev,
java.lang.String str)
Send the string to the device. |
static void |
setPulseTime(int nTime)
This function sets the PULSE time in .10 second units. |
static boolean |
Wait(WaitTimer timer)
This method is used to create and process an event of one or more statements at a later time. |
static boolean |
Wait(WaitTimer timer,
int nTimeOut)
This method is used to create and process an event of one or more statements at a specified period of time. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int FIRST_VIRTUAL_DEVICE
public static final int FIRST_LOCAL_PORT
public static final int TIMELINE_ONCE
public static final int TIMELINE_REPEAT
Constructor Detail |
public NetLinxUtil()
Method Detail |
public static final int SendLevel(com.amx.duet.da.NetLinxDevice nlDev, int nLevel, int nValue)
nlDev
- nLevel
- nValue
-
public static final int SendLevel(com.amx.duet.da.NetLinxDevice nlDev, int nLevel, float fValue)
nlDev
- nLevel
- fValue
-
public static final int SendString(com.amx.duet.da.NetLinxDevice nlDev, java.lang.String str)
nlDev
- str
-
public static final int SendCommand(com.amx.duet.da.NetLinxDevice nlDev, java.lang.String str)
nlDev
- str
-
public static final int Push(com.amx.duet.da.NetLinxDevice nlDev, int nChan)
nlDev
- nChan
-
public static final int Release(com.amx.duet.da.NetLinxDevice nlDev, int nChan)
nlDev
- nChan
-
public static final int On(com.amx.duet.da.NetLinxDevice nlDev, int nChan)
nlDev
- nChan
-
public static final int Off(com.amx.duet.da.NetLinxDevice nlDev, int nChan)
nlDev
- nChan
-
public static final int Pulse(com.amx.duet.da.NetLinxDevice nlDev, int nChan)
nlDev
- nChan
-
public static final void setPulseTime(int nTime)
nTime
- public static final int getPulseTime()
setPulseTime()
.
Time is measured in tenths of a second; the default is 5 (0.5 seconds).
public static final void CancelWait(WaitTimer timer)
timer
- WaitTimer to be cancelled.public static final boolean Wait(WaitTimer timer, int nTimeOut)
timer
- WaitTimer objectnTimeOut
- period of time to reset the timer to
public static final boolean Wait(WaitTimer timer)
timer
- WaitTimer object
public static final int RandomNumber(int number)
number
- integer (must be greater than zero) that will serve as
the upper limit for the random number generator.
public static final long MinValue(long lvar1, long lvar2)
lvar1
- variable that must be a long or casted to a longlvar2
- variable that must be a long or casted to a long
public static final long MaxValue(long lvar1, long lvar2)
lvar1
- variable that must be a long or casted to a longlvar2
- variable that must be a long or casted to a long
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |