ePass1000 Full ActiveX Control Reference Manual Version 2.0
ePass1000 Full ActiveX Control Reference Manual Version 2.0
Error Code Value
| Return Status | Description | Value(HEX) | Value(DEC) |
| FT_COMMUNICATIONS_ERROR | Exception occured during transfer data between device and driver. Driver recerved an invalid response from the device. Rarely occur. Try again, reboot the machine and restart the application. | 0x08 | 8 |
| FT_INVALID_RESP_SIZE | Abnormal response received from the device. Rarely occur. Try again, reboot the machine and restart the application. | 0x0D | 13 |
ChangeDir
The ChangeDir method changes the current directory.
HRESULT
ChangeDir(
[in] long lFlags,
[in] long lDirID,
[in[ unsigned char* pName, );
Parameters
lFlags[in] A bit mask defining the options for directory. changing. You may use OR operation to enable one or more options :
| Flag | Meaning | |
|---|---|---|
| EPAS_DIR_BY_ID | When this flag is set, lDirID parameter contain ID of the directory to be changed into. This flag may be combined with EPAS_DIR_FROM_MF or EPAS_DIR_FROM_CUR_DF. lDirID must be a 16-bit directory ID. | |
| EPAS_DIR_BY_LONG_ID | When this flag is set, lDirID parameter contain ID of the directory to be changed into. This flag may be combined with EPAS_DIR_FROM_MF, EPAS_DIR_FROM_CUR_DF, or EPAS_DIR_TO_PARENT. | |
| EPAS_DIR_BY_NAME | When this flag is set, pName parameter contain Application Name of the directory to be changed into. This flag cannot combine with others. | |
| EPAS_DIR_BY_GUID | When this flag is set, pName parameter contain Application GUID of the directory to be changed into. This flag cannot combine with others. | |
| EPAS_DIR_BY_GUID_STR | When this flag is set, pName parameter contain Application GUID string of the directory to be changed into. This flag cannot combine with others. |
此函数的lFlags参数在Private\Include\EPASSAPI.H中的Flags used for directory type部分
#define EPAS_DIR_BY_ID 0x00000100
#define EPAS_DIR_BY_LONG_ID 0x00000200
#define EPAS_DIR_BY_NAME 0x00000300
#define EPAS_DIR_BY_GUID 0x00000400
#define EPAS_DIR_BY_GUID_STR 0x00000500
#define EPAS_DIR_BY_MASK 0x00000f00
OpenDevice
The OpenDevice method finds and opens an ePass1000 for exclusive access, and create a session between application and device for further operation.
HRESULT
OpenDevice(
[in]long lFlags, [in]unsigned char* pAppID);
Requirement
Parameters
- lFlags
- [in]This parameter defines a bit mask of options for opening a device. You may use bit-wise OR operation to select more than one option. This parameter can be a combination of one or more of the following flags:
Flag Meaning EPAS_OPEN_FIRST Open the first found device. This flag can be combined with EPAS_OPEN_BY_NAME, EPAS_OPEN_BY_GUID or EPAS_OPEN_BY_GUID_STR. 0x00000000 EPAS_OPEN_NEXT Open the next device. This flag can be combined with EPAS_OPEN_BY_NAME, EPAS_OPEN_BY_GUID or EPAS_OPEN_BY_GUID_STR. 0x00000001 EPAS_OPEN_CURRENT Open the currently opened device. This flag can NOT be combined with other flags. 0x00000002 EPAS_OPEN_SPECIFIC Open the device, that has same serial number value as which specified by pAppID parameter. This flag can NOT be combined with other flags. 0x00000003 EPAS_OPEN_BY_NAME Open the device containing a directory name pointed to by pAppID. This parameter may be combined with EPAS_OPEN_FIRST or EPAS_OPEN_NEXT. 0x00000100 EPAS_OPEN_BY_GUID Open the device containing a directory GUID as specified by pAppID. This flag must combined with EPAS_OPEN_FIRST or EPAS_OPEN_NEXT. 0x00000200 EPAS_OPEN_BY_GUID_STR Open the device containing a directory GUID as specified by pAppID. This flag must combined with EPAS_OPEN_FIRST or EPAS_OPEN_NEXT. 0x00000300 - pAppID
- [in]This optional parameter provide additional information for the open. This parameter is only used if one of the following flags is assigned. If none of the flags below are assigned, pAppID should be set to NULL.
Flag Meaning EPAS_OPEN_SPECIFIC pAppID point to an array of two unsigned longs which specified serial number of the device to be opened. Use GetProperty function to obtain a device's serial number. EPAS_OPEN_BY_NAME pAppID point to a NULL terminated string that specifies the Application Directory Name to open. If a device is opened, the current directory will be set to the directory ID defined by the Application Directory Name. EPAS_OPEN_BY_GUID pAppID point to an array of 16 bytes that specified the Application Directory GUID to open. If a device is opened, the current directory will be set to the directory ID defined by the Application Directory GUID. EPAS_OPEN_BY_GUID_STR pAppID point to a NULL terminated string that specifies the Application Directory GUID to open. If a device is opened, the current directory will be set to the directory ID defined by the Application Directory GUID. The string format is "{xxxxxxxx - xxxx - xxxx - xxxx - xxxxxxxxxxxx}". Dashes and braces are optional.
Remarks
The order of devices opened (first and next) is based on the order they were detected by the system. To enumerate all devices connected to the system, use EPAS_OPEN_FIRST and EPAS_OPEN_NEXT until FT_UNIT_NOT_FOUND is returned.
Application access to ePass1000 is exclusive. Only one application can open an ePass1000 at one time. If any other application attempt to open this ePass1000, will get return code FT_DEVICE_IN_USE.
You can open specific ePass1000 by combining EPAS_OPEN_FIRST, EPAS_OPEN_NEXT flags with EPAS_OPEN_BY_NAME , EPAS_OPEN_BY_GUID, or EPAS_OPEN_BY_GUID_STR.
If you known serial number of the ePass1000 you intend to open, use EPAS_OPEN_SPECIFIC.
Return Values
If the function succeeds, FT_SUCCESS returned.
If the library failed to open the device driver, FT_CANNOT_OPEN_DRIVER is returned.
If the library do not support version of the driver, FT_INVALID_DRVR_VERSION is returned.
If there is no device connected to the system currently, FT_UNIT_NOT_FOUND is returned.
If the device is already opened by another application, FT_DEVICE_IN_USE is returned.
For a list of all return codes, see Error Code Values.
////
/// Flags used by epas_OpenDevice()
//
#define EPAS_OPEN_NEXT 0x00000000
#define EPAS_OPEN_FIRST 0x00000001
#define EPAS_OPEN_CURRENT 0x00000002
#define EPAS_OPEN_SPECIFIC 0x00000003
#define EPAS_OPEN_MASK 0x00000007
#define EPAS_OPEN_BY_NAME 0x00000100
#define EPAS_OPEN_BY_GUID 0x00000200
#define EPAS_OPEN_BY_GUID_STR 0x00000300
#define EPAS_OPEN_BY_MASK 0x00000F00
ePass1000 Full ActiveX Control Reference Manual Version 2.0的更多相关文章
- This manual page is part of Xcode Tools version 5.0
https://developer.apple.com/library/mac/documentation/Darwin/Reference/ManPages/man1/xcodebuild.1.ht ...
- Sphinx 2.2.11-release reference manual
1. Introduction 1.1. About 1.2. Sphinx features 1.3. Where to get Sphinx 1.4. License 1.5. Credits 1 ...
- 一个ActiveX control的创建过程
创建 根据这篇文章的介绍:http://www.cnblogs.com/time-is-life/p/6354152.html 来创建,里面包含了创建的基本过程以及属性事件方法的使用. 使用: 参考文 ...
- How to develop and deploy ActiveX control in C#
Link:https://blogs.msdn.microsoft.com/asiatech/2011/12/05/how-to-develop-and-deploy-activex-control- ...
- 阅读Cortex-A53 Technical Reference Manual笔记
1. 前言 一颗芯片最主要的就是CPU核了,处理CPU Core之外,还存在很多其他IP,包括Graphical.Multimedia.Memory Controller.USB Controller ...
- official shiro(Reference Manual)
Apache Shiro Reference Documentation Overview Core Spring-based Applications 1.Overview pom.xml < ...
- ASP.NET Core: You must add a reference to assembly mscorlib, version=4.0.0.0
ASP.NET Core 引用外部程序包的时候,有时会出现下面的错误: The type 'Object' is defined in an assembly that is not referenc ...
- OpenCASCADE6.8.0 Reference Manual Serach Problem
OpenCASCADE6.8.0 Reference Manual Serach Problem eryar@163.com 1. Problem 有网友反映OpenCASCADE6.8.0的Refe ...
- OCX控件在IE中无法侦测到键盘消息( MFC ActiveX Control in IE Doesn't Detect Keystrokes)
症状描述: Accelerator keys, such as ARROW keys, are first received by the message pump of the ActiveX co ...
随机推荐
- 编写更好的C#代码
引言 开发人员总是喜欢就编码规范进行争论,但更重要的是如何能够在项目中自始至终地遵循编码规范,以保证项目代码的一致性.并且团队中的所有人都需要明确编码规范所起到的作用.在这篇文章中,我会介绍一些在我多 ...
- [百度地图] ZMap 与 MultiZMap 封装类说明;
ZMap.js 与 MultiZMap 说明 1. ZMap 与 MultiZMap 都是封装一些地图常用的使用方法,类方法功能大多使用 prototype 原型 实现: ZMap 在一个页面只能使用 ...
- WCF中安全的那些事!!!
WCF默认绑定 WCF预先为所有绑定都定义了能满足大多数情形的配置模式,这样的话,只要没有修改某个配置参数,WCF就使用默认的安全模式. 先上一张默认的安全设置表格 绑定 设置 wsHttpBindi ...
- iOS: ARC & MRC下string内存管理策略探究
ARC & MRC下string内存管理策略探究 前两天跟同事争论一个关于NSString执行copy操作以后是否会发生变化,两个人整了半天,最后写代码验证了一下,发现原来NSString操作 ...
- hadoop之 flume1.6安装
flume 1.6安装1.解压 2.复制 cp conf/flume-conf.properties.template conf/flume.conf cp conf/flume-env.sh.tem ...
- 一种map容器遍历的方法
遍历算法是一种很常见而且非常重要的算法,我们用map容器的时候可能用的比较多的是查找,我今天才第一次要用到遍历.下面举个例子就知道了. map<string,string> mp; str ...
- cocos2d内存管理
设想如下场景, 这是一个典型的内存合理分配的场景: 在一帧内, 有若干个函数, 每个函数都会创建一系列的精灵, 每个精灵都不同, 都会占用一定的内存, 精灵的总数可能会有1000个, 而一个函数只会创 ...
- dispaly:table-cell,inline-block,阐述以及案例
display:table 此元素会作为块级表格来显示(类似 <table>),表格前后带有换行符.dispaly:table-row 此元素会作为一个表格行显示(类似 <tr> ...
- 跟着百度学PHP[4]OOP面对对象编程-9-封装性,访问控制[private、pubic、protected]
其实之前就已经在封装的时候说到了.这个也属于封装的范畴吧. 用到的三个关键字(旁边是其中文翻译) private(私有的) public(公众的) protected(受保护的) 00X1 priva ...
- Android坐标系统
1 背景 去年有很多人私信告诉我让说说自定义控件,其实通观网络上的很多博客都在讲各种自定义控件,但是大多数都是授之以鱼,却很少有较为系统性授之于渔的文章,同时由于自己也迟迟没有时间规划这一系列文章, ...