MCP2502X/5X
DS2
1664D-page
26
20
07
M
ic
rochip
T
c
hnology
In
c
.
TABLE 4-3:
COMMAND MESSAGES (EXTENDED IDENTIFIER)
Information Request Messages (to MCP2502X/5X)
Standard ID
Extended ID
Data Bytes
1
0
9 8765 4321 0R
T
R
I
D
E
DLC
1
7
1
6
RXBEID8
(8 bits)
RXBEID0
(8 bits)
Read A/D Regs
x x xxxx xxxx x 11 1 0 0 0 8* x x
xxxx xxxx
xxxx *000
n/a
Read Control Regs
x x xxxx xxxx x 11 0 1 1 1 7* x x
xxxx xxxx
xxxx *001
n/a
Read Config Regs
x x xxxx xxxx x 11 0 1 0 1 5* x x
xxxx xxxx
xxxx *010
n/a
Read CAN Error
x x xxxx xxxx x 11 0 0 1 1 3* x x
xxxx xxxx
xxxx *011
n/a
Read PWM Config
x x xxxx xxxx x 11 0 1 1 0 6* x x
xxxx xxxx
xxxx *100
n/a
Read User Mem
x x xxxx xxxx x 11 1 0 0 0 8* x x
xxxx xxxx
xxxx *101
n/a
Read User Mem
x x xxxx xxxx x 11 1 0 0 0 8* x x
xxxx xxxx
xxxx *110
n/a
Read Register
x x xxxx xxxx x 1 1 0 0 0 0 1* x x
addr
xxxx *111
n/a
Output Messages (from MCP2502X/5X)
Standard ID
Extended ID
Data Bytes
1
0
9876 5432 1 0 R
T
R
I
D
E
DLC
1
7
1
6
RXBEID8
(8 bits)
RXBEID0
(8 bits)
Read A/D Regs
x xxxx xxxx x x 01 1 0 0 0 8
x x xxxx xxxx
xxxx *000
IOINTFL
GPIO
AN0H
AN1H
AN10L
AN2H
AN3H
AN32L
Read Control Regs
x xxxx xxxx x x 01 0 1 1 1 7
x x xxxx xxxx
xxxx *001
ADCON0
ADCON1
OPTREG
STCON
IOINTEN
IOINTPO
n/a
Read Config Regs
x xxxx xxxx x x 01 0 1 0 1 5
x x xxxx xxxx
xxxx *010
DDR
GPIO
CNF1
CNF2
CNF3
n/a
Read CAN Error
x xxxx xxxx x x 01 0 0 1 1 3
x x xxxx xxxx
xxxx *011
EFLG
TEC
REC
n/a
Read PWM Config
x xxxx xxxx x x 01 0 1 1 0 6
x x xxxx xxxx
xxxx *100
PR1
PR2
T1CON
T2CON
PWM1D
PWM2D
n/a
Read User Mem
x xxxx xxxx x x 01 1 0 0 0 8
x x xxxx xxxx
xxxx *101
USERID0 USERID1 USERID2 USERID3 USERID4 USERID5 USERID6 USERID7
Read User Mem
x xxxx xxxx x x 01 1 0 0 0 8
x x xxxx xxxx
xxxx *110
USERID8 USERID9 USERID1 USERID1 USERID1 USERID1 USERID1 USERID1
Read Register
x xxxx xxxx x x 0 1 0 0 0 0 1x x
addr
xxxx *111
value
n/a
Input Messages (to MCP2502X/5X)
Standard ID
Extended ID
Data Bytes
1
0
9876 5432 1 0 R
T
R
I
D
E
DLC
1
7
1
6
RXBEID8
(8 bits)
RXBEID0
(8 bits)
Write Register
x xxxx xxxx x x 0 1 0 0 1 1 3
x x xxxx xxxx
xxxx x000
addr
mask
value
n/a
Write TX Message
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x001
TX0SIDH
TX0SIDL
TX0EID8
TX0EID0
n/a
Write TX Message
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x010
TX1SIDH
TX1SIDL
TX1EID8
TX1EID0
n/a
Write TX Message
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x011
TX2SIDH
TX2SIDL
TX2EID8
TX2EID0
n/a
Write I/O Configura- x xxxx xxxx x x 0 1 0 1 0 1 5
x x xxxx xxxx
xxxx x100
IOINTEN
IOINTPO
DDR
OPTREG
ADCON1
n/a
Write RX Mask
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x101
RXM-
RXMSIDL RXMEID8 RXMEID0
n/a
Write RX Filter0
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x110
RXF0SID
RXF0EID
n/a
Write RX Filter1
x xxxx xxxx x x 0 1 0 1 0 0 4
x x xxxx xxxx
xxxx x111
RXF1SID
RXF1EID
n/a
* If using non-RTR messages for information request messages (IRM), the RTR bit = 0, DLC bit field = 0, and bit 3 of the IRM ID = 1. Also, bit 3 of the output message ID = 0.
If using RTR messages for IRMs, the RTR bit = 1, DLC bit field = number of bytes in corresponding output message, and bit three of the IRM ID = x (don’t care), also, bit 3 of the
output message = x (don’t care).
** User-defined IRM IDs must be different from input message IDs to avoid message contention between the corresponding output message and the input message.