Source code of Windows XP (NT5)
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.

1460 lines
51 KiB

  1. /*
  2. * OPOS.H
  3. *
  4. *
  5. *
  6. */
  7. // BUGBUG !!! need to make all GUIDs genuine !!!
  8. /*
  9. * These GUIDs identify the HID OPOS server and it's interface
  10. *
  11. */
  12. DEFINE_GUID( GUID_HID_OPOS_SERVER, 0x4AFA3D51L, 0x74A7, 0x11d0, 0xbe, 0x5e, 0x00, 0xA0, 0xC0, 0x06, 0x28, 0x60 );
  13. DEFINE_OLEGUID( IID_HID_OPOS_SERVER, 0x000000a1, 0, 0); // BUGBUG
  14. /*
  15. * These GUIDs identify the generic OPOS control and it's interface.
  16. *
  17. */
  18. DEFINE_OLEGUID( IID_OPOS_GENERIC_CONTROL, 0x000000a2, 0, 0); // BUGBUG
  19. /*
  20. * Interface declaration for HID OPOS Server
  21. */
  22. DECLARE_INTERFACE_(IOPOSService, IClassFactory)
  23. {
  24. /*
  25. * IUnknown methods
  26. */
  27. STDMETHOD(QueryInterface)(REFIID riid, LPVOID FAR* ppvObj) = 0;
  28. STDMETHOD_(ULONG,AddRef)(void) = 0;
  29. STDMETHOD_(ULONG,Release)(void) = 0;
  30. /*
  31. * IClassFactory methods
  32. */
  33. STDMETHOD(CreateInstance)(LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppvObj) = 0;
  34. STDMETHOD(LockServer)(int lock) = 0;
  35. /*
  36. * IOPOSService methods
  37. */
  38. STDMETHOD_(LONG, CheckHealth)(LONG Level) = 0;
  39. STDMETHOD_(LONG, Claim)(LONG Timeout) = 0;
  40. STDMETHOD_(LONG, ClearInput)() = 0;
  41. STDMETHOD_(LONG, ClearOutput)() = 0;
  42. STDMETHOD_(LONG, Close)() = 0;
  43. STDMETHOD_(LONG, COFreezeEvents)(BOOL Freeze) = 0;
  44. STDMETHOD_(LONG, DirectIO)(LONG Command, LONG* pData, BSTR* pString) = 0;
  45. STDMETHOD_(LONG, OpenService)(BSTR DeviceClass, BSTR DeviceName, LPDISPATCH pDispatch) = 0;
  46. // STDMETHOD_(LONG, Release)() = 0; // BUGBUG - override IUnknown ?
  47. STDMETHOD_(LONG, GetPropertyNumber)(LONG PropIndex) = 0;
  48. STDMETHOD_(BSTR, GetPropertyString)(LONG PropIndex) = 0;
  49. STDMETHOD_(void, SetPropertyNumber)(LONG PropIndex, LONG Number) = 0;
  50. STDMETHOD_(void, SetPropertyString)(LONG PropIndex, BSTR String) = 0;
  51. // BUGBUG - + Get/Set type methods
  52. // BUGBUG - + events
  53. };
  54. /*
  55. * Interface declaration for generic HID OPOS Control
  56. */
  57. DECLARE_INTERFACE_(IOPOSControl, IClassFactory)
  58. {
  59. /*
  60. * IUnknown methods
  61. */
  62. STDMETHOD(QueryInterface)(REFIID riid, LPVOID FAR* ppvObj) = 0;
  63. STDMETHOD_(ULONG,AddRef)(void) = 0;
  64. STDMETHOD_(ULONG,Release)(void) = 0;
  65. /*
  66. * IClassFactory methods
  67. */
  68. STDMETHOD(CreateInstance)(LPUNKNOWN pUnkOuter, REFIID riid, LPVOID FAR* ppvObj) = 0;
  69. STDMETHOD(LockServer)(int lock) = 0;
  70. /*
  71. * IOPOSControl methods
  72. */
  73. STDMETHOD_(LONG, Open)(BSTR DeviceName) = 0;
  74. STDMETHOD_(LONG, Close)() = 0;
  75. STDMETHOD_(LONG, CheckHealth)(LONG Level) = 0;
  76. STDMETHOD_(LONG, Claim)(LONG Timeout) = 0;
  77. STDMETHOD_(LONG, ClearInput)() = 0;
  78. STDMETHOD_(LONG, ClearOutput)() = 0;
  79. STDMETHOD_(LONG, DirectIO)(LONG Command, LONG* pData, BSTR* pString) = 0;
  80. // STDMETHOD_(LONG, Release)() = 0; // BUGBUG overrides IUnknown ?
  81. STDMETHOD_(void, SOData)(LONG Status) = 0;
  82. STDMETHOD_(void, SODirectIO)(LONG EventNumber, LONG* pData, BSTR* pString) = 0;
  83. STDMETHOD_(void, DirectIOEvent)(LONG EventNumber, LONG* pData, BSTR* pString) = 0;
  84. STDMETHOD_(void, SOError)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  85. // BUGBUG - moved to sub-ifaces STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  86. STDMETHOD_(void, SOOutputComplete)(LONG OutputID) = 0;
  87. STDMETHOD_(void, OutputCompleteEvent)(LONG OutputID) = 0;
  88. STDMETHOD_(void, SOStatusUpdate)(LONG Data) = 0;
  89. // BUGBUG - moved to sub-ifaces STDMETHOD_(void, StatusUpdateEvent)(LONG Data) = 0;
  90. STDMETHOD_(LONG, SOProcessID)() = 0;
  91. };
  92. /*
  93. * Interface declaration for specific control classes.
  94. * Each inherits from the generic control interface class.
  95. */
  96. DECLARE_INTERFACE_(IOPOSBumpBar, IOPOSControl)
  97. {
  98. STDMETHOD_(LONG, BumpBarSound)(LONG Units, LONG Frequency, LONG Duration, LONG NumberOfCycles, LONG InterSoundWait) = 0;
  99. STDMETHOD_(LONG, SetKeyTranslation)(LONG Units, LONG ScanCode, LONG LogicalKey) = 0;
  100. };
  101. DECLARE_INTERFACE_(IOPOSCashChanger, IOPOSControl)
  102. {
  103. // methods
  104. STDMETHOD_(LONG, DispenseCash)(BSTR CashCounts) = 0;
  105. STDMETHOD_(LONG, DispenseChange)(LONG Amount) = 0;
  106. STDMETHOD_(LONG, ReadCashCounts)(BSTR* pCashCounts, BOOL* pDiscrepancy) = 0;
  107. // events
  108. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  109. };
  110. DECLARE_INTERFACE_(IOPOSCashDrawer, IOPOSControl)
  111. {
  112. // methods
  113. STDMETHOD_(LONG, OpenDrawer)() = 0;
  114. STDMETHOD_(LONG, WaitForDrawerClose)(LONG BeepTimeout, LONG BeepFrequency, LONG BeepDuration, LONG BeepDelay) = 0;
  115. // events
  116. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  117. };
  118. DECLARE_INTERFACE_(IOPOSCoinDispenser, IOPOSControl)
  119. {
  120. // methods
  121. STDMETHOD_(LONG, DispenseChange)(LONG Amount) = 0;
  122. // events
  123. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  124. };
  125. DECLARE_INTERFACE_(IOPOSFiscalPrinter, IOPOSControl)
  126. {
  127. // methods
  128. STDMETHOD_(LONG, BeginFiscalDocument)(LONG DocumentAmount) = 0;
  129. STDMETHOD_(LONG, BeginFiscalReceipt)(BOOL PrintHeader) = 0;
  130. STDMETHOD_(LONG, BeginFixedOutput)(LONG Station, LONG DocumentType) = 0;
  131. STDMETHOD_(LONG, BeginInsertion)(LONG Timeout) = 0;
  132. STDMETHOD_(LONG, BeginItemList)(LONG VatID) = 0;
  133. STDMETHOD_(LONG, BeginNonFiscal)() = 0;
  134. STDMETHOD_(LONG, BeginRemoval)(LONG Timeout) = 0;
  135. STDMETHOD_(LONG, BeginTraining)() = 0;
  136. STDMETHOD_(LONG, ClearError)() = 0;
  137. STDMETHOD_(LONG, EndFiscalDocument)() = 0;
  138. STDMETHOD_(LONG, EndFiscalReceipt)(BOOL PrintHeader) = 0;
  139. STDMETHOD_(LONG, EndFixedOutput)() = 0;
  140. STDMETHOD_(LONG, EndInsertion)() = 0;
  141. STDMETHOD_(LONG, EndItemList)() = 0;
  142. STDMETHOD_(LONG, EndNonFiscal)() = 0;
  143. STDMETHOD_(LONG, EndRemoval)() = 0;
  144. STDMETHOD_(LONG, EndTraining)() = 0;
  145. STDMETHOD_(LONG, GetData)(LONG DataItem, LONG* OptArgs, BSTR* Data) = 0;
  146. STDMETHOD_(LONG, GetDate)(BSTR* Date) = 0;
  147. STDMETHOD_(LONG, GetTotalizer)(LONG VatID, LONG OptArgs, BSTR* Data) = 0;
  148. STDMETHOD_(LONG, GetVatEntry)(LONG VatID, LONG OptArgs, LONG* VatRate) = 0;
  149. STDMETHOD_(LONG, PrintDuplicateReceipt)() = 0;
  150. STDMETHOD_(LONG, PrintFiscalDocumentLine)(BSTR DocumentLine) = 0;
  151. STDMETHOD_(LONG, PrintFixedOutput)(LONG DocumentType, LONG LineNumber, BSTR Data) = 0;
  152. STDMETHOD_(LONG, PrintNormal)(LONG Station, BSTR Data) = 0;
  153. STDMETHOD_(LONG, PrintPeriodicTotalsReport)(BSTR Date1, BSTR Date2) = 0;
  154. STDMETHOD_(LONG, PrintPowerLossReport)() = 0;
  155. STDMETHOD_(LONG, PrintRecItem)(BSTR Description, CURRENCY Price, LONG Quantity, LONG VatInfo, CURRENCY OptUnitPrice, BSTR UnitName) = 0;
  156. STDMETHOD_(LONG, PrintRecItemAdjustment)(LONG AdjustmentType, BSTR Description, CURRENCY Amount, LONG VatInfo) = 0;
  157. STDMETHOD_(LONG, PrintRecMessage)(BSTR Message) = 0;
  158. STDMETHOD_(LONG, PrintRecNotPaid)(BSTR Description, CURRENCY Amount) = 0;
  159. STDMETHOD_(LONG, PrintRecRefund)(BSTR Description, CURRENCY Amount, LONG VatInfo) = 0;
  160. STDMETHOD_(LONG, PrintRecSubtotal)(CURRENCY Amount) = 0;
  161. STDMETHOD_(LONG, PrintRecSubtotalAdjustment)(LONG AdjustmentType, BSTR Description, CURRENCY Amount) = 0;
  162. STDMETHOD_(LONG, PrintRecTotal)(CURRENCY Total, CURRENCY Payment, BSTR Description) = 0;
  163. STDMETHOD_(LONG, PrintRecVoid)(BSTR Description) = 0;
  164. STDMETHOD_(LONG, PrintRecVoidItem)(BSTR Description, CURRENCY Amount, LONG Quantity, LONG AdjustmentType, CURRENCY Adjustment, LONG VatInfo) = 0;
  165. STDMETHOD_(LONG, PrintReport)(LONG ReportType, BSTR StartNum, BSTR EndNum) = 0;
  166. STDMETHOD_(LONG, PrintXReport)() = 0;
  167. STDMETHOD_(LONG, PrintZReport)() = 0;
  168. STDMETHOD_(LONG, ResetPrinter)() = 0;
  169. STDMETHOD_(LONG, SetDate)(BSTR Date) = 0;
  170. STDMETHOD_(LONG, SetHeaderLine)(LONG LineNumber, BSTR Text, BOOL DoubleWidth) = 0;
  171. STDMETHOD_(LONG, SetPOSID)(BSTR POSID, BSTR CashierID) = 0;
  172. STDMETHOD_(LONG, SetStoreFiscalID)(BSTR ID) = 0;
  173. STDMETHOD_(LONG, SetTrailerLine)(LONG LineNumber, BSTR Text, BOOL DoubleWidth) = 0;
  174. STDMETHOD_(LONG, SetVatTable)() = 0;
  175. STDMETHOD_(LONG, SetVatValue)(LONG VatID, BSTR VatValue) = 0;
  176. STDMETHOD_(LONG, VerifyItem)(BSTR ItemName, LONG VatID) = 0;
  177. // events
  178. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  179. STDMETHOD_(void, StatusUpdateEvent)(LONG Data) = 0;
  180. };
  181. DECLARE_INTERFACE_(IOPOSHardTotals, IOPOSControl)
  182. {
  183. // methods
  184. STDMETHOD_(LONG, BeginTrans)() = 0;
  185. STDMETHOD_(LONG, ClaimFile)(LONG HTotalsFile, LONG Timeout) = 0;
  186. STDMETHOD_(LONG, CommitTrans)() = 0;
  187. STDMETHOD_(LONG, Create)(BSTR FileName, LONG* pHTotalsFile, LONG Size, BOOL ErrorDetection) = 0;
  188. STDMETHOD_(LONG, Delete)(BSTR FileName) = 0;
  189. STDMETHOD_(LONG, Find)(BSTR FileName, LONG* pHTotalsFile, LONG* pSize) = 0;
  190. STDMETHOD_(LONG, FindByIndex)(LONG Index, BSTR* pFileName) = 0;
  191. STDMETHOD_(LONG, Read)(LONG HTotalsFile, BSTR* pData, LONG Offset, LONG Count) = 0;
  192. STDMETHOD_(LONG, RecalculateValidationData)(LONG HTotalsFile) = 0;
  193. STDMETHOD_(LONG, ReleaseFile)(LONG HTotalsFile) = 0;
  194. STDMETHOD_(LONG, Rename)(LONG HTotalsFile, BSTR FileName) = 0;
  195. STDMETHOD_(LONG, Rollback)() = 0;
  196. STDMETHOD_(LONG, SetAll)(LONG HTotalsFile, LONG Value) = 0;
  197. STDMETHOD_(LONG, ValidateData)(LONG HTotalsFile) = 0;
  198. STDMETHOD_(LONG, Write)(LONG HTotalsFile, BSTR Data, LONG Offset, LONG Count) = 0;
  199. };
  200. DECLARE_INTERFACE_(IOPOSKeyLock, IOPOSControl)
  201. {
  202. // methods
  203. STDMETHOD_(LONG, WaitForKeylockChange)(LONG KeyPosition, LONG Timeout) = 0;
  204. // events
  205. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  206. };
  207. DECLARE_INTERFACE_(IOPOSLineDisplay, IOPOSControl)
  208. {
  209. // methods
  210. STDMETHOD_(LONG, ClearDescriptors)() = 0;
  211. STDMETHOD_(LONG, ClearText)() = 0;
  212. // BUGBUG conflict ??? STDMETHOD_(LONG, CreateWindow)(LONG ViewportRow, LONG ViewportColumn, LONG ViewportHeight, LONG ViewportWidth, LONG WindowHeight, LONG WindowWidth) = 0;
  213. STDMETHOD_(LONG, DestroyWindow)() = 0;
  214. STDMETHOD_(LONG, DisplayText)(BSTR Data, LONG Attribute) = 0;
  215. STDMETHOD_(LONG, DisplayTextAt)(LONG Row, LONG Column, BSTR Data, LONG Attribute) = 0;
  216. STDMETHOD_(LONG, RefreshWindow)(LONG Window) = 0;
  217. STDMETHOD_(LONG, ScrollText)(LONG Direction, LONG Units) = 0;
  218. STDMETHOD_(LONG, SetDescriptor)(LONG Descriptor, LONG Attribute) = 0;
  219. };
  220. DECLARE_INTERFACE_(IOPOSMICR, IOPOSControl)
  221. {
  222. // methods
  223. STDMETHOD_(LONG, BeginInsertion)(LONG Timeout) = 0;
  224. STDMETHOD_(LONG, BeginRemoval)(LONG Timeout) = 0;
  225. STDMETHOD_(LONG, EndInsertion)() = 0;
  226. STDMETHOD_(LONG, EndRemoval)() = 0;
  227. // events
  228. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  229. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  230. };
  231. DECLARE_INTERFACE_(IOPOSMSR, IOPOSControl)
  232. {
  233. // events
  234. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  235. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  236. };
  237. DECLARE_INTERFACE_(IOPOSPinPad, IOPOSControl)
  238. {
  239. // methods
  240. STDMETHOD_(LONG, BeginEFTTransaction)(BSTR PINPadSystem, LONG TransactionHost) = 0;
  241. STDMETHOD_(LONG, ComputeMAC)(BSTR InMsg, BSTR* pOutMsg) = 0;
  242. STDMETHOD_(LONG, EnablePINEntry)() = 0;
  243. STDMETHOD_(LONG, EndEFTTransaction)(LONG CompletionCode) = 0;
  244. STDMETHOD_(LONG, UpdateKey)(LONG KeyNum, BSTR Key) = 0;
  245. STDMETHOD_(BOOL, VerifyMAC)(BSTR Message) = 0;
  246. // events
  247. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  248. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  249. };
  250. DECLARE_INTERFACE_(IOPOSKeyboard, IOPOSControl)
  251. {
  252. // events
  253. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  254. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  255. };
  256. DECLARE_INTERFACE_(IOPOSPrinter, IOPOSControl)
  257. {
  258. // methods
  259. STDMETHOD_(LONG, BeginInsertion)(LONG Timeout) = 0;
  260. STDMETHOD_(LONG, BeginRemoval)(LONG Timeout) = 0;
  261. STDMETHOD_(LONG, CutPaper)(LONG Percentage) = 0;
  262. STDMETHOD_(LONG, EndInsertion)() = 0;
  263. STDMETHOD_(LONG, EndRemoval)() = 0;
  264. STDMETHOD_(LONG, PrintBarCode)(LONG Station, BSTR Data, LONG Symbology, LONG Height, LONG Width, LONG Alignment, LONG TextPosition) = 0;
  265. STDMETHOD_(LONG, PrintBitmap)(LONG Station, BSTR FileName, LONG Width, LONG Alignment) = 0;
  266. STDMETHOD_(LONG, PrintImmediate)(LONG Station, BSTR Data) = 0;
  267. STDMETHOD_(LONG, PrintNormal)(LONG Station, BSTR Data) = 0;
  268. STDMETHOD_(LONG, PrintTwoNormal)(LONG Stations, BSTR Data1, BSTR Data2) = 0;
  269. STDMETHOD_(LONG, RotatePrint)(LONG Station, LONG Rotation) = 0;
  270. STDMETHOD_(LONG, SetBitmap)(LONG BitmapNumber, LONG Station, BSTR FileName, LONG Width, LONG Alignment) = 0;
  271. STDMETHOD_(LONG, SetLogo)(LONG Location, BSTR Data) = 0;
  272. STDMETHOD_(LONG, TransactionPrint)(LONG Station, LONG Control) = 0;
  273. STDMETHOD_(LONG, ValidateData)(LONG Station, BSTR Data) = 0;
  274. // events
  275. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  276. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  277. };
  278. DECLARE_INTERFACE_(IOPOSRemoteOrderDisplay, IOPOSControl)
  279. {
  280. // methods
  281. STDMETHOD_(LONG, ClearVideo)(LONG Units, LONG Attribute) = 0;
  282. STDMETHOD_(LONG, ClearVideoRegion)(LONG Units, LONG Row, LONG Column, LONG Height, LONG Width, LONG Attribute) = 0;
  283. STDMETHOD_(LONG, ControlClock)(LONG Units, LONG Function, LONG ClockId, LONG Hour, LONG Min, LONG Sec, LONG Row, LONG Column, LONG Attribute, LONG Mode) = 0;
  284. STDMETHOD_(LONG, ControlCursor)(LONG Units, LONG Function) = 0;
  285. STDMETHOD_(LONG, CopyVideoRegion)(LONG Units, LONG Row, LONG Column, LONG Height, LONG Width, LONG TargetRow, LONG TargetColumn) = 0;
  286. STDMETHOD_(LONG, DisplayData)(LONG Units, LONG Row, LONG Column, LONG Attribute, BSTR Data) = 0;
  287. STDMETHOD_(LONG, DrawBox)(LONG Units, LONG Row, LONG Column, LONG Height, LONG Width, LONG Attribute, LONG BorderType) = 0;
  288. STDMETHOD_(LONG, FreeVideoRegion)(LONG Units, LONG BufferId) = 0;
  289. STDMETHOD_(LONG, ResetVideo)(LONG Units) = 0;
  290. STDMETHOD_(LONG, RestoreVideoRegion)(LONG Units, LONG TargetRow, LONG TargetColumn, LONG BufferId) = 0;
  291. STDMETHOD_(LONG, SaveVideoRegion)(LONG Units, LONG Row, LONG Column, LONG Height, LONG Width, LONG BufferId) = 0;
  292. STDMETHOD_(LONG, SelectChararacterSet)(LONG Units, LONG CharacterSet) = 0;
  293. STDMETHOD_(LONG, SetCursor)(LONG Units, LONG Row, LONG Column) = 0;
  294. STDMETHOD_(LONG, TransactionDisplay)(LONG Units, LONG Function) = 0;
  295. STDMETHOD_(LONG, UpdateVideoRegionAttribute)(LONG Units, LONG Function, LONG Row, LONG Column, LONG Height, LONG Width, LONG Attribute) = 0;
  296. STDMETHOD_(LONG, VideoSound)(LONG Units, LONG Frequency, LONG Duration, LONG NumberOfCycles, LONG InterSoundWait) = 0;
  297. // events
  298. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  299. // BUGBUG - override ? STDMETHOD_(void, OutputCompleteEvent)(LONG OutputID) = 0;
  300. STDMETHOD_(void, StatusUpdateEvent)(LONG Status) = 0;
  301. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  302. };
  303. DECLARE_INTERFACE_(IOPOSScale, IOPOSControl)
  304. {
  305. // methods
  306. STDMETHOD_(LONG, DisplayText)(BSTR Data) = 0;
  307. STDMETHOD_(LONG, ReadWeight)(LONG* pWeightData, LONG Timeout) = 0;
  308. STDMETHOD_(LONG, ZeroScale)() = 0;
  309. // events
  310. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  311. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  312. };
  313. DECLARE_INTERFACE_(IOPOSScanner, IOPOSControl)
  314. {
  315. // events
  316. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  317. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  318. };
  319. DECLARE_INTERFACE_(IOPOSSignatureCapture, IOPOSControl)
  320. {
  321. // methods
  322. STDMETHOD_(LONG, BeginCapture)(BSTR FormName) = 0;
  323. STDMETHOD_(LONG, EndCapture)() = 0;
  324. // events
  325. STDMETHOD_(void, DataEvent)(LONG Status) = 0;
  326. STDMETHOD_(void, ErrorEvent)(LONG ResultCode, LONG ResultCodeExtended, LONG ErrorLocus, LONG* pErrorResponse) = 0;
  327. };
  328. DECLARE_INTERFACE_(IOPOSToneIndicator, IOPOSControl)
  329. {
  330. // methods
  331. STDMETHOD_(LONG, Sound)(LONG NumberOfCycles, LONG InterSoundWait) = 0;
  332. STDMETHOD_(LONG, SoundImmediate)() = 0;
  333. };
  334. /*
  335. * OPOS status values
  336. */
  337. #define OPOS_SUCCESS 0
  338. #define OPOS_E_CLOSED 101
  339. #define OPOS_E_CLAIMED 102
  340. #define OPOS_E_NOTCLAIMED 103
  341. #define OPOS_E_NOSERVICE 104
  342. #define OPOS_E_DISABLED 105
  343. #define OPOS_E_ILLEGAL 106
  344. #define OPOS_E_NOHARDWARE 107
  345. #define OPOS_E_OFFLINE 108
  346. #define OPOS_E_NOEXIST 109
  347. #define OPOS_E_EXISTS 110
  348. #define OPOS_E_FAILURE 111
  349. #define OPOS_E_TIMEOUT 112
  350. #define OPOS_E_BUSY 113
  351. #define OPOS_E_EXTENDED 114
  352. #define OPOSERREXT 200
  353. /*
  354. * OPOS state values
  355. */
  356. #define OPOS_S_CLOSED 1
  357. #define OPOS_S_IDLE 2
  358. #define OPOS_S_BUSY 3
  359. #define OPOS_S_ERROR 4
  360. /*
  361. * OPOS "BinaryConversion" Property Constants
  362. */
  363. #define OPOS_BC_NONE 0
  364. #define OPOS_BC_NIBBLE 1
  365. #define OPOS_BC_DECIMAL 2
  366. /*
  367. * "CheckHealth" Method: "Level" Parameter Constants
  368. */
  369. #define OPOS_CH_INTERNAL 1
  370. #define OPOS_CH_EXTERNAL 2
  371. #define OPOS_CH_INTERACTIVE 3
  372. /*
  373. * OPOS "CapPowerReporting", "PowerState", "PowerNotify" Property
  374. */
  375. #define OPOS_PR_NONE 0
  376. #define OPOS_PR_STANDARD 1
  377. #define OPOS_PR_ADVANCED 2
  378. #define OPOS_PN_DISABLED 0
  379. #define OPOS_PN_ENABLED 1
  380. #define OPOS_PS_UNKNOWN 2000
  381. #define OPOS_PS_ONLINE 2001
  382. #define OPOS_PS_OFF 2002
  383. #define OPOS_PS_OFFLINE 2003
  384. #define OPOS_PS_OFF_OFFLINE 2004
  385. /*
  386. * "ErrorEvent" Event: "ErrorLocus" Parameter Constants
  387. */
  388. #define OPOS_EL_OUTPUT 1
  389. #define OPOS_EL_INPUT 2
  390. #define OPOS_EL_INPUT_DATA 3
  391. /*
  392. * "ErrorEvent" Event: "ErrorResponse" Constants
  393. */
  394. #define OPOS_ER_RETRY 11
  395. #define OPOS_ER_CLEAR 12
  396. #define OPOS_ER_CONTINUEINPUT 13
  397. /*
  398. * "StatusUpdateEvent" Event: Common "Status" Constants
  399. */
  400. #define OPOS_SUE_POWER_ONLINE 2001
  401. #define OPOS_SUE_POWER_OFF 2002
  402. #define OPOS_SUE_POWER_OFFLINE 2003
  403. #define OPOS_SUE_POWER_OFF_OFFLINE 2004
  404. /*
  405. * General Constants
  406. */
  407. #define OPOS_FOREVER -1
  408. /*
  409. **********************************************************************
  410. *
  411. * BUMP BAR header section
  412. *
  413. **********************************************************************
  414. */
  415. #define BB_UID_1 (1 << 0)
  416. #define BB_UID_2 (1 << 1)
  417. #define BB_UID_3 (1 << 2)
  418. #define BB_UID_4 (1 << 3)
  419. #define BB_UID_5 (1 << 4)
  420. #define BB_UID_6 (1 << 5)
  421. #define BB_UID_7 (1 << 6)
  422. #define BB_UID_8 (1 << 7)
  423. #define BB_UID_9 (1 << 8)
  424. #define BB_UID_10 (1 << 9)
  425. #define BB_UID_11 (1 << 10)
  426. #define BB_UID_12 (1 << 11)
  427. #define BB_UID_13 (1 << 12)
  428. #define BB_UID_14 (1 << 13)
  429. #define BB_UID_15 (1 << 14)
  430. #define BB_UID_16 (1 << 15)
  431. #define BB_UID_17 (1 << 16)
  432. #define BB_UID_18 (1 << 17)
  433. #define BB_UID_19 (1 << 18)
  434. #define BB_UID_20 (1 << 19)
  435. #define BB_UID_21 (1 << 20)
  436. #define BB_UID_22 (1 << 21)
  437. #define BB_UID_23 (1 << 22)
  438. #define BB_UID_24 (1 << 23)
  439. #define BB_UID_25 (1 << 24)
  440. #define BB_UID_26 (1 << 25)
  441. #define BB_UID_27 (1 << 26)
  442. #define BB_UID_28 (1 << 27)
  443. #define BB_UID_29 (1 << 28)
  444. #define BB_UID_30 (1 << 29)
  445. #define BB_UID_31 (1 << 30)
  446. #define BB_UID_32 (1 << 31)
  447. /*
  448. * "DataEvent" Event: "Status" Parameter Constants
  449. */
  450. #define BB_DE_KEY 0x01
  451. /*
  452. **********************************************************************
  453. *
  454. * CASH DRAWER header section
  455. *
  456. **********************************************************************
  457. */
  458. #define CASH_SUE_DRAWERCLOSED 0
  459. #define CASH_SUE_DRAWEROPEN 1
  460. /*
  461. **********************************************************************
  462. *
  463. * CASH CHANGER header section
  464. *
  465. **********************************************************************
  466. */
  467. #define CHAN_STATUS_OK 0 // DeviceStatus, FullStatus
  468. #define CHAN_STATUS_EMPTY 11 // DeviceStatus, StatusUpdateEvent
  469. #define CHAN_STATUS_NEAREMPTY 12 // DeviceStatus, StatusUpdateEvent
  470. #define CHAN_STATUS_EMPTYOK 13 // StatusUpdateEvent
  471. #define CHAN_STATUS_FULL 21 // FullStatus, StatusUpdateEvent
  472. #define CHAN_STATUS_NEARFULL 22 // FullStatus, StatusUpdateEvent
  473. #define CHAN_STATUS_FULLOK 23 // StatusUpdateEvent
  474. #define CHAN_STATUS_JAM 31 // DeviceStatus, StatusUpdateEvent
  475. #define CHAN_STATUS_JAMOK 32 // StatusUpdateEvent
  476. #define CHAN_STATUS_ASYNC 91 // StatusUpdateEvent
  477. /*
  478. * "ResultCodeExtended" Property Constants for Cash Changer
  479. */
  480. #define OPOS_ECHAN_OVERDISPENSE (1 + OPOSERREXT)
  481. /*
  482. **********************************************************************
  483. *
  484. * COIN DISPENSER header section
  485. *
  486. **********************************************************************
  487. */
  488. #define COIN_STATUS_OK 1
  489. #define COIN_STATUS_EMPTY 2
  490. #define COIN_STATUS_NEAREMPTY 3
  491. #define COIN_STATUS_JAM 4
  492. /*
  493. **********************************************************************
  494. *
  495. * LINE DISPLAY header section
  496. *
  497. **********************************************************************
  498. */
  499. /////////////////////////////////////////////////////////////////////
  500. // "CapBlink" Property Constants
  501. /////////////////////////////////////////////////////////////////////
  502. #define DISP_CB_NOBLINK 0
  503. #define DISP_CB_BLINKALL 1
  504. #define DISP_CB_BLINKEACH 2
  505. /////////////////////////////////////////////////////////////////////
  506. // "CapCharacterSet" Property Constants
  507. /////////////////////////////////////////////////////////////////////
  508. #define DISP_CCS_NUMERIC 0
  509. #define DISP_CCS_ALPHA 1
  510. #define DISP_CCS_ASCII 998
  511. #define DISP_CCS_KANA 10
  512. #define DISP_CCS_KANJI 11
  513. /////////////////////////////////////////////////////////////////////
  514. // "CharacterSet" Property Constants
  515. /////////////////////////////////////////////////////////////////////
  516. #define DISP_CS_ASCII 998
  517. #define DISP_CS_WINDOWS 999
  518. /////////////////////////////////////////////////////////////////////
  519. // "MarqueeType" Property Constants
  520. /////////////////////////////////////////////////////////////////////
  521. #define DISP_MT_NONE 0
  522. #define DISP_MT_UP 1
  523. #define DISP_MT_DOWN 2
  524. #define DISP_MT_LEFT 3
  525. #define DISP_MT_RIGHT 4
  526. #define DISP_MT_INIT 5
  527. /////////////////////////////////////////////////////////////////////
  528. // "MarqueeFormat" Property Constants
  529. /////////////////////////////////////////////////////////////////////
  530. #define DISP_MF_WALK 0
  531. #define DISP_MF_PLACE 1
  532. /////////////////////////////////////////////////////////////////////
  533. // "DisplayText" Method: "Attribute" Property Constants
  534. // "DisplayTextAt" Method: "Attribute" Property Constants
  535. /////////////////////////////////////////////////////////////////////
  536. #define DISP_DT_NORMAL 0
  537. #define DISP_DT_BLINK 1
  538. /////////////////////////////////////////////////////////////////////
  539. // "ScrollText" Method: "Direction" Parameter Constants
  540. /////////////////////////////////////////////////////////////////////
  541. #define DISP_ST_UP 1
  542. #define DISP_ST_DOWN 2
  543. #define DISP_ST_LEFT 3
  544. #define DISP_ST_RIGHT 4
  545. /////////////////////////////////////////////////////////////////////
  546. // "SetDescriptor" Method: "Attribute" Parameter Constants
  547. /////////////////////////////////////////////////////////////////////
  548. #define DISP_SD_OFF 0
  549. #define DISP_SD_ON 1
  550. #define DISP_SD_BLINK 2
  551. /*
  552. **********************************************************************
  553. *
  554. * FISCAL PRINTER header section
  555. *
  556. **********************************************************************
  557. */
  558. #define FPTR_S_JOURNAL 1
  559. #define FPTR_S_RECEIPT 2
  560. #define FPTR_S_SLIP 4
  561. #define FPTR_S_JOURNAL_RECEIPT (FPTR_S_JOURNAL | FPTR_S_RECEIPT)
  562. /////////////////////////////////////////////////////////////////////
  563. // "CountryCode" Property Constants
  564. /////////////////////////////////////////////////////////////////////
  565. #define FPTR_CC_BRAZIL 1
  566. #define FPTR_CC_GREECE 2
  567. #define FPTR_CC_HUNGARY 3
  568. #define FPTR_CC_ITALY 4
  569. #define FPTR_CC_POLAND 5
  570. #define FPTR_CC_TURKEY 6
  571. /////////////////////////////////////////////////////////////////////
  572. // "ErrorLevel" Property Constants
  573. /////////////////////////////////////////////////////////////////////
  574. #define FPTR_EL_NONE 1
  575. #define FPTR_EL_RECOVERABLE 2
  576. #define FPTR_EL_FATAL 3
  577. #define FPTR_EL_BLOCKED 4
  578. /////////////////////////////////////////////////////////////////////
  579. // "ErrorState", "PrinterState" Property Constants
  580. /////////////////////////////////////////////////////////////////////
  581. #define FPTR_PS_MONITOR 1
  582. #define FPTR_PS_FISCAL_RECEIPT 2
  583. #define FPTR_PS_FISCAL_RECEIPT_TOTAL 3
  584. #define FPTR_PS_FISCAL_RECEIPT_ENDING 4
  585. #define FPTR_PS_FISCAL_DOCUMENT 5
  586. #define FPTR_PS_FIXED_OUTPUT 6
  587. #define FPTR_PS_ITEM_LIST 7
  588. #define FPTR_PS_LOCKED 8
  589. #define FPTR_PS_NONFISCAL 9
  590. #define FPTR_PS_REPORT 10
  591. /////////////////////////////////////////////////////////////////////
  592. // "SlipSelection" Property Constants
  593. /////////////////////////////////////////////////////////////////////
  594. #define FPTR_SS_FULL_LENGTH 1
  595. #define FPTR_SS_VALIDATION 2
  596. /////////////////////////////////////////////////////////////////////
  597. // "GetData" Method Constants
  598. /////////////////////////////////////////////////////////////////////
  599. #define FPTR_GD_CURRENT_TOTAL 1
  600. #define FPTR_GD_DAILY_TOTAL 2
  601. #define FPTR_GD_RECEIPT_NUMBER 3
  602. #define FPTR_GD_REFUND 4
  603. #define FPTR_GD_NOT_PAID 5
  604. #define FPTR_GD_MID_VOID 6
  605. #define FPTR_GD_Z_REPORT 7
  606. #define FPTR_GD_GRANDT_TOTAL 8
  607. #define FPTR_GD_PRINTER_ID 9
  608. #define FPTR_GD_FIRMWARE 10
  609. #define FPTR_GD_RESTART 11
  610. /////////////////////////////////////////////////////////////////////
  611. // "AdjustmentType" arguments in diverse methods
  612. /////////////////////////////////////////////////////////////////////
  613. #define FPTR_AT_AMOUNT_DISCOUNT 1
  614. #define FPTR_AT_AMOUNT_SURCHARGE 2
  615. #define FPTR_AT_PERCENTAGE_DISCOUNT 3
  616. #define FPTR_AT_PERCENTAGE_SURCHARGE 4
  617. /////////////////////////////////////////////////////////////////////
  618. // "ReportType" argument in "PrintReport" method
  619. /////////////////////////////////////////////////////////////////////
  620. #define FPTR_RT_ORDINAL 1
  621. #define FPTR_RT_DATE 2
  622. /////////////////////////////////////////////////////////////////////
  623. // "StatusUpdateEvent" Event: "Data" Parameter Constants
  624. /////////////////////////////////////////////////////////////////////
  625. #define FPTR_SUE_COVER_OPEN 11
  626. #define FPTR_SUE_COVER_OK 12
  627. #define FPTR_SUE_JRN_EMPTY 21
  628. #define FPTR_SUE_JRN_NEAREMPTY 22
  629. #define FPTR_SUE_JRN_PAPEROK 23
  630. #define FPTR_SUE_REC_EMPTY 24
  631. #define FPTR_SUE_REC_NEAREMPTY 25
  632. #define FPTR_SUE_REC_PAPEROK 26
  633. #define FPTR_SUE_SLP_EMPTY 27
  634. #define FPTR_SUE_SLP_NEAREMPTY 28
  635. #define FPTR_SUE_SLP_PAPEROK 29
  636. #define FPTR_SUE_IDLE 1001
  637. /////////////////////////////////////////////////////////////////////
  638. // "ResultCodeExtended" Property Constants for Fiscal Printer
  639. /////////////////////////////////////////////////////////////////////
  640. #define OPOS_EFPTR_COVER_OPEN (1 + OPOSERREXT) // (Several)
  641. #define OPOS_EFPTR_JRN_EMPTY (2 + OPOSERREXT) // (Several)
  642. #define OPOS_EFPTR_REC_EMPTY (3 + OPOSERREXT) // (Several)
  643. #define OPOS_EFPTR_SLP_EMPTY (4 + OPOSERREXT) // (Several)
  644. #define OPOS_EFPTR_SLP_FORM (5 + OPOSERREXT) // EndRemoval
  645. #define OPOS_EFPTR_MISSING_DEVICES (6 + OPOSERREXT) // (Several)
  646. #define OPOS_EFPTR_WRONG_STATE (7 + OPOSERREXT) // (Several)
  647. #define OPOS_EFPTR_TECHNICAL_ASSISTANCE (8 + OPOSERREXT) // (Several)
  648. #define OPOS_EFPTR_CLOCK_ERROR (9 + OPOSERREXT) // (Several)
  649. #define OPOS_EFPTR_FISCAL_MEMORY_FULL (10 + OPOSERREXT) // (Several)
  650. #define OPOS_EFPTR_FISCAL_MEMORY_DISCONNECTED (11 + OPOSERREXT) // (Several)
  651. #define OPOS_EFPTR_FISCAL_TOTALS_ERROR (12 + OPOSERREXT) // (Several)
  652. #define OPOS_EFPTR_BAD_ITEM_QUANTITY (13 + OPOSERREXT) // (Several)
  653. #define OPOS_EFPTR_BAD_ITEM_AMOUNT (14 + OPOSERREXT) // (Several)
  654. #define OPOS_EFPTR_BAD_ITEM_DESCRIPTION (15 + OPOSERREXT) // (Several)
  655. #define OPOS_EFPTR_RECEIPT_TOTAL_OVERFLOW (16 + OPOSERREXT) // (Several)
  656. #define OPOS_EFPTR_BAD_VAT (17 + OPOSERREXT) // (Several)
  657. #define OPOS_EFPTR_BAD_PRICE (18 + OPOSERREXT) // (Several)
  658. #define OPOS_EFPTR_BAD_DATE (19 + OPOSERREXT) // (Several)
  659. #define OPOS_EFPTR_NEGATIVE_TOTAL (20 + OPOSERREXT) // (Several)
  660. #define OPOS_EFPTR_WORD_NOT_ALLOWED (21 + OPOSERREXT) // (Several)
  661. /*
  662. **********************************************************************
  663. *
  664. * POS KEYBOARD header section
  665. *
  666. **********************************************************************
  667. */
  668. #define KBD_ET_DOWN 1
  669. #define KBD_ET_DOWN_UP 2
  670. /////////////////////////////////////////////////////////////////////
  671. // "POSKeyEventType" Property Constants
  672. /////////////////////////////////////////////////////////////////////
  673. #define KBD_KET_KEYDOWN 1
  674. #define KBD_KET_KEYUP 2
  675. /*
  676. **********************************************************************
  677. *
  678. * KEYLOCK header section
  679. *
  680. **********************************************************************
  681. */
  682. #define LOCK_KP_ANY 0 // WaitForKeylockChange Only
  683. #define LOCK_KP_LOCK 1
  684. #define LOCK_KP_NORM 2
  685. #define LOCK_KP_SUPR 3
  686. /*
  687. **********************************************************************
  688. *
  689. * MICR header section
  690. *
  691. **********************************************************************
  692. */
  693. #define MICR_CT_PERSONAL 1
  694. #define MICR_CT_BUSINESS 2
  695. #define MICR_CT_UNKNOWN 99
  696. /////////////////////////////////////////////////////////////////////
  697. // "CountryCode" Property Constants
  698. /////////////////////////////////////////////////////////////////////
  699. #define MICR_CC_USA 1
  700. #define MICR_CC_CANADA 2
  701. #define MICR_CC_MEXICO 3
  702. #define MICR_CC_UNKNOWN 99
  703. /////////////////////////////////////////////////////////////////////
  704. // "ResultCodeExtended" Property Constants for MICR
  705. /////////////////////////////////////////////////////////////////////
  706. #define OPOS_EMICR_NOCHECK (1 + OPOSERREXT) // EndInsertion
  707. #define OPOS_EMICR_CHECK (2 + OPOSERREXT) // EndRemoval
  708. /*
  709. **********************************************************************
  710. *
  711. * MSR header section
  712. *
  713. **********************************************************************
  714. */
  715. /////////////////////////////////////////////////////////////////////
  716. // "TracksToRead" Property Constants
  717. /////////////////////////////////////////////////////////////////////
  718. #define MSR_TR_1 1
  719. #define MSR_TR_2 2
  720. #define MSR_TR_3 4
  721. #define MSR_TR_1_2 (MSR_TR_1 | MSR_TR_2)
  722. #define MSR_TR_1_3 (MSR_TR_1 | MSR_TR_3)
  723. #define MSR_TR_2_3 (MSR_TR_2 | MSR_TR_3)
  724. #define MSR_TR_1_2_3 (MSR_TR_1 | MSR_TR_2 | MSR_TR_3)
  725. /////////////////////////////////////////////////////////////////////
  726. // "ErrorReportingType" Property Constants
  727. /////////////////////////////////////////////////////////////////////
  728. #define MSR_ERT_CARD 0
  729. #define MSR_ERT_TRACK 1
  730. /////////////////////////////////////////////////////////////////////
  731. // "ErrorEvent" Event: "ResultCodeExtended" Parameter Constants
  732. /////////////////////////////////////////////////////////////////////
  733. #define OPOS_EMSR_START (1 + OPOSERREXT)
  734. #define OPOS_EMSR_END (2 + OPOSERREXT)
  735. #define OPOS_EMSR_PARITY (3 + OPOSERREXT)
  736. #define OPOS_EMSR_LRC (4 + OPOSERREXT)
  737. /*
  738. **********************************************************************
  739. *
  740. * PIN PAD header section
  741. *
  742. **********************************************************************
  743. */
  744. /////////////////////////////////////////////////////////////////////
  745. // "CapDisplay" Property Constants
  746. /////////////////////////////////////////////////////////////////////
  747. #define PPAD_DISP_UNRESTRICTED 1
  748. #define PPAD_DISP_PINRESTRICTED 2
  749. #define PPAD_DISP_RESTRICTED_LIST 3
  750. #define PPAD_DISP_RESTRICTED_ORDER 4
  751. /////////////////////////////////////////////////////////////////////
  752. // "AvailablePromptsList" and "Prompt" Property Constants
  753. /////////////////////////////////////////////////////////////////////
  754. #define PPAD_MSG_ENTERPIN 1
  755. #define PPAD_MSG_PLEASEWAIT 2
  756. #define PPAD_MSG_ENTERVALIDPIN 3
  757. #define PPAD_MSG_RETRIESEXCEEDED 4
  758. #define PPAD_MSG_APPROVED 5
  759. #define PPAD_MSG_DECLINED 6
  760. #define PPAD_MSG_CANCELED 7
  761. #define PPAD_MSG_AMOUNTOK 8
  762. #define PPAD_MSG_NOTREADY 9
  763. #define PPAD_MSG_IDLE 10
  764. #define PPAD_MSG_SLIDE_CARD 11
  765. #define PPAD_MSG_INSERTCARD 12
  766. #define PPAD_MSG_SELECTCARDTYPE 13
  767. /////////////////////////////////////////////////////////////////////
  768. // "CapLanguage" Property Constants
  769. /////////////////////////////////////////////////////////////////////
  770. #define PPAD_LANG_NONE 1
  771. #define PPAD_LANG_ONE 2
  772. #define PPAD_LANG_PINRESTRICTED 3
  773. #define PPAD_LANG_UNRESTRICTED 4
  774. /////////////////////////////////////////////////////////////////////
  775. // "TransactionType" Property Constants
  776. /////////////////////////////////////////////////////////////////////
  777. #define PPAD_TRANS_DEBIT 1
  778. #define PPAD_TRANS_CREDIT 2
  779. #define PPAD_TRANS_INQ 3
  780. #define PPAD_TRANS_RECONCILE 4
  781. #define PPAD_TRANS_ADMIN 5
  782. /////////////////////////////////////////////////////////////////////
  783. // "EndEFTTransaction" Method Completion Code Constants
  784. /////////////////////////////////////////////////////////////////////
  785. #define PPAD_EFT_NORMAL 1
  786. #define PPAD_EFT_ABNORMAL 2
  787. /////////////////////////////////////////////////////////////////////
  788. // "DataEvent" Event Status Constants
  789. /////////////////////////////////////////////////////////////////////
  790. #define PPAD_SUCCESS 1
  791. #define PPAD_CANCEL 2
  792. /*
  793. **********************************************************************
  794. *
  795. * POS PRINTER header section
  796. *
  797. **********************************************************************
  798. */
  799. /////////////////////////////////////////////////////////////////////
  800. // Printer Station Constants
  801. /////////////////////////////////////////////////////////////////////
  802. #define PTR_S_JOURNAL 1
  803. #define PTR_S_RECEIPT 2
  804. #define PTR_S_SLIP 4
  805. #define PTR_S_JOURNAL_RECEIPT (PTR_S_JOURNAL | PTR_S_RECEIPT )
  806. #define PTR_S_JOURNAL_SLIP (PTR_S_JOURNAL | PTR_S_SLIP )
  807. #define PTR_S_RECEIPT_SLIP (PTR_S_RECEIPT | PTR_S_SLIP )
  808. #define PTR_TWO_RECEIPT_JOURNAL (0x8000 + PTR_S_JOURNAL_RECEIPT )
  809. #define PTR_TWO_SLIP_JOURNAL (0x8000 + PTR_S_JOURNAL_SLIP )
  810. #define PTR_TWO_SLIP_RECEIPT (0x8000 + PTR_S_RECEIPT_SLIP )
  811. /////////////////////////////////////////////////////////////////////
  812. // "CapCharacterSet" Property Constants
  813. /////////////////////////////////////////////////////////////////////
  814. #define PTR_CCS_ALPHA 1
  815. #define PTR_CCS_ASCII 998
  816. #define PTR_CCS_KANA 10
  817. #define PTR_CCS_KANJI 11
  818. /////////////////////////////////////////////////////////////////////
  819. // "CharacterSet" Property Constants
  820. /////////////////////////////////////////////////////////////////////
  821. #define PTR_CS_ASCII 998
  822. #define PTR_CS_WINDOWS 999
  823. /////////////////////////////////////////////////////////////////////
  824. // "ErrorLevel" Property Constants
  825. /////////////////////////////////////////////////////////////////////
  826. #define PTR_EL_NONE 1
  827. #define PTR_EL_RECOVERABLE 2
  828. #define PTR_EL_FATAL 3
  829. /////////////////////////////////////////////////////////////////////
  830. // "MapMode" Property Constants
  831. /////////////////////////////////////////////////////////////////////
  832. #define PTR_MM_DOTS 1
  833. #define PTR_MM_TWIPS 2
  834. #define PTR_MM_ENGLISH 3
  835. #define PTR_MM_METRIC 4
  836. /////////////////////////////////////////////////////////////////////
  837. // "CutPaper" Method Constant
  838. /////////////////////////////////////////////////////////////////////
  839. #define PTR_CP_FULLCUT 100
  840. /////////////////////////////////////////////////////////////////////
  841. // "PrintBarCode" Method Constants:
  842. /////////////////////////////////////////////////////////////////////
  843. // "Alignment" Parameter
  844. // Either the distance from the left-most print column to the start
  845. // of the bar code, or one of the following:
  846. #define PTR_BC_LEFT -1
  847. #define PTR_BC_CENTER -2
  848. #define PTR_BC_RIGHT -3
  849. // "TextPosition" Parameter
  850. #define PTR_BC_TEXT_NONE -11
  851. #define PTR_BC_TEXT_ABOVE -12
  852. #define PTR_BC_TEXT_BELOW -13
  853. // "Symbology" Parameter:
  854. // One dimensional symbologies
  855. #define PTR_BCS_UPCA 101 // Digits
  856. #define PTR_BCS_UPCE 102 // Digits
  857. #define PTR_BCS_JAN8 103 // = EAN 8
  858. #define PTR_BCS_EAN8 103 // = JAN 8 (added in 1.2)
  859. #define PTR_BCS_JAN13 104 // = EAN 13
  860. #define PTR_BCS_EAN13 104 // = JAN 13 (added in 1.2)
  861. #define PTR_BCS_TF 105 // (Discrete 2 of 5) Digits
  862. #define PTR_BCS_ITF 106 // (Interleaved 2 of 5) Digits
  863. #define PTR_BCS_Codabar 107 // Digits, -, $, :, /, ., +;
  864. // 4 start/stop characters
  865. // (a, b, c, d)
  866. #define PTR_BCS_Code39 108 // Alpha, Digits, Space, -, .,
  867. // $, /, +, %; start/stop (*)
  868. // Also has Full ASCII feature
  869. #define PTR_BCS_Code93 109 // Same characters as Code 39
  870. #define PTR_BCS_Code128 110 // 128 data characters
  871. // (The following were added in Release 1.2)
  872. #define PTR_BCS_UPCA_S 111 // UPC-A with supplemental
  873. // barcode
  874. #define PTR_BCS_UPCE_S 112 // UPC-E with supplemental
  875. // barcode
  876. #define PTR_BCS_UPCD1 113 // UPC-D1
  877. #define PTR_BCS_UPCD2 114 // UPC-D2
  878. #define PTR_BCS_UPCD3 115 // UPC-D3
  879. #define PTR_BCS_UPCD4 116 // UPC-D4
  880. #define PTR_BCS_UPCD5 117 // UPC-D5
  881. #define PTR_BCS_EAN8_S 118 // EAN 8 with supplemental
  882. // barcode
  883. #define PTR_BCS_EAN13_S 119 // EAN 13 with supplemental
  884. // barcode
  885. #define PTR_BCS_EAN128 120 // EAN 128
  886. #define PTR_BCS_OCRA 121 // OCR "A"
  887. #define PTR_BCS_OCRB 122 // OCR "B"
  888. // Two dimensional symbologies
  889. #define PTR_BCS_PDF417 201
  890. #define PTR_BCS_MAXICODE 202
  891. // Start of Printer-Specific bar code symbologies
  892. #define PTR_BCS_OTHER 501
  893. /////////////////////////////////////////////////////////////////////
  894. // "PrintBitmap" Method Constants:
  895. /////////////////////////////////////////////////////////////////////
  896. // "Width" Parameter
  897. // Either bitmap width or:
  898. #define PTR_BM_ASIS -11 // One pixel per printer dot
  899. // "Alignment" Parameter
  900. // Either the distance from the left-most print column to the start
  901. // of the bitmap, or one of the following:
  902. #define PTR_BM_LEFT -1
  903. #define PTR_BM_CENTER -2
  904. #define PTR_BM_RIGHT -3
  905. /////////////////////////////////////////////////////////////////////
  906. // "RotatePrint" Method: "Rotation" Parameter Constants
  907. // "RotateSpecial" Property Constants
  908. /////////////////////////////////////////////////////////////////////
  909. #define PTR_RP_NORMAL 0x0001
  910. #define PTR_RP_RIGHT90 0x0101
  911. #define PTR_RP_LEFT90 0x0102
  912. #define PTR_RP_ROTATE180 0x0103
  913. /////////////////////////////////////////////////////////////////////
  914. // "SetLogo" Method: "Location" Parameter Constants
  915. /////////////////////////////////////////////////////////////////////
  916. #define PTR_L_TOP 1
  917. #define PTR_L_BOTTOM 2
  918. /////////////////////////////////////////////////////////////////////
  919. // "TransactionPrint" Method: "Control" Parameter Constants
  920. /////////////////////////////////////////////////////////////////////
  921. #define PTR_TP_TRANSACTION 11
  922. #define PTR_TP_NORMAL 12
  923. /////////////////////////////////////////////////////////////////////
  924. // "StatusUpdateEvent" Event: "Data" Parameter Constants
  925. /////////////////////////////////////////////////////////////////////
  926. #define PTR_SUE_COVER_OPEN 11
  927. #define PTR_SUE_COVER_OK 12
  928. #define PTR_SUE_JRN_EMPTY 21
  929. #define PTR_SUE_JRN_NEAREMPTY 22
  930. #define PTR_SUE_JRN_PAPEROK 23
  931. #define PTR_SUE_REC_EMPTY 24
  932. #define PTR_SUE_REC_NEAREMPTY 25
  933. #define PTR_SUE_REC_PAPEROK 26
  934. #define PTR_SUE_SLP_EMPTY 27
  935. #define PTR_SUE_SLP_NEAREMPTY 28
  936. #define PTR_SUE_SLP_PAPEROK 29
  937. #define PTR_SUE_IDLE 1001
  938. /////////////////////////////////////////////////////////////////////
  939. // "ResultCodeExtended" Property Constants for Printer
  940. /////////////////////////////////////////////////////////////////////
  941. #define OPOS_EPTR_COVER_OPEN (1 + OPOSERREXT) // (Several)
  942. #define OPOS_EPTR_JRN_EMPTY (2 + OPOSERREXT) // (Several)
  943. #define OPOS_EPTR_REC_EMPTY (3 + OPOSERREXT) // (Several)
  944. #define OPOS_EPTR_SLP_EMPTY (4 + OPOSERREXT) // (Several)
  945. #define OPOS_EPTR_SLP_FORM (5 + OPOSERREXT) // EndRemoval
  946. #define OPOS_EPTR_TOOBIG (6 + OPOSERREXT) // PrintBitmap
  947. #define OPOS_EPTR_BADFORMAT (7 + OPOSERREXT) // PrintBitmap
  948. /*
  949. **********************************************************************
  950. *
  951. * REMOTE ORDER DISPLAY header section
  952. *
  953. **********************************************************************
  954. */
  955. #define ROD_UID_1 (1 << 0)
  956. #define ROD_UID_2 (1 << 1)
  957. #define ROD_UID_3 (1 << 2)
  958. #define ROD_UID_4 (1 << 3)
  959. #define ROD_UID_5 (1 << 4)
  960. #define ROD_UID_6 (1 << 5)
  961. #define ROD_UID_7 (1 << 6)
  962. #define ROD_UID_8 (1 << 7)
  963. #define ROD_UID_9 (1 << 8)
  964. #define ROD_UID_10 (1 << 9)
  965. #define ROD_UID_11 (1 << 10)
  966. #define ROD_UID_12 (1 << 11)
  967. #define ROD_UID_13 (1 << 12)
  968. #define ROD_UID_14 (1 << 13)
  969. #define ROD_UID_15 (1 << 14)
  970. #define ROD_UID_16 (1 << 15)
  971. #define ROD_UID_17 (1 << 16)
  972. #define ROD_UID_18 (1 << 17)
  973. #define ROD_UID_19 (1 << 18)
  974. #define ROD_UID_20 (1 << 19)
  975. #define ROD_UID_21 (1 << 20)
  976. #define ROD_UID_22 (1 << 21)
  977. #define ROD_UID_23 (1 << 22)
  978. #define ROD_UID_24 (1 << 23)
  979. #define ROD_UID_25 (1 << 24)
  980. #define ROD_UID_26 (1 << 25)
  981. #define ROD_UID_27 (1 << 26)
  982. #define ROD_UID_28 (1 << 27)
  983. #define ROD_UID_29 (1 << 28)
  984. #define ROD_UID_30 (1 << 29)
  985. #define ROD_UID_31 (1 << 30)
  986. #define ROD_UID_32 (1 << 31)
  987. /////////////////////////////////////////////////////////////////////
  988. // Broadcast Methods: "Attribute" Parameter Constants
  989. /////////////////////////////////////////////////////////////////////
  990. #define ROD_ATTR_BLINK 0x80
  991. #define ROD_ATTR_BG_BLACK 0x00
  992. #define ROD_ATTR_BG_BLUE 0x10
  993. #define ROD_ATTR_BG_GREEN 0x20
  994. #define ROD_ATTR_BG_CYAN 0x30
  995. #define ROD_ATTR_BG_RED 0x40
  996. #define ROD_ATTR_BG_MAGENTA 0x50
  997. #define ROD_ATTR_BG_BROWN 0x60
  998. #define ROD_ATTR_BG_GRAY 0x70
  999. #define ROD_ATTR_INTENSITY 0x08
  1000. #define ROD_ATTR_FG_BLACK 0x00
  1001. #define ROD_ATTR_FG_BLUE 0x01
  1002. #define ROD_ATTR_FG_GREEN 0x02
  1003. #define ROD_ATTR_FG_CYAN 0x03
  1004. #define ROD_ATTR_FG_RED 0x04
  1005. #define ROD_ATTR_FG_MAGENTA 0x05
  1006. #define ROD_ATTR_FG_BROWN 0x06
  1007. #define ROD_ATTR_FG_GRAY 0x07
  1008. /////////////////////////////////////////////////////////////////////
  1009. // "DrawBox" Method: "BorderType" Parameter Constants
  1010. /////////////////////////////////////////////////////////////////////
  1011. #define ROD_BDR_SINGLE 1
  1012. #define ROD_BDR_DOUBLE 2
  1013. #define ROD_BDR_SOLID 3
  1014. /////////////////////////////////////////////////////////////////////
  1015. // "ControlClock" Method: "Function" Parameter Constants
  1016. /////////////////////////////////////////////////////////////////////
  1017. #define ROD_CLK_START 1
  1018. #define ROD_CLK_PAUSE 2
  1019. #define ROD_CLK_RESUME 3
  1020. #define ROD_CLK_MOVE 4
  1021. #define ROD_CLK_STOP 5
  1022. /////////////////////////////////////////////////////////////////////
  1023. // "ControlCursor" Method: "Function" Parameter Constants
  1024. /////////////////////////////////////////////////////////////////////
  1025. #define ROD_CRS_LINE 1
  1026. #define ROD_CRS_LINE_BLINK 2
  1027. #define ROD_CRS_BLOCK 3
  1028. #define ROD_CRS_BLOCK_BLINK 4
  1029. #define ROD_CRS_OFF 5
  1030. /////////////////////////////////////////////////////////////////////
  1031. // "SelectChararacterSet" Method: "CharacterSet" Parameter Constants
  1032. /////////////////////////////////////////////////////////////////////
  1033. #define ROD_CS_ASCII 998
  1034. #define ROD_CS_WINDOWS 999
  1035. /////////////////////////////////////////////////////////////////////
  1036. // "TransactionDisplay" Method: "Function" Parameter Constants
  1037. /////////////////////////////////////////////////////////////////////
  1038. #define ROD_TD_TRANSACTION 11
  1039. #define ROD_TD_NORMAL 12
  1040. /////////////////////////////////////////////////////////////////////
  1041. // "UpdateVideoRegionAttribute" Method: "Function" Parameter Constants
  1042. /////////////////////////////////////////////////////////////////////
  1043. #define ROD_UA_SET 1
  1044. #define ROD_UA_INTENSITY_ON 2
  1045. #define ROD_UA_INTENSITY_OFF 3
  1046. #define ROD_UA_REVERSE_ON 4
  1047. #define ROD_UA_REVERSE_OFF 5
  1048. #define ROD_UA_BLINK_ON 6
  1049. #define ROD_UA_BLINK_OFF 7
  1050. /////////////////////////////////////////////////////////////////////
  1051. // "EventTypes" Property and "DataEvent" Event: "Status" Parameter Constants
  1052. /////////////////////////////////////////////////////////////////////
  1053. #define ROD_DE_TOUCH_UP 0x01
  1054. #define ROD_DE_TOUCH_DOWN 0x02
  1055. #define ROD_DE_TOUCH_MOVE 0x04
  1056. /////////////////////////////////////////////////////////////////////
  1057. // "ResultCodeExtended" Property Constants for Remote Order Display
  1058. /////////////////////////////////////////////////////////////////////
  1059. #define OPOS_EROD_BADCLK (1 + OPOSERREXT) // ControlClock
  1060. #define OPOS_EROD_NOCLOCKS (2 + OPOSERREXT) // ControlClock
  1061. #define OPOS_EROD_NOREGION (3 + OPOSERREXT) // RestoreVideo
  1062. // Region
  1063. #define OPOS_EROD_NOBUFFERS (4 + OPOSERREXT) // SaveVideoRegion
  1064. #define OPOS_EROD_NOROOM (5 + OPOSERREXT) // SaveVideoRegion
  1065. /*
  1066. **********************************************************************
  1067. *
  1068. * SCALE DISPLAY header section
  1069. *
  1070. **********************************************************************
  1071. */
  1072. /////////////////////////////////////////////////////////////////////
  1073. // "WeightUnit" Property Constants
  1074. /////////////////////////////////////////////////////////////////////
  1075. #define SCAL_WU_GRAM 1
  1076. #define SCAL_WU_KILOGRAM 2
  1077. #define SCAL_WU_OUNCE 3
  1078. #define SCAL_WU_POUND 4
  1079. /////////////////////////////////////////////////////////////////////
  1080. // "ResultCodeExtended" Property Constants for Scale
  1081. /////////////////////////////////////////////////////////////////////
  1082. #define OPOS_ESCAL_OVERWEIGHT (1 + OPOSERREXT) // ReadWeight
  1083. /*
  1084. **********************************************************************
  1085. *
  1086. * BAR CODE SCANNER header section
  1087. *
  1088. **********************************************************************
  1089. */
  1090. /////////////////////////////////////////////////////////////////////
  1091. // "ScanDataType" Property Constants
  1092. /////////////////////////////////////////////////////////////////////
  1093. // One dimensional symbologies
  1094. #define SCAN_SDT_UPCA 101 // Digits
  1095. #define SCAN_SDT_UPCE 102 // Digits
  1096. #define SCAN_SDT_JAN8 103 // = EAN 8
  1097. #define SCAN_SDT_EAN8 103 // = JAN 8 (added in 1.2)
  1098. #define SCAN_SDT_JAN13 104 // = EAN 13
  1099. #define SCAN_SDT_EAN13 104 // = JAN 13 (added in 1.2)
  1100. #define SCAN_SDT_TF 105 // (Discrete 2 of 5) Digits
  1101. #define SCAN_SDT_ITF 106 // (Interleaved 2 of 5) Digits
  1102. #define SCAN_SDT_Codabar 107 // Digits, -, $, :, /, ., +;
  1103. // 4 start/stop characters
  1104. // (a, b, c, d)
  1105. #define SCAN_SDT_Code39 108 // Alpha, Digits, Space, -, .,
  1106. // $, /, +, %; start/stop (*)
  1107. // Also has Full ASCII feature
  1108. #define SCAN_SDT_Code93 109 // Same characters as Code 39
  1109. #define SCAN_SDT_Code128 110 // 128 data characters
  1110. #define SCAN_SDT_UPCA_S 111 // UPC-A with supplemental
  1111. // barcode
  1112. #define SCAN_SDT_UPCE_S 112 // UPC-E with supplemental
  1113. // barcode
  1114. #define SCAN_SDT_UPCD1 113 // UPC-D1
  1115. #define SCAN_SDT_UPCD2 114 // UPC-D2
  1116. #define SCAN_SDT_UPCD3 115 // UPC-D3
  1117. #define SCAN_SDT_UPCD4 116 // UPC-D4
  1118. #define SCAN_SDT_UPCD5 117 // UPC-D5
  1119. #define SCAN_SDT_EAN8_S 118 // EAN 8 with supplemental
  1120. // barcode
  1121. #define SCAN_SDT_EAN13_S 119 // EAN 13 with supplemental
  1122. // barcode
  1123. #define SCAN_SDT_EAN128 120 // EAN 128
  1124. #define SCAN_SDT_OCRA 121 // OCR "A"
  1125. #define SCAN_SDT_OCRB 122 // OCR "B"
  1126. // Two dimensional symbologies
  1127. #define SCAN_SDT_PDF417 201
  1128. #define SCAN_SDT_MAXICODE 202
  1129. // Special cases
  1130. #define SCAN_SDT_OTHER 501 // Start of Scanner-Specific bar
  1131. // code symbologies
  1132. #define SCAN_SDT_UNKNOWN 0 // Cannot determine the barcode
  1133. // symbology.
  1134. /*
  1135. **********************************************************************
  1136. *
  1137. * SIGNATURE CAPTURE header section
  1138. *
  1139. **********************************************************************
  1140. */
  1141. // (no definitions in this version)
  1142. /*
  1143. **********************************************************************
  1144. *
  1145. * TONE INDICATOR header section
  1146. *
  1147. **********************************************************************
  1148. */
  1149. /////////////////////////////////////////////////////////////////////
  1150. // "ResultCodeExtended" Property Constants for Hard Totals
  1151. /////////////////////////////////////////////////////////////////////
  1152. #define OPOS_ETOT_NOROOM (1 + OPOSERREXT) // Create, Write
  1153. #define OPOS_ETOT_VALIDATION (2 + OPOSERREXT) // Read, Write