API
Applications
Utilities
API
Handbook
GitHub
Home
ArcusPerformaxDriver.h
Go to the documentation of this file.
1
#ifndef _ARCUSPERFORMAXDRIVER_H_
2
#define _ARCUSPERFORMAXDRIVER_H_
3
4
//libusb standard header file
5
#include "libusb-1.0/libusb.h"
6
7
//these are defined by Arcus
8
#define PERFORMAX_RETURN_SERIAL_NUMBER 0x0
9
#define PERFORMAX_RETURN_DESCRIPTION 0x1
10
#define PERFORMAX_MAX_DEVICE_STRLEN 256
11
12
//these defines are to conveniently turn these types transparent
13
//note: C does not have a bool type.
14
typedef
int
AR_BOOL
;
15
typedef
long
AR_DWORD
;
16
typedef
void
AR_VOID
;
17
//typedef usb_dev_handle* AR_HANDLE;
18
typedef
libusb_device_handle*
AR_HANDLE
;
19
20
//the function definitions are the same as the windows API
21
AR_BOOL
fnPerformaxComGetNumDevices
(
AR_DWORD
*numDevices);
22
AR_BOOL
fnPerformaxComGetProductString
(
AR_DWORD
dwNumDevice,
AR_VOID
*lpDeviceString,
AR_DWORD
dwOptions);
23
AR_BOOL
fnPerformaxComOpen
(
AR_DWORD
dwDeviceNum,
AR_HANDLE
*pHandle);
24
AR_BOOL
fnPerformaxComClose
(
AR_HANDLE
pHandle);
25
AR_BOOL
fnPerformaxComSetTimeouts
(
AR_DWORD
dwReadTimeout,
AR_DWORD
dwWriteTimeout);
26
AR_BOOL
fnPerformaxComSendRecv
(
AR_HANDLE
Handle,
AR_VOID
*wBuffer,
AR_DWORD
dwNumBytesToWrite,
AR_DWORD
dwNumBytesToRead,
AR_VOID
*rBuffer);
27
AR_BOOL
fnPerformaxComFlush
(
AR_HANDLE
Handle);
28
29
//the following does _not_ need to be called before using the other functions. It is safe to ignore its existence
30
AR_BOOL
InitializePerformaxLibrary
(
AR_VOID
);
31
32
#endif
33
AR_VOID
void AR_VOID
Definition:
ArcusPerformaxDriver.h:16
InitializePerformaxLibrary
AR_BOOL InitializePerformaxLibrary(AR_VOID)
Definition:
ArcusPerformaxDriver.c:258
fnPerformaxComGetNumDevices
AR_BOOL fnPerformaxComGetNumDevices(AR_DWORD *numDevices)
Definition:
ArcusPerformaxDriver.c:36
AR_BOOL
int AR_BOOL
Definition:
ArcusPerformaxDriver.h:14
fnPerformaxComGetProductString
AR_BOOL fnPerformaxComGetProductString(AR_DWORD dwNumDevice, AR_VOID *lpDeviceString, AR_DWORD dwOptions)
Definition:
ArcusPerformaxDriver.c:88
fnPerformaxComSetTimeouts
AR_BOOL fnPerformaxComSetTimeouts(AR_DWORD dwReadTimeout, AR_DWORD dwWriteTimeout)
Definition:
ArcusPerformaxDriver.c:195
fnPerformaxComFlush
AR_BOOL fnPerformaxComFlush(AR_HANDLE Handle)
Definition:
ArcusPerformaxDriver.c:241
fnPerformaxComOpen
AR_BOOL fnPerformaxComOpen(AR_DWORD dwDeviceNum, AR_HANDLE *pHandle)
Definition:
ArcusPerformaxDriver.c:144
AR_HANDLE
libusb_device_handle * AR_HANDLE
Definition:
ArcusPerformaxDriver.h:18
fnPerformaxComClose
AR_BOOL fnPerformaxComClose(AR_HANDLE pHandle)
Definition:
ArcusPerformaxDriver.c:177
fnPerformaxComSendRecv
AR_BOOL fnPerformaxComSendRecv(AR_HANDLE Handle, AR_VOID *wBuffer, AR_DWORD dwNumBytesToWrite, AR_DWORD dwNumBytesToRead, AR_VOID *rBuffer)
Definition:
ArcusPerformaxDriver.c:206
AR_DWORD
long AR_DWORD
Definition:
ArcusPerformaxDriver.h:15
apps
acesxeCtrl
ArcusPerformaxDriver.h
Generated by
1.9.1