Receiving a user defined CAN message
Section 4-6
44
Note
The C200HW-CORT21 ignores bits 11 to 15 of word n.
If no other node is connected to the network or the CAN interface of the Unit
is in error, the C200HW-CORT21 will not be able to transmit the message. In
that case error code 0448 is added to the error log for each message that the
Unit is unable to transmit.
Example
The following example shows how two bytes are transmitted with identifier 0.
In this example, the Machine number is set to ‘1’.
13.00
IOWR (-)
TX_data
#0003
DM0400
#1003
255.06
12.00
EQ_FLAG
ERROR
PLC memory address
Contents
DM0400
0000
DM0401
0002
DM0402
0201
4-6
Receiving a user defined CAN message
Control code #0004
The C200HW-CORT21 enables to receive an arbitrary CAN message with a
combination of the IOWR instruction and the I/O refresh.
The frame of a CAN message is shown in the picture below.
*
Identifier (11 bits)
*
Data length (DLC)
Data byte 1
Data byte 8
*
* Frame control bits, not important for this function
The IOWR instruction is used to indicate to the Unit which identifier(s) to
receive and to which PLC area the received message must be transferred.
The figure below shows the IOWR message structure.
IOWR message structure
word n
Minimum identifier [hex]
range: 0000h ~ 07FFh
word n+1
Maximum identifier [hex]
range: 0000h ~ 07FFh
word n+2
Identifier mask [hex]
range: 0000h ~ 07FFh
word n+3
PLC start address
Содержание C200HW-CORT21
Страница 1: ...C200HW CORT21 CAN Unit OPERATION MANUAL Cat No W904 E2 1...
Страница 2: ......
Страница 3: ......
Страница 4: ......
Страница 5: ...C200HW CORT21 CAN Unit Operation Manual Produced July 2000...
Страница 6: ...iv...
Страница 8: ...vi...
Страница 10: ...viii...
Страница 12: ...x...
Страница 24: ...Performance Section 1 3 22...
Страница 40: ...LEDs 7 Segment Display Section 3 3 38...
Страница 56: ...Maintenance Section 5 3 54...
Страница 58: ...56...
Страница 60: ......