Function to read status information of the indicated workstation.
|
i32 co_get_ws_diagno (i32 nWs)
|
|
Robox station ID (logical workstation 1-:-64).
Note: If 0 is specified as ws then it is meant for all.
|
|
Returns the status code. The meaning of the bits that make up the status code is:
|
|
|
0
|
0x00000001
|
Rx PDO 1 missing.
|
1
|
0x00000002
|
Rx PDO 2 missing
|
2
|
0x00000004
|
Rx PDO 3 missing
|
3
|
0x00000008
|
Rx PDO 4 missing
|
4
|
0x00000010
|
Rx PDO 1 received before time
|
5
|
0x00000020
|
Rx PDO 2 received before time
|
6
|
0x00000040
|
Rx PDO 3 received before time
|
7
|
0x00000080
|
Rx PDO 4 received before time
|
8
|
0x00000100
|
Ws mandatory missing
|
9
|
0x00000200
|
Missing ws
|
10
|
0x00000400
|
Last RTR request failed
|
11
|
0x00000800
|
Ws presence imposed
|
12
|
0x00001000
|
Ws reconfiguration
|
13
|
0x00002000
|
Error during configuration
|
14
|
0x00004000
|
-
|
15
|
0x00008000
|
-
|
16
|
0x00010000
|
Emergency message present
|
17
|
0x00020000
|
No communication (in operational mode)
|
18
|
0x00040000
|
Ws type: mandatory
|
19
|
0x00080000
|
Ws type: rechargeable at connection
|
20
|
0x00100000
|
Satisfactory configuration performed
|
21
|
0x00200000
|
Ws not connected to the first configuration
|
22
|
0x00400000
|
Problem during configuration of an SDO command
|
23
|
0x00800000
|
Problem during configuration of an NMT command
|
24
|
0x01000000
|
Configuration performed
|
25
|
0x02000000
|
SI in which data is read/write (only on physical CANbus devices)
|
26
|
0x04000000
|
-
|
27
|
0x08000000
|
-
|
28
|
0x10000000
|
-
|
29
|
0x20000000
|
-
|
30
|
0x40000000
|
Ws not started
|
31
|
0x80000000
|
Ws undefined
|
|
|
Rule, Task
|
|
Returns the same information as the d_co_wsdiagno command from RDE shell
|
Example usage:
int canDiagno2, canDiagno3
canDiagno2 = co_get_ws_diagno(2)
canDiagno3 = co_get_ws_diagno(3)
|
|