org.mbari.siam.tests.utils.osdt
Class Model
java.lang.Object
java.lang.Thread
org.mbari.siam.foce.devices.controlLoop.WorkerThread
org.mbari.siam.tests.utils.osdt.Model
- All Implemented Interfaces:
- java.lang.Runnable
public class Model
- extends WorkerThread
| Nested classes/interfaces inherited from class java.lang.Thread |
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler |
| Fields inherited from class java.lang.Thread |
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY |
|
Constructor Summary |
Model()
|
Model(long delayMillis)
|
Model(java.lang.String osdtHost,
int osdtPort,
java.lang.String testHost,
int testPort,
long delayMillis)
|
| Methods inherited from class java.lang.Thread |
activeCount, checkAccess, clone, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield |
| Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
ID_PHCORR
public static final int ID_PHCORR
- See Also:
- Constant Field Values
ID_PHPUMPCMD
public static final int ID_PHPUMPCMD
- See Also:
- Constant Field Values
ID_VELCORR
public static final int ID_VELCORR
- See Also:
- Constant Field Values
ID_VELXINT
public static final int ID_VELXINT
- See Also:
- Constant Field Values
ID_TFWDCMD
public static final int ID_TFWDCMD
- See Also:
- Constant Field Values
ID_TAFTCMD
public static final int ID_TAFTCMD
- See Also:
- Constant Field Values
ID_PSCALE
public static final int ID_PSCALE
- See Also:
- Constant Field Values
ID_ISCALE
public static final int ID_ISCALE
- See Also:
- Constant Field Values
ID_TSHIFT
public static final int ID_TSHIFT
- See Also:
- Constant Field Values
ID_USEVCONST
public static final int ID_USEVCONST
- See Also:
- Constant Field Values
ID_VXCONST
public static final int ID_VXCONST
- See Also:
- Constant Field Values
ID_VYCONST
public static final int ID_VYCONST
- See Also:
- Constant Field Values
ID_VELA
public static final int ID_VELA
- See Also:
- Constant Field Values
ID_VELB
public static final int ID_VELB
- See Also:
- Constant Field Values
ID_VELC
public static final int ID_VELC
- See Also:
- Constant Field Values
ID_PHBOXCARDEPTH
public static final int ID_PHBOXCARDEPTH
- See Also:
- Constant Field Values
ID_PH1
public static final int ID_PH1
- See Also:
- Constant Field Values
ID_PH2
public static final int ID_PH2
- See Also:
- Constant Field Values
ID_PH3
public static final int ID_PH3
- See Also:
- Constant Field Values
ID_PH4
public static final int ID_PH4
- See Also:
- Constant Field Values
ID_PH5
public static final int ID_PH5
- See Also:
- Constant Field Values
ID_PH6
public static final int ID_PH6
- See Also:
- Constant Field Values
_log4j
protected static org.apache.log4j.Logger _log4j
Model
public Model()
Model
public Model(long delayMillis)
Model
public Model(java.lang.String osdtHost,
int osdtPort,
java.lang.String testHost,
int testPort,
long delayMillis)
setOSDTHost
public void setOSDTHost(java.lang.String host)
setOSDTPort
public void setOSDTPort(int port)
setTestHost
public void setTestHost(java.lang.String host)
setTestPort
public void setTestPort(int port)
initialize
public void initialize()
throws java.lang.Exception
- Overrides:
initialize in class WorkerThread
- Throws:
java.lang.Exception
connect
public void connect(java.lang.String testHost,
int testPort,
java.lang.String osdtHost,
int osdtPort)
throws java.lang.Exception
- Throws:
java.lang.Exception
pumpCmd2PH
protected double pumpCmd2PH(double backgroundPH,
double pumpSpeedRPM)
- compute new pH from pump command
updatePH
protected void updatePH()
- Update model pH inputs and outputs
rpm2VEL
protected double rpm2VEL(double thrusterRPM)
- compute new water velocity (vx) from thruster command
updateCurrent
protected void updateCurrent()
- Update model water velocity (current) inputs and outputs
updateConfig
public void updateConfig()
readConnectors
public void readConnectors()
doWorkerAction
public void doWorkerAction()
- Specified by:
doWorkerAction in class WorkerThread
shutdown
public void shutdown()
- Overrides:
shutdown in class WorkerThread
printHelp
public void printHelp()
getChannel
public Model.ChannelDefinition getChannel(int channelID)
getParameterNames
public java.util.Vector getParameterNames()
getChannelValue
public java.lang.Number getChannelValue(int channelID)
getChannelValue
public java.lang.String getChannelValue(java.lang.String channelName)
configure
public void configure(java.lang.String[] args)
throws java.lang.Exception
- Throws:
java.lang.Exception
main
public static void main(java.lang.String[] args)
Copyright © 2003 MBARI.
The Monterey Bay Aquarium Research Institute (MBARI) provides this documentation and code "as is", with no warranty, express or implied, of its quality or consistency. It is provided without support and without obligation on the part of MBARI to assist in its use, correction, modification, or enhancement.