Add a COP function block, variables, and a contact (MSG_CIPSYMBOLIC)

The COP instruction is used to convert the data you enter to the destination data type so the data is compatible with the controller variable.
To add a COP function block, variables, and a contact (MSG_CIPSYMBOLIC)
  1. Add a controller.
    1. In
      Project Organizer
      , select
      New device
      .
    2. In
      Add device
      , select the checkbox beside the 2080-L50E0-48QVB controller.
    3. In
      Selection
      , enter a name for the controller, and then select
      Add
      .
  2. Add a ladder diagram program.
    1. In
      Project Organizer
      , expand the controller node.
    2. Right-click
      Programs
      , and then select
      New program
      .
    3. In
      New program
      , in the
      Name
      box, enter
      CIPSymbolicMessage
      .
    4. Verify that the program type is
      Ladder Diagram
      .
    5. Select
      Create
      .
  3. Add a COP function block.
    1. In
      Project Organizer
      , double-click
      CIPSymbolicMessage
      to open the program.
    2. In
      Toolbox
      , in
      Search
      , enter
      COP
      , and then drag the function block to a valid location in the language editor or double-click
      COP
      to add it to the language editor.
  4. Add COP variables and initial values.
    1. In
      Project Organizer
      , under the program you created, double-click
      Local Variables
      .
    2. In the local variable gird, add variables according to the following table.
      COP variables and initial values
      Parameter
      Variable Name
      Data Type
      Src
      ValueToWrite
      Array UDINT
      Initial value: 987654321
      SrcOffset
      0
      UINT
      Dest
      A_Data
      Array USINT
      DestOffset
      0
      UINT
      Length
      4
      UINT
      Swap
      TRUE
      BOOLEAN
      STS
      COPsts
      Array UINT
  5. Create arrays.
    1. For ValueToWrite, double-click
      Dimension
      , and then change the array size to [1..1].
    2. For A_Data, double-click
      Dimension
      , and then change the array size to [1..4].
  6. Add a contact.
    1. In
      Toolbox
      , in the
      Search
      box, enter
      XIC
      .
    2. From
      Toolbox
      , drag the XIC to the left of the COP function block input on the first ladder rung.
    3. Right-click the XIC, and then select
      New variable
      .
    4. In
      New variable
      , enter the variable name
      Convert_Data
      for the XIC, and then select
      Create
      .
The first rung of your ladder diagram program for MSG_CIPSYMBOLIC messaging looks similar to the following image:
How the first rung of MSG_CIPSYMBOLIC messaging looks like
Provide Feedback
Have questions or feedback about this documentation? Please submit your feedback here.
Normal