Back to top

Automation of the AKD Drive with a Siemens S7-1200 and S7-1500 PLC and Profinet RT



The following utility provides a connection between AKD servo drive and Siemens SIMATIC S7-1200/S7-1500 programmable logic controllers (PLC) using Profinet RT programmed in TIA V13.

The application contains the following functionality:

  • SW Enable/Disable
  • Emergency Stop
  • Reset of drive faults
  • Jog
  • Home
  • Execution of a pre-defined motion task
  • Direct positioning (direct motion task)
  • Read and Write access to the Parameters

AKD - PLC Connection

The axis control is done with one function bloc, which can be used as multi instance.

BV_AKDPNCommFB_020_en.PNG

Direct Parameter access

All accessible PNU's on the AKD can be read or written with a second function bloc.

BV_AKDPNCommFB2_030_en.PNG

 

Common issues:

  • iMTNo, This value needs to have the number of the motion task to be executed. If the motion task is pre-defined in the AKD take the number MT.NUM. If the motion task will be setup by the iCmdXXX values the number needs to be 0x8000.
  • The conversion of the unit from Profinet scaling to user unit is tricky due to the fact that different formatting gives different results doing the same math. Easiest is to always transfer with DINT. So first assign the value to a DINT variable and then do the calculation into a REAL.

Here is an example for oPos:

image

  • For a command being sent to the drive, the same conversion applies the other way around. Do a REAL calculation assigned to a DINT and then move this double integer to the function block input.

Here is an example for iVelCmd:

image

Comments

karstenjorgensen's picture
karstenjorgensen
How can I obtain the code for these two function blocks (AKD1_PNComm and AKD1_PNComm_Param)?
Martin Rupf's picture
Martin Rupf
All the example have been shifted to one single page, please refer to this for getting the latest.

https://www.kollmorgen.com/en-us/developer-network/sample-projects-siemens-s7-1200-s7-1500-plcs-and-...

There are different application and approache for any user, inlcunding Official Kollmorgen AKD Profinet Sample Project - For TIA
 
karstenjorgensen's picture
karstenjorgensen
Thanks, Martin