Data Source: CIP

The CIP Data Source connects directly to PLCs supporting the Common Industrial Protocol (e.g. Allen Bradley Control Logix, OMRON NJ Series) to read and write Tags.

The Allen Bradley Control Logix CIP Data Source supports the ByteArray type. The OMRON CIP Data Source does not support the ByteArray type. Using a ByteArray tag in a CIP data source will cause a delay on start up as Sym3 retrieves project type information required. The length of the delay depends on the size of the project on the PLC, the speed of connection, and other such factors.

Create a new Data Source

A Data Source can be defined in Sym3, right click on Project Explorer > Data Sources then select ‘CIP’ from the ‘New Source’ menu.

Note: Browsing is not supported for CIP Data Sources.

Select the newly created Data Source and in the Property Editor.

Fill in the address of the PLC in the Hostname field. Add an optional port number to use:

$ipaddress:$ipport

The default is 44818. Example:

10.200.115.27:22222

Add the Path to the CPU e.g. 1.1.

Or

Adding a CIP Tag

Click on the Property Editor option in the Ribbon bar to open the Property Editor Panel.

Create Tags in the Tag Manager Window using the + button.

Enter a Name for the Tag in Sym3 and the Data Source for the Tag.

Entering a Data Type for tags is optional except BOOL arrays and STRING tags.

The Tag Address is the Symbolic Tag Name on the PLC.

  • The Symbolic Tag Name is not case sensitive.
  • Invalid characters (space)!@%^&*()-+=~`;<>?|{}"’.
  • The Symbolic Tag Name must begin with alphabetical character or underscore.
  • The character after ‘:’ must be alphanumeric.
  • The character after ‘.’ must be alphanumeric.
  • The character after ‘[’ must be numeric.
  • The character after ‘_’ must be alphanumeric.
  • The character after ‘]’ (if any) must be alphanumeric.
  • The Symbolic Tag Name must end with alphanumeric or ‘]’.

Special Tag Addresses

It is possible to map parts of a byte array on the PLC to specific tags. This allows for faster reads of data from the PLC as the array is read back and then split onto tags. (This is only supported with the CIP (Omron NJ) Data Source.)

The special tag address format is as follows:

  • PLCArrayName{n} where:
    • PLCArrayName: Name of the array of bytes on the PLC.
    • n: The starting byte index of the array to use for the tag value.
  • PLCArrayName{n:m} where:
    • PLCArrayName: Name of the array of bytes on the PLC.
    • n: The byte index of the array to use for the tag value.
    • m: The bit index (0-7) of the above byte to use for the tag value.

If a tag type requires more than one byte (for example an DWORD needs 4 bytes), this will be used following the n byte index.

Some limitations apply:

  • Since tag reads are grouped by refresh rate, it is recommended to ensure all tags with the same array name use the same refresh rate.
  • String tags are not supported.
  • Array overflow is possible and care should be taken when defining special tags.
  • Writing to one of these special boolean tags could trigger a read first to prevent resetting other bits on the same byte.

Example Scenario

PLC variable: MyArray[0..10] OF BYTE

Tags

Name Address Type Notes
Bool0 MyArray{0:0} Boolean The first bit of the first byte will be used to store ‘Bool0’ value.
Bool1 MyArray{0:1} Boolean The second bit of the first byte will be used to store ‘Bool1’ value.
Bool7 MyArray{0:7} Boolean The last (8th) bit of the first byte will be used to store ‘Bool7’ value.
BoolN MyArray{1:5} Boolean The sixth bit of the second byte will be used to store ‘BoolN’ value.
ByteX MyArray{2} Byte The third byte of the array will be used to store the ‘ByteX’ tag value.
LongX MyArray{3} Long Eight bytes from (and including) the fourth byte are used to store the tag value for ‘LongX’.

Browsing for tags

In the tag manager:

  • Click on ‘Browse’ button.
  • Select your datasource.
  • If the PLC in active and Sym3 can connect to it, all tags are available.
  • Double-click on tag you want to add to your project or multiple select then and click the ‘Add To Tag Database’.

Predefined types:

ALARM
AXIS_CONSUMED
AXIS_GENERIC
AXIS_GENERIC_DRIVE
AXIS_SERVO
AXIS_SERVO_DRIVE
AXIS_VIRTUAL
CAM
CAM_PROFILE
CONNECTION_STATUS
CONTROL
COORDINATE_SYSTEM
COUNTER
DEADTIME
DERIVATIVE
DISCRETE_2STATE
DISCRETE_3STATE
DIVERSE_INPUT
DOMINANT_RESET
DOMINANT_SET
EMERGENCY_STOP
ENABLE_PENDANT
EXT_ROUTINE_CONTROL
EXT_ROUTINE_PARAMETERS
FBD_BIT_FIELD_DISTRIBUTE
FBD_BOOLEAN_AND
FBD_BOOLEAN_NOT
FBD_BOOLEAN_OR
FBD_BOOLEAN_XOR
FBD_COMPARE
FBD_CONVERT
FBD_COUNTER
FBD_LIMIT
FBD_LOGICAL
FBD_MASKED_MOVE
FBD_MASK_EQUAL
FBD_MASKED_MOVE
FBD_MATH
FBD_MATH_ADVANCED
FBD_ONESHOT
FBD_TIMER
FBD_TRUNCATE
FILTER_HIGH_PASS
FILTER_LOW_PASS
FILTER_NOTCH
FIVE_POS_MODE_SELECTOR
FLIP_FLOP_D
FLIP_FLOP_JK
FUNCTION_GENERATOR
HL_LIMIT
INTEGRATOR
LEAD_LAG
LEAD_LAG_SEC_ORDER
LIGHT_CURTAIN
MAXIMUM_CAPTURE
MESSAGE
MINIMUM_CAPTURE
MOTION_GROUP
MOTION_INSTRUCTION
MOVING_AVERAGE
MOVING_STD_DEV
MULTIPLEXER
OUTPUT_CAM
OUTPUT_COMPENSATION
PHASE
PHASE_INSTRUCTION
PID
PID_ENHANCED
PIDE_AUTOTUNE
POSITION_PROP
PROP_INT
PULSE_MULTIPLIER
RAMP_SOAK
RATE_LIMITER
REDUNDANT_INPUT
REDUNDANT_OUTPUT
S_CURVE
SCALE
SEC_ORDER_CONTROLLER
SELECT
SELECT_ENHANCED
SELECTABLE_NEGATE
SELECTED_SUMMER
SERIAL_PORT_CONTROL
SFC_ACTION
SFC_STEP
SFC_STOP
SPLIT_RANGE
TIMER
TOTALIZER
TWO_HAND_RUN_STATION
UP_DOWN_ACCUM

Syntax:

Type Name.$member_name

Example:

Address = MyTimer.PRE
Address = MyCounter.ACC