|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||
java.lang.Objectjava.rmi.server.RemoteObject
java.rmi.server.RemoteServer
java.rmi.server.UnicastRemoteObject
org.mbari.siam.core.DeviceService
org.mbari.siam.core.BaseInstrumentService
org.mbari.siam.core.PolledInstrumentService
org.mbari.siam.devices.wetlabs.WetLabsECO
public class WetLabsECO
Implements instrument service for WET Labs ECO instrument. Instrument begins emitting samples at power-up or when the "$run" command is issued; the number of samples that are emitted can be modified by configuration. Thus the instrument has both "streaming" and "polled" characteristics. This implementation extends the PolledInstrumentService class.
| Nested Class Summary | |
|---|---|
protected class |
WetLabsECO.Attributes
Configurable attributes |
| Field Summary | |
|---|---|
protected WetLabsECO.Attributes |
_attributes
|
| Fields inherited from class org.mbari.siam.core.BaseInstrumentService |
|---|
_defaultSamplerTask, _defaultSampleScheduleName, _errorCache, _instrumentAttributes, _lastPacket, _lastSensorDataPacket, _maxSampleBytes, _messagePacket, _nPowerRequests, _nWakeRequests, _packetLog, _recordType, _running, _samplerWakeupTime, _scheduleKey, _schedules, _sensorDataPacket, _turbinator, MAX_BASE_RECORDTYPE, RECORDTYPE_DEFAULT, RECORDTYPE_METADATA, RECORDTYPE_UNDEFINED |
| Fields inherited from class org.mbari.siam.core.DeviceService |
|---|
_fromDevice, _instrumentPort, _nodeProperties, _parentNode, _regEntry, _sandBox, _serviceCachePath, _serviceName, _servicePropertiesPath, _serviceXMLPath, _toDevice, CACHED_PROPERTIES_FILENAME, PROPERTIES_FILENAME, XML_FILENAME |
| Fields inherited from class java.rmi.server.RemoteObject |
|---|
ref |
| Fields inherited from interface org.mbari.siam.distributed.Device |
|---|
ERROR, INITIAL, INSTRUMENT_STATE, MDATA_ALL, OK, SAFE, SAMPLING, SERVICE_ATTRIBUTES, SERVICE_CACHE, SERVICE_PROPERTIES, SERVICE_XML, SHUTDOWN, SLEEPING, SUSPEND, UNKNOWN |
| Constructor Summary | |
|---|---|
WetLabsECO()
Allocates a new WetLabsECO |
|
| Method Summary | |
|---|---|
protected ScheduleSpecifier |
createDefaultSampleSchedule()
Return specifier for default sampling schedule. |
protected void |
doCommand(java.lang.String command)
Execute specified command, don't verify response. |
protected void |
doCommand(java.lang.String cmd,
java.lang.String response)
Method to send commands to the instrument. |
protected void |
doSoftBreak()
Issue "soft break" until instrument goes into command mode. |
protected void |
enterCommandMode()
Put instrument into command mode. |
void |
enterSafeMode()
Enter mode for resource-restricted environement. |
DevicePacketParser |
getDevicePacketParser()
Get instruments' DevicePacketParser, which returns JDDAC records. |
protected byte[] |
getInstrumentStateMetadata()
Get instrument state information from the device itself. |
SerialPortParameters |
getSerialPortParameters()
Return parameters to use on serial port. |
protected PowerPolicy |
initCommunicationPowerPolicy()
Return initial value of communication power policy. |
protected int |
initCurrentLimit()
Specify current limit in increments of 120 mA upto 11880 mA. |
protected void |
initializeInstrument()
Called by the framework to initialize the instrument prior to sampling. |
protected PowerPolicy |
initInstrumentPowerPolicy()
Return initial value of instrument power policy. |
protected int |
initInstrumentStartDelay()
Specify startup delay (millisec) |
protected int |
initMaxSampleBytes()
Specify maximum bytes in raw sample. |
protected byte[] |
initPromptString()
Specify prompt string. |
protected byte[] |
initSampleTerminator()
Specify sample terminator. |
protected byte[] |
mkCmd(java.lang.String cmd)
Utility method to construct a message of the form: - |
protected void |
powerOnCallback()
Called after power is applied; return when instrument is ready for use. |
protected void |
requestSample()
Request a data sample from instrument. |
void |
setClock()
Set instrument's time and date. |
void |
setClock(long t)
Not implemented. |
protected java.lang.String |
shutdownInstrument()
Return message regarding power-cycling. |
int |
test()
Run device's self-test routine. |
| Methods inherited from class org.mbari.siam.core.PolledInstrumentService |
|---|
acquire, doScheduledTask, setAttributes |
| Methods inherited from class java.rmi.server.UnicastRemoteObject |
|---|
clone, exportObject, exportObject, exportObject, unexportObject |
| Methods inherited from class java.rmi.server.RemoteServer |
|---|
getClientHost, getLog, setLog |
| Methods inherited from class java.rmi.server.RemoteObject |
|---|
equals, getRef, hashCode, toString, toStub |
| Methods inherited from class java.lang.Object |
|---|
finalize, getClass, notify, notifyAll, wait, wait, wait |
| Methods inherited from interface org.mbari.siam.distributed.Instrument |
|---|
acquireSample, addDefaultPacketFilters, annotate, cacheProperties, clearDefaultPacketFilters, clearPropertiesCache, disableSummary, enableSummary, getDefaultPacketFilters, getLastSample, getPackets, getPackets, getParser, getPortDiagnostics, getPortDiagnosticsSummary, getProperties, getProperty, getSampleSchedule, getSchedules, resetPortDiagnostics, setProperty, summaryEnabled |
| Methods inherited from interface org.mbari.siam.distributed.Device |
|---|
getChildren, getCommPortName, getFrameworkVersion, getId, getLocation, getMetadata, getName, getParent, getSamplingCount, getSamplingErrorCount, getSamplingRetryCount, getStatus, host, powerOff, powerOn, prepareToRun, resume, shutdown, suspend |
| Methods inherited from interface org.mbari.siam.distributed.DeviceServiceIF |
|---|
getName |
| Methods inherited from interface org.mbari.siam.core.ScheduleOwner |
|---|
addSchedule, getAllSchedules, getScheduleKey, removeAllSchedules, removeSchedule, resumeSchedule, sleepingUntil, suspendSchedule, syncSchedule |
| Field Detail |
|---|
protected WetLabsECO.Attributes _attributes
| Constructor Detail |
|---|
public WetLabsECO()
throws java.rmi.RemoteException
WetLabsECO
java.rmi.RemoteException - .| Method Detail |
|---|
protected int initInstrumentStartDelay()
initInstrumentStartDelay in class BaseInstrumentServiceprotected byte[] initPromptString()
initPromptString in class BaseInstrumentServiceprotected byte[] initSampleTerminator()
initSampleTerminator in class BaseInstrumentServiceprotected int initMaxSampleBytes()
initMaxSampleBytes in class BaseInstrumentServiceprotected int initCurrentLimit()
initCurrentLimit in class BaseInstrumentServiceprotected PowerPolicy initInstrumentPowerPolicy()
initInstrumentPowerPolicy in class BaseInstrumentServiceprotected PowerPolicy initCommunicationPowerPolicy()
initCommunicationPowerPolicy in class BaseInstrumentService
protected ScheduleSpecifier createDefaultSampleSchedule()
throws ScheduleParseException
createDefaultSampleSchedule in class PolledInstrumentServiceScheduleParseException
public SerialPortParameters getSerialPortParameters()
throws gnu.io.UnsupportedCommOperationException
getSerialPortParameters in class DeviceServicegnu.io.UnsupportedCommOperationException
protected void initializeInstrument()
throws InitializeException,
java.lang.Exception
initializeInstrument in class BaseInstrumentServiceInitializeException
java.lang.Exception
public void setClock()
throws NotSupportedException
setClock in interface InstrumentsetClock in class BaseInstrumentServiceNotSupportedException
protected void requestSample()
throws TimeoutException,
java.lang.Exception
PolledInstrumentService
requestSample in class PolledInstrumentServiceTimeoutException - thrown if no data is detected for a period of twice the
_preemptionTime
java.lang.Exception - not thrown
see setNumSensors
see _preemptionTimeprotected byte[] getInstrumentStateMetadata()
getInstrumentStateMetadata in class BaseInstrumentServicepublic void setClock(long t)
setClock in interface InstrumentsetClock in class BaseInstrumentServicet -
protected void doCommand(java.lang.String cmd,
java.lang.String response)
throws java.lang.Exception
cmd - Command string to send
java.lang.Exception - thrown if the method fails to send the command.
protected void doCommand(java.lang.String command)
throws java.lang.Exception
java.lang.Exception
protected void enterCommandMode()
throws java.lang.Exception
java.lang.Exception
protected void doSoftBreak()
throws java.lang.Exception
java.lang.Exceptionprotected void powerOnCallback()
powerOnCallback in class BaseInstrumentServiceprotected byte[] mkCmd(java.lang.String cmd)
and returns this as a byte array for transmission"cmd + \r"
cmd - basic command string to construct
public int test()
Device
test in interface Device
public void enterSafeMode()
throws java.lang.Exception
enterSafeMode in interface Safeablejava.lang.Exception
protected java.lang.String shutdownInstrument()
throws java.lang.Exception
shutdownInstrument in class BaseInstrumentServicejava.lang.Exception
public DevicePacketParser getDevicePacketParser()
throws NotSupportedException
BaseInstrumentService
getDevicePacketParser in class BaseInstrumentServiceNotSupportedException
|
||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||