Profinet Io Controller v3 Protocol API 06 En
Profinet Io Controller v3 Protocol API 06 En
PROFINET IO Controller
V3.2.0
Table of contents
1 Introduction............................................................................................................................................. 4
1.1 About this document ...................................................................................................................... 4
1.2 List of revisions............................................................................................................................... 4
1.3 Technical data ................................................................................................................................ 5
1.3.1 Supported protocols .......................................................................................................................... 5
1.3.2 Features of the loadable firmware ..................................................................................................... 5
1.3.3 Restrictions........................................................................................................................................ 7
1.3.4 Additional features ............................................................................................................................. 8
1.4 References to documents .............................................................................................................. 8
1.5 Legal Notes .................................................................................................................................... 9
1.6 Third party software licenses ....................................................................................................... 12
2 Getting started ...................................................................................................................................... 13
2.1 Configuration of PROFINET IO Controller ................................................................................... 13
2.1.1 Overview ......................................................................................................................................... 13
2.1.2 AR table........................................................................................................................................... 14
2.1.3 IOCR tables ..................................................................................................................................... 14
2.1.4 Submodule table ............................................................................................................................. 15
2.1.5 Record storage ................................................................................................................................ 15
2.1.6 Packet configuration sequence ....................................................................................................... 16
2.2 Process data handling .................................................................................................................. 17
2.2.1 Output data handling ....................................................................................................................... 17
2.2.2 Input data handling .......................................................................................................................... 20
2.2.3 Process data timing in isochronous applications ............................................................................. 23
2.3 Configuration / Network state ....................................................................................................... 24
3 Application interface ............................................................................................................................ 25
3.1 Configuration ................................................................................................................................ 25
3.1.1 Configure OEM Parameter service .................................................................................................. 25
3.1.2 Configure IO Controller service ....................................................................................................... 33
3.1.3 Configure IO Controller parameter service ...................................................................................... 41
3.1.4 Configure IO Device service ............................................................................................................ 46
3.1.5 Configure AR parameters service ................................................................................................... 53
3.1.6 Configure IOCR service................................................................................................................... 57
3.1.7 Configure submodule service .......................................................................................................... 65
3.1.8 Configure record service ................................................................................................................. 71
3.1.9 Configure topology service .............................................................................................................. 76
3.1.10 Download finished service ............................................................................................................... 79
3.1.11 Load Remanent service................................................................................................................... 81
3.1.12 Configure record structures ............................................................................................................. 83
3.2 Acyclic requests ......................................................................................................................... 118
3.2.1 Read submodule record service .................................................................................................... 118
3.2.2 Write submodule record service .................................................................................................... 124
3.2.3 Read implicit record service .......................................................................................................... 128
3.2.4 Acknowledge Alarm service .......................................................................................................... 134
3.2.5 DCP Set Name service.................................................................................................................. 137
3.2.6 DCP Set IP service ........................................................................................................................ 140
3.2.7 DCP Set Signal Service................................................................................................................. 144
3.2.8 DCP Reset Factory Settings service ............................................................................................. 147
3.2.9 DCP Get service ............................................................................................................................ 151
3.2.10 Get Logbook Service ..................................................................................................................... 156
3.2.11 Get AR Vendor Block Response Service ...................................................................................... 160
3.2.12 Set AR Status service.................................................................................................................... 163
3.2.13 Establish Device Access AR ......................................................................................................... 165
3.2.14 Release Device Access AR ........................................................................................................... 169
3.3 Network scan.............................................................................................................................. 171
3.4 Device Access AR (DA-AR) ....................................................................................................... 174
3.4.1 Overview ....................................................................................................................................... 174
3.4.2 Usage ............................................................................................................................................ 175
3.5 Acyclic indications ...................................................................................................................... 176
3.5.1 Receive Alarm service ................................................................................................................... 176
3.5.2 Receive Diagnosis service ............................................................................................................ 181
3.5.3 Store Remanent service ................................................................................................................ 188
3.6 Get configuration services .......................................................................................................... 190
1 Introduction
1.1 About this document
This manual describes the application interface of the PROFINET IO Controller protocol stack. The
aim of this manual is to support the integration of netX-based devices into applications.
1.3.3 Restrictions
The size of the bus configuration file is limited by the size of the RAM Disk (1 Megabyte)
The configuration database interface and its structure and definitions apply for netX products
which use the PROFINET IO Controller - firmware only.
Structures and functions described in this document apply only to hardware from 3rd party
vendors insofar as original Hilscher firmware is concerned. Therefore, whenever the term
"netX firmware" is used throughout this manual it refers to ready-made firmware provided by
Hilscher. Although 3rd party vendors are free to implement the same structures and functions
in their product, no guarantee for compatibility of drivers etc. can be given.
The following limitations apply
The usable (minimum) cycle time depends on the number of used IO Devices, the
number of used input and output data. See technical data for details
RT over UDP not supported
Multicast communication not supported
DHCP is not supported (neither for PROFINET IO Controller nor for the IO-Devices)
Only one IOCR per IO-Device per direction
only one instance of DeviceAccess AR can be used at the same time
MRPD is not supported
planing of IRT is not done by the PROFINET IO Controller protocol stack
Sync Slave is not supported
MRP Manager requires an additional license in security memory
only one fragmented acyclic services can be used at the same time
Multiple MRP Managers are not supported
only one DCP Service can be used in parallel
Multiple Sync Masters are not supported
Fast startup
The PROFINET IO Controller supports Fast Startup (FSU). This feature can be configured
independently per AR.
Device Access AR
The PROFINET IO Controller implements Device Access AR. This AR Type is usually used to
write I&M record objects by the engineering software.
Important notes
Utmost care was/is given in the preparation of the documentation at hand consisting of a user's
manual, operating manual and any other document type and accompanying texts. However, errors
cannot be ruled out. Therefore, we cannot assume any guarantee or legal responsibility for
erroneous information or liability of any kind. You are hereby made aware that descriptions found
in the user's manual, the accompanying texts and the documentation neither represent a
guarantee nor any indication on proper use as stipulated in the agreement or a promised attribute.
It cannot be ruled out that the user's manual, the accompanying texts and the documentation do
not completely match the described attributes, standards or any other data for the delivered
product. A warranty or guarantee with respect to the correctness or accuracy of the information is
not assumed.
We reserve the right to modify our products and the specifications for such as well as the
corresponding documentation in the form of a user's manual, operating manual and/or any other
document types and accompanying texts at any time and without notice without being required to
notify of said modification. Changes shall be taken into account in future manuals and do not
represent an obligation of any kind, in particular there shall be no right to have delivered
documents revised. The manual delivered with the product shall apply.
Under no circumstances shall Hilscher Gesellschaft für Systemautomation mbH be liable for direct,
indirect, ancillary or subsequent damage, or for any loss of income, which may arise after use of
the information contained herein.
Liability disclaimer
The hardware and/or software was created and tested by Hilscher Gesellschaft für
Systemautomation mbH with utmost care and is made available as is. No warranty can be
assumed for the performance or flawlessness of the hardware and/or software under all application
conditions and scenarios and the work results achieved by the user when using the hardware
and/or software. Liability for any damage that may have occurred as a result of using the hardware
and/or software or the corresponding documents shall be limited to an event involving willful intent
or a grossly negligent violation of a fundamental contractual obligation. However, the right to assert
damages due to a violation of a fundamental contractual obligation shall be limited to contract-
typical foreseeable damage.
Warranty
Hilscher Gesellschaft für Systemautomation mbH hereby guarantees that the software shall run
without errors in accordance with the requirements listed in the specifications and that there were
no defects on the date of acceptance. The warranty period shall be 12 months commencing as of
the date of acceptance or purchase (with express declaration or implied, by customer's conclusive
behavior, e.g. putting into operation permanently).
The warranty obligation for equipment (hardware) we produce is 36 months, calculated as of the
date of delivery ex works. The aforementioned provisions shall not apply if longer warranty periods
are mandatory by law pursuant to Section 438 (1.2) BGB, Section 479 (1) BGB and Section 634a
(1) BGB [Bürgerliches Gesetzbuch; German Civil Code] If, despite of all due care taken, the
delivered product should have a defect, which already existed at the time of the transfer of risk, it
shall be at our discretion to either repair the product or to deliver a replacement product, subject to
timely notification of defect.
The warranty obligation shall not apply if the notification of defect is not asserted promptly, if the
purchaser or third party has tampered with the products, if the defect is the result of natural wear,
was caused by unfavorable operating conditions or is due to violations against our operating
regulations or against rules of good electrical engineering practice, or if our request to return the
defective object is not promptly complied with.
Additional guarantees
Although the hardware and software was developed and tested in-depth with greatest care,
Hilscher Gesellschaft für Systemautomation mbH shall not assume any guarantee for the suitability
thereof for any purpose that was not confirmed in writing. No guarantee can be granted whereby
Confidentiality
The customer hereby expressly acknowledges that this document contains trade secrets,
information protected by copyright and other patent and ownership privileges as well as any related
rights of Hilscher Gesellschaft für Systemautomation mbH. The customer agrees to treat as
confidential all of the information made available to customer by Hilscher Gesellschaft für
Systemautomation mbH and rights, which were disclosed by Hilscher Gesellschaft für
Systemautomation mbH and that were made accessible as well as the terms and conditions of this
agreement itself.
The parties hereby agree to one another that the information that each party receives from the
other party respectively is and shall remain the intellectual property of said other party, unless
provided for otherwise in a contractual agreement.
The customer must not allow any third party to become knowledgeable of this expertise and shall
only provide knowledge thereof to authorized users as appropriate and necessary. Companies
associated with the customer shall not be deemed third parties. The customer must obligate
authorized users to confidentiality. The customer should only use the confidential information in
connection with the performances specified in this agreement.
The customer must not use this confidential information to his own advantage or for his own
purposes or rather to the advantage or for the purpose of a third party, nor must it be used for
commercial purposes and this confidential information must only be used to the extent provided for
in this agreement or otherwise to the extent as expressly authorized by the disclosing party in
written form. The customer has the right, subject to the obligation to confidentiality, to disclose the
terms and conditions of this agreement directly to his legal and financial consultants as would be
required for the customer's normal business operation.
Export provisions
The delivered product (including technical data) is subject to the legal export and/or import laws as
well as any associated regulations of various countries, especially such laws applicable in
Germany and in the United States. The products / hardware / software must not be exported into
such countries for which export is prohibited under US American export control laws and its
supplementary provisions. You hereby agree to strictly follow the regulations and to yourself be
responsible for observing them. You are hereby made aware that you may be required to obtain
governmental approval to export, reexport or import the product.
2 Getting started
The following section gives an overview about general topics when using the PROFINET IO
Controller.
Note: The configuration file format was incompatibely changed between firmware
version 3.1.x and 3.2.x. Firmware version 3.1.x used “config.dat” whereas
firmware version 3.2.x is using “config.nxd”.
The configuration data will be internally stored into tables like structures as shown in the following
figure.
Note: Due to the internal firmware structure a special constraint applies to the frame id of any
input IOCRs and the frame id of IRT output IOCRs. Thus the frame id is automatically
generated from the IOCR handle.
Depending on the IOCR's handle, the IOCR Type and the direction the PROFINET IO Controller
will internally generate a frame id for the associated IOCR.
The output data is handled as follows for the PROFINET protocol stack:
1. The application writes the data into the DPM output area. Afterwards the application toggles
the HCF_PDx_OUT_CMD handshake bit.
2. When the HCF_PDx_OUT_CMD handshake bit is toggled, the firmware will start updating its
transmit buffers from the DPM output area. If the update is finished before the next send
clock starts, the new data will be transferred in the next red phase. If the update is not
finished before the next red phase starts, data from the previous cycle will be used again in
the next red phase and the new data will be used in the next to next red phase.
3. The firmware will confirm the buffer update on the next green phase begin after finishing the
transmitt buffer update by toggling the NCF_PDx_OUT_ACK handshake bit.
Note: Due to this implementation the NCF_PDx_OUT_ACK handshake bit will be toggled
atmost once per cycle, when the green phase starts. Thus the firmware enforces that
the application cannot update the process data more than once per sendclock. This
leads to the following behavior:
1. The firmware is implicitly protected from being overloaded by the application due to too
frequent process data update.
2. The application is implicitly synchronized to the network timing. This can be regarded as a
light form of bus synchronization of the application process.
The receive data is handled as follows for the PROFINET protocol stack:
1. The application toggles the HCF_PDx_IN_ACK handshake bit to request the DPM input area
update. The handshake toggle will be notified by the firmware but will not cause an
immediate action.
2. When the next green phase starts the firmware will check if the HCF_PDx_IN_ACK
handshake bit had been toggled before. If that is the case, the DPM input area will be
updated with the received process data from the preceding red phase and the previous and
possibly current green phase. This depends on receive timing in green phase. The time
needed by the firmware for doing so is denoted as Time_RxUpd. After performing the
update, the firmware will confirm the DPM input area update by toggling the
NCF_PDx_IN_CMD handshake bit.
3. The application can now access the DPM input area to get the received data.
Note: Due to this implementation the NCF_PDx_IN_CMD handshake bit will be toggled at
most once per cycle, after the begin of the green phase when all received process data
had been evaluated. Thus the firmware enforces that the application cannot retrieve
the process data more than once per sendclock. This leads to the following behavior:
1. The firmware is implicitly protected from being overloaded by the application due to too
frequent process data evaluation requests
2. The application is implicitly synchronized to the network timing. This can be regarded as a
light form of bus synchronization of the application process
Note: If using the function xChannelIORead it must be considered, that function copies the
current content of the DPM input area to the application. The update of the DPM input
area is requested after copying the data.
Note: The DPM handling follows the buffered host controlled scheme. This means for the
receive data, that the application has to call xChannelIORead initially in order to toggle
the HCF_PDx_IN_ACK if the application uses interrupt mode. Otherwise no initial
interrupt will be generated.
They following figure shows the timing relations for this use case. Note that in isochronous
applications each network cycle consist of a red and a green period. The isochronous data is
exchanged between the PROFINET Controller and Devices in the red period. (Realtime Class 3
traffic)
In isochronous applications, the PROFINET Devices are required to aquire the input values at a
time point T_IOInput before the next cycle starts. Likewise the output values are to be applied at
time T_IOOutput after the cycle start. While the T_IOInput time only depends on the capabilities of
a particular device the T_IOOutput value also depends on length of the red period. The length of
the red period in turn depends on the number of devices in the configuration, the amount of
process data to be exchanged and the network topology.
The length of the red period also influences the processing time available for the PROFINET
Controller Application. As shown in the image, right after the red period ends, the controller
firmware will transfer the input process data into the Dual Port Memory. Afterwards the application
can access and process the data. Finally the PROFINET Controller Firmware will transfer the
output process data into internal buffers ready for transmission in the next red period.
The PROFINET Controller implementation of the Dual Port Memory Process Data Handshake
mechanism simplifies the application handling. Calling the cifX Api Function xChannelIORead will
block until the process data of the current cycle is available.
The PROFINET Controller firmware implements a monitoring mechanism which takes timestamps
at some critical points in this processing loop: T_InputUpdateStart, T_InputUpdateFinish,
T_OutputUpdateStart and T_OutputUpdateFinish. This timing information is placed in the extend
status block. Additionally the firmware can be configured to provide this information in the input
area as well. In both places the timing information is synchronized with the DPM input area
handshake.
In order to provide the PROFINET Controller Application with an estimation about the available
processing time, the Configuration Parameter Isochronous Controller Data has been defined. It is
an artifical Parameter for the Controller generated by the engineering system. (e.g. Sycon.NET)
The Application can read this parameter using the Get Ioc Parameter Service.
Note: Only a configuration using the setting “Application Controlled Startup” will meet the
requirements of PROFINET IO Controller certification.
3 Application interface
This section contains the description of all packets of the application interface.
3.1 Configuration
This section contains the description of packets to configure the PROFINET IO Controller stack.
Note: The service can only be used if bus communication is deactivated. It can also be
performed after Configure IO Controller service (page 33) if the start mode is controlled
by the application. In general, parameters affected by this service will not be reset to
power-on values when the configuration is deleted. If this is desired a system reset or
power cycle must be performed. Exception from this rule are parameters which
overwrite configuration values.
enum PNM_AP_CFG_OEMPRM_TYPE_Etag
{
PNM_AP_CFG_OEMPRM_VERSION = 1,
PNM_AP_CFG_OEMPRM_SERIAL_NUMBER = 2,
PNM_AP_CFG_OEMPRM_ORDER_ID = 3,
PNM_AP_CFG_OEMPRM_ALARM_HANDLING = 4
PNM_AP_CFG_OEMPRM_DEVICE_IDENTITY = 5,
};
union PNM_AP_CFG_OEMPRM_PCK_Ttag
{
/** request packet */
PNM_AP_CFG_OEMPRM_REQ_T tReq;
/** confirmation packet */
PNM_AP_CFG_OEMPRM_CNF_T tCnf;
};
Packet description
Structure PNM_AP_CFG_OEMPRM_REQ_T Type: Request
Variable Type Value / Range Description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Ignored. Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 8+n Packet data length in bytes. n depends on the OEM
parameter type contained in the packet. (see )
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x9412 PNM_AP_CMD_CFG_OEMPRM_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_OEMPRM_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usPrmType UINT16 1 The the parameter to configure
usPadding UINT16 0 Padding. Set to zero for future compatibility
uData UNION Union container for parameters
Parameter descriptions
Parameter ulStructVersion
Version of this structure. This parameter is used for future extensions of the Configure Controller
service.
Parameter usPrmType
The usPrmType field is used to specify the parameter to configure. The following value is defined:
Option Numeric Parameter Meaning
value Length (n)
PNM_AP_CFG_OEMPRM_VERSION 1 14 The version identification of the firmware shall be
configured. The field uData contains version
information according structure
PNM_AP_CFG_OEMPRM_VERSION_T.
PNM_AP_CFG_OEMPRM_SERIAL_ 2 20 The Device unique serial number to be used.
NUMBER The field uData contains serial number according
structure
PNM_AP_CFG_OEMPRM_SERIAL_NUMBER_T.
PNM_AP_CFG_OEMPRM_ORDER_ID 3 24 The Order number of device. The field uData
contains order number according structure
PNM_AP_CFG_OEMPRM_SERIAL_NUMBER_T.
This information is overwritten when a new
configuration is loaded. Therfore this parameter
must be set after configuring the profinet IO
controller but before enabling the bus.
PNM_AP_CFG_OEMPRM_ALARM_ 4 8 Defines alarm handling behavior by PROFINET IO
HANDLING Controller stack. This service allows the application
to selct which alarm types can by the application be
handeled. The field uData contains alarm handling
flags according structure PNM_AP_CFG_
OEMPRM_ALARM_HANDLING_T.
This parameter is overwritten when a new
configuration is loaded. Therefore is must be set
after configuring the profinet IO controller but
before enabling the bus.
PNM_AP_CFG_OEMPRM_DEVICE_ID 5 10 Overwrite Profinet VendorId, DeviceId and Instance
ENTITY from Configuration Database with custom values.
This parameter is overwritten when a new
configuration is loaded. Therefore is must be set
after configuring the profinet IO controller but
before enabling the bus.
Table 8: Definiton of OEM parameter types
Parameter uData
This field contains the configuration parameter. The union PNM_AP_CFG_OEMPRM_UNION_T with
the following subfields is defined:
Variable Type Value / Description
Range
tVersion STRUCT - Parameter structure for Version
tSerialNumber STRUCT - Parameter structure for serial number.
tOrderID STRUCT - Parameter structure for order number.
tAlarmHandling STRUCT - Parameter structure for alaram handling flags.
tDeviceIdentity STRUCT - Parameter structure for device identity.
Parameter uData.tVersion
This parameter defines the version information to be reported by the protocol stack.
Note: If the firmware version of the PROFINET IO Controller is not a release or hotfix version
and the application specifies a value of 'V' or 'R' for the prefix, then the firmware will
force the prefix to the value 'P'.
Parameter uData.tSerialNumber
This parameter defines the unique production serial number. This serial number will be used for
RPCAnnotation, LLDP System Description and LLDP ChassisId in case of enabled Multiple
interface node.
Note: The serial number shall be left aligned and shall be padded with space(es) (character
0x20) to the full field length
Parameter uData.tOrderId
This Parameter defines the order number that allows a unambiguous identification of the
PROFINET IO Controller.
Note: This service is intended to be used only in conjunction with SYCON.net database
configuration. The application which use Configure IO Controller service may set the
OrderId using abOrderId parameter in PNM_AP_CFG_IOC_REQ_T request packet.
Parameter uData.tAlarmHandling
This parameter specifies which alarms shall be handled by the PROFINET IO Controller
automatically and which alarms shall be passed to the application for processing.
Note: This service is intended to be used only in conjunction with SYCON.net database
configuration. The application which use Configure IO Controller service may
deterimine the alarm handling behavior of IO Controller using ulAlarmHandlingFlags
parameter in PNM_AP_CFG_IOC_REQ_T request packet.
Parameter uData.tDeviceIdentity
This parameter set the PROFINET IO VendorId, DeviceId and Instance to the specified values. It
can be used to overwrite values from a configuration database.
Note: This service is intended to be used only in conjunction with SYCON.net database
configuration. The application which use Configure IO Controller service may set the
device identity using usVendorId, usDeviceId parameter in
PNM_AP_CFG_IOC_REQ_T request packet.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW)
Handle (LOM)
ulSrc UINT32 0 ... 232-1 Ignore
ulDestId UINT32 0
ulSrcId UINT32 mirrored
ulLen UINT32 0 Packet data length in bytes
ulId UINT32 mirrored
enum PNM_AP_CFG_ALARM_HANDLING_FLAGS_Etag
{
/* includes diagnosis disappears */
PNM_AP_CFG_ALARM_HANDLING_FLAG_DIAGNOSIS = 0x00000001,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PROCESS = 0x00000002,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL = 0x00000004,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG = 0x00000008,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL_MODULE = 0x00000010,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG_WRONG = 0x00000020,
PNM_AP_CFG_ALARM_HANDLING_FLAG_STATUS = 0x00000040,
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPDATE = 0x00000080,
PNM_AP_CFG_ALARM_HANDLING_FLAG_MEDIA_REDUND = 0x00000100,
PNM_AP_CFG_ALARM_HANDLING_FLAG_CONTROLLED = 0x00000200,
PNM_AP_CFG_ALARM_HANDLING_FLAG_RELEASED = 0x00000400,
PNM_AP_CFG_ALARM_HANDLING_FLAG_RETURN_OF_SUBM = 0x00000800,
PNM_AP_CFG_ALARM_HANDLING_FLAG_MCR_MISMATCH = 0x00001000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_PORT_DATA_CHANGE = 0x00002000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_SYNC_DATA_CHANGE = 0x00004000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_TIME_DATA_CHANGE = 0x00008000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_ISOCHR_MODE_PROBLEM = 0x00010000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_NETW_COMP_PROBLEM = 0x00020000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_DFP_PROBLEM = 0x00040000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_MRPD_PROBLEM = 0x00080000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_MULT_INTF_MISMATCH = 0x00100000,
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPLOAD_AND_RETRIVAL = 0x00200000,
/* unknown alarm types MUST be handled in application and are NOT handled automatically
by protocol stack */
PNM_AP_CFG_ALARM_HANDLING_FLAG_MANUFACTURER_ALARMS = 0x80000000,
};
With the ulAlarmHandlingFlags you can define which alarms should be handled by the
fieldbus stack automatically.
The definition of the ulAlarmHandlingFlags are \ref
PNM_AP_CFG_ALARM_HANDLING_FLAGS_Etag enumeration.
*/
uint32_t ulAlarmHandlingFlags;
/** DPM Channel Watchdog time in ms
\arg \c Deactivated 0
\arg \c Min 0
\arg \c Max 65535)
*/
uint32_t ulDpmWatchdogTime;
/** VendorID to be used by IO Controller
\note This parameter is for the OEMs to handover the own VendorID number.
\par See Spec:
Coding of fields related to Instance, DeviceID, VendorID
*/
uint16_t usVendorID;
/** DeviceID to be used by IO Controller
\note This parameter is for the OEMs to handover the Vendor spezific DeviceID
number.
\par See Spec:
Coding of fields related to Instance, DeviceID, VendorID
*/
uint16_t usDeviceID;
/** IP address to be used by IO Controller */
uint32_t ulIPAddr;
/** subnet mask to be used by IO Controller */
uint32_t ulNetmask;
/** Gateway address to be used by IO Controller */
uint32_t ulGateway;
/** Device Type to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\par See Spec:
See Coding of the field DeviceType
*/
uint8_t abDeviceType[25];
/** NameOfStation to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\note The default name should be get from the GSDML attribute \c
DNS_CompatibleName.
\par See Spec:
Coding of the field NameOfStationValue
*/
uint8_t abNameOfStation[240];
/** OrderId to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\note The GSDML Element \c OrderNumber.
\par See Spec:
Coding of the field OrderID
*/
/** Start offset in DPM input area for slave status bitlists.
Each bitlist has 128 bits (one for each IO Device) thus requires 16 byte.
The bitlists are always in the fix order: configured, active, faulty
The bitlist must be located outside of the process data area, that is,
either before any process data or behind.
*/
uint16_t usBitlistStartOffset;
/** Fix alignment of structure fields due to definition abDeviceType */
uint8_t bPadding;
/** Start offset in DPM input area for the IRT cycle counter
*
* This field is available since structure version 2. Set to 0xFFFF
* to disable cycle counter in input data area. */
uint16_t usIoTimingInfoOffset;
};
/* request packet */
typedef struct PNM_AP_CFG_IOC_REQ_Ttag PNM_AP_CFG_IOC_REQ_T;
__PACKED_PRE struct __PACKED_POST PNM_AP_CFG_IOC_REQ_Ttag
{
/** packet header */
PNM_AP_PCK_HEADER_T tHead;
/** packet data */
PNM_AP_CFG_IOC_DATA_T tData;
} ;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Ignored. Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 322 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x9400 PNM_AP_CMD_CFG_IOC_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_IOC_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
ulSystemFlags UINT32 0, 1 System flags
ulAlarmHandlingFlags UINT32 Automatic alarm handling flags
ulDpmWatchdogTime UINT32 0, 20 … 65535 DPM channel watchdog time
usVendorID UINT16 VendorID to be used by IO Controller
usDeviceID UINT16 DeviceID to be used by IO Controller
ulIPAddr UINT32 IP address to be used by IO Controller
ulNetmask UINT32 Subnet mask to be used by IO Controller
ulGateway UINT32 Gateway address to be used by IO Controller
abDeviceType[25] UINT8[] Device Type to be used by IO Controller
abNameOfStation[240] UINT8[] NameOfStation to be used by IO Controller
abOrderId[20] UINT8[] OrderId to be used by IO Controller
usBitlistStartOffset UINT16 Start offset in DPM input area for slave status bit lists
bPadding UINT8 0 Padding to fix structure field alignment. Set to zero
for future compatibility.
usIoTimingInfoOffset UINT16 Start offset in DPM input area for io timing
information (This field is available since structure
version 2)
Parameter descriptions
Parameter ulStructVersion
Version of this structure. This parameter is used for future extensions of the Configure Controller
Service.
Parameter ulSystemFlags
The ulSystemFlags field is a bitmask of flags defined as follows:
Option Numeric value Meaning
PNM_AP_IOC_FLAG_STARTMODE_ 0x00000000 The communication will be started automatically after the
AUTOMATIC PROFINET IO Controller had been configured successfully.
PNM_AP_IOC_FLAG_STARTMODE_ 0x00000001 The application must explicitly enable the bus to start
APPLICATION_CONTROLLED communication.
PNM_AP_IOC_FLAG_FORCE_NAME_ 0x00000002 The controller will assign the Name Of Station even to
ASSIGNMENT devices which are already assigned a Name Of Station.
Parameter ulAlarmHandlingFlags
This parameter specifies which alarms shall be handled by the PROFINET IO Controller itself and
which alarms shall be passed to the application for processing. The field ulAlarmHandlingFlags is
defined as a bitmask where each bit corresponds to a particular alarm type. For each alarm to be
handled by the PROFINET IO Controller the corresponding bit shall be set. As a special use case it
is also possible to handle all manufacturer specific alarms within the PROFINET IO Controller
using the bitmask PNM_AP_CFG_ALARM_HANDLING_FLAG_MANUFACTURER_ALARMS.
The following bitmasks are defined:
Flag Value
PNM_AP_CFG_ALARM_HANDLING_FLAG_DIAGNOSIS 0x00000001
PNM_AP_CFG_ALARM_HANDLING_FLAG_PROCESS 0x00000002
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL 0x00000004
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG 0x00000008
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL_MODULE 0x00000010
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG_WRONG 0x00000020
PNM_AP_CFG_ALARM_HANDLING_FLAG_STATUS 0x00000040
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPDATE 0x00000080
PNM_AP_CFG_ALARM_HANDLING_FLAG_MEDIA_REDUND 0x00000100
PNM_AP_CFG_ALARM_HANDLING_FLAG_CONTROLLED 0x00000200
PNM_AP_CFG_ALARM_HANDLING_FLAG_RELEASED 0x00000400
PNM_AP_CFG_ALARM_HANDLING_FLAG_RETURN_OF_SUBM 0x00000800
PNM_AP_CFG_ALARM_HANDLING_FLAG_MCR_MISMATCH 0x00001000
PNM_AP_CFG_ALARM_HANDLING_FLAG_PORT_DATA_CHANGE 0x00002000
PNM_AP_CFG_ALARM_HANDLING_FLAG_SYNC_DATA_CHANGE 0x00004000
PNM_AP_CFG_ALARM_HANDLING_FLAG_TIME_DATA_CHANGE 0x00008000
PNM_AP_CFG_ALARM_HANDLING_FLAG_ISOCHR_MODE_PROBLEM 0x00010000
PNM_AP_CFG_ALARM_HANDLING_FLAG_NETW_COMP_PROBLEM 0x00020000
PNM_AP_CFG_ALARM_HANDLING_FLAG_DFP_PROBLEM 0x00040000
PNM_AP_CFG_ALARM_HANDLING_FLAG_MRPD_PROBLEM 0x00080000
PNM_AP_CFG_ALARM_HANDLING_FLAG_MULT_INTF_MISMATCH 0x00100000
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPLOAD_AND_RETRIVAL 0x00200000
Flag Value
PNM_AP_CFG_ALARM_HANDLING_FLAG_MANUFACTURER_ALARMS 0x80000000
Table 9: Definition of alarm handling flags
Parameter ulDpmWatchdogTime
This parameter specifies the DPM channel watchdog timeout in units of milliseconds.
A value of 0 means DPM Channel Watchdog supervision is explicitly disabled.
A value between 20 (Minimum) and 65535 (Maximum) means DPM Channel Watchdog
supervision is prepared with the specified watchdog time. In order to activate the watchdog,
the application must start the supervision using the standard DPM Watchdog Mechanism
after the successful configuration of the PROFINET IO Controller.
Parameter usVendorID
This parameter specifies the PROFINET Vendor Id the controller shall use. The vendor id is an
unique identification number of the controller's vendor assigned by the PNO.
Note: This parameter is for the OEMs to handover the own VendorID number.
Parameter usDeviceID
This parameter specifies the PROFINET Device Id the controller shall use. The device id is a
unique device id assigned by the vendor of the device.
Note: This parameter is for the OEMs to handover the Vendor specific DeviceID number.
Parameter ulIPAddr
IP address to be used by IO Controller
Parameter ulNetmask
Subnet mask to be used by IO Controller
Parameter ulGateway
Gateway address to be used by IO Controller
Parameter abDeviceType
The device type is a short textual description of the device. It is used in device identification when
performing network scans or when reading out identification information from a PROFINET Device
or Controller. The value shall be padded with zero(es) to the full field length.
Parameter abNameOfStation
The name of station is the bus address of a PROFINET Device or Controller. The name of station
must be unique across the communication network. According to the PROFINET specification the
characters a-z, 0-9, '-' and '.' are allowed where '.' has the special meaning of a label separator..
The name must fulfill further conditions:
it must not look like an IP address, e.g. 1.2.3.4
a label must consist of at least one and at most 63 characters
the name must not start with 'port-abc' or 'port-abc-defgh' where a,b,c,d,e,f,g,h are digits 0-9
The field shall be padded with zero(es) to full field length
Parameter abOrderId
The vendor's order id of the PROFINET IO Controller. The field shall be padded with zero(es) to
full field length.
Parameter usBitlistStartOffset
The PROFINET IO Controller manages three bit lists within the DPM Input Area. Each bit list is 128
bits (=16 byte) wide and reflects the status when the DPM Input area was updated by the
PROFINET IO Controller. The parameter usBitlistStartOffset specifies the offset in byte
from the beginning of the DPM Input Area where these lists shall placed to. The lists are always
present and cannot be deactivated. The following bit lists are defined:
Name Offset in DPM Input Area Description
Configured Bitlist usBitListStartOffset A bit is set to true if associated AR had been configured
Active Bitlist usBitListStartOffset + 16 A bit is set to true if associated AR is communicating
Diagnosis usBitListStartOffset + 32 A bit is set to true if associated AR is communicating and either a
diagnosis is pending or a configuration difference was detected
The offset of the bit corresponding to a particular AR can be derived from the device handle as
follows:
ByteOffset = (usDeviceHandle - 1) / 8
BitMask = 0x1 << ((usDeviceHandle -1 ) % 8)
Note: The bit list area and the input IOCR data are placed within the DPM Input Area. Thus
the application must ensure that the bit lists memory area does not overlap with input
IOCR data blocks.
Parameter usIoTimingInfoOffset
The PROFINET IO Controller firmware provides timing information about process data handling
using the PNM_AP_IOTIMINGINFO_T structure. This information can be placed in DPM input area
if required. This parameter configures the start offset of this data within the DPM input area. If the
offset is larger than the size of the DPM input area or the data does not fully fit into the DPM input
area the feature is disabled. Thus using a value 0xFFFF will disable this feature.
Note: This information is also provided in the DPM extended status block
Packet description
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 -
ulSrcId UINT32 any -
ulLen UINT32 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x9402 PNM_AP_CMD_CFG_IOC_PRM_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_IOC_PRM_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usPrmType UINT16 1 to 8, 12, 13 Parameter type (identifier)
bPortId UINT8 0 to 2 Reference of controller port to apply this
parameters to
bPadding UINT8 0 Padding. Set to zero for future compatibility.
uData PNM_AP_CFG_IOC_ Parameter data
PRM_UNION_T
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions to this structure.
Parameter bPortId
This parameter defines to which PD instance the parameter shall be applied:
Numerical value Meaning
0 Interface (submodule) of PROFINET IO Controller
1 Port 1 (submodule) of PROFINET IO Controller
2 Port 2 (submodule of PROFINET IO Controller
Packet description
PNM_AP_CFG_IOD_FLAG_MAX,
};
/* AR Types */
enum PNM_AP_CFG_IOD_AR_TYPE_Etag
{
/* standard AR Type for RT communication */
PNM_AP_CFG_IOD_AR_TYPE_SINGLE = 0x01,
/* IO Supervisor AR (with IO-data), not supported */
PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR = 0x06,
/* standard AR Type for IRT communication */
PNM_AP_CFG_IOD_AR_TYPE_RTC3 = 0x10,
/* SystemRedundancy AR, not supported */
PNM_AP_CFG_IOD_AR_TYPE_SYSTEMREDUNDANCY = 0x20,
};
/* AR Properties */
enum PNM_AP_CFG_IOD_AR_PROP_FLAGS_Etag
{
/* a supervisor is allowed to take over submodules of this AR */
PNM_AP_CFG_IOD_AR_PROP_FLAG_SUPERVISOR_TAKEOVER_ALLOWED = 0x00000008,
/** startup according to Profinet specification 2.3, if not set the legacy startup is
used */
PNM_AP_CFG_IOD_AR_PROP_FLAG_STARTUPMODE_ADVANCED = 0x40000000,
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 47/290
/* alarm type PULL MODULE is supported */
PNM_AP_CFG_IOD_AR_PROP_FLAG_PULL_MODULE_ALARM_ALLOWED = 0x80000000,
/* AR is an device access AR, only valid in conjunction with
* PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR */
PNM_AP_CFG_IOD_AR_PROP_FLAG_DEVICEACCESS = 0x00000100,
};
enum PNM_AP_DEVICEHANDLE_Etag
{
/** Device handle of the controller itself */
PNM_AP_DEVICEHANDLE_IOC = 0x0000,
/* RTA Retries */
#define PNM_AP_CFG_IOD_RTA_RETRIES_MIN (0x0003) /**< minimum value allowed
for RTA retries */
#define PNM_AP_CFG_IOD_RTA_RETRIES_MAX (0x000F) /**< maximum value allowed
for RTA retries */
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility.
ulSrcId UINT32 any Ignored by protocol stack
ulLen UINT32 296 Packet data length in bytes
ulId UINT32 any Ignored by protocol stack
ulSta UINT32 0 -
ulCmd UINT32 0x9404 PNM_AP_CMD_CFG_IOD_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_IOD_REQ_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usDeviceHandle PNM_AP_DEVIC 1 … 128 Unique handle of this IO-Device defined by the
EHANDLE_T sender of this packet
bARType UINT8 0x01, 0x10 AR Type
bAddressMode UINT8 0 .. 1 IP address mode
ulFlags UINT32 Flags controlling AR behavior
tArUuid PNM_UUID_T UUID associated with this AR
ulArProperties UINT32 Properties of this AR.
usVendorID UINT16 GSDML PROFINET Vendor ID of the Device
usDeviceID UINT16 GSDML PROFINET Device ID of the Device
usInstanceID UINT16 GSDML PROFINET Instance ID of the Device
usMaxAlarmDataLength UINT16 200 … 224 Maximum alarm data length
usRTATimeoutFact UINT16 1 … 0xFFFF RTA Timeout Factor
usRTARetries UINT16 3 … 10 RTA Retries
abNameOfStation[240] UINT8[] NameOfStation of the IO Device
ulIPAddr UINT32 IP address
ulNetworkMask UINT32 Network mask
ulGatewayAddr UINT32 Gateway address (i.e. IP address of gateway)
Parameter descriptions
Parameter ulStructVersion
Structure version of the configuration structure. Used for future extensions.
Parameter usDeviceHandle
This parameter specifies the handle of the AR to be configured.
Parameter bARType
This parameter describes the type of the AR
Name Numeric value Meaning
PNM_AP_CFG_IOD_AR_TYPE_SINGLE 0x01 AR Type for RT communication
PNM_AP_CFG_IOD_AR_TYPE_RTC3 0x10 AR Type for IRT communication
Parameter bAddressMode
This parameter describes the possible modes of ip address resolution
Name Numeric value Meaning
PNM_AP_CFG_IOD_ADDRESS_MODE_DCP_ 0 (default) In this mode, the controller discovers the device
IDENTIFY_ASSIGN using its station name or alias name (only if topology
info available) and will assign the configured ip
address if required.
PNM_AP_CFG_IOD_ADDRESS_MODE_DCP_ 1 The controller identifies the device using its station
DISCOVER name or alias name and will use the ip address
reported by the device. The ip address of device will
not be reassigned in this mode.
Please note that the Controller will not establish the
communication if the ip address set in IO Device is
set to zero or unreachable.
Parameter ulFlags
The parameter ulFlags is a bitmask of flag bits specifying additional properties of the AR. The
following table lists the defined bits
Name Numeric Meaning
value
PNM_AP_CFG_IOD_FLAG_WRITE_ 0x01 Use multiple write to parameterize the device. This flag should be
MULTIPLE_SUPPORTED set if the PROFINET IO Device associated with this AR supports
multiple write. (Extracted from GSDML) The PROFINET IO
Controller will pack multiple parameter writes into one RPC
Service to save Startup Time.
RESERVED 0x02 This value is reserved for future usage. Set to 0 for compatibility
reasons.
Parameter tArUUID
Unique identifier of the AR. The AR UUID shall be generated by the engineering software or
application. It is a unique id of the AR and must be non-zero.
Parameter ulArProperties
The parameter ulARProperties is a bitmask describing PROFINET Properties of this AR. A
combination of the following values is allowed:
Name Numeric Meaning
value
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x00000008 A supervisor is allowed to take over submodules of this AR.
SUPERVISOR_TAKEOVER_ALLOWED
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x40000000 AR start-up is performed according to PROFINET
STARTUPMODE_ADVANCED specification 2.3 Advanced Startup Mode. (Extract from
GSDML file). If the bitmask is not set, then the PROFINET
V2.2 Startup Mode is used.
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x80000000 The alarm type PULL MODULE is supported by the device.
PULL_MODULE_ALARM_ALLOWED (Extract from GSDML file)
Parameter usVendorID
VendorID to be used by IO Controller for addressing the IO Device. (Extract from GSDML file)
Parameter usDeviceID
DeviceID to be used by IO Controller for addressing the IO Device (Extract from GSDML file)
Parameter usInstanceID
The instance ID of the device. (Extract from GSDML file, Attribute "ObjectUUID Instance")
Parameter usMaxAlarmDataLength
The maximum length of payload data to be transported in an alarm. The minimum value is 200
byte and must be supported by any PROFINET Device. The upper limit of the PROFINET IO
Controller is 224 byte.
Parameter usRTATimeoutFact
This parameter is used to specify the timeout of acyclic alarm services. When one side of the AR
sends an alarm it is expected that the other side acknowledges the alarm within
usRTATimeoutFact * 100ms. If the alarm is not acknowledged, up to usRTARetries will be
performed. If still no acknowledge is received, the AR will be aborted. Default value is 1. For
maximum compatibility values of the range 1 to 100 should be used.
Parameter usRTARetries
Number of times an alarm shall be retried before giving up and aborting the AR, Default value is 3
Parameter abNameOfStation[240]
The parameter abNameOfStation is the PROFINET Name Of Station to be used for this AR. The
PROFINET IO Controller will establish the AR with a PROFINET IO Device with that
NameOfStation. If multiple devices with same NameOfStation exists no connection will be made.
The filed should be zero padded to full field length.
Parameter ulIPAddr
IP address to be assigned to the PROFINET IO Device. This IP Address Setting is to be specified
by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Parameter ulGatewayAddr
Gateway Address to be assigned to the PROFINET IO Device. This IP Address Setting is to be
specified by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Packet description
enum PNM_AP_ARVENDORBLOCKHANDLE_Etag
{
/** The first handle value to use for AR Vendorblocks*/
PNM_AP_ARVENDORBLOCKHANDLE_FIRST = 0x0001,
/** The last handle value to use for AR Vendorblocks*/
PNM_AP_ARVENDORBLOCKHANDLE_LAST = 0x0100,
};
/* IR Data */
/* allowed values for field ulStructVersion */
#define PNM_AP_CFG_AR_PRM_IRDATA_STRUCT_VERSION_1 (0x0001)
#ifdef PNM_SUPPORT_PARAMETER_SERVER
#warning "usage of Parameter Server is not supported..."
/* Parameter Server */
/* allowed values for field ulStructVersion */
#define PNM_AP_CFG_AR_PRM_PARAMETERSERVER_BLOCK_STRUCT_VERSION_1 (0x0001)
/* FastStartUp */
/* allowed values for field ulFSParamMode */
enum PNM_AP_CFG_AR_PRM_FSPARAM_MODE_Etag
{
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_DISABLE = 1,
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_ENABLE = 2,
};
typedef enum PNM_AP_CFG_AR_PRM_FSPARAM_MODE_Etag PNM_AP_CFG_AR_PRM_FSPARAM_MODE_E;
/* identifier */
typedef enum
{
PNM_AP_CFG_AR_PRM_IDENT_ARVENDORBLOCKREQ = 0,
PNM_AP_CFG_AR_PRM_IDENT_IRDATA = 1,
PNM_AP_CFG_AR_PRM_IDENT_PARAMETERSERVER = 2,
} PNM_AP_CFG_AR_PRM_IDENTIFIER_E;
typedef union
{
PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T tArVendorBlock;
PNM_AP_CFG_AR_PRM_IRDATA_T tIrData;
#ifdef PNM_SUPPORT_PARAMETER_SERVER
PNM_AP_CFG_AR_PRM_PARAMETERSERVER_BLOCK_T tPrmServerBlock;
#endif
} PNM_AP_CFG_AR_PRM_UNION_T;
Packet description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter usDeviceHandle
Reference to the AR for which to configure the AR parameter for
Structure PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T
Variable Type Value / Range Description
ulStructVersion UINT32 1 Structure version of this structure
usArVendorBlockHandle UINT16 1 to 256 Handle to this AR vendor block. This a
configuration wide unique handle. That means
different ARs must use different handles here.
usAPStructureIdentifier UINT16 0 to 0x7FFF, 0x8000 AP Structure Identifier according to GSDML
ulApi UINT32 any API according to GSDML
abData[] UINT8[] Byte array containing the AR VendorBlock data.
Size of this array depends on parameter
tHead.ulLen. Allowed length of array: 0 (no data) -
512
Packet description
Structure PNM_AP_CFG_AR_PRM_CNF_T Type: Confirmation
Note: Please remind that the PROFINET IO Controller firmware assigns the PROFINET
frame id of an IOCR internally. The application cannot choose a particular frame id.
Details on the relationship between IOCR handle and frame id can be found in section
Configuration of PROFINET IO Controller on page 13.
enum PNM_AP_IOCR_HANDLE_Etag
{
/** minimum value for IOCR handle with type Input */
PNM_AP_IOCR_HANDLE_INPUT_FIRST = 0x1000,
/** maximum value for IOCR handle with type Input */
PNM_AP_IOCR_HANDLE_INPUT_LAST = 0x107F,
/* IOCR Type */
typedef enum
{
/* this is an Input CR */
PNM_AP_CFG_IOCR_TYPE_INPUT = 1,
/* this is an Output CR */
PNM_AP_CFG_IOCR_TYPE_OUTPUT = 2,
/* not supported, for future use */
PNM_AP_CFG_IOCR_TYPE_MULTICAST_PROVIDER = 3,
/* not supported, for future use */
PNM_AP_CFG_IOCR_TYPE_MULTICAST_CONSUMER = 4,
/* invalid value */
PNM_AP_CFG_IOCR_TYPE_MAX,
} PNM_AP_CFG_IOCR_TYPE_E;
/* IOCR Properties */
typedef enum
{
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1_LEGACY = 0x01, /* RT_CLASS_1, use legacy FrameIDs
(0xC000-0xF7FF) */
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1 = 0x02, /* RT_CLASS_1, use FrameIDs (0x8000-
0xBBFF) */
PNM_AP_CFG_IOCR_PROP_RT_CLASS_3 = 0x03, /* RT_CLASS_3 (IRT), use FrameIDs
(0x0100-0x06FF) */
PNM_AP_CFG_IOCR_PROP_RT_CLASS_UDP = 0x04, /* not supported, for future use */
} PNM_AP_CFG_IOCR_PROP_E;
/* SendClockFactor */
#define PNM_AP_CFG_IOCR_SEND_CLOCK_DEFAULT (0x0020) /**< default value for
SendClockFactor */
#define PNM_AP_CFG_IOCR_SEND_CLOCK_MIN_RTC1 (0x0008) /**< minimum value allowed
for SendClockFactor for RT_CLASS_1 */
#define PNM_AP_CFG_IOCR_SEND_CLOCK_MIN_RTC3 (0x0008) /**< minimum value allowed
for SendClockFactor for RT_CLASS_3 */
#define PNM_AP_CFG_IOCR_SEND_CLOCK_MAX (0x0080) /**< maximum value allowed
for SendClockFactor */
/* ReductionRatio */
/* the possible values depend on SendClock */
#define PNM_AP_CFG_IOCR_REDUCT_RATIO_MIN (0x0001) /**< minimum value allowed
for ReductionRatio */
#define PNM_AP_CFG_IOCR_REDUCT_RATIO_MAX_RTC1 (0x0200) /**< maximum value allowed
for ReductionRatio for RT_CLASS_1 */
#define PNM_AP_CFG_IOCR_REDUCT_RATIO_MAX_RTC3 (0x0010) /**< maximum value allowed
for ReductionRatio for RT_CLASS_3 */
/* Phase */
/* the possible values depend on SendClock and ReductionRatio */
#define PNM_AP_CFG_IOCR_PHASE_VALUE_MIN (0x0001) /**< minimum value allowed
for Phase */
#define PNM_AP_CFG_IOCR_PHASE_VALUE_MAX (0x4000) /**< maximum value allowed
for Phase */
/* FrameSendOffset */
#define PNM_AP_CFG_IOCR_FRAME_SEND_OFFSET_RTC1 (0xFFFFFFFF) /**< best practice,
default value */
/* DataHold Factor */
#define PNM_AP_CFG_IOCR_DATAHOLD_DEFAULT (0x0003) /**< default value for
datahold factor */
#define PNM_AP_CFG_IOCR_DATAHOLD_MIN (0x0001) /**< minimum value allowed
for datahold factor */
#define PNM_AP_CFG_IOCR_DATAHOLD_MAX (0x1E00) /**< maximum value allowed
for datahold factor */
/** base address for the whole IO data of this IOCR in IO Controllers DPM input/output
area */
uint16_t usDpmOffset;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 42 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x9408 PNM_AP_CMD_CFG_IOCR_REQ
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure PNM_AP_CFG_IOCR_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usIocrHandle PNM_AP_IO 0x1000...0x107F, The handle of the IOCR to configure
CR_HANDLE 0x2000...0x207F
_T
usDeviceHandle PNM_AP_DE Valid device The handle of the AR to associate this IOCR to
VICEHANDL handle
E_T
ulFlags UINT32 0
ulIocrProp UINT32 1…3 Properties of the IOCR
usIocrType UINT16 1…3 Type of the IOCR
abMcastMACAddr[6] UINT8[] 00:00:00:00:00:00 Multicast MAC Address to be used for this IOCR.
Reserved for future usage. Set to zero for compatibility.
usDataLen UINT16 1… 1440 Length of the data part of the IOCR without Frame
(% 4 == 0) Header and APDU Status (C_SDU Length). Must be a
multiple of 4.
usSendClockFact UINT16 8 … 128 Send Clock Factor to use for this IOCR. Only values with
power of 2 are allowed.
usReductRatio UINT16 1 … 512 Reduction Ratio for this IOCR. Only values with power of
2 are allowed.
usPhase UINT16 1 … 512 Phase for this IOCR. Must be smaller or equal
usReductionRatio
usSequence UINT16 0 Currently unused. Set to zero for future compatibility
usDataHoldFact UINT16 1 … 7680 Data Hold Factor for this IOCR
ulFrameSendOffs UINT32 0 … 3999999 Frame send offset for RTC Class 3 IOCRs. Set to zero
for non RTC Class 3 IOCRs
usDpmOffset UINT16 0 … 5700 Start address for IOCR data in DPM Input or Output
(% 4 == 0) Area. Must be 4-byte aligned.
Parameter descriptions
Parameter ulStructVersion
Structure version of this structure. Used for future extensions of this structure.
Parameter usIocrHandle
The parameter usIocrHandle is a reference to the IOCR object to be configured. The following
values are defined
Minimum value Maximum value Usage
0x1000 0x103F Input IOCR for RT Class 1 / RT Class 3
0x1040 0x107F Input IOCR for RT Class 1
0x2000 0x203F Output IOCR for RT Class 1 / RT Class 3
0x2040 0x207F Output IOCR for RT Class 1
The PROFINET IO Controller will internally generate the frame id of the Input IOCRs and RT Class
3 Output IOCRs based on the frame id value. For details see section Configuration of PROFINET
IO Controller on page 13.
Parameter ulIocrProp
The IOCR properties parameter ulIocrProp is a bit field describing the IOCR in more detail. The
following values are currently defined
Symbolic name Numeric value Usage
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1_LEGACY 0x01 RT_CLASS_1
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1 0x02 RT_CLASS_1
PNM_AP_CFG_IOCR_PROP_RT_CLASS_3 0x03 RT_CLASS_3 (IRT)
Parameter usIocrType
This parameter determines the type of the IOCR. Due to the internal firmware structure the type is
determined by the IOCR's handle value.
Symbolic name Numeric value Usage
PNM_AP_CFG_IOCR_TYPE_INPUT 1 For Input IOCR with 0x1000 <= usIocrHandle <= 0x107F
PNM_AP_CFG_IOCR_TYPE_OUTPUT 2 For Output IOCR with 0x2000 <= usIocrHandle <= 0x207F
Parameter abMcastMacAddr
This parameter is reserved for future usage. Set to zero.
Parameter usDataLen
The length of data part of the IOCR is defined by this parameter. It determines how many byte the
PROFINET IO Controller firmware will copy to / from the DPM Input / Output Area for this IOCR.
Internally, the data exchange is restricted to 4 byte- aligned operations, thus the parameter
usDataLen must be a multiple of 4.
The PROFINET IO Controller will internally pad the IOCR data block (CSDU) to the minimum size
of 40 byte if a value smaller than 40 byte is specified. This does not affect the used memory space
in DPM area. E.g. if a usDataLen = 20 byte is specified, a block of 20 byte will be used in DPM and
the IOCR C_SDU length will be 40.
Parameter usSequence
Currently not used. Set to zero for future compatibility.
Parameter usDataHoldFact
This parameter defines the timeout for the IOCR watchdog. If no IOCR data could be exchanged
for usDataHoldFact Data Cycle repetitions, the AR will be aborted with an timeout error. The Data
Hold Timeout time can be calculated as follows:
Data Hold Timeout =
(usDataHoldFact + 1) * usReductRatio * usSendclockFact * 31.25 [microseconds]
The maximum allowed value for the Data Hold Timeout is 1,92 seconds.
It is strongly recommended to set this timeout to a value greater or equal than 3. Lower values
might cause problems with occasional network transmission failures due to external
electromagnetic noise.
Parameter ulFrameSendOffs
This parameter defines the send offset of the IOCR frame in respect to send clock cycle start. It is
used in RT Class 3 mode. The parameter must match the corresponding value in the IR Data Sets
of the associated device. In RT Class 1 mode set this parameter to 0.
Parameter usDpmOffset
This parameter defines where the PROFINET IO Controller will take the data for an Output IOCR
from the DPM Output Area or to put the data of an Input IOCR into the DPM Input Area. The value
must be 4-byte aligned due to the internal implementation oft the PROFINET IO Controller. The
following image shows the relationships between the parameter usDPMOffset, usDataLen and the
DPM Area. The sum of usDPMOffset and usDataLen shall not exceed the length of DPM Area
(5700 byte for Ouput Image, 5652 byte for Input Image).
Packet description
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 42 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x940A PNM_AP_CMD_CFG_SUBMODULE_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_IOC_DATA_T
ulStructVersion UINT32 1 Structure version used for further extensions to this
packet.
usSubmoduleHandle PNM_AP_SU 1...2048 Submodule Handle
BMODULE_
HANDLE_T
usDeviceHandle PNM_AP_DE 1...128 AR this submodule is associated to
VICEHANDL
E_T
usIocrInputHandle PNM_AP_IO 0x1000 to 0x107F Input IOCR associated with this submodule
CR_HANDLE
_T
usIocrOutputHandle PNM_AP_IO 0x2000 to 0x207F Output IOCR associated with this submodule
CR_HANDLE
_T
ulModuleIdentNumber UINT32 any Module identifier according to GSDML
ulSubmoduleIdentNumber UINT32 any Submodule identifier according to GSDML
ulApi UINT32 Submodule API according GSDML
usSlot UINT16 Submodule slot according device configuration
usSubslot UINT16 Submodule subslot according device configuration
usSubmoduleProperties UINT16 Properties of the Submodule
usDataLenInput UINT16 0...1439 Length of the input data this submodule provides
according to GSDML
usDataLenOutput UINT16 0...1439 Length of the output data this submodule consumes
according to GSDML
usFrameOffsetInput UINT16 0...1439 Offset within the Input IOCR where the input process
data and provider status shall be placed
usFrameOffsetOutput UINT16 0...1439 Offset within the Output IOCR where the output
process data and provider status shall be placed
usIOCSFrameOffsetInput UINT16 0...1439 Offset within the Input IOCR where the output
consumer status shall be placed
usIOCSFrameOffsetOutput UINT16 0...1439 Offset within the Output IOCR where the input
consumer status shall be placed
Parameter ulStructVersion
Version of this configuration structure. Used for future extensions.
Parameter usSubmoduleHandle
The usSubmoduleHandle can be freely chosen from the user within the allowed range. It is a
globally unique handle associated with a submodule. Each submodule within the whole
configuration must be assigned an unique handle. This handle will be used in other services to
reference to the submodule. (E.g. Record Object Read/Write)
Parameter usDeviceHandle
The submodule will be associated with the AR referenced by usDeviceHandle. This is used
when establishing the connection with a PROFINET IO Device in order to verify the configuration
of this particular device.
Note: The Module ID of Submodules with same ulApi and ulSlot must be identical.
Parameter usSubmoduleProperties
The usSubmoduleProperties is a bit field describing various properties of the submodule. The
following flags are defined
Flag Numeric Usage
value
PNM_AP_CFG_SUBMODULE_PROPERTIES_INPUT 0x0001 Must be set if usDataLenInput > 0 or
usDataLenOutput == 0
PNM_AP_CFG_SUBMODULE_PROPERTIES_OUTPUT 0x0002 Must be set if usDataLenOutput > 0
Packet description
Note: The record parameters are internally stored within a storage associated with the AR.
The storage has a limited size. Please refer to section Technical data on page 5 for
details on the available memory amount for startup record object parameterization.
Additionally to the record data, each parameter consumes some byte for management
information. Details are described in PNM_AP_CFG_RECORD_REQ_T request (page
71).
union PNM_AP_CFG_RECORD_UNION_DATA_Ttag
{
PNM_AP_CFG_RECORD_DATA_T tRecord;
PNM_AP_CFG_PARAMETER_T tParam;
};
PNM_AP_CFG_RECORD_UNION_DATA_T uData;
};
Packet description
Structure PNM_AP_CFG_RECORD_UNION_DATA_T
tRecord PNM_AP_CFG_RECORD_DATA_T Used for specifying the manufacturers specific record
data
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions to this structure.
Parameter usSubmoduleHandle
This parameter specifies the submodule the record data is associated with
Packet description
/** @note the following rules shall apply if this Info contains topology information
about IO-Controller local Ports:
* - Device Handle shall be set to 0
* - Submodule handle shall be set to 0xFFF1 for Port 1 and to 0xFFF2 for Port 2
* */
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 12 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x940E PNM_AP_CMD_CFG_TOPO_REQ
ulExt UINT32 0 -
ulRoute UINT32 any -
Structure PNM_AP_CFG_IOC_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usDeviceHandle1 PNM_AP_DEVIC 0, 1 … 128 Handle to Device on this side of link
EHANDLE_T
usSubmoduleHandle1 PNM_AP_SUBM 1 … 2048, Handle to submodule on this side of link
ODULE_HANDL 0xFFF1, 0xFFF2
E_T
usDeviceHandle2 PNM_AP_DEVIC 0, 1 … 128 Handle to Device on the other side of link
EHANDLE_T
usSubmoduleHandle2 PNM_AP_SUBM 1 … 2048, Handle to submodule on the other side of link
ODULE_HANDL 0xFFF1, 0xFFF2
E_T
Parameter descriptions
Parameter ulStructVersion
Version of this structure.
Packet description
Packet description
Packet description
Parameter descriptions
Note: This service must be used after the Download finished service and before switching the
controller to Bus On. This implies that the PROFINET IO Controller must be configured
for application controlled startup in Configure IO Controller service.
In case of database configuration, this service shall be used after the channel has been
initialized.
struct PNM_AP_LOAD_REMANENT_REQ_DATA_Ttag
{
uint16_t usLength;
uint8_t abData[];
};
struct PNM_AP_LOAD_REMANENT_REQ_Ttag
{
PNM_AP_PCK_HEADER_T tHead;
PNM_AP_LOAD_REMANENT_REQ_DATA_T tData;
};
Packet description
Parameter usLength
The length of the remanent data to be restored. This field should use the same value as received
in Store Remanent service.
Parameter abData[]
The remanent data to be restored.
Packet description
Structure reference
#define PNM_AP_CFG_RECORD_STRUCT_VERSION_1 (0x0001)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure.
Parameter usIndex
The record object index of the record object to write. This parameter is provided in the GSDML file.
Parameter usTransferSequence
This parameter can be used to configure the order in which the record object shall be written. This
value is provided in the GSDML file of the PROFINET IO Device. The default value is zero.
Parameter abRecordData[]
This parameter contains the payload (the actual record data to be written). The length of the data is
determined from the packet length.
Structure reference
enum PNM_AP_CFG_PRM_PORT_MAUTYPE_Etag
{
PNM_AP_CFG_IOC_PRM_PORT_MAUTYPE_PORT_DISABLED = 0,
PNM_AP_CFG_IOC_PRM_PORT_MAUTYPE_100BASETX = 16,
};
typedef enum PNM_AP_CFG_PRM_PORT_MAUTYPE_Etag PNM_AP_CFG_PRM_PORT_MAUTYPE_E;
typedef enum
{
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_PEER_ID = 0x0001,
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_LINEDELAY = 0x0002,
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_MAUTYPE = 0x0004,
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_LINKSTATE = 0x0008,
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_SYNCMODE = 0x0010,
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAG_MAUTYPEMODE = 0x0020,
} PNM_AP_CFG_PRM_PDPORTDATA_CHECK_ENABLE_FLAGS;
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure.
Parameter ulEnableFlag
This bitmask which of the following settings should be applied to the device. The following bits are
defined
Name Numerical Usage
Value
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0001 Validate the remote peers station name and port. Associated
CHECK_ENABLE_FLAG_PEER_ID parameter abPeerId.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0002 Validate the measured line delay against reference value
CHECK_ENABLE_FLAG_LINEDELAY given by parameter ulLineDelay.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0004 Validate the MAU type against the reference value given by
CHECK_ENABLE_FLAG_MAUTYPE parameter usMauType.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0008 Check if the port detected a network link
CHECK_ENABLE_FLAG_LINKSTATE
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0010 Check if the remote peer is using the synchronization mode
CHECK_ENABLE_FLAG_SYNCMODE given by parameter usSyncMode.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0020 Validate the MAU type of this port against the MAU type
CHECK_ENABLE_FLAG_MAUTYPEMODE reported by the remote port
Parameters abPeerId[255]
The expected peer port alias name of this port. The value is specified using the standard
PROFINET alias name specification. E.g. if the port shall verify that it is connected to Port 1 of a
device with a name of station "mydevice" the value of this parameter should be set to "port-
001.mydevice"
Parameter ulLineDelay
The maximum line delay allowed on this port in nanoseconds.
Parameter usMauType
The expected MAU type of this port.
Name Numerical Meaning
Value
PNM_AP_CFG_IOC_PRM_PORT_ 16 Expect a 100 MBit Full Duplex on this port.
MAUTYPE_100BASETX
Parameter usSyncMode
This parameter is a bitmask activating peer checks related to synchronization
Name Numerical Meaning
Value
- 0x0001 Validate measured line delay of peer port against our measurement (Maximum deviation 50
ns)
- 0x0002 Validate peer's sync masters source mac address against our sync master's source mac
address
Structure reference
typedef enum
{
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_DOMAIN_BOUNDARY = 0x0001,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_MULTICAST_BOUNDARY = 0x0002,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_PEERTOPEER_BOUNDARY = 0x0004,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_DCP_BOUNDARY = 0x0008,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_MAUTYPE = 0x0010,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_LINKSTATE = 0x0020,
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAG_PREAMBLELENGTH = 0x0040,
} PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_ENABLE_FLAGS;
typedef enum
{
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_PASS = 0x0000,
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_LLDP = 0x0001,
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_PTCP_DELAY = 0x0002,
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_PTCP_PATH = 0x0004,
} PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_E;
typedef enum
{
PNM_AP_CFG_PRM_DCP_BOUNDARY_PASS = 0x0000,
PNM_AP_CFG_PRM_DCP_BOUNDARY_BLOCK_IDENTIFY = 0x0001,
PNM_AP_CFG_PRM_DCP_BOUNDARY_BLOCK_HELLO = 0x0002,
} PNM_AP_CFG_PRM_DCP_BOUNDARY_E;
enum PNM_AP_CFG_PRM_PORT_MAUTYPE_Etag
{
PNM_AP_CFG_IOC_PRM_PORT_MAUTYPE_PORT_DISABLED = 0,
PNM_AP_CFG_IOC_PRM_PORT_MAUTYPE_100BASETX = 16,
};
typedef enum PNM_AP_CFG_PRM_PORT_MAUTYPE_Etag PNM_AP_CFG_PRM_PORT_MAUTYPE_E;
enum PNM_AP_CFG_PRM_PORT_PREAMBLE_LENGTH_Etag
{
PNM_AP_CFG_IOC_PRM_PORT_PREAMBLE_LENGTH_7_OCTETS = 7,
PNM_AP_CFG_IOC_PRM_PORT_PREAMBLE_LENGTH_1_OCTET = 1,
};
typedef enum PNM_AP_CFG_PRM_PORT_PREAMBLE_LENGTH_Etag
PNM_AP_CFG_PRM_PORT_PREAMBLE_LENGTH_E;
Structure description
Structure PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_T
ulStructVersion UINT32 1 Structure version of this structure
ulEnableFlag UINT32 Bitmask of Adjustments to active
ulDomainBoundaryIngress UINT32 0, 1 Defines If the port should block incoming PTCP
sync frames
ulDomainBoundaryEgress UINT32 0, 1 Defines If the port should block outgoing PTCP
sync frames
ulMulticastBoundary UINT32 Bitmask defining which multicast frames shall be
blocked by this port
ulPeerToPeerBoundary UINT32 0…7 Bitmask defining which peer to peer multicast
frames shall be blocked by this port
ulDCPBoundary UINT32 0…3 Bitmask defining which DCP Frames should be
blocked by this port
usMauType UINT16 MAU Type to force on this port, supported values
see GSDML of IO Device
if used to configure IO Controller only value 16
is supported
usLinkState UINT16 2 Link State to force on this port.
usPreambleLength UINT16 7 Ethernet Preamble Length
Parameter descriptions
Parameter ulStructVersion
Version of this structure.
Parameter ulEnableFlag
This bitmask which of the following settings should be applied to the device.
Name Numerical Usage
Value
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0001 Configure Domain Boundary specified by parameters
ADJUST_ENABLE_FLAG_ ulDomainBoundaryIngress and ulDomainBoundaryEgress for this
DOMAIN_BOUNDARY port.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0002 Configure Multicast Boundary specified by ulMulticastBoundary
ADJUST_ENABLE_FLAG_ for this port.
MULTICAST_BOUNDARY
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0004 Configure PeerToPeer Boundary specified by parameter
ADJUST_ENABLE_FLAG_ ulPeerToPeerBoundary for this port
PEERTOPEER_BOUNDARY
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0008 Configure DCP Boundary specified by parameter ulDCPBoundary
ADJUST_ENABLE_FLAG_ for this port.
DCP_BOUNDARY
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0010 Configure MAU Type specified by parameter usMauType for this
ADJUST_ENABLE_FLAG_MAUTYPE port.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0020 Configure Link State as specified by parameter usLinkState for
ADJUST_ENABLE_FLAG_LINKSTATE this port.
PNM_AP_CFG_PRM_PDPORTDATA_ 0x0040 Configure the Ethernet frame preamble length as specified by
ADJUST_ENABLE_FLAG_ parameter usPreambleLength.
PREAMBLELENGTH
Parameter ulMulticastBoundary
This parameter configures a frame filter for the port. The value is interpreted as an bitmask where
each bit 0 to 31 represents one multicast MAC address from the range 01:0E:CF:00:02:00 to
01:0E:CF:00:02:1F. The port will block any outgoing frame with the destination MAC equal to the
MAC address associated with the corresponding bit if the bit is set.
Parameter ulPeerToPeerBoundary
This parameter configures a frame filter for Peer To Peer Multicast frames. The value is interpreted
as a bitmask where each bit corresponds to a multicast MAC address. The port will block outgoing
frames if the corresponding bit is set. The following values are defined.
Name Numerical Usage
Value
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_LLDP 0x00000001 Block LLDP Frames
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_PTCP_DELAY 0x00000002 Block PTCP Delay Frames
PNM_AP_CFG_PRM_PEER_TO_PEER_BOUNDARY_BLOCK_PTCP_PATH 0x00000003 Block PATH Delay Frames
Parameter ulDCPBoundary
This parameter configures a frame filter for DCP frames. The value is interpreted as a bitmask
where each bit corresponds to a DCP Multicast MAC address. The port will block outgoing frames
if the corresponding bit is set. The following values are defined.
Name Numerical Usage
Value
PNM_AP_CFG_PRM_DCP_BOUNDARY_BLOCK_IDENTIFY 0x0001 Block DCP Identify with Mac Address
01:0E:CF:00:00:00
PNM_AP_CFG_PRM_DCP_BOUNDARY_BLOCK_HELLO 0x0002 Block DCP Hello with Mac Address
01:0E:CF:00:00:01
In order to disable the port, set usLinkState to the value 2. The following values are allowed for the
MAU type and Link State.
usMauType usLinkState
Name Numerical Name Numerical Value Meaning
Value
PNM_AP_CFG_IOC_PRM_PORT_ 16 - - Use 100 MBit Full Duplex
MAUTYPE_100BASETX on this port.
- - - 2 Disable the Port
Parameter usPreambleLength
This parameter can be used to configure the Ethernet frame preamble length. The default value is
7.
Structure reference
#define PNM_AP_CFG_PRM_MAX_PORTS (4)
enum PNM_AP_CFG_FRAME_DATA_PROP_Etag
{
PNM_AP_CFG_FRAME_PROP_FORWARDING_MODE_ABSOLUTE = 0x00000000,
PNM_AP_CFG_FRAME_PROP_FORWARDING_MODE_RELATIVE = 0x00000001,
PNM_AP_CFG_FRAME_PROP_FAST_FORWARDING_LEGACY = 0x00000000,
PNM_AP_CFG_FRAME_PROP_FAST_FORWARDING_RTC3_MCAST = 0x00000002,
PNM_AP_CFG_FRAME_PROP_FAST_FORWARDING_MCAST = 0x00000004,
};
typedef enum PNM_AP_CFG_FRAME_DATA_PROP_Etag PNM_AP_CFG_FRAME_DATA_PROP_E;
Structure description
Structure PNM_AP_CFG_PRM_IRDATA_GLOBAL_T
ulStructVersion UINT32 1, 2 Structure version of this structure
tIRDataUuid UUID UUID of the IRT Parameter set
ulMaxBridgeDelay UINT32 Maximum Bridge Delay
usStartOfRedFrameId UINT16 0x0100 to 0x013F The first frame id used for IRT
usEndOfRedFrameId UINT16 0x0200 to 0x023F The last frame id used for IRT
usNumFrames UINT16 1 … 128 Number of Frames in IR Data set
bNumPorts UINT8 Number of ports of the device as specified in
GSDML
bNumPhases UINT8 1 … 16 Number of IRT Phases
ulFrameDataProperties UINT32 0…7 Common IRT Frame Properties
atPorts[] Array of Port Description structures (one for each
port)
Structure PNM_AP_CFG_PRM_IRDATA_PORT_T
ulMaxPortTxDelay UINT32 Maximum Port TX Delay as specified in GSDML
ulMaxPortRxDelay UINT32 Maximum Port RX Delay as specified in GSDML
ulMaxLineRxDelay UINT32 Maximum Line RX Delay
ulYellowTime UINT32 125000 Length of Yellow Interval
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used to specify the encoding of the PD IR Data Record. The following
values are defined:
Name Numerical Meaning
Value
PNM_AP_CFG_IOC_PRM_IRDATA_ 0x0001 To be used when the parameter is associated with the
GLOBAL_STRUCT_VERSION_1 PROFINET Controller Firmware itself
PNM_AP_CFG_IOD_PRM_IRDATA_ 0x0001 To be used when the parameter is associated with a PROFINET
GLOBAL_STRUCT_VERSION_1 Specification 2.2 Device
PNM_AP_CFG_IOD_PRM_IRDATA_ 0x0002 To be used when the parameter is associated with a PROFINET
GLOBAL_STRUCT_VERSION_2 Specification 2.3 Device
Parameter tIRDataUuid
This parameter defines the UUID associated with the IRT domain. All devices of an IRT domain
have are parameterized with the same UUID.
Parameter ulMaxBridgeDelay
The maximum bridge delay of the IRT Switch. This value shall be derived from the PROFINET
Device's GSDML file. An additional delay auf 100 ns must be added to the GSDML value for
"Relative Forwarding Mode".
Parameter usNumFrames
This parameter defines the number of frames configured for the associated IRT switch.
Parameter bNumPorts
This parameter configures the number of ports of the associated IRT switch.
Parameter bNumPhases
This parameter specifies the number of phases used in the IRT domain. A maximum of 16 phases
is supported.
Parameter ulFrameDataProperties
This parameter is a bitmask defining additional properties of IR frame set configuration
Name Numerical Meaning
Value
Structure reference
enum PNM_AP_CFG_FRAME_DETAILS_Etag
{
PNM_AP_CFG_FRAME_NO_SYSNC_FRAME = 0x00,
PNM_AP_CFG_FRAME_PRIMARY_SYNC_FRAME = 0x01,
PNM_AP_CFG_FRAME_SECONDARY_SYNC_FRAME = 0x02,
};
typedef enum PNM_AP_CFG_FRAME_DETAILS_Etag PNM_AP_CFG_FRAME_DETAILS_E;
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter usEntryId
A reference to the frame within the PD IR Data Set. Each frame of a PD IR Data set must be
associated an unique entry id. The value must be smaller than usNumFrames parameter from
PNM_AP_CFG_PRM_IRDATA_GLOBAL_T structure on page 90. This value is used internally in
the PROFINET Controller Firmware to organize the PD IR Data set.
Parameter usCSDULength
The length of the frames C_SDU part. That is the length of the cyclically exchanged process data
and states padded to at least 40 byte.
Parameter bFrameDetails
This parameter provides additional information about the frame. It is a bitmask defined as follows:
Name Numerical Meaning
Value
Bits 0 to 1 - Syncframe
PNM_AP_CFG_FRAME_NO_SYSNC_FRAME 0x00 Frame is no PTCP Sync Frame
PNM_AP_CFG_FRAME_PRIMARY_SYNC_FRAME 0x01 Frame is a primary Sync Frame
PNM_AP_CFG_FRAME_SECONDARY_SYNC_FRAME 0x02 Frame is a secondary Sync Frame
Structure reference
#define PNM_AP_CFG_PRM_MAX_BEGIN_END_ASSIGNMENTS (16)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter atBeginEnd[]
This parameter contains an array of phase descriptions for one port. The array must contain
bNumPhases entries. (See PNM_AP_CFG_PRM_IRDATA_GLOBAL_T structure on page 90)
Structure reference
#define PNM_AP_CFG_IOC_PRM_SYNC_STRUCT_VERSION_1 (0x0001)
#define PNM_AP_CFG_IOD_PRM_PDSYNCDATA_VERSION_1 (0x0001)
enum PNM_AP_CFG_PRM_SYNC_SYNCPROP_FLAGS_Etag
{
PNM_AP_CFG_PRM_SYNC_SYNCPROP_ROLE_SLAVE = 0x00000001,
PNM_AP_CFG_PRM_SYNC_SYNCPROP_ROLE_MASTER = 0x00000002,
};
typedef enum PNM_AP_CFG_PRM_SYNC_SYNCPROP_FLAGS_Etag
PNM_AP_CFG_PRM_SYNC_SYNCPROP_FLAGS_E;
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter tSyncDomainUuid
This parameter defines the UUID associated with the synchronization domain. All devices in one
domain must be parameterized with the same synchronization domain.
Parameter usSyncProperties
This parameter is a bitmask defining the synchronization properties of the associated device. The
following values are defined:
Name Numerical Meaning
Value
PNM_AP_CFG_PRM_SYNC_SYNCPROP_ROLE_SLAVE 0x0001 The associated device is configured as
synchronization slave. To be used for a
PROFINET Device.
PNM_AP_CFG_PRM_SYNC_SYNCPROP_ROLE_MASTER 0x0002 The associated device is configured as
synchronization master. To be used for the
PROFINET Controller
Parameter usSendClockFactor
This parameter defines the Base Clock of the Synchronization Domain. This is the length of a
single IRT phase and thus defines the minimum cycle time for process data exchange. The value
is encoded in units of 31.25 µs. (1ms corresponds to a factor of 32)
Parameter ulPllWindow
This parameter defines the maximum allowed deviation of a synchronization slave's local PLL from
the synchronization master. If the deviation exceeds the window the synchronization will be
regarded as lost and restarted. The value is encoded in units of 1ns. The proper value is described
within the GSDML of a PROFINET Device. The value has no meaning for a Synchronization
Master.
Parameter ulSyncSendFactor
This parameter parameterizes the frequency of the synchronization frames exchanged on the bus.
The time base for this parameter is the length of one phase configured by usSendClockFactor The
synchronization master will issue a synchronization frame every ulSyncSendFactor phases
while the synchronization slave expects a synchronization frame every ulSyncSendFactor
phases. The default value for this parameter is 30.
Parameter usPtcpTimeoutFactor
This parameter defines the synchronization timeout. A synchronization slave will regard the
synchronization master as lost if no synchronization frame has been received within the specified
interval. The time base of this parameter is defined by ulSyncSendFactor. The default value is
6.
Parameter usPtcpTakeoverTimeoutFactor
This parameter defines the synchronization takeover timeout. If the device does not receive a
synchronization frame within the specified time, the synchronization slave tries to switch to another
synchronization master of the same domain and a secondary synchronization master tries to
become the primary synchronization master. The time base if this parameter is defined by
ulSyncSendFactor. The default value is 3 for a synchronization master and 2 for a
synchronization slave.
Parameter bPtcpMasterPrio1
This parameter is a bitmask used for the Best Master Clock Algorithm. The following values are
defined:
Name Numerical Meaning
Value
Bit 0 to 2 - Priority 0x00 To be used for a synchronization slave
0x01 The device is the primary synchronization master
0x02 The device is a secondary synchronization master
Bit 3 to 5 - Level 0x00 Level 0 (highest priority)
0x08 Level 1
0x10 Level 2
0x18 Level 3
0x20 Level 4
0x28 Level 5
0x30 Level 6
0x38 Level 7 (lowest priority)
The default value is 0x00 for a synchronization slave and 0x01 for the synchronization master.
Parameter bPtcpMasterPrio2
The parameter is used for the Best Master Clock algorithm. Only the value 0xFF shall be used.
Parameter abSubdomainName[]
This parameter defines a human readable identifier of the synchronization domain.
Structure reference
#define PNM_AP_CFG_PRM_MRP_INSTANCE_DATA_VERSION_1 (0x0001)
typedef enum
{
PNM_AP_CFG_PRM_MRP_CHECK_OFF = 0,
PNM_AP_CFG_PRM_MRP_CHECK_MANGER_ON = 1,
PNM_AP_CFG_PRM_MRP_CHECK_UUID_ON = 2,
PNM_AP_CFG_PRM_MRP_CHECK_MAX = 4,
} PNM_AP_CFG_PRM_MRP_CHECK_FLAGS_E;
struct PNM_AP_CFG_PRM_PDINTFMRPDATACHECK_Ttag
{
uint32_t ulStructVersion;
PNM_AP_CFG_PRM_MRP_INSTANCE_DATACHECK_T atCheck[ARRAYS_OF_LENGTH_ZERO];
};
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. This field is used for future extensions. In case of
PNM_AP_CFG_PRM_PDINTFMRPDATACHECK_T the structure version specifies the encoding
to use when writing the associated record data object:
Name Numerical Usage
Value
PNM_AP_CFG_PRM_PDINFMRPDATACHECK_VERSION_1 1 Use encoding according PROFINET
Specification V2.2. Only one MRP Instance
per device is possible (field bMRP_Instance
is ignored)
PNM_AP_CFG_PRM_PDINFMRPDATACHECK_VERSION_2 2 Use encoding according PROFINET
Specification V2.31. Multiple MRP Instances
can be defined (depends on capabilities of
device).
Parameter bMRP_Instance
A reference to the MRP instance. Only relevant for Multiple Interface Devices. Default value is
Zero.
Parameter ulMRP_Check
A bitmask that defines which parameters should be checked. The following values are defined
Name Numerical Usage
Value
PNM_AP_CFG_PRM_MRP_CHECK_MANGER_ON 0x00000001 Enable MRP Manager Diagnosis
PNM_AP_CFG_PRM_MRP_CHECK_UUID_ON 0x00000002 Enable Validation of Peer MRP Domain UUID
Parameter tMRP_DomainUUID
This parameter defines the domain uuid to check against if enabled by parameter ulMRP_Check.
Structure reference
#define PNM_AP_CFG_MRP_TOPO_CHANGE_IN TERVAL_MAX (100)
typedef union
{
PNM_AP_CFG_MRP_MANAGER_PARAMS_T tManager;
PNM_AP_CFG_MRP_CLIENT_PARAMS_T tClient;
} PNM_AP_CFG_MRP_PARAMS_T;
enum PNM_AP_CFG_MRP_ROLE_Etag
{
PNM_AP_CFG_MRP_ROLE_DISABLE = 0,
PNM_AP_CFG_MRP_ROLE_CLIENT = 1,
PNM_AP_CFG_MRP_ROLE_MANAGER = 2,
};
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. This field is used for future extensions. In case of
PNM_AP_CFG_PRM_PDINTFMRPDATAADJUST_T the structure version specifies the encoding to
use when writing the associated record data object:
Name Numerical Usage
Value
PNM_AP_CFG_PRM_PDINFMRPDATAADJUST_ 1 Use encoding according PROFINET
VERSION_1 Specification V2.2. Only one MRP Instance per
device is possible (field bMRP_Instance is
ignored)
PNM_AP_CFG_PRM_PDINFMRPDATAADJUST_ 2 Use encoding according PROFINET
VERSION_2 Specification V2.31. Multiple MRP Instances can
be defined. (Depends on capabilities of device)
Parameter bMRP_Instance
A reference to the MRP instance. Only relevant for Multiple Interface Devices. Default value is
zero.
Parameter usMrpRole
The role of the device within the MRP ring. The following values are defined
Name Numerical Usage
Value
PNM_AP_CFG_MRP_ROLE_DISABLE 0x00000000 MRP Disabled for this device
PNM_AP_CFG_MRP_ROLE_CLIENT 0x00000001 Device shall operate as MRP Client.
uParam.tClient contains the related parameters
PNM_AP_CFG_MRP_ROLE_MANAGER 0x00000002 Device shall operate as MRP Manager.
uParam.tManager contains the related
parameters
Parameter abMrpDomainName[240]
The domain name of the MRP domain. Must be a name with minimum length 1 according
PROFINET Name Of Station syntax. Even if MRP is disabled a valid name must be specified.
Structure reference
#define PNM_AP_CFG_PRM_PDPORTMRPDATAADJUST_VERSION_1 (0x0001)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter tMRP_DomainUUID
This parameter defines the UUID associated with a particular MRP domain. All Ports in one MRP
Domain must be configured with the same UUID.
Structure reference
#define PNM_AP_CFG_PRM_PDPORTFIBEROPTICDATACHECK_VERSION_1 (0x0001)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameters ulMaintenanceRequiredPowerBudget,
ulMaintenanceDemandedPowerBudget and ulErrorPowerBudget
These parameters define the minimum power budget of the transmitter (the power reserve of the
transmitter) for a maintenance required, demanded or error diagnosis entry shall be generated. If
the power budget falls below the corresponding value a diagnosis entry will be generated by the
device. The bit 0 to 30 of the value express the power budget in 0.1 db steps from 0 to 99,9. Bit 31
is a flag which enables the particular check.
Structure reference
typedef enum
{
PNM_AP_CFG_FIBEROPTIC_CABLE_UNKNOWN = 0,
PNM_AP_CFG_FIBEROPTIC_CABLE_FIXED_INSTALLATION = 1,
PNM_AP_CFG_FIBEROPTIC_CABLE_FLIXIBLE_INSTALLATION = 2,
PNM_AP_CFG_FIBEROPTIC_CABLE_OUTDOOR_FIXED_INSTALLATION = 3,
} PNM_AP_CFG_FIBEROPTIC_CABLE_TYPE_E;
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Numerical Meaning
value
0 Not Adjusted
1 9 µm single mode
2 50 µm multi mode
3 62,5 µm multi mode
4 SI-POF, NA = 0.5
5 SI-PCF, NA = 0.36
6 LowNA-POF, NA = 0.3
7 GI-POF
8 GI-PCF
0x80 to 0xFF Vendor specific
Table 12: Known values for fiber optic type
Structure reference
typedef enum
{
PNM_AP_CFG_PRM_NC_DROP_BUDGET_CHECK_VALID_FLAG_MAINTENANCE_REQUIRED = 0x00000001,
PNM_AP_CFG_PRM_NC_DROP_BUDGET_CHECK_VALID_FLAG_MAINTENANCE_DEMANDED = 0x00000002,
PNM_AP_CFG_PRM_NC_DROP_BUDGET_CHECK_VALID_FLAG_ERROR = 0x00000004,
} PNM_AP_CFG_PRM_NC_DROP_BUDGET_VALID_FLAGS;
Structure description
Structure PNM_AP_CFG_PRM_PDNCDATACHECK_T
ulStructVersion UINT32 1 Structure version of this structure
ulEnableFlag UINT32 0…7 Bitmask specifying which checks to enable
ulMaintenanceRequired UINT32 1 … 999 Maximum number of frames dropped within 1 second
DropBudget until a Maintenance Required shall be generated
ulMaintenanceDemanded UINT32 1 … 999 Maximum number of frames dropped within 1 second
DropBudget until a Maintenance Demanded shall be generated
ulErrorDropBudget UINT32 1 … 999 Maximum number of frames dropped within 1 second
until a Diagnosis shall be generated
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter ulEnableFlag
This bitmask defines which of the following Ethernet frame drop limits are active and will generate
a diagnosis.
Name Numerical Meaning
value
PNM_AP_CFG_PRM_NC_DROP_BUDGET_ 0x00000001 Enable Maintenance Required Limit
CHECK_VALID_FLAG_MAINTENANCE_REQUIRED
PNM_AP_CFG_PRM_NC_DROP_BUDGET_ 0x00000002 Enable Maintenance Demanded Limit
CHECK_VALID_FLAG_MAINTENANCE_DEMANDED
PNM_AP_CFG_PRM_NC_DROP_BUDGET_ 0x00000004 Enable Diagnosis (Error) Limit
CHECK_VALID_FLAG_ERROR
Structure reference
#define PNM_AP_CFG_PRM_PDINTFDATAADJUST_VERSION_1 (0x0001)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter ulMultipleInterfaceMpde
This parameter shall be set to "1" to enable LLDP Multiple Interface Mode according PROFINET
Specification V2.31 or to "0" to use standard LLDP Mode as defined in PROFINET specification
V2.2.
Structure reference
enum PNM_AP_FS_HELLO_MODE_Etag
{
PNM_AP_FS_HELLO_MODE_OFF = 0,
PNM_AP_FS_HELLO_MODE_LINKUP = 1,
PNM_AP_FS_HELLO_MODE_LINKUP_DELAY = 2,
};
enum PNM_AP_FS_HELLO_INTERVAL_Ttag
{
PNM_AP_FS_HELLO_INTERVAL_30MS = 30,
PNM_AP_FS_HELLO_INTERVAL_50MS = 50,
PNM_AP_FS_HELLO_INTERVAL_100MS = 100,
PNM_AP_FS_HELLO_INTERVAL_300MS = 300,
PNM_AP_FS_HELLO_INTERVAL_500MS = 500,
PNM_AP_FS_HELLO_INTERVAL_1000MS = 1000,
};
enum PNM_AP_FS_HELLO_RETRY_Ttag
{
PNM_AP_FS_HELLO_RETRY_MIN = 1,
PNM_AP_FS_HELLO_RETRY_MAX = 15,
};
enum PNM_AP_FS_HELLO_DELAY_Ttag
{
PNM_AP_FS_HELLO_DELAY_OFF = 0,
PNM_AP_FS_HELLO_DELAY_50MS = 50,
PNM_AP_FS_HELLO_DELAY_100MS = 100,
PNM_AP_FS_HELLO_DELAY_500MS = 500,
PNM_AP_FS_HELLO_DELAY_1000MS = 1000,
};
Structure description
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter ulFSHelloMode
The "Hello" mode the device shall use. The following values are defined:
Name Numerical Meaning
value
PNM_AP_FS_HELLO_MODE_OFF 0 The device shall not issue hello mode.
PNM_AP_FS_HELLO_MODE_LINKUP 1 The device shall issue DCP Hello Frames after
LinkUp
PNM_AP_FS_HELLO_MODE_LINKUP_DELAY 2 The device shall issue DCP Hello Frames with a
delay of ulFSHelloDelay milliseconds after
Linkup.
Parameter ulFSHelloInterval
This parameter defines the time interval in milliseconds between two DCP Hello Frames sent by
the device. The following values are valid:
Name Numerical Meaning
value
PNM_AP_FS_HELLO_INTERVAL_30MS 30 30 ms interval
PNM_AP_FS_HELLO_INTERVAL_50MS 50 50 ms interval
PNM_AP_FS_HELLO_INTERVAL_100MS 100 100 ms interval
PNM_AP_FS_HELLO_INTERVAL_300MS 300 300 ms interval
PNM_AP_FS_HELLO_INTERVAL_500MS 500 500 ms interval
PNM_AP_FS_HELLO_INTERVAL_1000MS 1000 1000 ms interval
Parameter ulFSHelloRetry
The device will resend the DCP Hello Frame up to ulFSHelloRetry times if no AR is
established.
Parameter ulFSHelloDelay
This parameter defines the delay between LinkUp and the first DCP Hello Frame if mode
PNM_AP_FS_HELLO_MODE_LINKUP_DELAY is used. The following values are defined:
Name Numerical Meaning
value
PNM_AP_FS_HELLO_DELAY_OFF 0 No Delay. Use for
PNM_AP_FS_HELLO_MODE_LINKUP
PNM_AP_FS_HELLO_DELAY_50MS 50 50 ms delay
PNM_AP_FS_HELLO_DELAY_100MS 100 100 ms delay
PNM_AP_FS_HELLO_DELAY_500MS 500 500 ms delay
PNM_AP_FS_HELLO_DELAY_1000MS 1000 1000 ms delay
Note: Depending on the AR Startup Mode, this record object is either written as first record
(Legacy Startup) or parameterized already in AR Connect (Advanced Startup). This is
done automatically within the PROFINET IO Controller protocol stack.
Structure reference
enum PNM_AP_CFG_AR_PRM_FSPARAM_MODE_Etag
{
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_DISABLE = 1,
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_ENABLE = 2,
};
typedef enum PNM_AP_CFG_AR_PRM_FSPARAM_MODE_Etag PNM_AP_CFG_AR_PRM_FSPARAM_MODE_E;
Structure description
Structure PNM_AP_CFG_PRM_AR_FSU_PARAMETERS_T
ulStructVersion UINT32 1 Structure version of this structure
ulFSParamMode UINT32 1, 2 Mode of Fast Startup Parameters
tFSParamUuid UUID A UUID associated with the parameters set
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter ulFSParamMode
The mode hello mode the device shall use. The following values are defined
Name Numerical Meaning
value
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_DISABLE 1 The device shall not use fast parameterization
PNM_AP_CFG_AR_PRM_FSPARAM_MODE_ENABLE 2 The device shall use fast parameterization
Parameter tFSParamUuid
A UUID associated the with complete parameter set associated with the device. This UUID is
generated by the engineering software.
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 114/290
Structure reference
#define PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA_TIMEIOINPUT_MAX (32000000)
#define PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA_TIMEIOOUTPUT_MAX (32000000)
#define PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA_TIMEIOINPUTVALID_MAX (32000000)
#define PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA_TIMEIOOUTPUTVALID_MAX (32000000)
Structure description
Structure PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA_T
ulStructVersion UINT32 1 Structure version of this structure
usControllerApplica UINT16 0x0001 to 0x0400 Reduction of the controller application relative to time
tionCycleFactor data cycle
usTimeDataCycle UINT16 0x0001 to 0x0400 Length of one data cycle in units of 31.25 µs.
ulTimeIOInput UINT32 0 to 32000000 Sample point of input data relative to start of next
network cycle in nanoseconds.
ulTimeIOOutput UINT32 0 to 32000000 Apply point of output data relative to start of current
network cycle in nanoseconds
ulTimeIOInputValid UINT32 0 to 32000000 Set to zero
ulTimeIOOutputValid UINT32 0 to 32000000 Time relative to start of current network cycle when the
process data is available at the device.
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter usControllerApplicationCycleFactor
This parameter describes the reduction of the controller application relative to time data cycle of
the submodule.
Parameter usTimeDataCycle
Length of one network cycle. This is typically the same value as the sendclock of the IRT AR
associated with this submodule
Parameter ulTimeIOInput
The time when the submodule shall sample the input value. The time is relative to the next network
cycle start. This time is calculated by the engineering software based on values from the GSDML
and controller application requirements.
Parameter ulTimeIOOutput
The time when the submodule shall apply the output values. The time is relative to the current
network cycle start. This time is calculated by the engineering software bases on values from the
GSDML, controller application requirements and the network topology. This value is always greater
then ulTimeIOOutputValid.
Parameter ulTimeIOInputValid
This parameter is defined in PROFINET specification symmetrically to ulTimeIOOutputValid, but
this time is always zero. (There is no propagation delay of the input data to the next bus cycle).
Parameter ulTimeIOOutputValid
This time indicates when the new output process data is available at the device for processing. It is
relative to the current network cycle start and depends on the network topology.
Structure reference
#define PNM_AP_CFG_PRM_ISOCHRONOUSCONTROLLERDATA_VERSION_1 (0x0001)
Structure description
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter ulTimeControllerApplicationInputMin
This is the time required by the PROFINET IRT Controller firmware to copy process data from
receive buffers into the DPM input area. This time depends on the configuration and other is
estimated by the engineering software.
Parameter usTimeControllerApplicationOutputMin
This is the time required by the PROFINET IRT Controller firmware to copy process data from the
DPM output area to the transmit buffers. This time depends on the configuration and other is
estimated by the engineering software.
Parameter ulTimeControllerApplicationStart
This time offset is relative to the start of the current network cycle and provides an estimation when
the controller application can start handling the process data. The value depends on network
topology and includes the time required to copy the input data into the DPM inpuit area.
Note: It is not expected that the host application acts upon this time point. The DPM input
area handshake mechanism will ensure that the input process data will be available to
the application around this time point.
Parameter ulTimeControllerApplicationEnd
This time offset is relative to the start of the current network cycle and provides an estimation when
the controller application should be finished handling the process data. The value depends mainly
on the copy time from DPM output area into the transmit buffer. Using
ulTimeControllerApplicationStart the application can calculate how much time is
available for data processing.
Note: In order for the output data to be transmitted in the next bus cycle, the application shall
handshake DPM output area before this time point.
Note: This service can also be used to read record objects provided by the PROFINET IRT
Controller itself. For that purpose the fix defined submodule handles of the controllers
PDEV submodules can be used.
Note: When the confirmation packet of this service might exceed the mailbox size a
fragmented transfer will be used. This is either the case if a fragmented transfer is
explicitly initiated by setting ulExt to RCX_PACKET_SEQ_LAST or when the
ulLenToRead is set to a value greater than 1540. Only one such fragmented service
might be active at the same time.
The following record objects are currently implemented by the PROFINET controller (when using
submodule handles 0xFFF0, 0xFFF1 or 0xFFF2):
Name Numerical value of Meaning
record index
Diagnosis in channel coding for one 0x800A Return all channel diagnosis for the specified
subslot subslot with severity “diagnosis”
Diagnosis in all codings for one 0x800B Return all diagnosis for the specified subslot with
subslot severity “diagnosis”
Diagnosis, Maintenance, Qualified 0x800C Return all diagnosis for the specified subslot
and Status for one subslot
Maintenance required in channel 0x8010 Return all channel diagnosis for the specified
coding for one subslot subslot with severity “maintenance required”
Maintenance demanded in channel 0x8011 Return all channel diagnosis for the specified
coding for one subslot subslot with severity “maintenance demanded”
Maintenance required in all codings 0x8012 Return all diagnosis for the specified subslot with
for one subslot severity “maintenance required”
Maintenance demanded in all codings 0x8013 Return all diagnosis for the specified subslot with
for one subslot severity “maintenance demanded”
PD Port Data Real 0x802A Return current Profinet Physical Device Port state.
E.g. Information about detected network peers, Mau
Type, Cable Delay. (Available for Handle 0xFFF1
and 0xFF2 only)
PD Port Statistics 0x8072 Return ethernet switch port or interface statistics,
E.g. Bytes received/Sent.
PD Interface Data Real 0x8080 Return current Profinet Physical Device Interface
state. E.g. Name Of Station, IP Address, Interface
Mac Address. (Available for Handle 0xFFF0 only)
Diagnosis in channel coding for one 0xC00A Return all channel diagnosis for the specified slot
slot with severity “diagnosis”
Diagnosis in all codings for one slot 0xC00B Return all diagnosis for the specified slot with
severity “diagnosis”
Packet description
Parameter usSubmoduleHandle
The handle of the (previously configured) submodule to read the record object from. The following
values are defined:
Submodule handle Meaning
1 to 2048 Read a record object from a configured device's submodule.
0xFFF0 Read a record object from the controllers interface submodule
0xFFF1 Read a record object from the controllers first port submodule
0xFFF2 Read a record object from the controllers second port submodule
Parameter usIndex
The index of the record object to read.
Parameter ulMaxReadLen
The maximum number of bytes to read from the object.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 -
ulSrc UINT32 -
ulDestId UINT32 0 Ignore for future compatibility.
ulSrcId UINT32 mirrored -
ulLen UINT32 16 to 65552 Packet data length in bytes. Depends on amount of
record data returned by the device
ulId UINT32 mirrored -
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page
276.
ulCmd UINT32 0x9423 PNM_AP_CMD_READ_RECORD_SUBM_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure PNM_AP_READ_RECORD_SUBM_CNF_DATA_T
usSubmoduleHandle UINT16 1 to 2048 Handle of submodule the data was read from
usIndex UINT16 0 to 0xFFFF Index of record object read
ulReadLen UINT32 0 to 65536 Amount of data read from the object
ulPnio UINT32 any The PROFINET Status Code from the read operation
usAddVal1 UINT16 any Additional value returned by PROFINET Device when
reading the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device
when reading the record object
abRecordData[] UINT8 The data returned by the record object
Parameter descriptions
Parameter usSubmoduleHandle
The handle of the (previously configured) submodule the record data was read from
Parameter usIndex
The index of the record object read.
Parameter ulReadLen
The number of bytes returned from the record object
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if an PROFINET error
occurred during processing the read service. The error code is either generated by the PROFINET
IO Controller or by the associated PROFINET IO Device. Section PROFINET Status Code on page
279 describes the meanings of the PROFINET status code.
Parameter abRecordData[]
This parameter contains the record data returned by the device.
Note: When the request packet of this service will exceed the mailbox size a fragmented
transfer will be used. This is the case when the ulDataLen is set to a value greater than
1544. Only one such fragmented service might be active at the same time.
Packet description
Structure PNM_AP_WRITE_RECORD_SUBM_REQ_T Type: Request
Parameter descriptions
Parameter usSubmoduleHandle
The handle of the (previously configured) submodule to write the record object for.
Parameter usIndex
The index of the record object to write.
Parameter ulDataLen
The number of bytes to write to the object
Parameter abRecordData[]
The record data to write.
Packet description
Parameter descriptions
Parameter usSubmoduleHandle
The handle of the (previously configured) submodule the record data was written to.
Parameter usIndex
The index of the record object written.
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if a PROFINET error
occurred during processing the write service. The error code is either generated by the PROFINET
IO Controller or by the associated PROFINET IO Device. Section PROFINET Status Code on page
279 describes the meanings of the PROFINET status code.
Note: The service involves RPC Transactions which might timeout due to network problems
or unreachable devices. Due to these timeouts the confirmation packet might be
delayed by several seconds. This must be considered for the application
implementation.
Note: Only one Read implicit record service may be active at the same time. The application
must wait for the confirmation before the next read can be performed.
Note: When the confirmation packet of this service might exceed the mailbox size a
fragmented transfer will be used. This is either the case if a fragmented transfer is
explicitly initiated by setting ulExt to RCX_PACKET_SEQ_LAST or when the
ulMaxLenToRead field is set to a value greater than 1530.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Unused by Stack Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 26 Packet Data Length in bytes
ulId UINT32 any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x9426 PNM_AP_CMD_READ_IMPLICIT_RECORD_REQ
ulExt UINT32 0 Set to zero
ulRoute UINT32 0 Set to zero
Structure PNM_AP_READ_IMPLICIT_RECORD_REQ_DATA_T
ulIpAddr UINT32 any IP address of device to read the record from
usVendorID UINT16 Any PNO Vendor ID of the device to read the record from
usDeviceID UINT16 any Device ID of the device to read the record from
usInstanceID UINT16 any Instance ID of the device to read the record from
usReserved1 UINT16 0 Reserved for future use. Set to zero.
ulApi UINT32 Any API to use for reading the object
usSlot UINT16 Any Slot to use for reading the object
usSubslot UINT16 Any Subslot to use for reading the object
usIndex UINT16 any Index of the record object to read
usReserved2 UINT16 0 Reserved for future use. Set to zero.
ulMaxLenToRead UINT32 1 to 65536 Maximum length to read
Parameter descriptions
Parameter ulIPAddr
The IP Address of the device to read the record object from.
Parameter usIndex
The index of the record object to read.
Parameter ulMaxLenToRead
The maximum number of bytes to read from the object.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility
ulSrcId UINT32 mirrored -
ulLen UINT32 36 - 65572 Packet Data Length in bytes. Depends on amount of
record data returned by the device
ulId UINT32 mirrored -
ulSta UINT32 0 =0: no error
<> 0: see section Status codes / Error codes on page 276.
ulCmd UINT32 0x9427 PNM_AP_CMD_READ_IMPLICIT_RECORD_CNF
ulExt UINT32 0 Ignore
ulRoute UINT32 0 Ignore
Structure PNM_AP_READ_IMPLICIT_RECORD_CNF_DATA_T
ulIPAddr UINT32 mirrored IP Address of the device the record was read from
usVendorId UINT16 mirrored PROFINET Vendor Id of the device the record was read
from
usDeviceId UINT16 mirrored PROFINET Device Id of the device the record was read
from
usInstanceId UINT16 mirrored Instance Id of the device the record was read from
usReserved1 UINT16 0 Ignore for future compatibility
ulApi UINT32 mirrored API of the submodule the record was read from
usSlot UINT16 mirrored Slot of the submodule the record was read from
usSubslot UINT16 mirrored Subslot of the submodule the record was read from
usIndex UINT16 mirrored Index of record object read
usReserved2 UINT16 0 Ignore for future compatibility
ulLenRead UINT32 0 to 65536 Amount of bytes read from the record object
ulPnio UINT32 any PROFINET Status code of the read implicit operation
usAddVal1 UINT16 any Additional value returned by the PROFINET Device when
reading the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device when
reading the record object
abRecordData[] UINT8 The data read from the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device when
reading the record object
abRecordData[] UINT8 The data read from the record object
Parameter descriptions
Parameter ulIPAddr
The IP Address of the device the record object was read from.
Parameter usIndex
The index of the record object to read.
Parameter ulLenRead
The number of bytes returned from the record object
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if an PROFINET error
occurred during processing the read implicit service. The error code is either generated by the
PROFINET IO Controller or by the associated PROFINET IO Device. Section PROFINET Status
Code on page 279 describes the meanings of the PROFINET status code.
Parameter abRecordData[]
This parameter contains the record data returned by the device.
Note: According to PROFINET Specification it is expected that this service is used after
application processing of the Diagnosis/Alarm. The intention behind this service is to
confirm to the device that the Diagnosis/Alarm had been processed by the application.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 12 Packet Data Length in bytes
ulId UINT32 any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x942C PNM_AP_CMD_ACK_ALARM_REQ
ulExt UINT32 0
ulRoute UINT32 0
Structure PNM_AP_ACK_ALARM_REQ_DATA_T
usDeviceHandle UINT16 0, 1 to 128 Handle of the device causing the alarm
usSubmoduleHandle UINT16 1 to 2048, Handle of the submodule causing the alarm
0xFFF0, 0xFFF1,
0xFFF2
usAlarmType UINT16 PROFINET Type of the Alarm
usAlarmPriority UINT16 0, 1 Priority of the Alarm
ulPnio UINT32 Status Code of Alarm Processing
Parameter descriptions
Parameter usAlarmType
This parameter defines the type of the alarm received. It must be set to the same value as in the
indication packet.
Parameter usAlarmPriority
This parameter defines the alarm priority. It must be set to the same value as in the indication
packet.
Parameter ulPnio
This parameter shall be set to the application status code of the alarm/diagnosis processing. If this
value is set to a non-zero value the associated application relation might be aborted depending on
the device application implementation.
Packet description
Note: Only one DCP Service can be active at a time. It is not possible to use different DCP
Services at the same time to the same or different devices. The application must wait
for the confirmation of this service before requesting the next DCP Service.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 8 to 248 Packet Data Length in bytes
ulId UINT32 any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x9430 PNM_AP_CMD_DCP_SET_NAME_REQ
ulExt UINT32 0
ulRoute UINT32 0
Structure PNM_AP_DCP_SET_NAME_REQ_DATA_T
abMac[6] UINT8[] Valid MAC MAC address of IO Device
address
usQualifier UINT16 0,1 Additional qualification of the request
tName[240] UINT8[] The new Name of Station
Parameter descriptions
Parameter abMac[6]
MAC address of IO Device whose name shall be set.
Parameter usQualifier
This parameter defines additional qualification of the request. The following table explains the
available flags and their meaning:
Name Numerical Meaning
Value
PNIO_APCTL_DCP_QUALIFIER_STORE_TEMPORARY 0x0000 The name should be assigned temporary.
The device will startup without a Name Of
Station after a Power Cycle
PNIO_APCTL_DCP_QUALIFIER_STORE_PERMANENT 0x0001 The name should be assigned
permanently.
Parameter abName[240]
The new NameOfStation to set for the specified IO Device. The length of the name will be derived
from the packet length.
Packet description
Parameter descriptions
Parameter bDcpError
contains the result status of the DCP operation. The following values are defined according
PROFINET Specification:
Name Numerical Meaning
Value
- 0x00 No error occurred
- 0x01 Unsupported DCP Option - The device does not support setting this parameter
- 0x02 Unsupported DCP Suboption - The device does not support setting this parameter
- 0x03 Setting suboption failed - The device was not able to apply the requested parameter setting for
unknown reason
- 0x04 Resource error - The device encountered a resource error while applying the parameter
setting
- 0x05 Set not possible - The device cannot apply the parameter at the moment
- 0x06 Set not possible In operation - The device cannot apply the parameter as it is in operation
Note: Only one DCP Service can be active at a time. It is not possible to use different DCP
Services at the same time to the same or different devices. The application must wait
for the confirmation of this service before requesting the next DCP Service.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 20 Packet Data Length in bytes
ulId UINT32 any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x9432 PNM_AP_CMD_DCP_SET_IP_REQ
ulExt UINT32 0
ulRoute UINT32 0
Structure PNM_AP_DCP_SET_IP_REQ_DATA_T
abMac[6] UINT8[] Valid MAC MAC address of IO Device
address
usQualifier UINT16 0,1
ulIpAddr UINT32 The IP Address to be assigned to the device
ulNetmask UINT32 The Network Mask to be assigned to the device
Parameter descriptions
Parameter abMac[6]
Parameter usQualifier
The following table explains the available flags and their meaning:
Packet description
Parameter descriptions
Parameter ulSta
Contains a non-zero error code if the request was rejected by the PROFINET IO Controller. For
details on error codes refer to Status/Error codes.
Parameter bDcpError
contains the result status of the DCP operation. The following values are defined according
PROFINET Specification:
Name Numerical Meaning
Value
- 0x00 No error occurred
- 0x01 Unsupported DCP Option - The device does not support setting this parameter
- 0x02 Unsupported DCP Suboption - The device does not support setting this parameter
- 0x03 Setting suboption failed - The device was not able to apply the requested parameter setting
for unknown reason
- 0x04 Resource error - The device encountered a resource error while applying the parameter
setting
- 0x05 Set not possible - The device cannot apply the parameter at the moment
- 0x06 Set not possible In operation - The device cannot apply the parameter as it is in operation
Note: Only one DCP Service can be active at a time. It is not possible to use different DCP
Services at the same time to the same or different devices. The application must wait
for the confirmation of this service before requesting the next DCP Service.
Packet description
Parameter descriptions
Parameter abMac[6]
MAC address of IO Device whose name shall be set.
Parameter usQualifier
This parameter defines additional qualification of the request. The following values are defined:
Name Numerical Value Meaning
PNIO_APCTL_DCP_QUALIFIER_SIGNAL 0x0100 The only valid value in case of DCP
Set Signal.
Packet description
Parameter descriptions
Parameter bDcpError
Contains the result status of the DCP operation. The following values are defined according to the
PROFINET Specification:
Name Numerical Meaning
Value
- 0x00 No error occurred
- 0x01 Unsupported DCP Option - The device does not support setting this parameter
- 0x02 Unsupported DCP Suboption - The device does not support setting this parameter
- 0x03 Setting suboption failed - The device was not able to apply the requested parameter setting for
unknown reason
- 0x04 Resource error - The device encountered a resource error while applying the parameter
setting
- 0x05 Set not possible - The device cannot apply the parameter at the moment
- 0x06 Set not possible In operation - The device cannot apply the parameter as it is in operation
Note: Only one DCP Service can be active at a time. It is not possible to use different DCP
Services at the same time to the same or different devices. The application must wait
for the confirmation of this service before requesting the next DCP Service.
Packet description
Parameter abMac[6]
MAC address of PROFINET IO Device whose name shall be set.
Parameter usQualifier
This parameter defines additional qualification of the request. The following values are defined for
DCP Reset Factory Settings:
Name Numerical Reset Meaning
Value Mode
0x0000 - Use DCP FactoryReset according
to PROFINET Specification 2.2
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0002 1 The device shall reset the
APPLICATION application data in submodules
and modules.
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0004 2 The device shall reset all PDev
COMMUNICATION Parameters, AR Parameters and
Communication Parameters.
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0006 3 The device shall reset all
ENGINEERING Parameters stored by the
engineering system
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0008 4 The device shall reset all stored
ALL data to factory default values
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0010 8 The device shall reset all stored
DEVICE data and communication
parameters of the device to factory
default values. (Out of the Box
State)
PNIO_APCTL_DCP_QUALIFIER_RESETTOFACTORY_ 0x0012 9 The device shall reset its software
RESTORE to the factory images.
Note: PROFINET Devices according to Specification V2.2 support only the DCP
FactoryReset variant of this service. Therefore the usQualifier must be set to zero for
these devices. For PROFINET Devices according to Specification V2.3 the supported
Reset Modes are specified in the GSDML file.
Packet description
Parameter descriptions
Parameter ulSta
Contains a non-zero error code if the request was rejected by the PROFINET IO Controller. For
details on error codes refer to Status/Error codes.
Parameter bDcpError
contains the result status of the DCP operation. The following values are defined according to the
PROFINET Specification:
Name Numerical Meaning
Value
- 0x00 No error occurred
- 0x01 Unsupported DCP Option - The device does not support setting this parameter
- 0x02 Unsupported DCP Suboption - The device does not support setting this parameter
- 0x03 Setting suboption failed - The device was not able to apply the requested parameter setting for
unknown reason
- 0x04 Resource error - The device encountered a resource error while applying the parameter
setting
- 0x05 Set not possible - The device cannot apply the parameter at the moment
- 0x06 Set not possible In operation - The device cannot apply the parameter as it is in operation
Note: Only one DCP Service can be active at a time. It is not possible to use different DCP
Services at the same time to the same or different devices. The application must wait
for the confirmation of this service before requesting the next DCP Service.
Packet description
Parameter abMac[6]
MAC address of IO Device whose name shall be set.
Parameter usRequestFlags
This parameter is a bit field defining which parameters shall be retrieved from the target device.
Name Numerical Meaning
Value
PNM_AP_DCP_GET_OPTION_MACADDR 0x0001 Return the MAC Address of the device
(internally forced to be always true)
PNM_AP_DCP_GET_OPTION_IP_PARAM 0x0002 Retrieve the IP Settings of the device
PNM_AP_DCP_GET_OPTION_TYPEOFSTATION 0x0004 Retrieve the Type Of Station of the Device
(Equal to Device Type since PROFINET
Specification V2.3)
PNM_AP_DCP_GET_OPTION_NAMEOFSTATION 0x0008 Retrieve the Name of Station of the device
PNM_AP_DCP_GET_OPTION_DEVICE_IDENT 0x0010 Retrieve the Vendor and Device ID of the
device
PNM_AP_DCP_GET_OPTION_DEVICE_ROLE 0x0020 Retrieve the role of the device
PNM_AP_DCP_GET_OPTION_DEVICE_INSTANCE 0x0040 Retrieve the instance of the device. This
Parameter is supported by PROFINET
Specification V2.3 devices and above.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 -
ulSrc UINT32 -
ulDestId UINT32 0 Ignore for future compatibility
ulSrcId UINT32 mirrored -
ulLen UINT32 512 Packet Data Length in bytes
ulId UINT32 mirrored -
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page
276.
ulCmd UINT32 0x9439 PNM_AP_CMD_DCP_GET_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure PNM_AP_DCP_GET_CNF_DATA_T
abMacAddr[] UINT8[] The MAC Address of the target device
usValidFlags UINT16 Bitmask defining the valid values
ulIpAddr UINT32 IP Address returned by device
ulNetmask UINT32 Network mask returned by the device
ulGateway UINT32 IPv4 Gateway address returned by the device
usVendorId UINT16 PROFINET Vendor ID returned by the device
usDeviceId UINT16 PROFINET Device ID returned by the device
usInstance UINT16 PROFINET Device Instance
usRole UINT16 1 to 3 PROFINET Role returned by the device
bLenNameOfStation UINT8 0 to 240 Length of the Name Of Station returned by the device
bLenTypeOfStation UINT8 0 to 240 Length of the Type Of Station returned by the device
abNameOfStation[] UINT8[] The Name Of Station of the Device
abTypeOfStation[] UINT8 The Type Of Station of the Device
bErrorCount UINT8 The number of DCP Get Option Errors returned by the
device
bBlockError UINT8 The last DCP Option Block error returned by the device
Parameter descriptions
Parameter usValidFlags
This parameter is a bitmask which defines which parameters have been retrieved from the target
device. The following values are defined:
Name Numerical Value Meaning
PNM_AP_DCP_GET_OPTION_MACADDR 0x0001 Return the MAC address of the device
(taken from request packet, internally forced
to be always true)
PNM_AP_DCP_GET_OPTION_IP_PARAM 0x0002 Retrieve the IP Settings of the device
PNM_AP_DCP_GET_OPTION_TYPEOFSTATION 0x0004 Retrieve the Type Of Station of the Device
(Equal to Device Type since PROFINET
Specification V2.3)
PNM_AP_DCP_GET_OPTION_NAMEOFSTATION 0x0008 Retrieve the Name of Station of the device
PNM_AP_DCP_GET_OPTION_DEVICE_IDENT 0x0010 Retrieve the Vendor and Device ID of the
device
PNM_AP_DCP_GET_OPTION_DEVICE_ROLE 0x0020 Retrieve the role of the device
PNM_AP_DCP_GET_OPTION_DEVICE_INSTANCE 0x0040 Retrieve the instance of the device. This
Parameter is supported by PROFINET
Specification V2.3 devices and above.
Packet description
Parameter descriptions
Parameter usDeviceHandle
Reference to the AR for which to retrieve the logbook. Set to zero to retrieve the PROFINET IO
Controller logbook.
Parameter usMaxEntries
Maximum number of entries to return in confirmation packet
PNM_AP_LOGBOOK_HIF_WDGERROR = 0x0100,
PNM_AP_LOGBOOK_EVENT_AR_NOTESTABLISHED = 0x8000,
PNM_AP_LOGBOOK_EVENT_AR_ESTABLISHED = 0x8001,
PNM_AP_LOGBOOK_EVENT_AR_ABORT = 0x8002,
PNM_AP_LOGBOOK_EVENT_AR_LOW_PRIO_ALARM = 0x8003,
PNM_AP_LOGBOOK_EVENT_AR_HIGH_PRIO_ALARM = 0x8004,
PNM_AP_LOGBOOK_EVENT_AR_RPC_READ_FAILED = 0x8005,
PNM_AP_LOGBOOK_EVENT_AR_RPC_WRITE_FAILED = 0x8006,
PNM_AP_LOGBOOK_EVENT_STACK_BUSSTATE = 0x8100,
};
typedef enum PNM_AP_LOGBOOK_EVENT_Etag PNM_AP_LOGBOOK_EVENT_E;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility.
ulSrcId UINT32 mirrored
ulLen UINT32 4 to 1028 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page
276.
ulCmd UINT32 0x94F1 PNM_AP_CMD_GET_LOGBOOK_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure PNM_AP_DWNL_FIN_CNF_DATA_T
Parameter descriptions
Parameter usDeviceHandle
A reference to the AR the logbook was retreived for. Zero if the PROFINET IO Controllers logbook
was received
Parameter usNumEntries
The actual number of entries returned in atEntries.
AR related events
PNM_AP_LOGBOOK_EVENT_AR_NOTESTABLISHED 0x8000 The AR was not PROFINET Error
established Status
PNM_AP_LOGBOOK_EVENT_AR_ESTABLISHED 0x8001 The AR was 0: No Module Diff
established Block was reported
by the device
1: A Module Diff
Block was reported
by the device
PNM_AP_LOGBOOK_EVENT_AR_ABORT 0x8002 The AR was aborted PROFINET Error
Status
PNM_AP_LOGBOOK_EVENT_AR_LOW_PRIO_ALARM 0x8003 A low priority Lower 16 Bit:
PROFINET alarm Handle of
was received Submodule
Upper 16 Bit: Alarm
Type
PNM_AP_LOGBOOK_EVENT_AR_HIGH_PRIO_ALARM 0x8004 A high priority Lower 16 Bit:
PROFINET alarm Handle of
was received Submodule
Upper 16 Bit: Alarm
Type
PNM_AP_LOGBOOK_EVENT_AR_RPC_READ_FAILED 0x8005 A Record Read PROFINET Error
Request failed Status
PNM_AP_LOGBOOK_EVENT_AR_RPC_WRITE_FAILED 0x8006 A Record Write PROFINET Error
Request failed Status
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW)
-
Handle (LOM)
ulSrc UINT32 Handle (LFW)
-
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 2 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 PNM_AP_CMD_GET_ARVENDORBLOCK_RESPONSE_R
0x9420
EQ
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure PNM_AP_CFG_AR_PRM_DATA_T
usArVendorBlock UINT16 1 to 256 Handle of the previously configured AR Vendor Block
Handle Request associated with the desired AR Vendor Block
Response
Parameter descriptions
Parameter usArVendorBlockHandle
The handle of the previously configured AR Vendor Block. The confirmation packet will contain the
associated AR Vendor Block Response Value.
3.2.11.2 PNM_AP_GET_ARVENDORBLOCK_RESPONSE_CNF_DATA_T
confirmation
Packet description
Parameter descriptions
Parameter usArVendorBlockHandle
The handle of the requested AR Vendor Block.
Parameter abData[]
The AR Vendor Block Response Data returned by the device in its connect response. The actual
length of the data can be calculated from tHead.ulLen.
Packet description
Parameter descriptions
Parameter usDeviceHandle
The handle of the AR to configure.
Parameter ulStatus
A bitmask defining the new properties of an AR.
Name Value Meaning
PNM_AP_SET_ARSTATUS_ENABLED 0x00000000 If no bit is set, this particular AR will be enabled.
PNM_AP_SET_ARSTATUS_DISABLED 0x00000004 If this bit is set, this particular AR will be disabled. If the
AR is connected, the connection will be aborted.
Packet description
Note: The confirmation packet will be sent after the DA-AR has been established. If it was not
possible to establish a DA-AR the confirmation packet will contain an error.
enum PNM_AP_CFG_IOD_AR_PROP_FLAGS_Etag
{
PNM_AP_CFG_IOD_AR_PROP_FLAG_DEVICEACCESS = 0x00000100,
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 Handle (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility
ulSrcId UINT32 any Ignored by protocol stack
ulLen UINT32 296 Packet data length in bytes
ulId UINT32 any Ignored by protocol stack
ulSta UINT32 0 -
ulCmd UINT32 0x941C PNM_AP_CMD_ESTABLISH_DAAR_REQ command
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure PNM_AP_ESTABLISH_DAAR_REQ_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usDeviceHandle PNM_AP_DE 0xF000 Handle of device acccess AR
VICEHANDL
E_T
bARType UINT8 0x06 AR Type
bPadding UINT8 0 Set to zero for future compatibility
ulFlags UINT32 0 Flags controlling AR behavior
Parameter descriptions
Parameter ulStructVersion
Structure version of the configuration structure. Used for future extensions.
Parameter usDeviceHandle
This parameter specifies the handle of the AR to be configured. For device access AR this handle
is fixed to the value PNM_AP_DEVICEHANDLE_DAAR_FIRST (0xF000).
Parameter bARType
This parameter describes the type of the AR
Name Numeric value Meaning
PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR 0x06 AR Type for supervisor communication
Parameter ulFlags
The parameter ulFlags is a bitmask of flag bits specifying additional properties of the AR. For
device access AR this field shall be set to zero.
Parameter tArUUID
Unique identifier of the AR. The AR UUID shall be generated by the engineering software or
application. It is a unique id of the AR and must be non-zero. Each new device access AR must
use a new UUID.
Parameter ulArProperties
The parameter ulARProperties is a bitmask describing PROFINET Properties of this AR. For
device access AR the value PNM_AP_CFG_IOD_AR_PROP_FLAG_DEVICEACCESS must be
used.
Name Numeric value Meaning
PNM_AP_CFG_IOD_AR_PROP_FLAG_DEVICEACCESS 0x00000100 A device access ar shall be established
Parameter usVendorID
VendorID to be used by IO Controller for addressing the IO Device. (Extract from GSDML file)
Parameter usDeviceID
DeviceID to be used by IO Controller for addressing the IO Device (Extract from GSDML file)
Parameter usInstanceID
The instance ID of the device. (Extract from GSDML file, Attribute "ObjectUUID Instance")
Parameter abNameOfStation[240]
The parameter abNameOfStation is the PROFINET Name Of Station to be used for this AR. The
PROFINET IO Controller will establish the AR with a PROFINET IO Device with that
NameOfStation. If multiple devices with same NameOfStation exist, no connection will be made.
The field should be zero padded to full field length.
Parameter ulIPAddr
IP address to be assigned to the PROFINET IO Device. This IP Address Setting is to be specified
by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Parameter ulNetmask
Network Mask to be assigned to the PROFINET IO Device. This IP Address Setting is to be
specified by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Parameter ulGatewayAddr
Gateway Address to be assigned to the PROFINET IO Device. This IP Address Setting is to be
specified by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Packet description
Packet description
Parameter descriptions
Parameter usDeviceHandle
The handle of the AR to release. For device access AR this handle is fixed to the value
PNM_AP_DEVICEHANDLE_DAAR_FIRST (0xF000).
Parameter ulFlags
A bitmask defining the flags associated with the service properties of an AR. For device access AR
the value PNM_AP_RELEASE_DAAR_RELEASE must be used (0x00000004).
Name Value Meaning
PNM_AP_RELEASE_DAAR_RELEASE 0x00000004 Release the AR associated with this service
Packet description
Packet description
Structure TLR_PACKET_HEADER_T
ulDest UINT32 0x20 (LFW) Destination Queue-Handle
Handle (LOM)
ulSrc UINT32 0 ... 232-1 Source Queue-Handle
ulDestId UINT32 0 Destination End Point Identifier, specifying the final
receiver of the packet within the Destination Process. Set
to 0 for the Initialization Packet
ulSrcId UINT32 0 ... 232-1 Source end point identifier, specifying the origin of the
packet inside the source process
ulLen UINT32 516 Packet data length in bytes
ulId UINT32 Packet Identification as unique number generated by the
source process of the packet
ulSta UINT32 See section Status codes / Error codes on page 276.
ulCmd UINT32 0x2f25 RCX_GET_DEVICE_INFO_CNF_T - Command
ulExt UINT32 0 Extension not in use, set to zero for compatibility reasons
ulRoute UINT32 Routing, do not touch
Structure RCX_GET_DEVICE_INFO_CNF_DATA_T
ulDeviceIdx UINT32 Value taken from request
ulStructId UINT32 5389 Struct identifier for PROFINET Device Info
usVendorId UINT16 PROFINET Vendor Id of the device
usDeviceId UINT16 PROFINET Device Id of the device
ulIpAddress UINT32 Current IP address of the device
ulNetmask UINT32 Current IP network mask of the device
ulGateway UINT32 Current IP gateway address of the device
usLenName UINT16 0 to 240 Length of name of station of the device
usLenType UINT16 0 to 240 Length of type of station of the device
usDeviceRole UINT16 0 ... 3 Role of the device
abNameOfStation UINT8 Name of station of the device
[240]
abTypeOfStation UINT8 Type of station of the device
[240]
Table 13: RCX_GET_DEVICE_INFO_CNF_T - Get User Parameter Data Request
Parameter descriptions
Parameter ulDeviceIdx
The identifier of the device associated with the device info.
Parameter ulStructId
The identifier of the structure type. Always 5389 for the PROFINET Controller
Name Value
PNM_AP_DEVICEHANDLE_DAAR_FIRST 0xF000
Table 14: Device Handle for Device Access AR
In contrast to an IO-AR, the DA-AR is configured and established at runtime. A DA-AR has no
IOCRs, no submodules and no records. Record objects are read and written by the application
using acyclic services. The following services are used in conjunction with an Device Access AR:
According to the PROFINET specification the PROFINET Device will internally abort the DA-AR
after the CMI timeout. The timeout starts initially with the RPC Connect Response and is restarted
on each RPC Read/Write response. The Controller must sent the next RPC Request before the
CMI timeout has passed, otherwise the Device will reject the RPC request. The PROFINET
specification defines no direct indication from Device to Controller in case of a CMI timeout for an
Device Access AR.
Note: This service will not be used for alarm types configured for automatic alarm handling in
Configure IO Controller service on page 33. These alarms will be handled internally by
the PROFINET controller firmware.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 Handle Ignore
ulSrc UINT32 Handle Ignore
ulDestId UINT32 any Will contain value from ulSrcId from
RCX_REGISTER_APPLICATION_REQ request packet
ulSrcId UINT32 0 Ignore for future compatibility
ulLen UINT32 20 to 280 Packet data length in bytes
ulId UINT32 any Ignore
ulSta UINT32 0 -
ulCmd UINT32 0x9428 PNM_AP_CMD_RECV_ALARM_IND
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure PNM_AP_RECV_ALARM_IND_DATA_T
usDeviceHandle UINT16 0, 1 to 128 Handle of the device causing the alarm
usSubmoduleHandl UINT16 1 to 2048, Handle of the submodule causing the alarm
e 0xFFF0, 0xFFF1,
0xFFF2
usAlarmType UINT16 PROFINET Type of the Alarm
usAlarmPriority UINT16 0, 1 Priority of the Alarm
ulApi UINT32 any Api of the submodule associated with the alarm
usSlot UINT16 any Slot of the submodule associated with the alarm
usSubslot UINT16 any Subslot of the submodule associated with the alarm
usAlarmSpecifier UINT16 PROFINET Alarm Specifier
usAlarmDataLen UINT16 0 to 240 Length of alarm data payload
abAlarmData[] UINT8[] Alarm data payload
Parameter descriptions
Parameter usAlarmType
This parameter defines the type of the alarm received. The following values are defined:
Name Numerical Meaning
value
PN_ALARM_TYPE_PROCESS 0x0002 The submodules application issued a process alarm.
PN_ALARM_TYPE_PULL 0x0003 The submodule was pulled from the device
PN_ALARM_TYPE_PLUG 0x0004 The submodule was plugged into the device
PN_ALARM_TYPE_STATUS 0x0005 PROFINET Status Alarm was received
PN_ALARM_TYPE_UPDATE 0x0006 PROFINET Update Alarm was received
PN_ALARM_TYPE_MEDIA_REDUNDANCY 0x0007 PROFINET Media Redundancy Alarm was received
PN_ALARM_TYPE_SUPERVISOR 0x0008 The submodule was taken over by an IO Supervisor
PN_ALARM_TYPE_RELEASED 0x0009 The submodule was released by an IO Supervisor
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 178/290
Parameter usAlarmPriority
This parameter is zero for low priority alarms and one for high priority alarms.
Parameter usAlarmSpecifier
This parameter provides additional information about the alarm. The lower 15 bits contain the
alarm sequence number.
Packet description
Parameter descriptions
Parameter usAlarmType
This parameter defines the type of the alarm received. It must be set to the same value as in the
indication packet.
Parameter usAlarmPriority
This parameter defines the alarm priority. It must be set to the same value as in the indication
packet.
Note: This service will not be used for alarm types configured for automatic alarm handling in
Configure IO Controller service on page 33. These alarms will be handled internally by
the PROFINET controller firmware.
Note: This service will also be used to indicate diagnosis alarms generated by the PDEV
submodules of the PROFINET IO Controller itself. These alarms are virtual alarms
associated with the PDEV submodules of the controller. They are generated by the
firmware in order to provide a unique interface to diagnosis events regardless of their
origin. The indication of this internal diagnosis alarms depends on the setting of
automatic alarm handling as well. These alarms must be confirmed similar to device
diagnosis alarms.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 Handle Ignore
ulSrc UINT32 Handle Ignore
ulDestId UINT32 any Will contain value from ulSrcId from
RCX_REGISTER_APPLICATION_REQ request packet
ulSrcId UINT32 0 -
ulLen UINT32 20 to 260 Packet data length in bytes
ulId UINT32 any Ignore
ulSta UINT32 0 -
ulCmd UINT32 0x942A PNM_AP_CMD_RECV_DIAGNOSIS_IND
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure PNM_AP_RECV_DIAGNOSIS_IND_DATA_T
usDeviceHandle UINT16 0, 1 to 128 Handle of the device causing the alarm
usSubmoduleHandle UINT16 1 to 2048, Handle of the submodule causing the alarm
0xFFF0, 0xFFF1,
0xFFF2
usAlarmType UINT16 PROFINET Type of the alarm
usAlarmPriority UINT16 0, 1 Priority of the alarm
ulApi UINT32 any API of the submodule associated with the alarm
usSlot UINT16 any Slot of the submodule associated with the alarm
usSubslot UINT16 any Subslot of the submodule associated with the alarm
usAlarmSpecifier UINT16 PROFINET alarm specifier
usAlarmDataLen UINT16 0, 2 to 240 Length of alarm data payload including user structure
identifier
usUSI UINT16 User structure Identifier
uData UNION Alarm data payload. Valid union element depends on
value of usUSI
Parameter descriptions
Parameter usAlarmType
This parameter defines the type of the alarm received. The following values are defined:
Name Numerical Meaning
value
PN_ALARM_TYPE_DIAGNOSIS 0x0001 A diagnosis was added to the submodule
PN_ALARM_TYPE_MEDIA_REDUNDANCY 0x0007 PROFINET Media Redundancy Alarm was received
PN_ALARM_TYPE_DIAGNOSIS_DIS 0x000C A diagnosis was removed from the submodule
PN_ALARM_TYPE_MC_COMM_MISMATCH 0x000D An change of multicast communication was detect by
the device
PN_ALARM_TYPE_PORT_DATA_CH_N 0x000E A change of PD Port diagnosis was detected by the port
submodule
PN_ALARM_TYPE_SYNC_CH_NOT 0x000F A change of Sync state was detected by the interface
submodule
PN_ALARM_TYPE_ISO_PROBLEM 0x0010 A change of isochronous mode diagnosis was detected
by the submodule
PN_ALARM_TYPE_NETWORK_PRB 0x0011 A change of network problem diagnosis was detected
by the submodule
PN_ALARM_TYPE_TIME_CH_N 0x0012 A change of time diagnosis was detected by the
submodule
PN_ALARM_TYPE_DFP_PROBLEM 0x0013 A change of DFP diagnosis was detected by the
submodule
PN_ALARM_TYPE_MRPD_PROBLEM 0x0014 A change of MRPD diagnosis was detected by the
submodule
PN_ALARM_TYPE_SYSTEM_REDUNDANCY 0x0015 PROFINET System Redundancy event occurred
Parameter usAlarmPriority
This parameter is zero for low priority alarms and one for high priority alarms.
Parameter usAlarmSpecifier
This parameter provides additional information about the alarm. The lower 15 bits contain the
alarm sequence number.
Packet description
Parameter descriptions
Parameter usAlarmType
This parameter defines the type of the alarm received. It must be set to the same value as in the
indication packet.
Parameter usAlarmPriority
This parameter defines the alarm priority. It must be set to the same value as in the indication
packet.
As the remanent data indication packet does not fit into the DPM mailboy as a whole, a fragmented
packet transfer sequence is used for this service.
Packet description
Parameter descriptions
Parameter usLength
Specifies the length of the remanent data
Parameter abData
Array containing the remanent data.
Packet description
There are no sections directly dealing with modules, but there is a way to retrieve the module a
given submodule belongs to described in section Get submodule service on page 231.
In order to access data, you first have to obtain offsets (namely the base offset and relative
offsets):
1. The base offset usDpmOffset can be obtained from the Get IOCR service described in
section Get IOCR service (page 223)
2. The following relative offsets can be obtained from the Get submodule service described in
section Get submodule service (page 231):
usFrameOffsetInput
usFrameOffsetOutput
usIOCSFrameOffsetInput
usIOCSFrameOffsetOutput
/*
PNM_AP_CMD_CFG_GET_IOC_DATA_REQ
return basic parameters of IO Controller itself
*/
struct PNM_AP_CFG_GET_IOC_REQ_Ttag
{
PNM_AP_PCK_HEADER_T tHead;
PNM_AP_CFG_GET_IOC_REQ_DATA_T tData;
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 Handle
ulSrc UINT32 Handle
ulDestId UINT32 Any Set to zero for future compatibility
ulSrcId UINT32 0 -
ulLen UINT32 4 Packet Data Length in bytes
ulId UINT32 Any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x00009454 PNM_AP_CMD_CFG_GET_IOC_REQ
ulExt UINT32 any
ulRoute UINT32 any
Structure PNM_AP_CFG_GET_IOC_REQ_DATA_T
ulStructVersion UINT32 1 Structure version
Table 17: PNM_AP_CFG_GET_IOC_REQ_T request
Parameter descriptions
Parameter ulStructVersion
Specifies the structure version.
With the ulAlarmHandlingFlags you can define which alarms should be handled by the
fieldbus stack automatically.
The definition of the ulAlarmHandlingFlags are \ref
PNM_AP_CFG_ALARM_HANDLING_FLAGS_Etag enumeration.
*/
uint32_t ulAlarmHandlingFlags;
/** DPM Channel Watchdog time in ms
\arg \c Deactivated 0
\arg \c Min 0
\arg \c Max 65535)
*/
uint32_t ulDpmWatchdogTime;
/** VendorID to be used by IO Controller
\note This parameter is for the OEMs to handover the own VendorID number.
\par See Spec:
Coding of fields related to Instance, DeviceID, VendorID
*/
uint16_t usVendorID;
/** DeviceID to be used by IO Controller
\note This parameter is for the OEMs to handover the Vendor specific DeviceID
number.
\par See Spec:
Coding of fields related to Instance, DeviceID, VendorID
*/
uint16_t usDeviceID;
/** IP address to be used by IO Controller */
uint32_t ulIPAddr;
/** subnet mask to be used by IO Controller */
uint32_t ulNetmask;
/** Gateway address to be used by IO Controller */
uint32_t ulGateway;
/** Device Type to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\par See Spec:
See Coding of the field DeviceType
*/
uint8_t abDeviceType[25];
/** NameOfStation to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\note The default name should be get from the GSDML attribute \c
DNS_CompatibleName.
\par See Spec:
Coding of the field NameOfStationValue
*/
uint8_t abNameOfStation[240];
/** OrderId to be used by IO Controller, Pad With Zero:
we don't need a length here, can be computed by searching for zeros
\note The GSDML Element \c OrderNumber.
\par See Spec:
Coding of the field OrderID
*/
uint8_t abOrderId[20];
The bitlist must be located outside of the process data area, that is,
either before any process data or behind.
*/
uint16_t usBitlistStartOffset;
/** Fix alignment of structure fields due to definition abDeviceType */
uint8_t bPadding;
/** Start offset in DPM input area for the IRT cycle counter
*
* This field is available since structure version 2. Set to 0xFFFF
* to disable cycle counter in input data area. */
uint16_t usIoTimingInfoOffset;
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 322 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009455 PNM_AP_CMD_CFG_GET_IOC_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_IOC_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
ulSystemFlags UINT32 0, 1, 2 System flags
ulAlarmHandlingF UINT32 Automatic alarm handling flags
lags
ulDpmWatchdogTim UINT32 0, 20 … 65535 DPM channel watchdog time
e
usVendorID UINT16 VendorID to be used by IO Controller
usDeviceID UINT16 DeviceID to be used by IO Controller
ulIPAddr UINT32 IP address to be used by IO Controller
ulNetmask UINT32 Subnet mask to be used by IO Controller
ulGateway UINT32 Gateway address to be used by IO Controller
abDeviceType[25] UINT8[] Device Type to be used by IO Controller
abNameOfStation[ UINT8[] NameOfStation to be used by IO Controller
240]
abOrderId[20] UINT8[] OrderId to be used by IO Controller
usBitlistStartOf UINT16 Start offset in DPM input area for slave status bit lists
fset
bPadding UINT8 0 Padding to fix structure field alignment. Set to zero for
future compatibility.
usIoTimingInfoOf UINT16 Start offset in DPM input area for IO timing information
fset (This field is available since structure version 2)
Table 18: PNM_AP_CFG_GET_IOC_CNF_T confirmation
Parameter descriptions
Parameter ulStructVersion
Version of this structure. This parameter is used for future extensions of the Configure Controller
Service.
Parameter ulSystemFlags
The ulSystemFlags field is a bitmask of flags defined as follows:
Option Numeric value Meaning
PNM_AP_IOC_FLAG_STARTMODE_ 0x00000000 The communication will be started automatically after the
AUTOMATIC PROFINET IO Controller had been configured successfully.
PNM_AP_IOC_FLAG_STARTMODE_ 0x00000001 The application must explicitly enable the bus to start
APPLICATION_CONTROLLED communication.
PNM_AP_IOC_FLAG_FORCE_NAME_ 0x00000002 The controller will assign the Name Of Station even to
ASSIGNMENT devices which are already assigned a Name Of Station.
Parameter ulAlarmHandlingFlags
This parameter specifies which alarms shall be handled by the PROFINET IO Controller itself and
which alarms shall be passed to the application for processing. The field
ulAlarmHandlingFlags is defined as a bitmask where each bit corresponds to a particular
alarm type. For each alarm to be handled by the PROFINET IO Controller the corresponding bit
shall be set. As a special use case it is also possible to handle all manufacturer specific alarms
within the PROFINET IO Controller using the bitmask
PNM_AP_CFG_ALARM_HANDLING_FLAG_MANUFACTURER_ALARMS.
The following bitmasks are defined:
Flag Value
PNM_AP_CFG_ALARM_HANDLING_FLAG_DIAGNOSIS 0x00000001
PNM_AP_CFG_ALARM_HANDLING_FLAG_PROCESS 0x00000002
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL 0x00000004
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG 0x00000008
PNM_AP_CFG_ALARM_HANDLING_FLAG_PULL_MODULE 0x00000010
PNM_AP_CFG_ALARM_HANDLING_FLAG_PLUG_WRONG 0x00000020
PNM_AP_CFG_ALARM_HANDLING_FLAG_STATUS 0x00000040
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPDATE 0x00000080
PNM_AP_CFG_ALARM_HANDLING_FLAG_MEDIA_REDUND 0x00000100
PNM_AP_CFG_ALARM_HANDLING_FLAG_CONTROLLED 0x00000200
PNM_AP_CFG_ALARM_HANDLING_FLAG_RELEASED 0x00000400
PNM_AP_CFG_ALARM_HANDLING_FLAG_RETURN_OF_SUBM 0x00000800
PNM_AP_CFG_ALARM_HANDLING_FLAG_MCR_MISMATCH 0x00001000
PNM_AP_CFG_ALARM_HANDLING_FLAG_PORT_DATA_CHANGE 0x00002000
PNM_AP_CFG_ALARM_HANDLING_FLAG_SYNC_DATA_CHANGE 0x00004000
PNM_AP_CFG_ALARM_HANDLING_FLAG_TIME_DATA_CHANGE 0x00008000
PNM_AP_CFG_ALARM_HANDLING_FLAG_ISOCHR_MODE_PROBLEM 0x00010000
PNM_AP_CFG_ALARM_HANDLING_FLAG_NETW_COMP_PROBLEM 0x00020000
PNM_AP_CFG_ALARM_HANDLING_FLAG_DFP_PROBLEM 0x00040000
PNM_AP_CFG_ALARM_HANDLING_FLAG_MRPD_PROBLEM 0x00080000
PNM_AP_CFG_ALARM_HANDLING_FLAG_MULT_INTF_MISMATCH 0x00100000
PNM_AP_CFG_ALARM_HANDLING_FLAG_UPLOAD_AND_RETRIVAL 0x00200000
PNM_AP_CFG_ALARM_HANDLING_FLAG_MANUFACTURER_ALARMS 0x80000000
Table 19: Definition of alarm handling flags
Parameter usVendorID
This parameter specifies the PROFINET Vendor ID the controller shall use. The Vendor ID is a
unique identification number of the controller's vendor assigned by the PNO.
Note: This parameter is for the OEMs to handover the own VendorID number.
Parameter usDeviceID
This parameter specifies the PROFINET Device ID the controller shall use. The device ID is a
unique device id assigned by the vendor of the device.
Note: This parameter is for the OEMs to handover the Vendor specific DeviceID number.
Parameter ulIPAddr
IP address to be used by the IO Controller
Parameter ulNetmask
Subnet mask to be used by the IO Controller
Parameter ulGateway
Gateway address to be used by the IO Controller
Parameter abDeviceType
The device type is a short textual description of the device. It is used in device identification when
performing network scans or when reading out identification information from a PROFINET Device
or Controller. The value shall be padded with zero(es) to the full field length.
Parameter abNameOfStation
The name of station is the bus address of a PROFINET Device or Controller. The name of station
must be unique across the communication network. According to the PROFINET specification the
characters a-z, 0-9, '-' and '.' are allowed where '.' has the special meaning of a label separator..
The name must fulfill further conditions:
it must not look like an IP address, e.g. 1.2.3.4
a label must consist of at least one and at most 63 characters
the name must not start with 'port-abc' or 'port-abc-defgh' where a,b,c,d,e,f,g,h are
digits 0-9
The field shall be padded with zero(es) to full field length
Parameter abOrderId
The vendor's order id of the PROFINET IO Controller. The field shall be padded with zero(es) to
full field length.
Parameter usBitlistStartOffset
The PROFINET IO Controller manages three bit lists within the DPM Input Area. Each bit list is 128
bits (=16 byte) wide and reflects the status when the DPM Input area was updated by the
PROFINET IO Controller. The parameter usBitlistStartOffset specifies the offset in byte
from the beginning of the DPM Input Area where these lists shall be placed. The lists are always
present and cannot be deactivated. The following bit lists are defined:
Name Offset in DPM Input Area Description
Configured bit list usBitListStartOffset A bit is set to true if associated AR had been configured
Active bit list usBitListStartOffset + 16 A bit is set to true if associated AR is communicating
Diagnosis usBitListStartOffset + 32 A bit is set to true if associated AR is communicating and either a
diagnosis is pending or a configuration difference was detected
The offset of the bit corresponding to a particular AR can be derived from the device handle as
follows:
ByteOffset = (usDeviceHandle - 1) / 8
BitMask = 0x1 << ((usDeviceHandle -1 ) % 8)
Note: The bit list area and the input IOCR data are placed within the DPM Input Area. Thus
the application must ensure that the bit lists memory area does not overlap with input
IOCR data blocks.
Parameter usIoTimingInfoOffset
The PROFINET IO Controller firmware provides timing information about process data handling
using the PNM_AP_IOTIMINGINFO_T structure. This information can be placed in DPM input area
if required. This parameter configures the start offset of this data within the DPM input area. If the
offset is larger than the size of the DPM input area or the data does not fully fit into the DPM input
area the feature is disabled. Thus using a value 0xFFFF will disable this feature.
Note: This information is also provided in the DPM extended status block
/*
PNM_AP_CMD_CFG_GET_IOC_PRM_LIST_REQ
return all "ParameterTypes" that have been configured for IO Controller
*/
Packet description
struct PNM_AP_CFG_GET_IOC_PRM_LIST_CNF_DATA_Ttag
{
uint16_t uiPrmTypes[PNM_AP_MAX_IOC_PRM_TYPES];
uint16_t uiPrmTypesSize;
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 10 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009457 PNM_AP_CMD_CFG_GET_IOC_PRM_LIST_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_GET_IOC_PRM_LIST_CNF_DATA_T
uiPrmTypes[4] UINT16[] Array Type of parameter data, see Table 10: Parameter
usPrmType
uiPrmTypesSize UINT16 0…4 Size of the parameter data structure
Table 21. PNM_AP_CFG_GET_IOC_PRM_LIST_CNF_T confirmation
Parameter descriptions
Parameter uiPrmTypes
This parameter specifies an array containing type information about the parameter data
Parameter uiPrmTypesSize
This parameter specifies the size of the parameter data structure.
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 Handle
ulSrc UINT32 Handle
ulDestId UINT32 Any Set to zero for future compatibility
ulSrcId UINT32 0 -
ulLen UINT32 3 Packet Data Length in bytes
ulId UINT32 Any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x00009458 PNM_AP_CMD_CFG_GET_IOC_PRM_REQ
ulExt UINT32 any
ulRoute UINT32 any
Structure PNM_AP_CFG_GET_IOC_PRM_REQ_DATA_T
uiPrmType UINT16 1-8, 12, 13 Parameter type
bPortId UINT8 0-2 Port ID. The values have the following meaning:
0 = Interface,
1 = Port 0,
2 = Port 1
Table 22: PNM_AP_CFG_GET_IOC_PRM_REQ_T request
Parameter descriptions
Parameter uiPrmType
This parameter specifies the parameter type, see Table 10: Parameter usPrmType.
Parameter bPortId
Some records are related to a specific port of the controller. This parameter specifies the port ID of
that port.
/* parameter union */
typedef union PNM_AP_CFG_IOC_PRM_UNION_Ttag PNM_AP_CFG_IOC_PRM_UNION_T;
union PNM_AP_CFG_IOC_PRM_UNION_Ttag
{
PNM_AP_CFG_PRM_PDINTERFACEADJUST_T tIntfAdjust;
PNM_AP_CFG_PRM_SYNC_T tSyncData;
PNM_AP_CFG_PRM_IRDATA_GLOBAL_T tIrtGlobal;
PNM_AP_CFG_PRM_IRDATA_PHASES_T tIrtPhases;
PNM_AP_CFG_PRM_IRDATA_FRAME_T tIrtFrames;
PNM_AP_CFG_PRM_PDINTFMRPDATACHECK_T tIntfMRPDataCheck;
PNM_AP_CFG_PRM_PDINTFMRPDATAADJUST_T tIntfMRPDataAdjust;
PNM_AP_CFG_PRM_PDPORTMRPDATAADJUST_T tPortMRPDataAdjust;
PNM_AP_CFG_PRM_PDPORTDATA_ADJUST_T tPortDataAdjust;
PNM_AP_CFG_PRM_PDPORTDATA_CHECK_T tPortDataCheck;
PNM_AP_CFG_PRM_PDNCDATACHECK_T tNCDataCheck;
PNM_AP_CFG_PRM_ISOCHRONOUSCONTROLLERDATA_T tIsochronousControllerData;
};
struct PNM_AP_CFG_IOC_PRM_DATA_Ttag
{
/** structure version of this structure */
uint32_t ulStructVersion;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 See Table 24 Packet data length in bytes.
Depends on contents of usPrmType
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009459 PNM_AP_CMD_CFG_GET_IOC_PRM_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_IOC_PRM_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usPrmType UINT16 1 to 8, 12, 13 Parameter type (identifier)
bPortId UINT8 0 to 2 Reference of controller port to apply this parameters to
bPadding UINT8 0 Padding. Set to zero for future compatibility.
uData PNM_AP_CFG Parameter data
_IOC_PRM_U
NION_T
Table 23: PNM_AP_CFG_GET_IOC_PRM_CNF_T confirmation
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions to this structure.
Parameter bPortId
This parameter defines to which PD instance the parameter shall be applied:
Numerical value Meaning
0 Interface (submodule) of PROFINET IO Controller
1 Port 1 (submodule) of PROFINET IO Controller
2 Port 2 (submodule of PROFINET IO Controller
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 Handle
ulSrc UINT32 Handle
ulDestId UINT32 Any Set to zero for future compatibility
ulSrcId UINT32 0 -
ulLen UINT32 0 Packet Data Length in bytes
ulId UINT32 Any -
ulSta UINT32 0 Status unused for request. Set to zero.
ulCmd UINT32 0x00009450 PNM_AP_CMD_CFG_GET_NUM_CONFIGURED_OBJEC
TS_REQ
ulExt UINT32 any
ulRoute UINT32 any
Table 25: PNM_AP_CFG_GET_NUM_CONFIGURED_OBJECTS_REQ_T request
/*******************************************************************************
Packet description
Packet description
Parameter descriptions
Parameter ulStructVersion
Structure version of the configuration structure. Used for future extensions.
Parameter usDeviceHandle
This parameter specifies the handle of the AR to be configured.
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 210/290
3.6.5.2 PNM_AP_CFG_GET_IOD_CNF_T confirmation
enum PNM_AP_CFG_IOD_FLAG_Etag
{
/** the IO-Device supports WriteMultiple */
PNM_AP_CFG_IOD_FLAG_WRITE_MULTIPLE_SUPPORTED = 0x01,
/** IO Controller firmware shall not check parameters inside this request */
PNM_AP_CFG_IOD_FLAG_DISABLE_PRM_CHECK = 0x02,
/** The AR is initially disabled. If this flag is set, the profinet controller firmware
* will not establish this AR on startup */
PNM_AP_CFG_IOD_FLAG_DISABLED = 0x04,
PNM_AP_CFG_IOD_FLAG_MAX,
};
/* AR Types */
enum PNM_AP_CFG_IOD_AR_TYPE_Etag
{
/* standard AR Type for RT communication */
PNM_AP_CFG_IOD_AR_TYPE_SINGLE = 0x01,
/* IO Supervisor AR (with IO-data), not supported */
PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR = 0x06,
/* standard AR Type for IRT communication */
PNM_AP_CFG_IOD_AR_TYPE_RTC3 = 0x10,
/* SystemRedundancy AR, not supported */
PNM_AP_CFG_IOD_AR_TYPE_SYSTEMREDUNDANCY = 0x20,
};
/* AR Properties */
enum PNM_AP_CFG_IOD_AR_PROP_FLAGS_Etag
{
/* a supervisor is allowed to take over submodules of this AR */
PNM_AP_CFG_IOD_AR_PROP_FLAG_SUPERVISOR_TAKEOVER_ALLOWED = 0x00000008,
/** startup according to Profinet specification 2.3, if not set the legacy startup is
used */
PNM_AP_CFG_IOD_AR_PROP_FLAG_STARTUPMODE_ADVANCED = 0x40000000,
/* alarm type PULL MODULE is supported */
PNM_AP_CFG_IOD_AR_PROP_FLAG_PULL_MODULE_ALARM_ALLOWED = 0x80000000,
enum PNM_AP_DEVICEHANDLE_Etag
{
/** Device handle of the controller itself */
PNM_AP_DEVICEHANDLE_IOC = 0x0000,
/* RTA Retries */
#define PNM_AP_CFG_IOD_RTA_RETRIES_MIN (0x0003) /**< minimum value allowed
for RTA retries */
#define PNM_AP_CFG_IOD_RTA_RETRIES_MAX (0x000F) /**< maximum value allowed
for RTA retries */
Packet description
Parameter descriptions
Parameter ulStructVersion
Structure version of the configuration structure. Used for future extensions.
Parameter usDeviceHandle
This parameter specifies the handle of the AR to be configured.
Parameter bARType
This parameter describes the type of the AR.
Name Numeric value Meaning
PNM_AP_CFG_IOD_AR_TYPE_SINGLE 0x01 AR Type for RT communication
PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR 0x06 IO Supervisor AR (with IO-data), not supported
PNM_AP_CFG_IOD_AR_TYPE_RTC3 0x10 AR Type for IRT communication
PNM_AP_CFG_IOD_AR_TYPE_SYSTEMREDUN 0x20 SystemRedundancy AR, not supported
DANCY
Table 29: Parameter bARType - Type of the AR
Parameter bAddressMode
This parameter describes the possible modes of IP address resolution.
Name Numeric value Meaning
PNM_AP_CFG_IOD_ADDRESS_MODE_DCP_ 0 (default) In this mode, the controller discovers the device
IDENTIFY_ASSIGN using its station name or alias name (only if topology
info available) and will assign the configured IP
address if required.
PNM_AP_CFG_IOD_ADDRESS_MODE_DCP_ 1 The controller identifies the device using its station
DISCOVER name or alias name and will use the IP address
reported by the device. The IP address of device will
not be reassigned in this mode.
Please note that the Controller will not establish the
communication if the IP address set in IO Device is
set to zero or unreachable.
PNM_AP_CFG_IOD_ADDRESS_MODE_ARP_ 2 The controller discovers the device using its ip
DISCOVER address by means of ARP. No DCP is sent.
Table 30: Parameter bAddressMode - Modes of IP address resolution
Parameter tArUUID
Unique identifier of the AR. The AR UUID shall be generated by the engineering software or
application. It is a unique ID of the AR and must be non-zero.
Parameter ulArProperties
The parameter ulARProperties is a bitmask describing PROFINET Properties of this AR.
A combination of the following values is allowed:
Name Numeric Meaning
value
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x00000008 A supervisor is allowed to take over submodules of this AR.
SUPERVISOR_TAKEOVER_ALLOWED
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x00000100 AR is an device access AR, only valid in conjunction with
DEVICEACCESS PNM_AP_CFG_IOD_AR_TYPE_SUPERVISOR.
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x40000000 AR start-up is performed according to PROFINET
STARTUPMODE_ADVANCED specification 2.3 Advanced Startup Mode. (Extract from
GSDML file). If the bitmask is not set, then the PROFINET
V2.2 Startup Mode is used.
PNM_AP_CFG_IOD_AR_PROP_FLAG_ 0x80000000 The alarm type PULL MODULE is supported by the device.
PULL_MODULE_ALARM_ALLOWED (Extract from GSDML file)
Table 32: Parameter ulArProperties - Bitmask describing PROFINET Properties of the AR
Parameter usVendorID
VendorID to be used by IO Controller for addressing the IO Device. (Extract from GSDML file)
Parameter usDeviceID
DeviceID to be used by IO Controller for addressing the IO Device (Extract from GSDML file)
Parameter usInstanceID
The instance ID of the device. (Extract from GSDML file, Attribute "ObjectUUID Instance")
Parameter usMaxAlarmDataLength
The maximum length of payload data to be transported in an alarm. The minimum value is 200
byte and must be supported by any PROFINET Device. The upper limit of the PROFINET IO
Controller is 224 byte.
Parameter usRTARetries
Number of times an alarm shall be retried before giving up and aborting the AR, Default value is 3
Parameter abNameOfStation[240]
The parameter abNameOfStation is the PROFINET Name Of Station to be used for this AR. The
PROFINET IO Controller will establish the AR with a PROFINET IO Device with that
NameOfStation. If multiple devices with same NameOfStation exists no connection will be made.
The filed should be zero padded to full field length.
Parameter ulIPAddr
IP address to be assigned to the PROFINET IO Device. This IP Address Setting is to be specified
by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Parameter ulNetmask
Network Mask to be assigned to the PROFINET IO Device. This IP Address Setting is to be
specified by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Parameter ulGatewayAddr
Gateway Address to be assigned to the PROFINET IO Device. This IP Address Setting is to be
specified by the application and will be assigned to the PROFINET IO Device by the PROFINET IO
Controller on Startup.
Packet description
Parameter descriptions
Parameter uiDeviceHandle
This parameter specifies the handle of the AR to be configured.
#define PNM_AP_MAX_AR_PRM 4
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 10 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x0000945D PNM_AP_CMD_CFG_GET_AR_PRM_LIST_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_GET_AR_PRM_LIST_CNF_DATA_T
uiPrmTypes[4] UINT16 Array Type of parameter data, see Table 10: Parameter
usPrmType
uiPrmTypesSize UINT16 Size of the parameter data structure
Table 34: PNM_AP_CFG_GET_AR_PRM_LIST_CNF_T confirmation
Parameter descriptions
Parameter uiPrmTypes
This parameter specifies an array containing type information about the parameter data
Parameter uiPrmTypesSize
This parameter specifies the size of the parameter data structure.
/* PNM_AP_CFG_AR_PRM_IDENT_ARVENDORBLOCKREQ */
uint16_t uiVendorHandle;
/* PNM_AP_CFG_AR_PRM_IDENT_IRDATA */
/* Nothing */
};
Packet description
Parameter uiDeviceHandle
This parameter specifies the handle of the AR to be configured.
Parameter uiPrmTypes
This parameter specifies an array containing type information about the parameter data.
Parameter uiVendorHandle
This parameter specifies the handle to the AR vendor block to be configured.
enum PNM_AP_ARVENDORBLOCKHANDLE_Etag
{
/** The first handle value to use for AR Vendorblocks*/
PNM_AP_ARVENDORBLOCKHANDLE_FIRST = 0x0001,
/** The last handle value to use for AR Vendorblocks*/
PNM_AP_ARVENDORBLOCKHANDLE_LAST = 0x0100,
};
/* IR Data */
/* allowed values for field ulStructVersion */
#define PNM_AP_CFG_AR_PRM_IRDATA_STRUCT_VERSION_1 (0x0001)
typedef union
{
PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T tArVendorBlock;
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 221/290
PNM_AP_CFG_AR_PRM_IRDATA_T tIrData;
#ifdef PNM_SUPPORT_PARAMETER_SERVER
PNM_AP_CFG_AR_PRM_PARAMETERSERVER_BLOCK_T tPrmServerBlock;
#endif
} PNM_AP_CFG_AR_PRM_UNION_T;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 8+length(PNM_ Packet data length in bytes
AP_CFG_AR_PRM
_UNION_T)
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x0000945F PNM_AP_CMD_CFG_GET_AR_PRM_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_AR_PRM_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usDeviceHandle PNM_AP_DE 1 … 128 Handle of AR this AR Parameter belongs to
VICEHANDL
E_T
usIdentifier UINT16 0…2 Identifier for the type
uData PNM_AP_CF Parameter data
G_AR_PRM_
UNION_T
Table 36: PNM_AP_CFG_GET_AR_PRM_CNF_T confirmation
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter usDeviceHandle
Reference to the AR for which to configure the AR parameter for.
Structure PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T
Variable Type Value / Range Description
ulStructVersion UINT32 1 Structure version of this structure
usArVendorBlockHandle UINT16 1 to 256 Handle to this AR vendor block. This a
configuration wide unique handle. That means
different ARs must use different handles here.
usAPStructureIdentifier UINT16 0 to 0x7FFF, 0x8000 AP Structure Identifier according to GSDML
ulApi UINT32 any API according to GSDML
abData[] UINT8[] Byte array containing the AR VendorBlock data.
Size of this array depends on parameter
tHead.ulLen.
Allowed length of array: 0 (no data) - 512
Table 38: Structure PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T
/*
PNM_AP_CMD_CFG_GET_IOCR_REQ
return IOCR configuration of the requested IOCR
*/
PNM_AP_IOCR_HANDLE_T usIocrHandle;
};
Packet description
Structure PNM_AP_CFG_GET_IOCR_REQ_T Type: Request
Parameter ulStructVersion
Structure version of this structure. Used for future extensions of this structure.
Parameter usIocrHandle
The parameter usIocrHandle is a reference to the IOCR object whose configuration is to be
determined. The following values are defined
Minimum value Maximum value Usage
0x1000 0x103F Input IOCR for RT Class 1 / RT Class 3
0x1040 0x107F Input IOCR for RT Class 1
0x2000 0x203F Output IOCR for RT Class 1 / RT Class 3
0x2040 0x207F Output IOCR for RT Class 1
/** base address for the whole IO data of this IOCR in IO Controllers DPM input/output
area */
uint16_t usDpmOffset;
};
/*
PNM_AP_CMD_CFG_GET_IOCR_REQ
return IOCR configuration of the requested IOCR
*/
PNM_AP_IOCR_HANDLE_T usIocrHandle;
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 42 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009461 PNM_AP_CMD_CFG_GET_IOCR_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_IOCR_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usIocrHandle PNM_AP_IO 0x1000...0x107F,0 Unique handle of the IOCR to configure
CR_HANDLE x2000...0x207F
_T
usDeviceHandle PNM_AP_DE IO-Device handle (handle of the AR) the IOCR is
VICEHANDL associated with
E_T
ulFlags UINT32 0 Flags for future use, set to 0
ulIocrProp UINT32 1…3 Properties of the IOCR
usIocrType UINT16 1…3 Type of the IOCR
abMcastMACAddr[6 UINT8[] 00:00:00:00:00:00 Multicast MAC Address to be used for this IOCR.
] Reserved for future usage. Set to zero for compatibility.
usDataLen UINT16 1… 1440 Length of the data part of the IOCR without Frame Header
(% 4 == 0) and APDU Status (C_SDU Length).
Must be a multiple of 4.
usSendClockFact UINT16 8, 16, 32, 64, 128 Send Clock Factor to use for this IOCR.
(Only values equal to a power of 2 are allowed.)
usReductRatio UINT16 1 … 512 Reduction Ratio for this IOCR.
(Only values equal to a power of 2 are allowed.)
usPhase UINT16 1 … 512 Phase for this IOCR.
Must be smaller or equal usReductionRatio
usSequence UINT16 0 IOCR sequence number.
Currently unused. Set to zero for future compatibility
usDataHoldFact UINT16 1 … 7680 Data Hold Factor for this IOCR
ulFrameSendOffs UINT32 0 … 3999999 Frame send offset for RTC Class 3 IOCRs. Set to zero for
non RTC Class 3 IOCRs
usDpmOffset UINT16 0 … 5700 Base address for the whole IO data of this IOCR in IO
(% 4 == 0) Controllers DPM input/output area.
Must be 4-byte aligned.
Table 40: PNM_AP_CFG_GET_IOCR_CNF_T confirmation
The PROFINET IO Controller will internally generate the frame id of the Input IOCRs and RT Class
3 Output IOCRs based on the frame id value. For details see section Configuration of PROFINET
IO Controller on page 13.
Parameter ulIocrProp
The IOCR properties parameter ulIocrProp is a bit field describing the IOCR in more detail. The
following values are currently defined
Symbolic name Numeric value Usage
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1_LEGACY 0x01 RT_CLASS_1
PNM_AP_CFG_IOCR_PROP_RT_CLASS_1 0x02 RT_CLASS_1
PNM_AP_CFG_IOCR_PROP_RT_CLASS_3 0x03 RT_CLASS_3 (IRT)
Parameter usIocrType
This parameter determines the type of the IOCR. Due to the internal firmware structure the type is
determined by the IOCR's handle value.
Symbolic name Numeric value Usage
PNM_AP_CFG_IOCR_TYPE_INPUT 1 For Input IOCR with 0x1000 <= usIocrHandle <= 0x107F
PNM_AP_CFG_IOCR_TYPE_OUTPUT 2 For Output IOCR with 0x2000 <= usIocrHandle <= 0x207F
Parameter abMcastMacAddr
This parameter is reserved for future usage. Set to zero.
Parameter usDataLen
The length of data part of the IOCR is defined by this parameter. It determines how many byte the
PROFINET IO Controller firmware will copy to / from the DPM Input / Output Area for this IOCR.
Internally, the data exchange is restricted to 4 byte- aligned operations, thus the parameter
usDataLen must be a multiple of 4.
The PROFINET IO Controller will internally pad the IOCR data block (CSDU) to the minimum size
of 40 byte if a value smaller than 40 byte is specified. This does not affect the used memory space
in DPM area. E.g. if a usDataLen = 20 byte is specified, a block of 20 byte will be used in DPM and
the IOCR C_SDU length will be 40.
Figure 13: Definition of Send Clock Factor, Reduction Ration and Phase
Parameter usSequence
Currently not used. Set to zero for future compatibility.
Parameter usDataHoldFact
This parameter defines the timeout for the IOCR watchdog. If no IOCR data could be exchanged
for usDataHoldFact Data Cycle repetitions, the AR will be aborted with an timeout error. The Data
Hold Timeout time can be calculated as follows:
Data Hold Timeout =
(usDataHoldFact + 1) * usReductRatio * usSendclockFact * 31.25
[microseconds]
The maximum allowed value for the Data Hold Timeout is 1,92 seconds.
It is strongly recommended to set this timeout to a value greater or equal than 3. Lower values
might cause problems with occasional network transmission failures due to external
electromagnetic noise.
Parameter ulFrameSendOffs
This parameter defines the send offset of the IOCR frame in respect to send clock cycle start. It is
used in RT Class 3 mode. The parameter must match the corresponding value in the IR Data Sets
of the associated device. In RT Class 1 mode set this parameter to 0.
Parameter usDpmOffset
This parameter defines where the PROFINET IO Controller will take the data for an Output IOCR
from the DPM Output Area or to put the data of an Input IOCR into the DPM Input Area. The value
must be 4-byte aligned due to the internal implementation oft the PROFINET IO Controller. The
following image shows the relationships between the parameter usDPMOffset, usDataLen and the
DPM Area. The sum of usDPMOffset and usDataLen shall not exceed the length of DPM Area
(5700 byte for Output Image, 5652 byte for Input Image).
Figure 14: Memory mapping of IOCR data (CSDU) to DPM input/output area
/*
PNM_AP_CMD_CFG_GET_SUBMODULE_REQ
return submodule parameters of the requested submodule
*/
Packet description
Parameter ulStructVersion
Parameter usSubmoduleHandle
Handle for accessing the requested submodule.
/*
PNM_AP_CMD_CFG_GET_SUBMODULE_REQ
return submodule parameters of the requested submodule
*/
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 42 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009463 PNM_AP_CMD_CFG_GET_SUBMODULE_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_SUBMODULE_DATA_T
ulStructVersion UINT32 1 Structure version used for further extensions to this packet.
usSubmoduleHandl PNM_AP_SU 1...2048 Unique submodule handle
e BMODULE_ (can freely be defined by the user)
HANDLE_T
usDeviceHandle PNM_AP_DE 1...128 IO-Device handle the submodule belongs to
VICEHANDL
E_T
usInputIocrHandl PNM_AP_IO 0x1000...0x107F Consumer IOCR handle the submodule belongs to
e CR_HANDLE
_T
usOutputIocrHand PNM_AP_IO 0x2000...0x207F Provider IOCR handle the submodule belongs to
le CR_HANDLE
_T
ulModuleIdentNum UINT32 any Module identifier according to GSDML
ber
ulSubmoduleIdent UINT32 any Submodule identifier according to GSDML
Number
ulApi UINT32 API the submodule belongs to
usSlot UINT16 Slot the submodule is expected in
usSubslot UINT16 Subslot the submodule is expected in
usSubmodulePrope UINT16 Submodule flags
rties
usDataLenInput UINT16 0...1439 Length of the data this submodule provides according to
GSDML
usDataLenOutput UINT16 0...1439 Length of the data this submodule consumes according to
GSDML
usFrameOffsetInp UINT16 0...1439 Offset inside the frame where the input data of this
ut submodule shall reside
usFrameOffsetOut UINT16 0...1439 Offset inside the frame where the output data of this
put submodule shall reside
usIOCSFrameOffse UINT16 0...1439 Offset inside the frame where IOCS of input data of this
tInput submodule shall reside.
Note that this is an offset in the output IOCR
usIOCSFrameOffse UINT16 0...1439 Offset inside the frame where IOCS of output data of this
tOutput submodule shall reside.
Note that this is an offset in the input IOCR
Table 42: PNM_AP_CFG_GET_SUBMODULE_CNF_T confirmation
PROFINET IO Controller | Protocol API
DOC150403API06EN | Revision 6 | English | 2017-09 | Released | Public © Hilscher, 2015–2017
Application interface 236/290
Parameter descriptions
Parameter ulStructVersion
Parameter usSubmoduleHandle
The usSubmoduleHandle can be freely chosen from the user within the allowed range. It is a
globally unique handle associated with a submodule. Each submodule within the whole
configuration must be assigned an unique handle. This handle will be used in other services to
reference to the submodule. (E.g. Record Object Read/Write)
Parameter usDeviceHandle
The submodule will be associated with the AR referenced by usDeviceHandle. This is used
when establishing the connection with a PROFINET IO Device in order to verify the configuration
of this particular device.
Note: The Module ID of Submodules with same ulApi and ulSlot must be identical.
Parameter usSubmoduleProperties
The usSubmoduleProperties is a bit field describing various properties of the submodule. The
following flags are defined
Flag Numeric Usage
value
PNM_AP_CFG_SUBMODULE_PROPERTIES_INPUT 0x0001 Must be set if usDataLenInput > 0 or
usDataLenOutput == 0
PNM_AP_CFG_SUBMODULE_PROPERTIES_OUTPUT 0x0002 Must be set if usDataLenOutput > 0
Note: The record parameters are internally stored within a storage associated with the AR.
The storage has a limited size. Please refer to section Technical data on page 5 for
details on the available memory amount for startup record object parameterization.
Additionally to the record data, each parameter consumes some byte for management
information. Details are described in PNM_AP_CFG_RECORD_REQ_T request (page
71).
/*
shall return ONLY the following parameters
* PNM_AP_CFG_PRM_ISOCHRONOUSCONTROLLERDATA
* PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA
* PNM_AP_CFG_PRM_RECORD (to deliver this Type in Requestor has to provide the index)
PNM_AP_CMD_CFG_GET_RECORD_DATA_REQ
get records and parameters for a specific submodule
*/
#if 0
/** request packet */
typedef PNM_AP_EMTPY_PCK_T PNM_AP_CFG_GET_RECORD_DATA_REQ_T;
Packet description
struct PNM_AP_CFG_RECORD_DATA_Ttag
{
/** structure version of this structure */
uint32_t ulStructVersion;
/* the index of the record - defined in GSDML */
uint16_t usIndex;
/* the transfersequence value - defined in GSDML */
uint16_t usTransferSequence;
/** Array of Record Data, length of the data is derived from packet length */
uint8_t abRecordData[ARRAYS_OF_LENGTH_ZERO];
};
/*
shall return ONLY the following parameters
* PNM_AP_CFG_PRM_ISOCHRONOUSCONTROLLERDATA
* PNM_AP_CFG_PRM_ISOCHRONOUSMODEDATA
* PNM_AP_CFG_PRM_RECORD (to deliver this Type in Requestor has to provide the index)
PNM_AP_CMD_CFG_GET_RECORD_DATA_REQ
get records and parameters for a specific submodule
*/
#if 0
/** confirmation packet */
typedef struct PNM_AP_CFG_GET_RECORD_DATA_CNF_Ttag PNM_AP_CFG_GET_RECORD_DATA_CNF_T;
struct PNM_AP_CFG_GET_RECORD_DATA_CNF_Ttag
{
PNM_AP_PCK_HEADER_T tHead;
PNM_AP_CFG_RECORD_DATA_T tData;
};
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 mirrored -
ulSrc UINT32 mirrored -
ulDestId UINT32 mirrored -
ulSrcId UINT32 mirrored -
ulLen UINT32 8 + length of Packet data length in bytes
record data
ulId UINT32 mirrored
ulSta UINT32 0
ulCmd UINT32 0x00009465 PNM_AP_CMD_CFG_GET_RECORD_CNF
ulExt UINT32 mirrored
ulRoute UINT32 mirrored
Structure PNM_AP_CFG_RECORD_DATA_T
ulStructVersion UINT32 1 Structure version of this structure
usIndex UINT16 1 … 0x7FFF The index of the manufacturer specific record object
usTransferSequen UINT16 any The transfer sequence for the record object - defined in
ce GSDML
abRecordData[ARR UINT8[] any Array of record data
AYS_OF_LENGTH_ZE
RO]
Table 44: PNM_AP_CFG_GET_RECORD_DATA_CNF_T confirmation
Parameter descriptions
Parameter ulStructVersion
Version of this structure. Used for future extensions.
Parameter usIndex
The record object index of the record object to write. This parameter is provided in the GSDML file.
Parameter usTransferSequence
This parameter can be used to configure the order in which the record object shall be written. This
value is provided in the GSDML file of the PROFINET IO Device. The default value is 0.
Parameter abRecordData[]
This parameter contains the payload (the actual record data to be written). The length of the data is
determined from the packet length.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_READ_REQ_DATA_T tData;
} APIOC_READ_REQ_T;
Packet description
Structure PNM_AP_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Unused by Stack Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 18 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x0C1A PNIO_APCTL_CMD_READ_REQ
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure APIOC_READ_REQ_DATA_T
ulHandle UINT32 0, 1 to 128 Handle of the device to read the record from
ulApi UINT32 any API of the submodule to read the record from
ulDataLength UINT32 1 to 1024 Maximum amount of data to read from the submodule
usSlot UINT16 0 to 0xFFFF Slot of the submodule to read the record from
usSubSlot UINT16 0 to 0xFFFF Subslot of the submodule to read the record from
usIndex UINT16 0 to 0xFFFF Index of record object to read
Parameter descriptions
Parameter ulHandle
The handle of the (previously configured) device to read the record object from.
Parameter usIndex
The index of the record object to read.
Parameter ulDataLength
The maximum number of bytes to read from the object.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_READ_CNF_DATA_T tData;
} APIOC_READ_CNF_T;
Packet description
Structure PNM_PNIOAPCTL_PCK_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility
ulSrcId UINT32 mirrored
ulLen UINT32 28 to 1052 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page 276.
ulCmd UINT32 0x0C1B PNIO_APCTL_CMD_READ_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure APIOC_READ_CNF_DATA_T
ulHandle UINT32 mirrored Handle of the device the record was read from
ulPnio UINT32 any The PROFINET Status Code from the read operation
ulApi UINT32 mirrored API of the submodule the record was read from
ulDataLength UINT32 0 to 1024 Amount of data read from the record object
usSlot UINT16 mirrored Slot of the submodule the record was read from
usSubSlot UINT16 mirrored Subslot of the submodule the record was read from
usIndex UINT16 mirrored Index of record object read
usAddVal1 UINT16 any Additional value returned by PROFINET Device when
reading the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device when
reading the record object
usAlign UINT16 any Alignment. Ignore for future Compatibility
abReadData[] UINT8 The data read from the record object
Parameter ulHandle
The handle of the (previously configured) device the record object was read from.
Parameter usIndex
The index of the record object read.
Parameter ulDataLength
The number of bytes read from the record object
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if a PROFINET error
occurred during processing the read service. The error code is either generated by the PROFINET
IO Controller or by the associated PROFINET IO Device. Section PROFINET Status Code on page
279 describes the meanings of the PROFINET status code.
Parameter abReadData[]
This parameter contains the actual record data (payload) returned by the device.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_WRITE_REQ_DATA_T tData;
} APIOC_WRITE_REQ_T;
Packet description
Structure APIOC_READ_REQ_T Type: Request
Parameter ulHandle
The handle of the (previously configured) device to write the record object to
Parameter usIndex
The index of the record object to write.
Parameter ulDataLength
The number of bytes to write to the record object.
Parameter abWriteData[]
The data to write to the record object.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_WRITE_CNF_DATA_T tData;
} APIOC_WRITE_CNF_T;
Packet description
Structure PNM_PNIOAPCTL_PCK_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility
ulSrcId UINT32 mirrored
ulLen UINT32 22 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page 276.
ulCmd UINT32 0x0C1D PNIO_APCTL_CMD_WRITE_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure APIOC_WRITE_CNF_DATA_T
ulHandle UINT32 mirrored Handle of the device the record data was written to
ulPnio UINT32 any The PROFINET Status Code from the write operation
ulApi UINT32 mirrored API of the submodule the record was written to
usSlot UINT16 mirrored Slot of the submodule the record was written to
usSubSlot UINT16 mirrored Subslot of the submodule the record was written to
usIndex UINT16 mirrored Index of record object written
usAddVal1 UINT16 any Additional value returned by PROFINET Device when
writing the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device when
writing the record object
Parameter descriptions
Parameter ulHandle
The handle of the (previously configured) device the record data was written to.
Parameter usIndex
The index of the record object written.
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if an PROFINET error
occurred during processing the write service. The error code is either generated by the PROFINET
IO Controller or by the associated PROFINET IO Device. Section PROFINET Status Code on page
279 describes the meanings of the PROFINET status code.
Note: The service involves RPC Transactions which might timeout due to network problems
or unreachable devices. Due to these timeouts the confirmation packet might be
delayed by several seconds. This must be considered for the application
implementation.
Note: Only one Read implicit record service may be active at the same time. The application
must wait for the confirmation before the next read can be performed.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_READ_IMPL_REQ_DATA_T tData;
} APIOC_READ_IMPL_REQ_T;
Packet description
Structure PNM_PNIOAPCTL_PCK_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Unused by Stack Set to zero for future compatibility
ulSrcId UINT32 any -
ulLen UINT32 26 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x0C1E PNIO_APCTL_CMD_READ_IMPL_REQ
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure APIOC_READ_IMPL_REQ_DATA_T
ulIPAddr UINT32 any IP Address of the device to read the record from
usDeviceId UINT16 any PROFINET Device Id of the device to read the record from
usVendorId UINT16 any PROFINET Vendor Id of the device to read the record from
usInstanceId UINT16 any Instance Id of the device to read the record from
usReserved UINT16 0 Padding. Set to zero for future compatibility.
ulApi UINT32 any API of the submodule to read the record from
ulDataLength UINT32 1 to 1024 Maximum amount of data to read from the submodule
usSlot UINT16 0 to 0xFFFF Slot of the submodule to read the record from
usSubSlot UINT16 0 to 0xFFFF Subslot of the submodule to read the record from
usIndex UINT16 0 to 0xFFFF Index of record object to read
Parameter descriptions
Parameter ulIPAddr
The IP Address of the device to read the record object from.
Parameter usIndex
The index of the record object to read.
Parameter ulDataLength
The maximum number of bytes to read from the object.
typedef struct
{
PNM_PNIOAPCTL_PCK_HEADER_T tHead;
APIOC_READ_IMPL_CNF_DATA_T tData;
} APIOC_READ_IMPL_CNF_T;
Packet description
Structure PNM_PNIOAPCTL_PCK_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility
ulSrcId UINT32 mirrored
ulLen UINT32 24 … 1048 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page 276.
ulCmd UINT32 0x0C1F PNIO_APCTL_CMD_READ_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure APIOC_READ_IMPL_CNF_DATA_T
ulPnio UINT32 any The PROFINET Status Code from the read operation
ulApi UINT32 mirrored API of the submodule the record was read from
ulDataLength UINT32 0 … 1024 Amount of data read from the record object
usSlot UINT16 mirrored Slot of the submodule the record was read from
usSubSlot UINT16 mirrored Subslot of the submodule the record was read from
usIndex UINT16 mirrored Index of record object read
usAddVal1 UINT16 any Additional value returned by PROFINET Device when
reading the record object
usAddVal2 UINT16 any Additional value returned by the PROFINET Device when
reading the record object
usAlign UINT16 any Alignment. Ignore for future Compatibility
abReadData[] UINT8 The data read from the record object
Parameter descriptions
Parameter ulSta
Contains a non zero error code if the request was rejected by the PROFINET IO Controller. For
details on error codes refer to Status/Error codes.
Parameter usIndex
The index of the record object read.
Parameter ulDataLength
The number of bytes read from the record object
Parameter ulPnio
The PROFINET status code of the acyclic operation. This field is non-zero if an PROFINET error
occurred during processing the read service. The error code is either generated by the PROFINET
IO Controller or by the associated PROFINET IO Device. Section PROFINET Status Code on page
279 describes the meanings of the PROFINET status code.
Parameter abReadData[]
This parameter contains the actual record data returned by the device.
Note: The value of handles returned in the service confirmation are equal to the handles used
when configuring the devices using the Configure IO Device service on page 46.
Packet description
Parameter descriptions
Parameter ulParam
This parameter selects which list of slave handles shall be retrieved.
Name Numerical Meaning
value
RCX_LIST_CONF_SLAVES 0x00000001 Request the list of slave handles of configured slaves
RCX_LIST_ACTV_SLAVES 0x00000002 Request the list of slave handles of active (communicating) slaves
RCX_LIST_FAULTED_SLAVES 0x00000003 Request the list of slave handles of faulty slaves
Packet description
Parameter descriptions
Parameter aulHandle
The parameter aulHandle is an array containing the list of slave handles associated with the
request state. The number of entries in the list is determined by the packet length.
Note: The value of the handle used to specifiy the slave connection is equal to the value of
the handle used when configuring the device with the Configure IO Device service on
page 46.
Packet description
Structure TLR_PACKET_HEADER_T
ulDest UINT32 0x20 (LFW) -
Handle (LOM)
ulSrc UINT32 0 (LFW) -
Handle (LOM)
ulDestId UINT32 0 Set to zero for future compatibility.
ulSrcId UINT32 any -
ulLen UINT32 4 Packet data length in bytes
ulId UINT32 any -
ulSta UINT32 0 -
ulCmd UINT32 0x2F0A RCX_GET_SLAVE_CONN_INFO_REQ
ulExt UINT32 0 -
ulRoute UINT32 0 -
Structure RCX_PACKET_GET_SLAVE_CONN_INFO_REQ_DATA_T
ulHandle UINT32 The handle of the connection
Parameter descriptions
Parameter ulHandle
This parameter is the handle of the connection to retrieve the information for. Valid handles can be
retrieved using the Get Slave Handle service (see page 254) Furthermore the handle used in the
Configure IO Device service (see page 46) can be used.
enum PNM_AP_IOD_DIAGFLAG_Etag
{
/** the device does not exist in the network */
PNM_AP_IOD_DIAGFLAG_NOT_EXISTING = 0x00000001,
/** the device is not in cyclic dataexchange */
PNM_AP_IOD_DIAGFLAG_NOT_COMMUNICATING = 0x00000002,
/** Multiple stations with the ip or the name exist */
PNM_AP_IOD_DIAGFLAG_ADDRESS_CONFLICT = 0x00000004,
/** The device sent an faulty DCP response */
PNM_AP_IOD_DIAGFLAG_FAULTY_DCP = 0x00000008,
/** The device sent an RPC response with an error */
PNM_AP_IOD_DIAGFLAG_NEGATIVE_RPC = 0x00000010,
/** The device sent an RPC response with an error */
PNM_AP_IOD_DIAGFLAG_DEACTIVATED = 0x00000020,
/** Device has a module diff block identification related entries */
PNM_AP_IOD_DIAGFLAG_MODULEDIFF_WRONG_OR_MISSING = 0x00000800,
/** Device has a module diff block with diagnosis related entries */
PNM_AP_IOD_DIAGFLAG_MODULEDIFF_DIAGNOSIS = 0x00002000,
};
Packet description
Structure TLR_PACKET_HEADER_T
ulDest UINT32
ulSrc UINT32
ulDestId UINT32 0 Ignore for future compatibility.
ulSrcId UINT32 mirrored
ulLen UINT32 260 or 508 Packet data length in bytes
ulId UINT32 mirrored
ulSta UINT32 =0: no error
<> 0: see section Status codes / Error codes on page 276.
ulCmd UINT32 2F0B RCX_GET_SLAVE_CONN_INFO_CNF
ulExt UINT32 any Ignore
ulRoute UINT32 any Ignore
Structure RCX_PACKET_GET_SLAVE_CONN_INFO_CNF_DATA_T
ulHandle UINT32 Mirrored from request
ulStructID UINT32 0x2244, 0x2245 Identifier for the following data
Parameter descriptions
Parameter ulStructID
The parameter ulStructID denotes the type of the following data structure:
Name Numerical Meaning
value
- 0x2244 A structure of type PNM_AP_INACTIVE_SLAVE_CONNECT_INFO_T is appended to the
packet
- 0x2245 A structure of type PNM_AP_ACTIVE_SLAVE_CONNECT_INFO_T is appended to the packet
Structure PNM_AP_ACTIVE_SLAVE_CONNECT_INFO_T
ulLenName UINT32 1 … 240 Length of the NameOfStation
ulLenType UINT32 0 Length of the TypeOfStation. Always Zero, as not
supported
ulIPAddress UINT32 IP Address of the device
ulDiagFlags UINT32 Bitmask of diagnosis flags
usDeviceID UINT16 PROFINET Device ID of the device
usVendorID UINT16 PROFINET Vendor ID of the device
abMac[6] UINT8 Ethernet Mac Address of the device
usReserved UINT16 Reserved for future usage. Ignore
abName[240] UINT8 The NameOfStation
abType[240] UINT8 The TypeOfStation. For backwards compatibility. Not
supported.
Structure PNM_AP_INACTIVE_SLAVE_CONNECT_INFO_T
ulLenName UINT32 1 … 240 Length of the NameOfStation
ulDiagFlags UINT32 Bitmask of diagnosis flags
usDeviceID UINT16 PROFINET Device ID of the device
usVendorID UINT16 PROFINET Vendor ID of the device
abName[240] UINT8 The NameOfStation
Note: The application must generate a response packet for every Link Status Change
indication. If the response is not generated, no further Link Status Changed services
will be generated by the PROFINET IO Controller.
Packet description
Structure TLR_PACKET_HEADER_T
ulDest UINT32 Handle Ignore
ulSrc UINT32 Handle Ignore
ulDestId UINT32 0 Ignored. Set to zero for future compatibility.
ulSrcId UINT32 any Will contain value from ulSrcId from
RCX_REGISTER_APPLICATION_REQ request packet
ulLen UINT32 0 Ignore for future compatibility
ulId UINT32 32 Packet Data Length in bytes
ulSta UINT32 any Ignore
ulCmd UINT32 0 Zero in indication
ulExt UINT32 0x2F8A RCX_LINK_STATUS_CHANGE_IND
ulRoute UINT32 any Ignore
Structure RCX_LINK_STATUS_CHANGE_IND_DATA_T
atLinkData[2] STRUCT
Structure RCX_LINK_STATUS_T
ulPort UINT32 0 to 1 Number of the Port
fIsFullDuplex BOOL32 Non-Zero if Full Duplex Link used
fIsLinkUp BOOL32 Non-Zero if link is up
ulSpeed UINT32 0, 10, 100 Speed of the link in MBit/s
Parameter descriptions
Parameters atLinkData[2]
This parameter is an array of link status structures, one for each physical port.
Packet description
3.9 DPM
This section describes additional data structures used by the PROFINET IRT Controller firmware
for the DPM interface.
Structure reference
typedef __RCX_PACKED_PRE struct PNM_AP_EXTENDED_STATE_FIELD_DEFINITION_Ttag
{
PNM_AP_IOTIMINGINFO_T tIotimingInfo;
uint8_t abReserved[140];
NETX_EXTENDED_STATE_FIELD_T tExtStateField;
} __RCX_PACKED_POST PNM_AP_EXTENDED_STATE_FIELD_DEFINITION_T;
Structure description
Structure reference
typedef struct PNS_AP_TIMEINFO_Ttag PNS_AP_TIMEINFO_T;
Structure description
Parameter descriptions
Parameter ulCycleCounter
The value of the PROFINET Cycle Counter when the time measurement was taken
Parameter ulTimesinceCycleStart
The actual time of the event/state relative to the beginning of the bus cycle. The time is given in
nanoseconds.
Structure reference
typedef struct PNM_AP_IOTIMINGINFO_Ttag PNM_AP_IOTIMINGINFO_T;
Structure description
Structure PNM_AP_IOTIMINGNFO_T
tOutputUpdateStart PNS_AP_TI At this time the controller firmware started updating the
MEINFO_T transmit buffer from DPM output area
tOutputUpdateFinish PNS_AP_TI At this time the controller firmware finished updating
MEINFO_T the transmit buffer from DPM output area
tInputUpdateStart PNS_AP_TI At this time the controller firmware started updating the
MEINFO_T DPM input area from the receive buffer.
tInputUpdateFinish PNS_AP_TI At this time the controller firmware finished updating
MEINFO_T the DPM input area from the receive buffer.
Parameter descriptions
Parameter tOutputUpdateStart
This parameter represents the time when the PROFINET controller firmware starts copying the
data from the DPM output area into the transmit buffer. This happens when the host handshakes
the DPM output area.
Parameter tOutputUpdateFinish
This field is the time when the PROFINET controller firmware finished copying the data from the
DPM output area into the transmit buffer. The data will be transmitted in the next buscycle after the
given timepoint.
Note: The firmware does not handshake the DPM output area at this time
Parameter tInputUpdateStart
This parameter represents the time when the PROFINET controller firmware starts copying the
data from the receive buffers to the the DPM input area.
Note: This time is internally linked to the end of the IRT red phase. The host must have
handshaked the DPM input area prior to this time event in order for the copying to take
place.
Parameter tInputUpdateFinish
This field is the time when the PROFINET controller firmware finished copying the data from the
receive buffers to the the DPM input area. This event occurs right before the firmware handshakes
the DPM input area.
Please note that the image shows a bi-directional fragmented transfer for one service. In most
cases only one of request or confirmation will be fragmented. Also not shown in the image is the
usage of other bits in ulExt field.
4 Media Redundancy
4.1 Overview
Media Redundancy provides a means to recover in a short time from network cable breaks. The
PROFINET Standard defines the Media Redundancy Protocol (MRP) and Media Redundancy with
Planned Duplication of Frames (MRPD) for this purpose.
MRP ensures, when devices are connected in a ring topology, that frames do not circle in the ring
forever and a fast reconfiguring of the switch forwarding tables in case of a ring break is done. It
does not provide a reliable solution for bumpless media redundancy. That means that when a
cable break occurs, connections between the controller and the devices might be interrupted for a
short time.
MRPD requires MRP protocol to manage the ring topology and is an extension to IRT
communication. It provides bumpless media redundancy for IRT communication even in case of
synchronous applications. That means when the ring breaks, it is guaranteed that there will be no
communication abort and no synchronization loss.
Note: Using MRP Manager functionality is covered by patents. Please contact the
PROFINET User Organization for further details if the Hilscher PROFINET IO
Controller is configured for MRP Manager role.
In order to prevent accidental activation of MRP Manager role a License Bit for the
Security EEPROM has been implemented. The PROFINET Controller Firmware will
reject any Configuration where the PROFINET Controller is configured for MRP
Manager Role if this bit is not activated.
Note: MRPD is currently not supported by the Hilscher PROFINET IO Controller firmware.
4.2 Topologies
Generally, all devices which are connected in a ring topology must support the MRP protocol in
client mode. At least one device in the ring must support MRP Manager. The following image
shows the simple example of a MRP ring topology:
The image shows a ring manager connected with three ring clients in a ring topology. While it is
often the case, the ring manager and the profinet controller need not to be the same device. Each
device supporting ring manager capability can be configured as manager. It is also possible to
have multiple rings in a configuration as shown in the next image:
In such a case each ring must be assigned an individual MRP domain and own MRP domain
UUID. Rings must not be mixed, e.g. it is not allowed to share a network cable between two rings.
Manager parameters
Topology change 1 … 100 ms 10 ms The time interval between two topology change interval
Interval network frames. The topology change frame is used by the
MRP manager to indicate changes in topology (ring
break/close) to the MRP clients.
Topology change 1…5 5 The count how often the MRP manager will repeat the
repeat count topology change frame. This value multiplied with the
TOPNRmax topology change interval determines the delay between the
detection of the ring break and the reorganization of the
network switches.
Test short interval 1 … 500 ms 2 ms Short interval between ring test frames sent by the MRP
manager to detect the ring state. The short interval is used
when ever a ring transitions between closed or open state
occurs to verify the ring state.
Test default 1 … 1000 ms 10 ms Default interval between ring test frames sent by the MRP
interval manager to detect the ring state. The default interval is used
when the ring is in open or in closed state to detect changes
of the ring state.
Test NR Max 2 ... 10 3 The number of ring test frames which cause a state
TSTNRmax transition in MRP manager. E.g. when the ring breaks the
MRP manager will wait until Test NR max frames are not
passed through the ring before considering the ring as
broken. This value multiplied by the short test interval and
the default test interval determines the delay between the
physical ring break/close and the Ring manager considering
the ring as open/closed
Client parameters
Link Down 1 … 1000 ms 20 ms Time interval between two MRP link down frames sent by
Timeout the MRP client when a link down on a port occurs.
Link Up Timeout 1 … 1000 ms 20 ms Time interval between two MRP link up frames sent by the
MRP client when a link up on port occurs.
Link NR Max 1…5 5 The maximum number of Link/Down frames the MRP client
will sent while waiting for a reaction of the MRP manager.
Table 46 MRP parameter summary
5 LED
The following leds are defined for the PROFINET IO IRT Controller firmware:
SYS LED: Indicates the status of the system, colors: green, yellow
COM0 LED: BF LED (Bus Fail), color: red
COM1 LED: SF LED (System Fail), color: red
The table summarizes all available led states of the loadable firmware:
SYS SF BF Description
PROFINET communication
On, green Off or Flashing, red, Not all configured devices are in data exchange.
On, red 1 Hz
On, green On, red - One IO Device connected to the PROFINET IO Controller reports a
problem.
On, green Off Off All devices are in data exchange and no problem has been reported by
any device.
General requirements
The configuration of IO Controller firmware has to be set to “application-controlled startup”. The
application has to
register at the IO Controller firmware via Register Application Request (see reference [2])
handle the services for remanent data Load Remanent service (see page 81) and Store
Remanent service (see page 188)
use the Configure OEM Parameter service (see page 25) to set correct values for
identification information (e.g. OrderID, software version,…)
Moreover, a special GSDML file containing information on controller identification has to be
provided in order to be able to run automated test cases.
More recommendations
Experience shows that the application should display helpful diagnosis information for fault cases.
We therefore recommend supporting the following items:
Station diagnosis to indicate and support the following device states:
not connected
connected
has information on diagnosis
Use the Get Slave Connection Info service (see page 257) to get the device states.
Read request with a variable max. amount of data to be read from the submodule
Event logs from Controller and all devices using the Get Logbook Service (see page 156).
The time when the event occurs and the local machine time have to be synchronized.
AR Definition/description
0xC0CB0004 PNM_AP_CFG_INVALID_DEVICE_HANDLE
0xC0CB0005 PNM_AP_CFG_INVALID_SEND_CLOCK_FACTOR
0xC0CB0006 PNM_AP_CFG_INVALID_REDUCTION_RATIO
0xC0CB0007 PNM_AP_CFG_INVALID_DATA_HOLD_FACTOR
0xC0CB0008 PNM_AP_CFG_INVALID_PHASE
0xC0CB0009 PNM_AP_CFG_INVALID_FRAME_SEND_OFFSET
0xC0CB000A PNM_AP_CFG_INVALID_DOMAIN_NAME
0xC0CB000B PNM_AP_CFG_INVALID_UUID
0xC0CB000C PNM_AP_CFG_INVALID_NUMBER_OF_ENTRIES
IRT Definition/description
0xC0CB0024 PNM_AP_CFG_INVALID_PLL_WINDOW
0xC0CB0025 PNM_AP_CFG_INVALID_PTCTP_TIMEOUT
0xC0CB0026 PNM_AP_CFG_INVALID_TAKEOVER_TIMEOUT
0xC0CB0027 PNM_AP_CFG_INVALID_PTCP_STARTUP_TIME
0xC0CB0028 PNM_AP_CFG_INVALID_PTCP_MASTER_PRIO
0xC0CB0029 PNM_AP_CFG_INVALID_NUM_IRT_PHASES
0xC0CB002A PNM_AP_CFG_INVALID_NUM_IRT_FRAMES
0xC0CB002B PNM_AP_CFG_UNUSED
0xC0CB002C PNM_AP_CFG_INVALID_GREEN_PERIOD_BEGIN
0xC0CB002E PNM_AP_CFG_INVALID_ORANGE_PERIOD_BEGIN
0xC0CB002F PNM_AP_CFG_INVALID_FRAME_LENGTH
0xC0CB0030 PNM_AP_CFG_INVALID_LINE_DELAY
0xC0CB0031 PNM_AP_CFG_INVALID_PREAMBLE_LENGTH
0xC0CB0032 PNM_AP_CFG_INVALID_PARAMETER_FLAG
0xC0CB0033 PNM_AP_CFG_INVALID_PARAMETER_TYPE
FSU Definition/description
0xC0CB0034 PNM_AP_CFG_INVALID_FSU_MODE
0xC0CB0035 PNM_AP_CFG_INVALID_FS_HELLO_INTERVAL
0xC0CB0036 PNM_AP_CFG_INVALID_FS_HELLO_RETRY
0xC0CB0037 PNM_AP_CFG_INVALID_FS_HELLO_DELAY
0xC0CB0038 PNM_AP_CFG_INVALID_SYNC_MODE
0xC0CB0039 PNM_AP_CFG_INVALID_MAUTYPE_MODE
0xC0CB003A PNM_AP_CFG_INVALID_DOMAIN_BOUNDARY
0xC0CB003B PNM_AP_CFG_INVALID_DCP_BOUNDARY
0xC0CB003C PNM_AP_CFG_INVALID_PEERTOPEER_BOUNDARY
0xC0CB003D PNM_AP_CFG_INVALID_MULTIPLE_INTERFACE_MODE
0xC0CB003E PNM_AP_CFG_INVALID_MRP_INSTANCE
0xC0CB003F PNM_AP_CFG_INVALID_MRP_CHECK
0xC0CB0040 PNM_AP_CFG_INVALID_MRP_ROLE
0xC0CB0041 PNM_AP_CFG_INVALID_MRP_PARAMETERS
0xC0CB0042 PNM_AP_CFG_INVALID_MRP_MANAGER_PRIO
0xC0CB0043 PNM_AP_CFG_INVALID_MRP_TOPO_CHANGE_INTERVAL
0xC0CB0044 PNM_AP_CFG_INVALID_MRP_TOPO_REPEAT_COUNT
0xC0CB0045 PNM_AP_CFG_INVALID_MRP_SHORT_TEST_INTERVAL
0xC0CB0046 PNM_AP_CFG_INVALID_MRP_DEFAULT_TEST_INTERVAL
0xC0CB0047 PNM_AP_CFG_INVALID_MRP_TEST_MONITOR_COUNT
0xC0CB0048 PNM_AP_CFG_INVALID_MRP_LINK_DOWN_INTERVAL
0xC0CB0049 PNM_AP_CFG_INVALID_MRP_LINK_UP_INTERVAL
7.2 Sockets
Status code / Error code Definition/description
0x00000000 TLR_S_OK Status ok
0xC0C90001 TLR_E_SOCK_UNSUPPORTED_SOCKET Unsupported socket domain, type and
protocol combination.
0xC0C90002 TLR_E_SOCK_INVALID_SOCKET_HANDLE Invalid socket handle.
0xC0C90003 TLR_E_SOCK_SOCKET_CLOSED Socket was closed.
0xC0C90004 TLR_E_SOCK_INVALID_OP The command is invalid for the particular socket.
0xC0C90005 TLR_E_SOCK_INVALID_ADDRESS_FAMILY An invalid address family was used for this
socket
0xC0C90006 TLR_E_SOCK_IN_USE The specified address is already in use.
0xC0C90007 TLR_E_SOCK_HUP The remote side closed the connection.
0xC0C90008 TLR_E_SOCK_WOULDBLOCK The operation would block.
Table 49: Status codes / Error codes: Sockets
ErrorCode2
ErrorCode1
ErrorDecode
ErrorCode
The fields define a hierarchy on the error codes. The ordering is as follows:
ErrorCode,
ErrorDecode,
ErrorCode1 and
ErrorCode2.
The meaning of lower order fields depends on the values of the higher order fields.
Value 0x00000000 means no error or success.
Note: As the ErrorCode2 field can be freely chosen in this case, the application may use it to
provide more detailed information about the error (e.g. why writing the record into the
module was not possible, which value of the parameter was wrong…)
8 Appendix
8.1 List of tables
Table 1: List of revisions...................................................................................................................................................... 4
Table 2: Technical data ....................................................................................................................................................... 7
Table 3: Valid values of the device handle ........................................................................................................................ 14
Table 4: Valid values of the IOCR handle ......................................................................................................................... 14
Table 5: Internally generated frame id values ................................................................................................................... 14
Table 6: Valid values for a submodule handle................................................................................................................... 15
Table 7: Packet configuration sequence ........................................................................................................................... 16
Table 8: Definiton of OEM parameter types ...................................................................................................................... 28
Table 9: Definition of alarm handling flags ........................................................................................................................ 38
Table 10: Parameter usPrmType ...................................................................................................................................... 44
Table 11: Known values for fiber optic cable type ........................................................................................................... 106
Table 12: Known values for fiber optic type..................................................................................................................... 107
Table 13: RCX_GET_DEVICE_INFO_CNF_T - Get User Parameter Data Request......................................................... 173
Table 14: Device Handle for Device Access AR ............................................................................................................. 174
Table 15: Device Access AR Services ............................................................................................................................ 174
Table 16: Get configuration services ............................................................................................................................... 190
Table 17: PNM_AP_CFG_GET_IOC_REQ_T request ................................................................................................... 192
Table 18: PNM_AP_CFG_GET_IOC_CNF_T confirmation ............................................................................................ 195
Table 19: Definition of alarm handling flags .................................................................................................................... 196
Table 20: PNM_AP_CFG_GET_IOC_PRM_LIST_REQ_T request ................................................................................ 199
Table 21. PNM_AP_CFG_GET_IOC_PRM_LIST_CNF_T confirmation ......................................................................... 200
Table 22: PNM_AP_CFG_GET_IOC_PRM_REQ_T request.......................................................................................... 201
Table 23: PNM_AP_CFG_GET_IOC_PRM_CNF_T confirmation .................................................................................. 203
Table 24: Parameter usPrmType .................................................................................................................................... 205
Table 25: PNM_AP_CFG_GET_NUM_CONFIGURED_OBJECTS_REQ_T request ..................................................... 206
Table 26: PNM_AP_CFG_GET_NUM_CONFIGURED_OBJECTS_CNF_T confirmation .............................................. 207
Table 27: PNM_AP_CFG_GET_IOD_REQ_DATA_T request ........................................................................................ 209
Table 28: PNM_AP_CFG_GET_IOD_CNF_T confirmation ............................................................................................ 213
Table 29: Parameter bARType - Type of the AR ............................................................................................................ 213
Table 30: Parameter bAddressMode - Modes of IP address resolution ........................................................................ 213
Table 31: Parameter ulFlags - Flag bits specifying additional properties of the AR ..................................................... 214
Table 32: Parameter ulArProperties - Bitmask describing PROFINET Properties of the AR ................................... 214
Table 33: PNM_AP_CFG_GET_AR_PRM_LIST_REQ_T request ................................................................................. 216
Table 34: PNM_AP_CFG_GET_AR_PRM_LIST_CNF_T confirmation .......................................................................... 217
Table 35: PNM_AP_CFG_GET_AR_PRM_REQ_T request ........................................................................................... 218
Table 36: PNM_AP_CFG_GET_AR_PRM_CNF_T confirmation .................................................................................... 221
Table 37: Parameters usIdentifier, uData .............................................................................................................. 222
Table 38: Structure PNM_AP_CFG_AR_PRM_ARVENDORBLOCK_T .................................................................................. 222
Table 39: PNM_AP_CFG_GET_IOCR_REQ_T request ................................................................................................. 223
Table 40: PNM_AP_CFG_GET_IOCR_CNF_T confirmation .......................................................................................... 227
Table 41: PNM_AP_CFG_GET_SUBMODULE_REQ_T request ................................................................................... 231
Table 42: PNM_AP_CFG_GET_SUBMODULE_CNF_T confirmation ............................................................................ 235
Table 43: PNM_AP_CFG_GET_RECORD_DATA_REQ_T request ............................................................................... 238
Table 44: PNM_AP_CFG_GET_RECORD_DATA_CNF_T confirmation ........................................................................ 240
Table 45: Services using packet fragmentation............................................................................................................... 268
Table 46 MRP parameter summary ................................................................................................................................ 271
Table 47: PROFINET IO Controller LED status (Loadable firmware) .............................................................................. 273
Table 48: Status codes / Error codes: PROFINET IO Controller ..................................................................................... 278
Table 49: Status codes / Error codes: Sockets ............................................................................................................... 279
Table 50: Coding of PNIO Status ErrorCode (Excluding reserved Values) ..................................................................... 280
Table 51: Coding of PNIO status ErrorDecode (Excluding reserved Values) .................................................................. 280
Table 52: Coding of ErrorCode1 for ErrorDecode = PNIORW (Excluding reserved Values)........................................... 281
Table 53: Coding of ErrorCode1 for ErrorDecode = PNIO (Excluding reserved Values)................................................. 287
8.3 Contacts
Headquarters
Germany
Hilscher Gesellschaft für
Systemautomation mbH
Rheinstrasse 15
65795 Hattersheim
Phone: +49 (0) 6190 9907-0
Fax: +49 (0) 6190 9907-50
E-Mail: info@hilscher.com
Support
Phone: +49 (0) 6190 9907-99
E-Mail: de.support@hilscher.com
Subsidiaries
China Japan
Hilscher Systemautomation (Shanghai) Co. Ltd. Hilscher Japan KK
200010 Shanghai Tokyo, 160-0022
Phone: +86 (0) 21-6355-5161 Phone: +81 (0) 3-5362-0521
E-Mail: info@hilscher.cn E-Mail: info@hilscher.jp
Support Support
Phone: +86 (0) 21-6355-5161 Phone: +81 (0) 3-5362-0521
E-Mail: cn.support@hilscher.com E-Mail: jp.support@hilscher.com
France Korea
Hilscher France S.a.r.l. Hilscher Korea Inc.
69500 Bron Seongnam, Gyeonggi, 463-400
Phone: +33 (0) 4 72 37 98 40 Phone: +82 (0) 31-789-3715
E-Mail: info@hilscher.fr E-Mail: info@hilscher.kr
Support
Phone: +33 (0) 4 72 37 98 40 Switzerland
E-Mail: fr.support@hilscher.com Hilscher Swiss GmbH
4500 Solothurn
India Phone: +41 (0) 32 623 6633
Hilscher India Pvt. Ltd. E-Mail: info@hilscher.ch
Pune, Delhi, Mumbai Support
Phone: +91 8888 750 777 Phone: +49 (0) 6190 9907-99
E-Mail: info@hilscher.in E-Mail: ch.support@hilscher.com
Italy USA
Hilscher Italia S.r.l. Hilscher North America, Inc.
20090 Vimodrone (MI) Lisle, IL 60532
Phone: +39 02 25007068 Phone: +1 630-505-5301
E-Mail: info@hilscher.it E-Mail: info@hilscher.us
Support Support
Phone: +39 02 25007068 Phone: +1 630-505-5301
E-Mail: it.support@hilscher.com E-Mail: us.support@hilscher.com