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.

195 lines
4.9 KiB

​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
​
  1. //----------------------------------------------------------------------------
  2. // Dr.Frucht Systems Ltd.
  3. // Copyright © 2000-2016. All Rights Reserved.
  4. // Version 2.0 3/30/2016
  5. // Last modification: 3/30/2016
  6. // PROJECT:
  7. // SUBSYSTEM:
  8. // FILE: detectorStructures.h
  9. // AUTHOR: gagua
  10. // OVERVIEW
  11. // ~~~~~~~~
  12. // Header file of detectorStructures.h
  13. //----------------------------------------------------------------------------
  14. //
  15. #ifndef __ALG_DETECTOR_STRUCTURES_HEADER__
  16. #define __ALG_DETECTOR_STRUCTURES_HEADER__
  17. #include "../../components/base/basicTypes.h"
  18. #define LGS_MIRROR_BLANK_RANGE 20
  19. #define LGS_BLIND_TYPE_MR_ENTER 0L
  20. #define LGS_BLIND_TYPE_MR_EXIT 1L
  21. #define LGS_BLIND_TYPE_180_DEGRESE_ENTER 2L
  22. #define LGS_BLIND_TYPE_FS_ENTER 3L
  23. #define LGS_BLIND_TYPE_FS_EXIT 4L
  24. #define LGS_BLIND_TYPE_PD_ENTER 5L
  25. #define LGS_BLIND_TYPE_PD_EXIT 6L
  26. #define LGS_BLIND_TYPE_180_DEGRESE_EXIT 7L
  27. #define LGS_BLIND_TYPE_FAR_FOG_ENTER 8L
  28. #define LGS_BLIND_TYPE_FAR_FOG_EXIT 9L
  29. #define LGS_BLIND_TYPE_NEAR_FOG_ENTER 10L
  30. #define LGS_BLIND_TYPE_NEAR_FOG_EXIT 11L
  31. typedef struct S_QPD
  32. {
  33. U8 nOffset;
  34. U8 nOrder;
  35. } QPD, *LPQPD;
  36. typedef struct S_SAF
  37. {
  38. INT16 nMax;
  39. INT16 nMin;
  40. } SAF, *LPSAF;
  41. typedef struct S_HW_PARAMS
  42. {
  43. uint32_t Q_shift : 9;
  44. uint32_t B_shift : 12;
  45. uint32_t AutostartMotors : 1;
  46. uint32_t SignalSimulator : 1;
  47. uint32_t BBinterlace : 3;
  48. uint32_t Spike_TH : 2;
  49. uint32_t Sunbit_filter : 1;
  50. uint32_t popo : 3;
  51. //---------------------------------
  52. uint16_t HorizontalFreq;
  53. uint16_t VerticalFreq;
  54. //---------------------------------
  55. uint16_t MirrorScanCount; // Encoder Counts ?
  56. uint16_t BaseScanCount;
  57. //---------------------------------
  58. uint8_t MirrorsCount;
  59. uint8_t DetectorsCount;
  60. //---------------------------------
  61. uint16_t isMaster : 1;
  62. uint16_t LaserPulsesOn : 1;
  63. uint16_t VerticalMotorOn : 1;
  64. uint16_t HorizontalMotorOn : 1;
  65. uint16_t BuildThByCore : 1;
  66. uint16_t DryContactMode1 : 1;
  67. uint16_t DryContactStatus1 : 1;
  68. uint16_t DryContactMode2 : 1;
  69. uint16_t DryContactStatus2 : 1;
  70. uint16_t QQinterlace : 3;
  71. uint16_t TGZ_canENA : 1;
  72. uint16_t TGZ_canBus : 1;
  73. uint16_t TGZ_divider : 2;
  74. //----------------------------------
  75. uint16_t TGZ_ParamQ;
  76. //----------------------------------
  77. uint16_t TGZ_ParamB;
  78. //----------------------------------
  79. uint16_t TGZ_canSRC;
  80. uint16_t TGZ_canDST;
  81. } HW_PARAMS, *PHW_PARAMS;
  82. typedef struct S_LGS_2D_SETTINGS
  83. {
  84. LONG nOrder;
  85. LONG nOffset;
  86. LONG nDelta;
  87. LONG nWidth;
  88. LONG nFlip;
  89. LONG nShift;
  90. LONG nSun;
  91. } LGS_2D_SETTINGS, *PLGS_2D_SETTINGS;
  92. typedef struct S_LGS_2D_PARAMETERS
  93. {
  94. uint16_t nOrder;
  95. uint16_t nOffset;
  96. uint16_t nDelta;
  97. uint16_t nWidth;
  98. uint16_t nFlip;
  99. uint16_t nSun;
  100. uint8_t bSST;
  101. } LGS_2D_PARAMETERS, *PLGS_2D_PARAMETERS;
  102. // typedef struct S_RELAY_PARAMETERS {
  103. // uint8_t bAuto; // allow auto relay
  104. // uint8_t bNormallyClose;
  105. // uint16_t nAutoDelay; // in 0.1 sec (0,0 .. 3000,0 sec)
  106. // } RELAY_PARAMETERS, *PRELAY_PARAMETERS;
  107. typedef struct S_LGS_3D_PARAMETERS
  108. {
  109. uint8_t nOrder;
  110. uint8_t nOffset;
  111. uint8_t nDelta;
  112. uint8_t nSun;
  113. uint8_t bSST;
  114. uint16_t nFlip; // For Quick models (pls30) must be up to 1024
  115. uint32_t nWidth; // With future devices may gain big numbers
  116. /* 3D LRF Specific */
  117. uint8_t nGPointSamples;
  118. union
  119. {
  120. uint8_t flags_binary[sizeof(HW_PARAMS)];
  121. HW_PARAMS flags;
  122. };
  123. } LGS_3D_PARAMETERS, *PLGS_3D_PARAMETERS;
  124. typedef struct S_TARGET
  125. {
  126. uint8_t bType; // target type
  127. uint32_t nAngle; // target angle
  128. // BOOL bSent;
  129. #ifdef LOW_BIT_DATA
  130. uint8_t nRange; // target range
  131. uint16_t nWidth; // target width
  132. #else
  133. uint16_t nRange; // target range
  134. uint32_t nWidth; // target width
  135. #endif
  136. } TARGET, *PTARGET;
  137. typedef struct S_TARGET_EX
  138. {
  139. TARGET target;
  140. uint8_t nRemoveTime; // time when target shuld be removed as false alarm
  141. // uint8_t nDetectionTime; // time when begins comparison with other incoming targets
  142. uint8_t nLevel; // current SST level of target
  143. uint8_t bFlags;
  144. uint32_t nAngleMin; // scan2scan area left order in board angle units
  145. uint32_t nAngleMax; // scan2scan area right order in board angle units
  146. #ifdef LOW_BIT_DATA
  147. uint8_t nRangeMin; // scan2scan area bottom offset in board range units
  148. uint8_t nRangeMax; // scan2scan area top offset in board range units
  149. #else
  150. uint16_t nRangeMin; // scan2scan area bottom offset in board range units
  151. uint16_t nRangeMax; // scan2scan area top offset in board range units
  152. #endif
  153. } TARGET_EX, *PTARGET_EX, *LPTARGET_EX;
  154. typedef struct RAY
  155. {
  156. uint8_t bType;
  157. #ifdef LOW_BIT_DATA
  158. uint8_t nMin;
  159. uint8_t nMax;
  160. #else
  161. uint16_t nMin;
  162. uint16_t nMax;
  163. #endif
  164. } RAY, *LPRAY;
  165. typedef struct RAY_LINE
  166. {
  167. uint32_t nCount;
  168. LPRAY lpShadow;
  169. } RAY_LINE, *LPRAY_LINE;
  170. typedef struct HZ_POLYGON
  171. {
  172. U8 bType;
  173. uint32_t wCount;
  174. // LGS::LPHZ_POINT lpPoint;
  175. } HZ_POLYGON, *LPHZ_POLYGON;
  176. #endif