/****************************************************************************/
/* Copyright (c) 2000 MBARI                                                 */
/* MBARI Proprietary Information. All rights reserved.                      */
/****************************************************************************/
/* Summary  :                                                               */
/* Filename : StreamDriverTask.cc                                         */
/* Author   :                                                               */
/* Project  :                                                               */
/* Version  : 1.0                                                           */
/* Created  : 02/07/2000                                                    */
/* Modified :                                                               */
/* Archived :                                                               */
/****************************************************************************/
/* Modification History:                                                    */
/****************************************************************************/
#include <string.h>
#include "StreamDriverTask.h"
#include "Exception.h"
#include "Syslog.h"

StreamDriverTask::StreamDriverTask(const char *name,
				   SerialDeviceDriver *driver)
  : Task(name)
{
  _driver = driver;
  _driver->setContainer(this);

  if (_driver->startup() != DeviceIF::Ok) {
    throw Exception("StreamDriverTask::StreamDriverTask() - "
		    "device->startup() failed");
  }
}


StreamDriverTask::~StreamDriverTask()
{
}


void StreamDriverTask::run()
{
  Boolean debug = False;
  char errorBuf[512];

  dprintf("StreamDriverTask::run() - start main loop");

  while (True) {

    _driver->acquire();
  }
}



