Old fashion design for PC-104
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.

48 lines
1020 B

4 years ago
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. //----------------------------------------------------------------------------
  2. // Laser Guard Ltd.
  3. // Copyright � 2000-2002. All Rights Reserved.
  4. // Version 1.0 19/04/2000
  5. // Last modification: 08/10/2003
  6. // Project Intruder Position Indicator
  7. // SUBSYSTEM: Alarm
  8. // FILE: Alarm.h
  9. // AUTHOR: Chizhevskiy Sergey
  10. // OVERVIEW
  11. // ~~~~~~~~
  12. // Header file of class CAlarm
  13. //----------------------------------------------------------------------------
  14. #ifndef __ALARM__H__INCLUDED__
  15. #define __ALARM__H__INCLUDED__
  16. #include "..\lglib\lgalarm.h"
  17. class CAlarm
  18. {
  19. public:
  20. CAlarm();
  21. ~CAlarm();
  22. public:
  23. BOOL Create( LPCTSTR pCommPort, BOOL bDelay, INT nValue );
  24. void Beep();
  25. void Enable(BOOL fEnable);
  26. void End( BOOL bOnlyCommAlarm );
  27. void Begin();
  28. public:
  29. void OnTimer();
  30. private:
  31. HANDLE m_hCommPort;
  32. BOOL m_fEnabled;
  33. CLgAlarm m_Alarm;
  34. private:
  35. BOOL m_bDelay;
  36. BOOL m_bDelayStart;
  37. INT m_nDelayValue;
  38. DWORD m_dwDelayTime;
  39. };
  40. #endif