Innodisk EZU2-I301 User manual

USB to I2C
SYSINNO Sensor Carrier Board
EZU2-I301
User Manual
Rev 1.0
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

i
2005-2023 © Innodisk Corporation. All Rights Reserved
Copyright Information
2005-2023 ©Innodisk Corporation. All Rights Reserved
Innodisk™ is trademark or registered trademark of Innodisk Corporation.
This document is subject to change and revision without notice. No part of this
document may be reproduced in any form by any photographic, electronic,
mechanical or other means, or used in any information storage and retrieval system,
without prior written permission from Innodisk Corporation.
All other product and brand names in this document are trademarks or registered
trademarks of their respective owners.
版權說明
2005-2023 ©宜鼎國際股份有限公司
Innodisk™ 是宜鼎國際股份有限公司之註冊商標。
本文件得不經通知即更改或修訂。本文件中出現任何文字敘述、文件格式、圖
形、照片、方法及過程等內容,除另特別註明,版權均屬宜鼎國際股份有限公
司所有,受到相關之智慧財產權保護法之保障。任何個人、法人或機構未經宜
鼎國際股份有限公司的書面(包括電子文件)授權,不得以任何形式複製或引
用本文件之全部或片段。
其他出現在本文件的品牌或產品乃歸屬原公司所有之商標或註冊。
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

ii
2005-2023 © Innodisk Corporation. All Rights Reserved
Revision History
Revision
Date
Description
1.0
2023/07/20
Initial Release
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

iii
2005-2023 © Innodisk Corporation. All Rights Reserved
Table of Contents
Revision History..................................................................................................................ii
Table of Contents ...............................................................................................................iii
Hardware Installation.....................................................................................................1
1.1. Carrier Board............................................................................................................1
1.2. PM2.5 ......................................................................................................................1
1.3. Other Sensor............................................................................................................2
Windows OS...................................................................................................................3
2.1. Driver Installation......................................................................................................3
2.2. Sample Code ...........................................................................................................4
Linux OS.........................................................................................................................6
3.1. Driver Installation......................................................................................................6
3.2. Sample Code ...........................................................................................................6
Software API...................................................................................................................8
4.1. UISMShowVer..........................................................................................................8
4.2. UISMDebugLevel .....................................................................................................8
4.3. UISMOpenDevice.....................................................................................................9
4.4. UISMCloseDevice ....................................................................................................9
4.5. UISMSensorInfo .......................................................................................................9
4.6. UISMInit .................................................................................................................10
4.7. UISMQuery ............................................................................................................11
4.8. Error Codes............................................................................................................11
Contact us .........................................................................................................................13
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

1
2005-2023 © Innodisk Corporation. All Rights Reserved
Hardware Installation
1.1. Carrier Board
The board comes with a USB cable (9pin to 4pin) can connect USB 9pin connector
on motherboard to CN1.
1.2. PM2.5
PM 2.5 sensor comes with a cable can connector to CN2 of sensor carrier board.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

2
2005-2023 © Innodisk Corporation. All Rights Reserved
1.3. Other Sensor
Other sensors, which have two rows pins (4pin + 5pin) can install on the sensor
carrier, board directly.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

3
2005-2023 © Innodisk Corporation. All Rights Reserved
Windows OS
2.1. Driver Installation
Sensor carrier board uses OS native HID driver.
The device vendor ID “0x067B” can be found in “Device Manager”.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

4
2005-2023 © Innodisk Corporation. All Rights Reserved
2.2. Sample Code
Adjust “Setup.ini” according to the needs of the test. The details of individual
parameters are as follows.
debug_level:
Adjust different levels of debug level according to requirements.
(0=DBG_LVL_NONE, 1=DBG_LVL_FUNC, 2=DBG_LVL_HID)
Interval:
Set the data update interval of the selected monitoring sensor.
(unit: millisecond)
auto_scan:
Whether to use the Query function in the SDK to automatically detect the
existing sensor module on the device.
When the "auto_scan" is enabled, the "sensor" section will be ignored.
(0=disable, 1=enable)
check_status:
Whether to provide the status information of the sensor module at the same
time when returning data.
(0=disable, 1=enable)
“sensor option” section:
When the ‘auto_scan’ item is disabled, use this section to specify the sensor
module to be selected.
The detailed and latest information can be found in the description of
sample\setup.ini.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

5
2005-2023 © Innodisk Corporation. All Rights Reserved
The execution diagram of the sample code.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

6
2005-2023 © Innodisk Corporation. All Rights Reserved
Linux OS
3.1. Driver Installation
Sensor carrier board uses OS native HID driver. Supports Linux kernel 2.6.38 and above.
Use “lsusb” command to make sure the device is recognized by OS.
3.2. Sample Code
Adjust “Setup.ini” according to the needs of the test. The details of individual
parameters are as follows.
debug_level:
Adjust different levels of debug level according to requirements.
(0=DBG_LVL_NONE, 1=DBG_LVL_FUNC, 2=DBG_LVL_HID)
Interval:
Set the data update interval of the selected monitoring sensor.
(unit: millisecond)
auto_scan:
Whether to use the Query function in the SDK to automatically detect the
existing sensor module on the device.
When the "auto_scan" is enabled, the "sensor" section will be ignored.
(0=disable, 1=enable)
check_status:
Whether to provide the status information of the sensor module at the same
time when returning data.
(0=disable, 1=enable)
“sensor option” section:
When the ‘auto_scan’ item is disabled, use this section to specify the sensor
module to be selected.
The detailed and latest information can be found in the description of
sample\setup.ini.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

7
2005-2023 © Innodisk Corporation. All Rights Reserved
The execution diagram of the sample code.
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

8
2005-2023 © Innodisk Corporation. All Rights Reserved
Software API
UISM API is based on a dynamic library (DLL) in Windows/Linux to control USB to I2C
SYSINNO Sensor Carrier Board.
Please refer to the following table for UISM APIs:
ID
Function Name
4.1
UISMShowVer
4.2
UISMDebugLevel
4.3
UISMOpenDevice
4.4
UISMCloseDevice
4.5
UISMSensorInfo
4.6
UISMInit
4.7
UISMQuery
4.1. UISMShowVer
int UISMShowVer (VER_INFO *ver_info)
Function: get version information.
Parameters:
ver_info: version information.
typedef struct
{
char api[VER_LEN];
}
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.2. UISMDebugLevel
int UISMDebugLevel (int level)
Function: Set Debug level of SDK.
Parameters:
level: Debug level Number
enum
{
DBG_LVL_NONE = 0,
DBG_LVL_FUNC,
DBG_LVL_HID,
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

9
2005-2023 © Innodisk Corporation. All Rights Reserved
};
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.3. UISMOpenDevice
int UISMOpenDevice (void)
Function: Open HID device.
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.4. UISMCloseDevice
int UISMCloseDevice (void)
Function: Close HID device.
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.5. UISMSensorInfo
int UISMSensorInfo (SENSOR_INFO *sensor_info)
Function: Get the specified sensor module information.
Parameters:
sensor_info: The pointer of the sensor module information structure.
typedef struct
{
/*----- input variable from user to API -----*/
int name;
/*----- output variable from API to user -----*/
unsigned char PID[PID_LEN + 1];
unsigned char FW_ver[FW_LEN + 1];
unsigned char SN[SN_LEN + 1];
unsigned char status;
} SENSOR_INFO;
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

10
2005-2023 © Innodisk Corporation. All Rights Reserved
/* Sensor name */
#define SENSOR_NAME_HCHO 0x00000001
#define SENSOR_NAME_PM 0x00000002
#define SENSOR_NAME_CO2 0x00000004
#define SENSOR_NAME_CO 0x00000008
#define SENSOR_NAME_O3 0x00000010
#define SENSOR_NAME_TVOC 0x00000020
#define SENSOR_NAME_TH 0x00000040
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.6. UISMInit
int UISMInit (bool status, INIT_INFO *init_info)
Function: The data return of starting or stopping the SDK and setting the initial parameters.
Parameters:
status: Set the data return of starting or stopping the SDK.
/* INIT */
enum
{
INIT_STS_STOP = 0,
INIT_STS_START,
};
Init_info: The pointer of the initial information structure.
typedef struct
{
unsigned int interval; /* unit: ms */
int monitor_opt;
bool check_status;
DATA_CB data_cb;
} INIT_INFO;
monitor_opt: The value after performing the OR operator on the sensor module names to be
returned (for example, if you want to return CO2 and O3, that is SENSOR_NAME_CO2 |
SENSOR_NAME_O3 = 0x00000014), or you can use the UISMQuery() API to obtain the results
of all current sensor modules for use.
typedef void (*DATA_CB) (int error_code, int name, DATA_INFO *info);
typedef struct
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

11
2005-2023 © Innodisk Corporation. All Rights Reserved
{
unsigned char *data1;
int data1_len;
unsigned char *data2;
int data2_len;
unsigned char status;
} DATA_INFO;
Return Value:
If the function succeeds, the return value is zero. If the function fails, the return value is
nonzero and the error code generated by the API. Refer to section Error Codes to find more
information.
4.7. UISMQuery
int UISMQuery (int *result)
Function: Obtain the results of all current sensor modules.
Parameters:
result: The pointer used to store the query result.
Return Value:
If the function succeeds, the return value is filter total count - 1 (0-14, MAX: 15). If the
function fails, the return value is error code generated by the API. Refer to section Error
Codes to find more information.
4.8. Error Codes
The below table lists errors that functions API returns in response to calls. The detailed
and latest information can be found in the description of library\header\liblism.h.
Error Code
Description
0
Success
1
Found HID device error
2
HID device can't found (Device count is 0)
3
Open HID device error
4
Close HID device error
5
Initial HID device error
6
Exit HID device error
11
Set I2C frequency error
12
Set I2C address error
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

12
2005-2023 © Innodisk Corporation. All Rights Reserved
13
I2C get information error
21
This function is only supported when the device is opened
22
This function is only supported when the device is closed
23
This function is only supported when the device is started
24
This function is only supported when the device is stopped
25
Input invalid variable to API
31
Invalid sensor name
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com

13
2005-2023 © Innodisk Corporation. All Rights Reserved
Contact us
Headquarters (Taiwan)
5F., No. 237, Sec. 1, Datong Rd., Xizhi Dist., New Taipei City 221, Taiwan
Tel: +886-2-77033000
Email: [email protected]
Branch Offices:
USA
usasales@innodisk.com
+1-510-770-9421
Europe
eusales@innodisk.com
+31-40-3045-400
Japan
jpsales@innodisk.com
+81-3-6667-0161
China
sales_cn@innodisk.com
+86-755-21673689
www.innodisk.com
© 2023 Innodisk Corporation.
All right reserved. Specifications are subject to change without prior notice.
July 20, 2023
ES France - Mobilité & Systèmes Embarqués
127 rue de Buzenval BP 26 - 92380 Garches
Tél. 01 47 95 99 80
Fax. 01 47 01 16 22
e-mail : mse@es-france.com
Site Web : www.es-france.com
Table of contents