User`s manual

Software Manual • EKF Intelligent I/O Controller Family On
CompactPCI
- 114 -
EKF Elektronik GmbH * Philipp-Reis-Str. 4 * D-59065 HAMM (Germany)
Tel. +49 (0)2381/6890-0 * Fax. +49 (0)2381/6890-90 * E-Mail info@ekf.de * Internet http://www.ekf.de
Get CANbus Controller Register: CMDIMR_GET_REG_CAN
Description:
This command is used to get the current value of a register from the
SJA1000 CANbus controller of a CANbus port specified by the port
identifier.
Command Code:
46.
Command Data:
The controller’s register number is passed in bits 15:08.
Parameters:
None.
Data:
None.
Command Word:
0x0Y2E RR00
Flags Port ID Command Command Data
E
R
R
R
P
L
C
P
L
U
F
ID
3
ID
2
ID
1
ID
0
C
7
C
6
C
5
C
4
C
3
C
2
C
1
C
0
D
15
D
14
D
13
D
12
D
11
D
10
D
09
D
08
D
07
D
06
D
05
D
04
D
03
D
02
D
01
D0
0
0000YYYY00101110RRRRRRRR00000000
31 28 27 24 23 16 15 8 7 0
Reply:
Flags Port ID Command Command Data
E
R
R
R
P
L
C
P
L
U
F
ID
3
ID
2
ID
1
ID
0
C
7
C
6
C
5
C
4
C
3
C
2
C
1
C
0
D
15
D
14
D
13
D
12
D
11
D
10
D
09
D
08
D
07
D
06
D
05
D
04
D
03
D
02
D
01
D0
0
X110YYYY00101110RRRRRRRRDDDDDDDD
31 28 27 24 23 16 15 8 7 0
The controller returns the current register contents in bits 07:00 with the
RPL and CPL flags set. The value can be gotten by the .reg.data
member of the command word union EKF_IMR_COMMAND.
On error the RPL, CPL and ERR flags are set and an error code is
passed in bits 15:00 of the reply word.
Notes:
Absolutely caution should be given when using this command. In fact
most of the SJA1000 CANbus controller’s register could be read
anytime, but for example the Interrupt Register IR may change its
contents on a read access without knowledge of the firmware. Thus you
should be familiarly with the function of the SJA1000 CANbus controller
to avoid data lost or locking conditions.