Anybus B40 Modbus Serial CompactCom User Manual

June 6, 2024
Anybus

Anybus® CompactCom™ B40 Modbus Serial
CC-Link
USER MANUAL
SCM-1202-178 1.0

Important User Information

Disclaimer
The information in this document is for informational purposes only. Please inform HMS Networks of any inaccuracies or omissions found in this document. HMS Networks disclaims any responsibility or liability for any errors that may appear in this document.
HMS Networks reserves the right to modify its products in line with its policy of continuous product development.
The information in this document shall therefore not be construed as a commitment on the part of HMS Networks and is subject to change without notice. HMS Networks makes no commitment to update or keep current the information in this document.
The data, examples, and illustrations found in this document are included for illustrative purposes and are only intended to help improve understanding of the functionality and handling of the product. In view of the wide range of possible applications of the product, and because of the many variables and requirements associated with any particular implementation, HMS Networks cannot assume responsibility or liability for actual use based on the data, examples, or illustrations included in this document nor for any damages incurred during the installation of the product.
Those responsible for the use of the product must acquire sufficient knowledge in order to ensure that the product is used correctly in their specific application and that the application meets all performance and safety requirements including any applicable laws, regulations, codes, and standards. Further, HMS Networks will under no circumstances assume liability or responsibility for any problems that may arise as a result of the use of undocumented features or functional side effects found outside the documented scope of the product. The effects caused by any direct or indirect use of such aspects of the product are undefined and may include e.g. compatibility issues and stability issues.

Preface

1.1 About this Document
This document is intended to provide a good understanding of the functionality offered by the Anybus CompactCom B40 Modbus Serial – CC-Link.
The reader of this document is expected to be familiar with high-level software design and communication systems in general. The information in this networking guide, along with the Anybus CompactCom B40 Modbus Serial user manual should normally be sufficient to implement a design. However, if advanced CC-Link-specific functionality is required for the network interface of the device, in-depth knowledge of CC-Link networking internals and/or information from the official CC-Link specifications may be required. In such cases, the persons responsible for the implementation of this product should either obtain the CC-Link specification to gain sufficient knowledge or limit their implementation in such a way that this is not necessary.
For additional information, please visit the support website at www.anybus.com/support.
1.2 Document History

Version Date Description
1 3/3/2021 First release

1.3 Document Conventions
Numbered lists indicate tasks that should be carried out in sequence:

  1. First, do this
  2. Then do this

Bulleted lists are used for:

  • Tasks that can be carried out in any order
  • Itemized information
    • An action
    → and a result

User interaction elements (buttons etc.) are indicated with bold text.

Program code and script examples  

Cross-reference within this document: Document Conventions, p. 3
External link (URL): www.hms-networks.com
WARNING
Instruction must be followed to avoid a risk of death or serious injury.
Caution
Instruction must be followed to avoid a risk of personal injury.
Instruction that must be followed to avoid a risk of reduced functionality and/or damage to the equipment, or to avoid a network security risk.
Additional information which may facilitate installation and/or operation.
1.4 Document Specific Conventions

  • The terms “Anybus” or “module” refer to the Anybus CompactCom module.
  • The terms “host” or “host application” refer to the device that hosts the Anybus.
  • Hexadecimal values are written in the format NNNNh or 0xNNNN, where NNNN is the hexadecimal value.
  • A byte always consists of 8 bits.
  • All dimensions in this document have a tolerance of ±0.10 mm unless otherwise stated.
  • Outputs are TTL compliant unless otherwise stated.
  • Signals which are “pulled to GND” are connected to GND via a resistor.
  • Signals which are “pulled to 3V3” are connected to 3V3 via a resistor.
  • Signals which are “tied to GND” are directly connected to GND,
  • Signals which are “tied to 3V3” are directly connected to 3V3.

1.4.1 Pin Types
The pin types of the connectors are defined in the table below. The pin type may be different depending on which mode is used.

Pin type Definition
I Input
O Output
I/O Input/Output (bidirectional)
OD Open-Drain
Power Pin-connected directly to module power supply, GND or 3V3

1.5 Trademark Information
Anybus® is a registered trademark of HMS Networks.
All other trademarks are the property of their respective holders.

2.1 General Information
The Anybus CompactCom B40 Modbus Serial – CC-Link is a communication solution for simple industrial field devices. The host application communicates with the product using the Modbus RTU protocol. The Anybus CompactCom B40 Modbus Serial – CC-Link then communicates the data to the network. Typical applications are basic level I/O blocks, temperature controllers, measuring devices, and sensors.
The Anybus CompactCom B40 Modbus Serial – CC-Link software interface is designed to be network protocol independent, making it possible to support several networking systems using the same application software code/driver.
The Anybus CompactCom B40 Modbus Serial – CC-Link shares a footprint and electrical interface with the other members of the product family, independent of Fieldbus or network. The host application connector provides an interface between the host application (Modbus RTU) and the Anybus CompactCom, while the network connector provides access to the chosen network. The Anybus CompactCom acts as a Modbus RTU slave on the host application side.
The Anybus CompactCom 40 family offers a wide range of functionality. For advanced products and applications, we recommend the standard Anybus CompactCom 40.
For general information about other products using the Anybus CompactCom 40 platform, consult www.anybus.com/support.
This is a class A product. In a domestic environment, this product may cause radio interference in which case the user may be required to take adequate measures.
This product contains ESD (Electrostatic Discharge) sensitive parts that may be damaged if ESD control procedures are not followed. Static control precautions are required when handling the product. Failure to observe this may cause damage to the product.
2.2 Features

  • CC-Link Remote Device

  • I/O: up to 16-word points of 16-bit data (CC-Link v.1.10, default)

  • I/O: up to 128-word points of 16-bit data (CC-Link v.2.00)
    To use CC-Link v.2.00, this must be set during start-up. See Startup and Identity Customization, p. 7

  • Automatic CC-Link System Area handshaking

  • Sample configuration file (CSP+) provided by HMS Industrial Networks

  • Possibility to customize Vendor Code, Model Code, and Version via the application interface

  • Baud Rate and Station Number configuration via the application interface

  • Galvanic isolation between the host application and the industrial network is available if used with the CompactCom B40 connector board

All Anybus CompactCom 40 Modbus Serial, where the host is running an example application, will be precertified for network conformance. This is done to ensure that the final product can be certified, but it does not necessarily mean that the final product does not require recertification. Contact HMS Networks for further information.
2.3 Overview
The picture below shows the data flow in the Anybus CompactCom B40 Modbus Serial – CC-Link.
The application sets up the Modbus RTU communication, and the Anybus CompactCom maps the process data to the industrial network/Fieldbus.

2.4 Fieldbus Conformance Notes
The Anybus CompactCom 40 CC-Link has been tested standalone and found to comply with the CC-Link Conformance Test specification, publication BAP-C0401-012-F. The end product will however need to be re-certified in order to comply with CC-Link certification policies. For more information, see Certification Information, p. 17.

Basic Operation

3.1 Software Requirements
No additional network support code needs to be written in order to support the Anybus CompactCom B40 Modbus Serial – CC-Link, however, due to the nature of the CC-Link networking system certain restrictions must be taken into account:

  • Parameter names, types, and similar attributes cannot be accessed from the network.
  • No support for network reset requests.

3.2 CC-Link Family System Profile (CSP+) File
Each device on CC-Link is associated with a CC-Link Family System Profile (CSP+) file, which holds a description of the device and its functions.
HMS Networks supplies a generic CSP+ file which can serve as a basis for new implementations.
A tool for modifying the file is available on the CLPA web page (www.cc- link.org, membership is required).
3.3 Communications Settings
Station Number:
On CC-Link, each device on the network must be assigned a unique Station Number. The highest possible Station Number depends on the number of occupied stations.
Baud Rate:
The module supports all common CC-Link baud rates up to 10 Mbps.
3.4 Startup and Identity Customization
To customize the identity of the Anybus CompactCom (e.g. Vendor ID, Product Code, etc.), Virtual Attributes are used.
The most common customizations will be described here. For more detailed information, see the related documents listed in the beginning of this document.
Setting up the virtual attributes in the Anybus CompactCom can be accomplished in two different ways.

  • Using the user-defined Modbus function code (Function code 70).
    The use of Function code 70 can be included in the Modbus master. Hence the CompactCom does not need to be preprogrammed before mounting it in the host application.

  • Using the Anybus Virtual Attributes Manager.

The Virtual Attributes Manager is recommended for use during development and for low volume production since manual user operations are needed for every Anybus CompactCom that shall be programmed.
Once the virtual attributes are written to the Anybus CompactCom, they are saved in nonvolatile memory. It is not necessary to write the virtual attributes at each startup.
3.4.1 Virtual Attributes with Specific Modbus Function Code 70
With Modbus function code 70, the Modbus master has access to the Anybus CompactCom internal messaging protocol. This means that all attributes within the Anybus CompactCom are potentially accessible.
When writing the virtual attributes to the Anybus CompactCom, the Anybus object, Object 01h, Instance 1, Attribute 17 is used. All information relevant to the basic virtual attributes will be covered here. For more information, refer to the related documents section in this document.
The example shows example values to the basic virtual attributes:

Virtual Attribute Example Value
Vendor Code: 0x0212
SW Version: 1

To set the virtual attributes in the Anybus CompactCom to these values, using the Modbus function 70, create the request below:
Modbus function 70 Request

|

Value

|

Note

---|---|---
Modbus Address| OxXX|
Function Code| 0x46| FC70
Command| 0x42| Set Attribute
Object| Ox01| Anybus Object
Instance| Ox01|
Ox00
ExtO| Ox11| Attribute 17
Extl| Ox00| Not used
Data Size| OxOF| The data size in this example is 15 bytes
Ox00
Data| OxF7 OxOl Ox00 Ox01 0x02 Ox00 0x12 0x02 OxF7 OxOl Ox00 0x02 Ox01 Ox00 Ox01| Vendor Code SW Version
CRC| OxXX| CRC-16
OxXX

Response

| Value|

Note

---|---|---
Modbus Address| OxXX|
Function Code| 0x46| FC70
Command| 0x02| Set Attr_Resp
Object| Ox01| Anybus Object
Instance| Ox01|
Ox00
ExtO| Ox11| Attribute 17
Extl| Ox00| Not used
Data Size| Ox00|
Ox00
CRC| OxXX| CRC-16
OxXX

Requests with a size larger than 244 bytes will return Modbus exception code ILLEGAL DATA VALUE.
3.4.2 Virtual Attributes with Anybus Virtual Attributes Manager

  1. Start the Anybus Virtual Attributes Manager

  2. Enter the virtual attributes data for the attributes needed. The example below is setting up the attributes with the following values:
    Virtual Attribute| Example Value
    ---|---
    Vendor Code:| 0x0212
    SW Version:| 1

  3. Mount the Anybus CompactCom to the USB starter kit board.

  4. Select Module->Download and select the correct Transport Path to your USB board.

  5. The virtual attributes will be programmed and saved in non-volatile memory.

3.5 Data Exchange
3.5.1 The Bit Area and Word Area
On the Anybus CompactCom B40 Modbus Serial – CC-Link, data is divided into two categories as follows:
Bit Area:
For this product, the Bit Area is not available. The System Area is only used for initial data handshaking between a Master and a Slave device. For detailed information about the System Area, please refer to CC-Link System Area Implementation, p. 14.
It is possible to disable the System Area by setting the CC-Link Host Object (F7h), instance attribute #5, to -1 (0xFFFF) during start-up. For more information, see Startup and Identity Customization, p. 7.
Word Area:
Data is accessed as 16-bit words. Data is commonly referred to as RWr #nn (Slave->Master) and RWw #nn (Master->Slave) where “nn” represents an addressable point (i.e. a word) in the Word Area.

Direction Word Area Points (dec)
Slave -> Master RWr0… RWr127
Master -> Slave RWw0 … RWw127

3.5.2 Data Sizes
CC-Link Version 1
By default, the module automatically calculates the required number of occupied stations based on the mapped Process Data. The following data sizes are possible.

Occupied Stations Word Points
1 4 words
2 8 words
3 12 words
4 16 words

CC-Link Version 2
By implementing the attribute Network Settings (#4) in the CC-Link Host Object (F7h) it is possible to customize the implementation for CC-Link version 2 and use larger data sizes through extension cycles. In such case, the following sizes are possible:

Occupied Stations

| 1 Extension Cycle| 2 Extension Cycles| 4 Extension Cycles|

8 Extension Cycles

---|---|---|---|---

Points

| Points| Points|

Points

1| 4 words| 8 words| 16 words| 32 words
2| 8 words| 16 words| 32 words| 64 words
3| 12 words| 24 words| 48 words| 96 words
4| 16 words| 32 words| 64 words| 128 words

This page was intentionally left blank

A Implementation Details

A.1 Anybus State Machine
The table below describes how the Anybus State Machine relates to the CC-Link network.

Anybus State

|

Implementation (System Area handled by Anybus module)

---|---
WAIT_PROCESS| Automatic CC-Link handshaking in progress
ERROR| Possible causes:

  • Timeout error (ERR21)
  • 0 channel carrier detection status (ERR22)
  • an insufficient number of data for the host (ERR30…32) When the problem disappears, the module returns to the previous state.

PROCESS_ACTIVE| The module enters this state on the rising edge of ‘Initial Data Processing Complete’
IDLE| PLC/Master in STOP mode
When the PLC/Master returns to RUN mode, the module returns to the previous state.
EXCEPTION| Possible causes:

  • Configuration error
  • other error that cannot be indicated to the application in any other way

A.2 CC-Link Handshaking Implementation
CC-Link handshaking is performed automatically as described in the table below.

Flag Set when… Cleared when…
Initial Data Processing Request State changes from NW_INIT to WAIT_PROCESS

State transition from WAIT_PROCESS to PROCESS_ACTIVE
Remote READY| (initial setting) – At the rising edge of “Initial Data Processing Complete”| –

The initial value of the System Area is false, i.e. all flags are cleared during startup.

B CC-Link System Area Implementation

B.1 System Area Modes
An essential part of the CC-Link communication is the CC-Link System Area. This area holds various status- and diagnostic flags, and is handled automatically by the Anybus device (default).
Alternatively, it can be disabled by the host application.
B.1.1 System Area Handled by Anybus (Default)
All flags in the System Area are handled automatically by the module.
B.1.2 System Area Disabled by Host Application (Advanced)
To disable the System Area, the attribute “System Area Handler” (#5) in the CC-Link Host Object (F7h) must be set to -1 (disabled).
It is possible to change the location of the System Area by implementing the attribute System Area Handler (#5) in the CC-Link Host Object (F7h).
See also…

  • CC-Link Handshaking Implementation, p. 13

B.2 System Area Layout
This section is only relevant when the System Area is handled automatically by the module.

Slave - > Master

| Master - > Slave
---|---
Bit Offset| Contents| Bit Offset|

Contents

0| (reserved)| 0| (reserved)
1| 1
2| 2
3| 3
4| 4
5| 5
6| 6
7| 7
8| Initial Data Processing Request| 8| Initial Data Processing Complete
9| (reserved)| 9| (reserved)
10| (reserved)| 10| (reserved)
11| Remote READY| 11| (reserved)
12| (reserved)| 12
13| 13
14| 14
15| 15

The various flags listed in the table above are handled as described in CC- Link Handshaking Implementation, p. 13.
See also…

  • System Area Location, p. 15

B.3 System Area Location
This section is only relevant when the System Area is handled automatically by the module.
The default location of the System Area is at the very end of the Bit Area as follows:

Point

| Contents| Point|

Contents

---|---|---|---
RX #0| (reserved)| RY #0| (reserved)
RX #1| RY #1
|
RX #Q-18| RY #Q-18
RX #Q-17| RY #Q-17
RX #Q-16| (Reserved for CC-Link System Area)| RY #Q-16| (Reserved for CC-Link System Area)
RX #Q-15| RY #Q-15
|
RX #Q-2| RY #0-2
RX #Q-1| RY #0-1

(The table above illustrates how data is represented as seen from the CC-Link master. “Q” represents the number of addressable points in the Bit Area of the Anybus CompactCom.)
How to Calculate Q:

  • CC-Link Version 1 OR Extension Cycles = 1:
    Q = The number of occupied stations x 32.

  •  CC-Link Version 2 AND Extension Cycles >= 2:
    Q = ((The number of occupied stations x 32) – 16) x Extension cycles.

C LED Indications

C.1 RUN LED

LED State Indication/Description
Off No network participation, time out status (no power)
Green Participating, normal operation
Red Major fault (FATAL error)

C.2 ERROR LED

LED State Indication/Description
Off No error detected (no power)
Red Major fault (Exception or FATAL event)
Red, flickering CRC error (temporary flickering)
Red, flashing Station Number or Baud Rate has changed since startup

(flashing)

D Certification Information

D.1 General Information

  • The Anybus CompactCom B40 Modbus Serial – CC-Link implements the Generic Device profile. Memory mapping is application-specific.
  • In order to pass the conformance test, the application will have to show an error status when an erroneous baud rate or station number according to CC-Link is used. The Anybus CompactCom B40 Modbus Serial – CC-Link will not allow setup to complete in such a case.
  • The CC-Link V.2.00 protocol is implemented without a return check-in to the module.

D.2 Basics
The following steps are necessary to perform to obtain certification:

  1. Change Vendor Code:
    Replace the HMS Vendor ID with a unique Vendor Code. This is done by implementing the CC-Link Host Object (F7h), instance #1, and attribute #1. For information on how to do this, see Startup and Identity Customization, p. 7.
    Membership in the CLPA organization is necessary to obtain a vendor code. The vendor code consists of digits 5 – 8 in the CLPA ID number, issued when you join.

  2. Increment SW Version:
    Increment the SW version in the CC-Link Host Object (F7h) if you want to keep track of the versions. This number should be incremented at each change in functionality, leading to new recertification. Implement the CC-Link Host Object (F7h), instance #1, attribute #2. For information on how to do this, see Startup and Identity Customization, p. 7.

  3. Generate a new CSP+ file
    A CSP+ file, that complies with the customized implementation, must be generated.

These steps are the smallest possible amount of actions that you need to perform to obtain a certification.
D.3 Model Code
When the module is delivered, the Model Code (CC-Link Host Object (F7h), Instance #1, Attribute #3) is set to 7Fh (Generic device).
D.4 CC-Link Version 2.00
By implementing the attribute Network Settings (#4) in the CC-Link Host Object (F7h) it is possible to customize the implementation for CC-Link version 2.00 and use larger data sizes through extension cycles. See Startup and Identity Customization, p. 7 for more information.

© 2021 HMS Industrial Networks
Box 4126
300 04 Halmstad, Sweden
info@hms.se
Anybus® CompactCom™
B40 Modbus Serial CC-Link
User Manual
SCM-1202-178 1.0
SCM-1202-178 1.0 en-US / 2021-03-03 / 21731

References

Read User Manual Online (PDF format)

Loading......

Download This Manual (PDF format)

Download this manual  >>

Related Manuals