Functions
5.2 CAN transparent
SIMATIC PN/CAN LINK
70 Operating Instructions, 03/2022, A5E39895388-AC
5.2.5 Cyclic data exchange between controller and PN/CAN LINK for configured
CAN messages
CAN messages with PROFINET output data (transmit messages)
"Transmit messages" can be configured in the TIA Portal. Each of these messages has its own
message ID, which is configured in the TIA Portal, and its own data, which is transmitted
cyclically to the PN/CAN LINK via PROFINET in the output process image of the S7 controller.
The PN/CAN LINK sends a CAN message with the message ID and the current data:
• When the data changes
• When a CAN RTR frame (Remote Transmit Request) has been received with the matching
message ID
• During transition of the PN/CAN LINK to "ON" state
• Cyclically, if configured accordingly
The triggers are independent of one another. That is, the configured transmit cycle is
retained even if a message based on a data change or an RTR has been sent in the interim.
If configured, the PN/CAN LINK changes the order of specific data bytes for fixed CAN
messages prior to sending to compensate for the different "endianness" of PROFINET and
CAN. PROFINET uses "Big Endian", CAN usually uses "Little Endian". In the case of
programmed CAN messages, however, the order of the data bytes is not changed.
CAN messages with PROFINET input data (receive messages)
"Receive messages" can be configured in the TIA Portal. Each of these messages has its own
message ID, which is configured in the TIA Portal, and its own data, which is transmitted
cyclically from the PN/CAN LINK to the S7 controller via PROFINET as part of the input process
image.
The values of the input data are assigned during configuration of the PN/CAN LINK by the S7
controller according to the configuration.
If a CAN frame with the configured message ID has been received, the order of the data bytes
is first changed, if necessary, to correct the "endianness" before the data is transferred to the
input data for the S7 controller.
A setting can be made during configuration so that the PN/CAN LINK transmits an RTR frame
with the configured message ID during transition to the PN/CAN LINK state "ON" on the CAN
bus. This frame requests that the associated counterpart sends the corresponding data
message.
As soon as a PN/CAN LINK changes to "ON" state, it monitors the receipt of CAN messages of
all configured message IDs and transmits information about them, compressed into one
status bit, to the S7 controller. As long as there is at least one configured message ID from
which a CAN message has not yet been received, a zero is transmitted to the S7 controller in
the status bit.