Lenze PLC Designer PLC Designer (R2-x) CANopen for Runtime Systems User Manual
Page 43
 
L-force | PLC Designer - CANopen for Runtime Systems
CanDevice
42
DMS 2.0 EN 05/2009 TD29
3.6.4 Sending emergency messages by the application program
In order to transmit an emergency message via the application program, function block 
SEND_EMERGENCY can be used. 
The module has the following interface:
VAR_INPUT
ENABLE : BOOL;
* As long as Enable is TRUE, with each call an emergency message 
is transmitted.*) 
ErrorCode : WORD; (* Error code; according to CANopen some values are already pre-
defined. (See table below.)*)
ErrorRegister : BYTE; (* The error register is content of object 1001h.*) 
ManufacturerErrorField : ARRAY[0..4] OF BYTE; (* Here the application can define its own 
error codes.*)
DeviceIndex : INT;
(* The 0-based index of the device, which should send the 
emergency messages.*) 
END_VAR
VAR_OUTPUT
bReady : BOOL;
(* As soon as the message has been sent, bReady gets FALSE.*)
END_VAR
 
Table with error codes, from DSP301: 
00xx Error Reset or No Error 
10xx Generic Error 
20xx Current 
21xx Current, device input side 
22xx Current inside the device 
23xx Current, device output side 
30xx Voltage 
31xx Mains Voltage 
32xx Voltage inside the device 
33xx Output Voltage 
40xx Temperature 
41xx Ambient Temperature 
42xx Device Temperature 
50xx Device Hardware 
60xx Device Software 
61xx Internal Software 
62xx User Software 
63xx Data Set 
70xx Additional Modules 
80xx Monitoring 
81xx Communication 
8110 CAN Overrun (Objects lost) 
8120 CAN in Error Passive Mode 
8130 Life Guard Error or Heartbeat Error 
8140 recovered from bus off 
8150 Transmit COB-ID 
82xx Protocol Error 
8210 PDO not processed due to length error 
8220 PDO length exceeded 
90xx External Error 
F0xx Additional Functions 
FFxx Device specific