Shimadzu OMRON CJ Series Instruction Manual

Programmable Controller CJ-series
General-purpose Serial
Connection Guide
(RS-232C)
SHIMADZU CORPORATION
Shimadzu Analytical Balance /
Electronic Balance
(ATX-R/ATY-R/UPX/UPY/UW/UX Series)
P732-E1-01

About Intellectual Property Rights and Trademarks
Microsoft product screen shots reprinted with permission from Microsoft Corporation.
Windows is a registered trademark of Microsoft Corporation in the USA and other countries.
Company names and product names in this guide are the trademarks or registered trademarks of
their respective companies.

Contents
1. Related Manuals........................................................................................ 1
2. Terms and Definitions............................................................................... 2
3. Precautions................................................................................................ 3
4. Overview .................................................................................................... 4
5. Applicable Devices and Device Configuration ....................................... 5
5.1. Applicable Devices............................................................................. 5
5.2. Device Configuration.......................................................................... 6
6. Serial Communications Settings ............................................................. 8
6.1. Parameters ........................................................................................ 8
6.2. Cable Wiring ...................................................................................... 9
7. Serial Communications Connection Procedure ....................................11
7.1. Work Flow.........................................................................................11
7.2. SHIMADZU Balance Setup.............................................................. 13
7.3. PLC Setup........................................................................................ 21
7.4. Serial Communication Status Check................................................ 40
8. Initialization Method................................................................................ 48
8.1. Initializing a PLC .............................................................................. 48
8.2. Initializing a SHIMADZU Balance..................................................... 49
9. Program.................................................................................................... 50
9.1. Overview.......................................................................................... 50
9.2. Communications Sequence............................................................. 55
9.3. Error Detection Processing .............................................................. 57
9.4. Memory Maps .................................................................................. 58
9.5. Ladder Program............................................................................... 61
9.6. Protocol Data ................................................................................... 67
9.7. Timing Chart .................................................................................... 75
9.8. Error processing............................................................................... 76
10. Revision History...................................................................................... 78

1.Related Manuals
1
1. Related Manuals
To ensure system safety, make sure to always read and follow the information provided in all
Safety Precautions and Precautions for Safe Use in the manuals for each device which is
used in the system.
The table below lists the manuals provided by SHIMADZU CORPORATION (hereinafter
referred to as "SHIMADZU") and OMRON Corporation (hereinafter referred to as "OMRON"),
which pertain to this guide.
Manufacturer
Cat. No.
Model
Manual name
OMRON W472 CJ2M-CPU□□
CJ2H-CPU6□
CJ2H-CPU6□-EIP
CJ Series
CJ2 CPU Unit
Hardware USER'S MANUAL
OMRON W473 CJ2M-CPU□□
CJ2H-CPU6□
CJ2H-CPU6□-EIP
CJ Series
CJ2 CPU Unit
Software USER'S MANUAL
OMRON W336 CJ1W-SCU□1-V1
CJ1W-SCU□2 CJ Series
Serial Communications Units
OPERATION MANUAL
OMRON W474 CJ2□-CPU□□ CJ Series Programmable Controllers
INSTRUCTIONS REFERENCE
MANUAL
OMRON W446 CXONE-AL□□C-V4
/ AL□□D-V4 CX-Programmer
OPERATION MANUAL
OMRON W344 CXONE-AL□□C-V4
/ AL□□D-V4 CX-Protocol
OPERATION MANUAL
SHIMADZU 321-78327 ATX-R series
ATY-R series Analytical Balance Instruction Manual
SHIMADZU 321-78282 UPX series
UPY series
Top-loading Balance Instruction Manual
SHIMADZU 321-78048 UW series
UX series Electronic Balance Instruction Manual

2.Terms and Definitions
2
2. Terms and Definitions
The terms and definitions used in this guide are given below.
Term
Explanation and Definition
protocol macro Data transfer procedures (protocols) with general-purpose external
devices are created and stored in Serial Communications Boards or Serial
Communications Units. These protocols enable data to be exchanged with
general-purpose external devices by executing the protocol macro
instruction (hereinafter referred to as "the PMCR instruction") in a CPU
Unit.
protocol A set of rules governing the data transmission procedure that unifies
independent communication processes for a specific general-purpose
device. A protocol consists of more than one sequence.
sequence
An independent process that can be performed by executing the PMCR
instruction in a program. The sequence started by the instruction executes
its steps in a given order.
step A unit to execute any one of the followings: message send processing,
message receive processing, message send/receive processing, receive
buffer clear or step wait. Up to 15 steps can be created per sequence.
send message A communication frame (command) sent to a general-purpose external
device. The send message is invoked by steps in the sequence and is sent
to general-purpose external devices.
receive message A communication frame (response) sent from a general-purpose external
device. The receive message is invoked by steps in the sequence and is
compared with data received from general-purpose external devices.
receive matrix A function to register and use some communication frames (responses)
when more than one communication frame is expected to be received from
a general-purpose external device. The receive processing can be
executed according to registered communication frames by using this
function.

3.Precautions
3
3. Precautions
(1) Understand the specifications of devices which are used in the system. Allow some
margin for ratings and performance. Provide safety measures, such as installing a safety
circuit, in order to ensure safety and minimize the risk of abnormal occurrence.
(2) To ensure system safety, make sure to always read and follow the information provided in
all Safety Precautions and Precautions for Safe Use in the manuals for each device
which is used in the system.
(3) The user is encouraged to confirm the standards and regulations that the system must
conform to.
(4) It is prohibited to copy, to reproduce, and to distribute a part or the whole of this guide
without the permission of OMRON Corporation.
(5) The information contained in this guide is current as of November 2019. It is subject to
change for improvement without notice.
The following notations are used in this guide.
Indicates a potentially hazardous situation which, if not avoided,
may result in minor or moderate injury or property damage.
Precautions for Safe Use
Precautions on what to do and what not to do to ensure safe usage of the product.
Precautions for Correct Use
Precautions on what to do and what not to do to ensure proper operation and performance.
Additional Information
Additional information to read as required.
This information is provided to increase understanding or make operation easier.
Symbol
The triangle symbol indicates precautions (including warnings).
The specific operation is shown in the triangle and explained in the text.
This example indicates a general precaution.
The filled circle symbol indicates operations that you must do.
The specific operation is shown in the circle and explained in the text.
This example shows a general precaution for something that you must do.

4.Overview
4
4. Overview
This guide describes procedures for connecting a SHIMADZU Analytical Balance
ATX-R/ATY-R series or Electronic Balance UPX/UPY/UW/UX series (hereinafter collectively
referred to as the "Balance") to an OMRON CJ-series Programmable Controller + Serial
Communications Unit (hereinafter referred to as the "PLC") via serial communications and for
checking their serial communication connection.
Refer to Section 6. Serial Communications Settings and Section 7. Serial Communications
Connection Procedure to understand setting methods and key points to send and receive a
message via serial communications.
This guide uses the pre-configured program (ladder program in the CX-Programmer project
file and the protocol data in the CX-Protocol project file) in order to check the serial
communication connection by sending a message of "single output with stability information"
to and receiving a response from the Balance.
Sending "single output with stability information" and receiving a response
PLC
Serial communications
(RS-232C)
Balance
Sends command data Executes the command
Receives response data
and stores in memory Returns response data
Contact OMRON to obtain latest versions of the CX-Programmer and CX-Protocol project files
before proceeding.
Name File name Version
CX-Programmer project file
(extension: cxp) P732_CJ_PMCR232C_SHIMADZU_E-Balance
_V100.cxp Ver.1.00
CX-Protocol project file
(extension: psw)
P732_CJ_PMCR_SHIMADZU_E-Balance_V10
0.psw
Ver.1.00
This guide aims to explain wiring methods, communications settings and setting
procedures necessary to connect the devices used in this guide. The program
used in this guide is not designed to be constantly used at a site but is designed
to check if the connection is established normally. Both functionality and
performance are therefore not fully considered for the program.
When you build a system, please use the wiring methods, communications
settings and setting procedures described in this guide as references, and
design a program according to your application needs.
Command data
Response data

5.Applicable Devices and Device Configuration
5
5. Applicable Devices and Device Configuration
5.1. Applicable Devices
The applicable devices are as follows:
Manufacturer Name Model
OMRON
CJ2 CPU Unit
CJ2□-CPU□□
OMRON
Serial Communications Unit
CJ1W-SCU□1-V1
CJ1W-SCU□2
SHIMADZU
Analytical Balance
ATX-R series
ATY-R series
SHIMADZU
Electronic Balance
UPX series
UPY series
UW series
UX series
Precautions for Correct Use
In this guide, the devices with models and versions listed in 5.2. Device Configuration are
used as examples of applicable devices to describe the procedures for connecting the
devices and checking their connection. You cannot use devices with versions lower than
those listed in 5.2. To use the above devices with models not listed in 5.2. or versions higher
than those listed in 5.2., check the differences in the specifications by referring to the
manuals before operating the devices.
Additional Information
This guide describes the procedures for establishing the network connection.
It does not provide information on operation, installation, wiring method, device functionality,
or device operation, which is not related to the connection procedures.
Refer to the manuals or contact the manufacturers.

5.Applicable Devices and Device Configuration
6
5.2. Device Configuration
The hardware components to reproduce the connection procedures in this guide are as
follows:
Manufacturer
Name
Model
Version
OMRON
Serial Communications Unit
CJ1W-SCU42
Ver.2.0
OMRON
CJ2 CPU Unit
CJ2M-CPU12
Ver.2.0
OMRON
Power Supply Unit
CJ1W-PA202
OMRON
CX-One
CXONE-AL□□C-V4
/AL□□D-V4
Ver.4.□□
OMRON
CX-Programmer
(provided in CX-One
package)
Ver.9.71
OMRON
CX-Protocol
(provided in CX-One
package)
Ver.2.01
OMRON
CX-Programmer project file
P732_CJ_PMCR232C_SHI
MADZU_E-Balance_V100.c
xp
Ver.1.00
OMRON
CX-Protocol project file
P732_CJ_PMCR_SHIMAD
ZU_E-Balance_V100.psw
Ver.1.00
―
Personal computer
(OS: Windows 10)
―
―
USB cable (USB 2.0-compliant,
USB-B connector)
―
―
Serial cable (RS-232C)
―
SHIMADZU
Balance
ATX324R
SHIMADZU
AC Adapter
(supplied with the Balance)
Precautions for Correct Use
Contact OMRON to obtain latest versions of the CX-Programmer and CX-Protocol project
files before proceeding.
Precautions for Correct Use
Update CX-Programmer and CX-Protocol to the versions specified above or to higher
versions. If you use a version higher than the one specified, the procedures and related
screenshots described in Section 7. and the subsequent sections may not be applicable.
In that case, use the equivalent procedures described in this guide by referring to the
CX-Programmer OPERATION MANUAL (Cat. No. W446) and the CX-Protocol OPERATION
MANUAL (Cat. No. W344).
AC adapter
CJ2M-CPU12
+
CJ1W-SCU42
Personal computer
(CX-One installed,
OS: Windows 10
)
USB cable
Serial cable
(RS-232C)
ATX324R

5.Applicable Devices and Device Configuration
7
Additional Information
For information on the serial cable (RS-232C) used in this guide, refer to 3-4 RS-232C and
RS-422A/485 Wiring of the CJ Series Serial Communications Units OPERATION MANUAL
(Cat. No. W336).
Additional Information
The system configuration in this guide uses USB for the connection between the personal
computer and the PLC. For information on how to install the USB driver, refer to A-5 Installing
the USB Driver of the CJ-series CJ2 CPU Unit Hardware USER'S MANUAL (Cat. No. W472).

6.Serial Communications Settings
8
6. Serial Communications Settings
This section describes the parameters and cable wiring that are used in this guide.
6.1. Parameters
The following parameters are required to connect the Balance and the PLC via serial
communications.
ATX-R/ATY-R series
Item
PLC (Serial Communications Unit)
ATX-R/ATY-R series
Unit number
0
―
Communications port
(communications type)
Port 2 (RS-232C)
―
Serial communications mode
Protocol macro
―
Communication specifications
―
MODE.2
(standard settings 2)
*1
Data (bit) length
8 bits
8 (fixed)
Stop bit (length)
1 bit
1 (fixed)
Parity
None
None (fixed)
Baud rate (communication speed)
1200 bps
1200 bps (fixed)
Protocol macro transmission
method (Full-duplex / Half-duplex)
Full-duplex
―
Handshake
―
Hardware
Data format
―
Shimadzu standard (fixed)
Delimiter
―
CR (fixed)
*When setting the communication specifications to "MODE.2" (standard settings 2), the following items
are all set at once: data (bit) length, stop bit (length), parity, baud rate (communication speed),
handshake and data format. For details on the communication settings, refer to 10 CONNECTION
AND COMMUNICATION of the Analytical Balance Instruction Manual (321-78327).
UPX/UPY/UW/UX series
Item
PLC (Serial Communications Unit)
UPX/UPY/UW/UX series
Unit number
0
―
Communications port
(communications type)
Port 2 (RS-232C)
―
Serial communications mode
Protocol macro
―
Data (bit) length
8 bits
8 (default)
Stop bit (length)
1 bit
1 (default)
Parity
None
None (default)
Baud rate (communication speed)
1200 bps
1200 bps (default)
Protocol macro transmission
method (Full-duplex / Half-duplex)
Full-duplex
―
Handshake
―
OFF
Data format
―
EB type (default)
Delimiter
―
CR (default)
Precautions for Correct Use
The following Serial Communications Unit, unit number and communications (connection)
port are assumed to be used in this guide.
Model: CJ1W-SCU42, Unit number: 0, Communications (connection) port: Port 2
If you connect the devices under different conditions, change the CIO area and control data
of the PMCR instruction by referring to 9. Program.

6.Serial Communications Settings
9
6.2. Cable Wiring
For details on cable wiring, refer to SECTION 3 Installation and Wiring of the CJ Series Serial
Communications Units OPERATION MANUAL (Cat. No. W336).
Check the shapes and pin layouts of the connectors before wiring.
Shape and pin layout of the connector
Serial Communications Unit (CJ1W-SCU42) applicable connector: D-SUB 9-pin female
Pin No.
Abbreviation
Signal name
I/O
1
FG
Shield
―
2
SD
Send data
Output
3
RD
Receive data
Input
4
RS
Request to send
Output
5
CS
Clear to send
Input
6
5V
Power supply
―
7
DR
Data set ready
Input
8
ER
Data terminal ready
Output
9
SG
Signal ground
―
Shell
FG
Shield
―
ATX-R/ATY-R series applicable connector: D-SUB 9-pin male
Use Pin No. Abbreviation
Signal name
RS-232C
1 ―
―
2 RXD Data input
3 TXD Data output
4 DTR Handshake (send)
5 SG Signal ground
6 DSR Handshake (receive)
7 RTS Request to send (RS-232C)
8 CTS Clear to send (RS-232C)
9 ――
Cable and pin layout
Serial Communications Unit
(CJ1W-SCU42)
ATX-R/ATY-R series
RS-232C
Interface
Signal
name
Pin No.
Pin No.
Signal
name
RS-232C
Interface
FG
1
1
NC
SD
2
2
RXD
RD
3
3
TXD
RS
4
4
DTR
CS
5
5
SG
5V
6
6
DSR
DR
7
7
RTS
ER
8
8
CTS
SG
9
9
NC
FG
Shell
D-SUB 9-pin
cable connector: female
D-SUB 9-pin
Cable connector: male

6.Serial Communications Settings
10
UPX/UPY/UW/UX series applicable connector: D-SUB 25-pin female
Use Pin No.
Terminal
name
Function
RS-232C
1 FG
Protective ground or
earth
2
TXD
Data output
3
RXD
Data input
4 RTS
Internal connection to
CTS
5 CTS
Internal connection to
RTS
6
DSR
Handshake (receive)
7
SG
Signal ground
8 to 19
Undefined
-
20
DTR
Handshake (send)
21 to 25
Undefined
-
Cable and pin layout
Serial Communications Unit
(CJ1W-SCU42)
UPX/UPY/UW/UX series
RS-232C
Interface
Signal
name
Pin No.
Pin No.
Signal
name
RS-232C
Interface
FG
1
1
FG
SD
2
2
TXD
RD
3
3
RXD
RS
4
4
RTS
CS
5
5
CTS
5V
6
6
DSR
DR
7
7
SG
ER
8
8 to 19
Undefined
SG
9
20
DTR
FG
Shell
21 to 25
Undefined
D-SUB 9-pin
cable connector: male
D-SUB 25-pin
cable connector: male

7.Serial Communications Connection Procedure
11
7. Serial Communications Connection Procedure
This section describes the procedures for connecting the Balance and the PLC via serial
communications. The procedures for setting up the Balance and the PLC in this guide are
based on the factory default settings.
For information on initialization, refer to Section 8. Initialization Method.
7.1. Work Flow
Take the following steps to connect the Balance and the PLC via serial communications and
send and receive a message.
7.2. SHIMADZU Balance Setup
Set up the SHIMADZU Balance.
↓
7.2.1 Parameter Settings
Set parameters for the Balance.
↓
7.3. PLC Setup
Set up the PLC.
↓
7.3.1. Hardware Settings
Set the hardware switches on the Serial
Communications Unit and connect the cables.
↓
7.3.2. Opening the Project File and
Going Online with the PLC
Start CX-Programmer, open the project file and go
online with the PLC.
↓
7.3.3. Creating an I/O Table
Create an I/O table for the PLC.
↓
7.3.4. Parameter Settings
Set parameters for the Serial Communications
Unit.
↓
7.3.5. Transferring the Project Data
Transfer the project data to the PLC.
↓
7.3.6. Starting CX-Protocol and
Opening the Project File
Start CX-Protocol and open the project file.
↓
7.3.7 Going Online and Transferring
the Protocol Data
Place CX-Protocol online and transfer the protocol
data to the Serial Communications Unit.
↓

7.Serial Communications Connection Procedure
12
7.4. Serial Communication Status
Check
Start the send/receive processing and confirm that
serial communications is performed normally.
↓
7.4.1. Starting the Trace
Start tracing with CX-Protocol.
↓
7.4.2. Executing the Communications
Sequence
Execute the communications sequence with
CX-Programmer.
↓
7.4.3. Checking the Trace Data
Check with the trace data in CX-Protocol that
correct data is sent and received.
↓
7.4.4. Checking Received Data
With CX-Programmer, check that correct data is
written to the I/O memory of the PLC.

7.Serial Communications Connection Procedure
13
7.2. SHIMADZU Balance Setup
Set up the SHIMADZU Balance.
7.2.1. Parameter Settings
Set parameters for the Balance.
The parameter settings vary depending on the model used.
Use one of the following parameter setting procedures appropriate for your Balance's model.
Model Procedure to be followed
ATX-R/ATY-R series 1) Parameter settings for ATX-R/ATY-R series
UPX/UPY/UW/UX series
2) Parameter settings for UPX/UPY/UW/UX series
1) Parameter settings for ATX-R/ATY-R series
Set parameters for ATX-R/ATY-R series.
Precautions for Correct Use
Make sure the power supply is OFF before setting up.
If it is ON, the settings described in the following steps and subsequent procedures may not
be applicable.
1
Make sure AC Adapter is
powered OFF.
2
Check the position of the
connectors on Balance.
Connect a Serial cable
(RS-232C) to RS-232C
connector.
Connect AC Adapter to DC IN
connector.
Back view of Balance
3
Check the position of the
operation keys by referring to
the figure on the right.
Front view of Balance
4
Turn ON AC Adapter.
Serial cable (RS-232C)
AC adapter
RS-232C connector
O/T key
USB connector
CAL key
DC IN connector
MENU key
PRINT key
UNIT key
Display
panel
BREAK key

7.Serial Communications Connection Procedure
14
5
Display panel shows "OFF".
Press BREAK key.
6
Display panel shows gram units.
Press and hold PRINT key for
about 3 seconds.
7
Display panel shows
"APL.PRN".
Press MENU key once.
Display panel shows
"COMM.SET".
Press PRINT key once.
Display panel shows "MODE.1".
Press UNIT key once.
Display panel shows "MODE.2".
Press O/T key once.
*In this guide, the communication
specifications of Balance are set
to "MODE.2" (standard settings
2), in order to send command
data from PLC to Balance and
check response data received
from Balance.
Check that Display panel shows
"SET".
Once the setting is confirmed,
Display panel shows "MODE.2".
Press and hold BREAK key for
about 3 seconds.
*For more information on the
menu operations, refer to 10
CONNECTION AND
COMMUNICATION WITH
PERIPHERAL DEVICES of the
Analytical Balance Instruction
Manual (321-78327).

7.Serial Communications Connection Procedure
15
8
Display panel shows gram units.
Press BREAK key.
9
Display panel shows "READY".
*Balance is in the standby
mode.
10
Turn OFF AC Adapter.

7.Serial Communications Connection Procedure
16
2) Parameter settings for UPX/UPY/UW/UX series
Set parameters for UPX/UPY/UW/UX series.
Precautions for Correct Use
Make sure the power supply is OFF before setting up.
If it is ON, the settings described in the following steps and subsequent procedures may not
be applicable.
1
Make sure AC Adapter is
powered OFF.
2
Check the position of the
connectors on Balance.
Connect a Serial cable
(RS-232C) to RS-232C
connector.
Connect AC Adapter to DC IN
connector.
Back view of Balance
3
Check the position of the
operation keys by referring to
the figure on the right.
Front view of UPX/UPY series
Front view of UW/UX series
4
Turn ON AC Adapter.
POWER key
PRINT key
UNIT key
Serial cable (RS-232C)
AC adapter
KEY connector
RS-232C
connector
DATA I/O
connector
AUX
connector
DC IN
connector
Display
panel
PRINT key
O/T key
CAL key UNIT key
POWER key
Display
panel
O/T key
CAL key

7.Serial Communications Connection Procedure
17
5
Display panel shows "OFF".
Press POWER key.
6
Display panel shows gram units.
Press CAL key on UPX/UPY
series twice or on UW/UX series
three times.
7
Display panel shows
"SEL:EAUS".
Check that is blinking.
Press CAL key six times.
*The blinking of indicates the
menu group 1.
*Press CAL key to move to the
next menu group.
The analog display blinks.
Check that is blinking.
Press O/T key.
Set the communication
specifications by following the
next steps.
*The blinking of indicates
the menu group 7
(communication with computer
and external devices).
*For more information on the
menu operations, refer to
Appendices of the Top-loading
Balance Instruction Manual
(321-78282) and Electronic
Balance Instruction Manual
(321-78048).
:
Table of contents
Other Shimadzu Controllers manuals