Blog

Siemens Decentralized Motion Control with SINA_POS

Siemens Decentralized Motion Control with SINA_POS

In a previous blog I discussed programming motion control with a S7-1500 with Technology Objects in TIA Portal. This is a very popular method of doing the motion control on the PLC.

We can also offload the motion control to the drive control unit using Siemens’ library motion blocks such as SINA_POS and allow the PLC to control more drives. The Siemens library motion blocks are also available for S7-300 PLCs, which do not support the same Technology Objects as S7-1500 PLCs.

How to Do Motion Control with SINA_POS

  1. Add the DO Servo Module to the control unit.

    Sinamics-S120-CU Configuration

  2. Add Telegram 111. 

    Siemens telegram 111

  3. For a 1200 or 1500 CPU note the HW identifier in the System Constants when Telegram 111 is selected. For a 300 or 400 CPU note the I address and Q address.

    1200/1500

    S7-1200/1500 HW Identifier

    300/400

    S7-300/400 HW Identifier

  4. In the Global Libraries find the EPOS function blocks.

    Siemens EPOS Library Blocks

  5. Pull the desired motion block into your code. In this case, we created fbPositionAxis and we pulled in SINA_POS. We made SINA_POS a Multiple instance block so that it will be static memory in fbPositionAxis.

    SINA_POS Function Block Default

  6. I added a few inputs to the fbPositionAxis function block to simplify the Axis control. I chose to include basic jogging, absolute moves, setting a zero home position, and interrupting a move with the fast stop.

    SINA_POS Wrapper Function Block

  7. Based on the inputs to fbPositionAxis I set the ModePos input of SINA_POS. You can see how I use the other inputs and the axis status to control the axis.

    SINA_POS Function Block Finalized

A few important points:

  • The Velocity input of SINA_POS affects the absolute position move, but it does not change the speeds of Jog1 or Jog2. Those parameters must be changed in the STARTER/SCOUT configuration or by using the SINA_PARA or SINA_PARA_S function blocks.
  • My example above only uses 3 of the 8 SINA_POS operating modes, so there are functions that this example does not demonstrate.
  • SINA_POS uses Telegram 111 whereas SINA_SPEED uses Telegram 1.

Learn more about DMC's Siemens PLC programming services. 

Comments

Amber Lyla
# Amber Lyla
Thank you so much for this wonderful article really! epos If someone want to learn more about the this kind of information. I think this is the right place for you!
Maksim Melnikau
# Maksim Melnikau
Thank you Otto,
very useful note,. Im applying it to V90 servos.
Will be great if you can share the UDT you use for axis control.

Post a comment

Name (required)

Email (required)

CAPTCHA image
Enter the code shown above:

Related Blog Posts