org.mbari.siam.core
Class NVTDevicePort

java.lang.Object
  extended by org.mbari.siam.core.DevicePort
      extended by org.mbari.siam.core.SerialDevicePort
          extended by org.mbari.siam.core.NVTDevicePort
All Implemented Interfaces:
gnu.io.CommPortOwnershipListener, java.util.EventListener

public class NVTDevicePort
extends SerialDevicePort

NVTDevicePort extends SerialDevicePort for an RFC2217 compliant serial device. Put into core package because it inherits from core.SerialDevicePort.


Field Summary
protected  NVTSerialPort _nvtSerialPort
           
protected  java.lang.String _portId
           
 
Fields inherited from class org.mbari.siam.core.DevicePort
_service
 
Fields inherited from interface gnu.io.CommPortOwnershipListener
PORT_OWNED, PORT_OWNERSHIP_REQUESTED, PORT_UNOWNED
 
Constructor Summary
NVTDevicePort(int index, java.lang.String portId, java.lang.String portName, PowerPort powerPort, java.lang.String jar, DeviceService service, CommsMode commsMode)
           
 
Method Summary
 void addCommPortListener()
          Null function.
 void closeComms()
          Close the serial port
 void createInstrumentPort()
          Create the SerialInstrumentPort
 void openComms(int baudRate)
          Open the serial port at a specified baud rate
 
Methods inherited from class org.mbari.siam.core.SerialDevicePort
openComms, ownershipChange
 
Methods inherited from class org.mbari.siam.core.DevicePort
equals, getCommsMode, getDeviceService, getIndex, getPortName, getPowerPort, hashCode, hasPowerPort, hasPuck, powerDownPort, powerUpPort, setCommsMode, setPowerPort, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Field Detail

_nvtSerialPort

protected NVTSerialPort _nvtSerialPort

_portId

protected java.lang.String _portId
Constructor Detail

NVTDevicePort

public NVTDevicePort(int index,
                     java.lang.String portId,
                     java.lang.String portName,
                     PowerPort powerPort,
                     java.lang.String jar,
                     DeviceService service,
                     CommsMode commsMode)
Method Detail

openComms

public void openComms(int baudRate)
               throws java.net.UnknownHostException,
                      java.io.IOException,
                      java.lang.Exception
Open the serial port at a specified baud rate

Overrides:
openComms in class SerialDevicePort
Throws:
java.net.UnknownHostException
java.io.IOException
java.lang.Exception

closeComms

public void closeComms()
Close the serial port

Overrides:
closeComms in class SerialDevicePort

createInstrumentPort

public void createInstrumentPort()
                          throws InitializeException
Create the SerialInstrumentPort

Overrides:
createInstrumentPort in class SerialDevicePort
Throws:
InitializeException

addCommPortListener

public void addCommPortListener()
Null function. We don't support concept of ownership

Overrides:
addCommPortListener in class SerialDevicePort


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.