Section 5. Example Applications
45
C++ EXAMPLE
The following is an example of C++:
/* -------------------------------------------------------------------------- */
/*
TST: Test Application
*/
/*
*/
/*
MTDTEST.C - Test module for Mag-Tek device drivers
*/
/* -------------------------------------------------------------------------- */
/* Version 1.00
$Revision::
$ */
/* -------------------------------------------------------------------------- */
#include <windows.h>
#include <stdio.h>
#include <conio.h>
#include <string.h>
/* --- Static variables ----------------------------------------------------- */
static volatile BOOL
quit = FALSE;
static char
sbuff[128];
static HANDLE
drv_h;
static HANDLE
in_threadh;
static HANDLE
out_threadh;
static OVERLAPPED
ov_r, ov_w;
/* --- Macro definitions ---------------------------------------------------- */
#define OPEN_DEVICE(name)
\
CreateFile(
\
(name),
/* LPCTSTR - pointer to name of the file */ \
GENERIC_READ | GENERIC_WRITE,/* DWORD
- access (read-write) mode
*/ \
0,
/* DWORD
- share mode
*/ \
NULL,
/* LPSECURITY_ATTRIBUTES
*/ \
/*
- pointer to security attribs */ \
OPEN_EXISTING,
/* DWORD
- how to create
*/ \
0
|
\
FILE_FLAG_OVERLAPPED,
/* DWORD
- file attributes
*/ \
NULL
/* HANDLE
- template handle
*/ \
)
/* --- Internal Function Prototypes ----------------------------------------- */
void
input_thread
(void *p);
void
output_thread
(void *p);
/* --- Main ----------------------------------------------------------------- */
int main ( int argc, char *argv[])
{
HANDLE
ret_h;
DWORD
ws;
DWORD
retdw;
int
stage=1;
Summary of Contents for Entuitive 1229L
Page 1: ......
Page 11: ...1 6 E l o E n t u i t i v e T o u c h m o n i t o r U s e r G u i d e...
Page 14: ...2 9 Side View Base Bottom View...
Page 43: ...4 38 E l o E n t u i t i v e T o u c h m o n i t o r U s e r G u i d e...
Page 54: ...C 49...
Page 55: ...C 50 E l o E n t u i t i v e T o u c h m o n i t o r U s e r G u i d e...
Page 59: ...54 E l o E n t u i t i v e T o u c h m o n i t o r U s e r G u i d e...
Page 70: ...vii...
Page 71: ...Figure 1 1 USB Swipe Reader viii...
Page 75: ...USB HID Keyboard Emulation Swipe Reader 4...
Page 79: ...USB HID Keyboard Emulation Swipe Reader 8...
Page 81: ...USB HID Keyboard Emulation Swipe Reader 10...
Page 103: ...vi Figure 1 1 Port Powered Swipe Reader...
Page 107: ...Port Powered Swipe Reader 4 Figure 1 3 Dimensions...
Page 111: ...Port Powered Swipe Reader 8...
Page 115: ...Port Powered Swipe Reader 12...
Page 151: ...MagTek Device Drivers for Windows 28...
Page 161: ...MagTek Device Drivers for Windows 38...
Page 175: ...MagTek Device Drivers for Windows 52...
Page 197: ...MagTek Device Drivers for Windows 74...
Page 199: ...MagTek Device Drivers for Windows 76...
Page 201: ...MagTek Device Drivers for Windows 78...
Page 220: ...i Customer Displays 2 by 20 character display USER MANUAL Models LD9000 Series...
Page 249: ......