You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
56 lines
1.3 KiB
56 lines
1.3 KiB
//----------------------------------------------------------------------------
|
|
// Laser Guard Ltd.
|
|
// Copyright © 2000-2002. All Rights Reserved.
|
|
// Version 1.0 01/01/2000
|
|
// Last modification: 08/10/2003
|
|
// PROJECT:
|
|
// SUBSYSTEM:
|
|
// FILE: SocketLGS.h
|
|
// AUTHOR: Sergey Chizhevskiy
|
|
// OVERVIEW
|
|
// ~~~~~~~~
|
|
// Header file of SocketLGS.h
|
|
//----------------------------------------------------------------------------
|
|
#ifndef __SOCKET__SINGLE__LGS__H__INCLUDED__
|
|
#define __SOCKET__SINGLE__LGS__H__INCLUDED__
|
|
|
|
#if _MSC_VER > 1000
|
|
#pragma once
|
|
#endif
|
|
|
|
#include "..\..\LgLib\Comm\RS485.h"
|
|
#include "Socket.h"
|
|
#include "..\..\LgLib\Thread.h"
|
|
#include "EventQueue.h"
|
|
|
|
class CSocketLGS :
|
|
public CSocket,
|
|
public CLgThread
|
|
{
|
|
public:
|
|
CSocketLGS();
|
|
virtual ~CSocketLGS();
|
|
|
|
public:
|
|
BOOL Create( CSensorArray* pSensorArray, LPCTSTR pPort );
|
|
BOOL DeviceAttach(CDeviceLGSs *pDevice);
|
|
BOOL DeviceDetach();
|
|
|
|
public:
|
|
virtual void CommandLoopStart();
|
|
virtual void CommandLoopStop();
|
|
|
|
private:
|
|
virtual DWORD ThreadProc();
|
|
virtual BOOL Stop( BOOL bWaitForComplete );
|
|
|
|
private:
|
|
BYTE m_pBuffer[10];
|
|
DWORD m_nCount;
|
|
BOOL m_bRunning;
|
|
HANDLE m_hEvent;
|
|
CDeviceLGSs *m_pDevice;
|
|
CConnectionRS485 m_Connection;
|
|
};
|
|
|
|
#endif
|