ZS-6222A Series
USB/DIO Adapter
instruction manual

2nd edition

2-13-37 Honmachi, Fuchu City, Tokyo 183-0027
Phone: +81-42-368-2126 Fax: +81-42-364-0067
URL https://www.zenisu.co.jp/

1◆ Contents ◆1. Overview ................................................................................................................................. 3
2. Features .................................................................................................................................. 3
3. Specifications .......................................................................................................................... 3
3.1.Operating environment .................................................................................................... 3
3.2.USB ................................................................................................................................... 3
3.3. Digital I/O Port ................................................................................................................ 4
3.4. Product specifications ...................................................................................................... 4
3.5. Appearance and dimensional drawing ............................................................................ 5
4. How to install ......................................................................................................................... 6
4.1.Installation on Windows 10/11 ......................................................................................... 64. 2 .Installation on Windows 7/8 ........................................................................................... 64. 3 .Installation on Windows Vista/ XP /2000 ...................................................................... 75. Operation ................................................................................................................................ 85.1.Transfer data method ....................................................................................................... 85.2. Control Signals ................................................................................................................ 95.3. Input/output operation .................................................................................................. 105.4. Command list ................................................................................................................. 115.4.1. R command .............................................................................................................. 115.4.2. W command ............................................................................................................. 115.4.3. T command .............................................................................................................. 125.4.4. C command .............................................................................................................. 125.4.5. D command .............................................................................................................. 125.4.6. P command .............................................................................................................. 125.4.7. L command .............................................................................................................. 13
5.4.8. U command .............................................................................................................. 13
5.4.9. B Command ............................................................................................................. 13
5.4.10. I Command ............................................................................................................ 13
6. Connector table..................................................................................................................... 14
7. Warranty ............................................................................................................................... 152

1. Overview
The ZS-6222A is a unit that communicates digital I/O signals and USB.
By connecting to a Windows PC with a USB interface, various measuring instruments with BCD
output or User-specific device control and data collection can be performed.

2. Features①②③

Measurement control can be easily performed from the USB port of a personal computer.
There are 4 ports (8 bits/port) for digital I/O signals, each with input/output selection foreach port.
In addition to data, a control line is provided to synchronize with an external device.

3. Specifications
3.1.Operating environment


PC
OS

: IBM PC/AT compatible machine (USB port required): Microsoft Windows 2000, XP, Vista, 7 , 8, 10, 11: Linux: Mac* We have not confirmed the operation of Linux and Mac.

3.2.USB
USB 2.0 compliant (full speed compatible)33.3. Digital I/O Port

Number of ports
Input/output level: 4 ports (8 bits/port): Fan-in = 1
Fan-out = 10
Pull-up resistor 10KΩ (factory setting) Can also be set to pull-down

3.4. Product specifications
ModelZS-6222AP

ZS-6222AS

Features

Printed circuit board, embedded, low price

Small case, low price

Data connector

50-core flat cable

50-core flat cable

Power supply

DC4.75V to 5.25V 100mA or lessDC4.75V to 5.25V 100mA or less

Usage environment Temperature 0°C to 50°C Humidity 85% max. Temperature 0°C to 50°C Humidity 85% max.
Storagetemperature-20°C to 80°C
-20°C to 80°C
Externaldimensions
74 x 100 x about 20 ( H )80 x 110 x about 30 (H)data connector FAS-5001-2101-0BF
data connector FAS-5001-2101-0BF( Yamaichi )( Yamaichi )Accessories
DC power cable4

3.5. Appearance and dimensional drawing
・ZS-6222AP (PC board type)・ZS-6222AS (small case type)・Dimensional drawing
ZS-6222AP

ZS-6222AS

5

4. How to install
4.1.Installation on Windows 10/11
If you have Windows 10 / 11 installed and are connected to the Internet, the driver will be
automatically downloaded and installed by simply connecting the instrument to your PC.
If the driver is not installed automatically, download the driver from our website and install
it manually.
Please refer to "4.2. Installation on Windows 7 / 8" for the manual procedure.
Although some screens may be different, the overall process is the same.

4. 2 .Installation on Windows 7/8
To use this instrument in a Windows 7 / 8 environment, it is necessary to first install thehardware and device drivers according to the following procedure.
① Install the device driver on your PC② Connect the instrument and the computer with a USB cable.
③ Installation completed (reboot in some cases)
The following is an explanation of how to install the device driver for the ①.
The following screenshots may differ in text display, etc., depending on the PC configurationand Windows version, but they are basically the same.
The following is an example on Windows 7.
When you start the device driver setup program "CDM212364_Setup.exe" downloaded fromour website, the following screen will appear.
If the User Account Control screen appears, click "Yes" to proceed.

" Extract " button. ※The following screenshots are from the Japanese version.

Click the "Next" button.
6

Check "I agree" and click the "Next" button.

Depending on the version of Windows, this screen may be displayed, but click " Install thisdriver software anyway ".

Device driver installation is complete. Click "Finish".
the installation method of the device driver, and when you connect the instrument and thecomputer with a USB cable, the setup will be completed automatically, and the COM port
connection will be possible.
Depending on the configuration of your computer, you may be asked to restart. In that case,follow the on-screen instructions. Please reboot.

4. 3 .Installation on Windows Vista/ XP /2000
Windows Vista / XP / 2000 is installed, it is necessary to obtain an older version of the driverfrom FTDI 's HP and install it.
https://ftdichip.com/drivers/vcp-drivers/
the link " setup executable " in " comments " from the column of the target OS and downloadit.
Please refer to " 4.2.Installation on Windows 7/8 " for the procedure after downloading .
7

5. Operation
5.1.Transfer data method① The ZS-6222A communicates via COM port. After installing the device driver, "USB SerialPort (COM x)" will appear in the "Ports (COM and LPT)" column of the device manager ofeach OS.
USB Serial Port (COM x)" in the "Port (COM and LPT)" column of the device manager of
each OS. (x is a number. The value varies depending on the connection environment.)
When creating a program, open it according to the COM number displayed.
② Data code assignment table
ASCII code is used for data transfer, and one character is converted to 4-bit binary code.
84-bit binary
421

USB dataHEX000000001100102001130

100

401015011060111

71000

8

1001

910

10A

1011B

1100C

1101D

1111

1
10
1EF

8

③ Data sent from a personal computer is transferred sequentially from the smallest port
number set for output.
The port set for input also takes data sequentially from the smallest number and sends itto the personal computer.
Data for each port is set or read in 4-bit increments.
 Example: When ports 1 and 2 are set to input and ports 3 and 4 are set to output
Send to PC
order to doport data

Order of output
to ZS-6222A ports

port data123
4

D7 to D4 of port 1
D3 to D0 of port 1
D7 to D4 of port 2
D3 to D0 of port 2

123
4

D7 to D4 of port 3
D3 to D0 of port 3
D7 to D4 of port 4
D3 to D0 of port 4

5.2. Control Signals
A control signal is provided to synchronize with the connected device.
Signalnamesignaldirection

explanation
The adapter completes receiving all data from the PC and outputs aSTB

OUT

pulse signal after output to the port.
External devices can use this signal for Latch-Clock or other purposes
as needed.

TRG

OUT

Pulse signals are output to external devices by the "T" command.

CLROUT

LAH

IN

Pulse signals are output to external devices by the "C" command.
This can be used to reset external devices.
When the latch circuit is enabled (set by "L" command), input data islatched with this signal.
Input a signal with a pulse width of 500us or more.

Note) Output pulse width can be set by command.
The pulse widths that can be set are 10µs, 100µs, 1ms, 10ms, and 100ms.

9

5.3. Input/output operation① Output data from PC to port
 continuous output
After receiving the data from the PC, send the data to the port set for output.
Set data in 4-bit units (in the order of high order and low order).
After setting the data to the output port, the STB pulse is output.
Note) If more data than the output port setting is sent, the extra data will be discarded.
If less data than the output port setting is sent, the previously sent data will remainin the missing area.

pulse output
After receiving the data from the PC, send the data to the port set for output.
Set data in 4-bit units (in the order of high order and low order).
Output port data is output only for the specified pulse width.

② Send data input from port to PC
 No latch
When the ZS-6222A receives an "R" command from the PC, it takes data from theinput port at that time (in the order of upper and lower) and sends it to the PC.
 with latch
Data from the input port is captured when the LAH input is Low.
When the ZS-6222A receives the "R" command from the PC, it sends the data to thePC when it is captured as described above.

10

5.4. Command list
The ZS-6222A recognizes the first byte of data as a control command and controls it.
Also, be sure to add a delimiter (CR+LF) at the end of the data string before sending.
If there is a character string other than the command at the beginning of the data, NG will besent as the return value.
The commands are as follows.
commandfunction
RReads data from all ports set as inputs
W
Writes data to a port set to output
TOutput pulse from TRG signal
C
Output pulse from CLR signal
D
Configure port input/output settings
P
Sets the pulse width of the control signal
L
Sets the presence or absence of the latch circuitU
Set the output signal
B
Sets the positive/negative logic of the port
I
Reads data from all ports regardless of input/output settings※ The I command was added in Ver. 2.00.

5.4.1. R commandfunction
Data is read from all ports that are set as inputs. For example, if 4 input ports areset, the "R" command will send 8 bytes of data from the ZS-6222A.
formatR CR LF
return valuexxxx・・・CR LF : The number of data set in the input port is sent.
NG CR LF

x is an ASCII code from 0 to F: No input port

5.4.2. W command

function
Data is written to the ports set for output.
For example, if four output ports are set, the "W" command is followed by 8 bytes ofdata to be sent to the ZS-6222A.
If less than 8 bytes of data is sent, the amount of data sent will be newly changed,
and the previous data will be retained in the missing parts.
formatWxxxx・・・CR LF : Write the data to be output to the output port after "W"
x is an ASCII code from 0 to Freturn value
OK CR LF
NG CR LF

: Completion of data output to the output port
: No output port, wrong data character error

115.4.3. T commandfunctionOutput a pulse to the control signal "TRG"
formatT CR LF
return value
OK CR LF
: Pulse output complete
NG CR LF
: Pulse output error

5.4.4. C commandfunction
Output a pulse to the control signal "CLR"
formatC CR LF
return value: Pulse output complete
OK CR LF
NG CR LF
: Pulse output error

5.4.5. D commandfunction
Input/output settings for the four ports.
When the ZS-6222A is powered on, all are set to input.
formatI CR LF
return value
OK CR LF
: Setting completed
NG CR LF
: Input/output setting error, setting character error

5.4.6. P commandfunction
The pulse widths of the control signals "STB," "TRG," and "CLR" and the pulse width
at data output can be set from one of five types: 10µs, 100µs, 1ms, 10ms, and 100ms.
When the ZS-6222A is powered on, it is set to 10µs.
formatPx CR LF
: x is a number. The number assignment is as follows.
0...10 µs, 1...100 µs, 2...1 ms
3...10ms, 4...100ms
return value
OK CR LF
: Setting complete
NG CR LF
: Setting error, wrong setting error

125.4.7. L commandfunction
It can be set with or without latch circuit at the time of data input.
When the ZS-6222A is powered on, it is set to no latch circuit.
format: x is a number, "0" if no, "1" if yes.
Lx CR LF
return value
OK CR LF
: Setting complete
NG CR LF
: Setting error, wrong setting error

5.4.8. U commandfunction
This is used to set the signal setting for data output.
When the ZS-6222A is turned on, it is set to continuous output.
The pulse width at the time of pulse output is set by the P command.
formatUx CR LF
: x is a number, "0" for continuous output and "1" for pulse output.
return value: Setting complete
OK CR LF
NG CR LF
: Setting error, wrong setting error

5.4.9. B Command

function
Positive and negative logic settings for the four ports.
When the ZS-6222A is powered on, all are set to positive logic.
This command should be performed when the ports are set to input.
formatBx CR LF
: x is a number, "0" for positive logic and "1" for negative logic.
return value
OK CR LF: Setting complete
NG CR LF
: Setting error, wrong setting error

5.4.10. I Commandfunction
Data is read from all ports regardless of input/output settings.
Data is read from ports that are set to output, regardless of the input/output settings.
When the "I" command is issued, 8 bytes of data are sent from the ZS-6222A.
formatI CR LF
return value
xxxxxxxxCR LF : Data (8 bytes) for all 4 ports is sent.
x is an ASCII code from 0 to F13

6. Connector table
Data connector (used connector FAP-5001-1202-0BF (Yamaichi))
DATA (CN1)
I/O
SIGNALPIN
SIGNAL
I/O
D01 2
D0
D1
3 4
D1
D25 6
D2PORT
D37 8
D3PORT①②
D49 10
D4
D511 12
D5
D613 14D6
D715 16D7
D017 18
D0
D119 20
D1
D221 22
D2
PORT
D323 24
D3PORT③④
D425 26
D4
D527 28
D5
D629 30
D6
D731 32
D7IN
LAH
33 34+5V
OUT
STBs
35 36+5V
OUT
TRG
37 38+5V
OUT
CLR39 40+5V(NC)41 42
GND(NC)
43 44
GND(NC)
45 46
GND(NC)
47 48
GND(NC)
49 50
GNDNote) PIN 34, 36, 38, and 40 are (NC) in the former model ZS-6222 and +5V in the ZS-6222A.
Note) I/O indicates the direction between signals between the ZS-6222A adapter and thedigital I/O signal input/output device.
IN: ZS-6222A ← External device
OUT: ZS-6222A → external device
PORT : Bi-directional data bus.
You can switch IN/OUT by D command setting

147. Warranty①②Although Minebea's products are delivered under strict quality control and inspection, in theunlikely event of a malfunction, we will repair the product free of charge only under thefollowing conditions.
 If the product malfunctions during the warranty period (one year from the date ofpurchase) under normal conditions of use in accordance with the instruction manualand other notes.
In the following cases, the product will be repaired for a fee even during the warranty period.
 Malfunction or damage caused by improper use or carelessness
 Malfunction or damage caused by improper repair or modification Malfunction or damage caused by fire, earthquake, other natural disasters,
earthquakes, or external factors such as abnormal voltage damage
 Replacement of consumable parts
 Change of power supply or voltage

15