Download Print this page

Renesas M16C/50 Series User Manual page 603

Advertisement

M16C/5L Group, M16C/56 Group
23.1.9
CAN0 Message Control Register (C0MCTLj) (j = 0 to 31)
CAN0 Message Control Register j
b7 b6 b5 b4
b3
b2
b1
Notes:
1. Write to the C0MCTLj register in CAN operation mode or CAN halt mode.
2. Do not use registers C0MCTL24 to C0MCTL31 in FIFO mailbox mode.
3. Write 0 only. Writing 1 has no effect.
4. When writing 0 to bits NEWDATA, SENTDATA, MSGLOST, TRMABT, RECREQ, and TRMREQ by a program,
use the MOV instruction to ensure that only the specified bit is set to 0 and the other bits are set to 1.
5. To enter one-shot receive mode, write 1 to the ONESHOT bit at the same time as setting the RECREQ bit to 1.
To exit one-shot receive mode, write 0 to the ONESHOT bit after writing 0 to the the RECREQ bit and confirming
it has been set to 0.
To enter one-shot transmit mode, write 1 to the ONESHOT bit at the same time as setting the TRMREQ bit to 1.
To exit one-shot transmit mode, write 0 to the ONESHOT bit after the message has been transmitted or aborted.
6. Do not set both the RECREQ and TRMREQ bits to 1.
7. When setting the RECREQ bit to 0, set bits MSGLOST, NEWDATA, RECREQ to 0 simultaneously.
Figure 23.10 C0MCTLj Register
R01UH0127EJ0110 Rev.1.10
Sep 01, 2011
b0
Symbol
C0MCTL0 to C0MCTL31
Bit Symbol
When the TRMREQ bit is 0 and the RECREQ bit is 1
Reception Complete
NEWDATA
(3, 4)
Flag
Reception-in-Progress
INVALDATA
Status Flag
MSGLOST
Message Lost Flag
When the TRMREQ bit is 1 and the RECREQ bit is 0
Transmission Complete
SENTDATA
(3, 4)
Flag
Transmission-in-Progress
TRMACTIVE
Status Flag
Transmission Abort
TRMABT
Complete Flag
No register bit; If necessary, set to 0. The read value is 0.
(b3)
ONESHOT
One-shot Enable Bit
No register bit; If necessary, set to 0. The read value is 0.
(b5)
Receive Mailbox
RECREQ
Set Bit
Transmit Mailbox
TRMREQ
Set Bit
(1, 2)
(j = 0 to 31)
Address
D7A0h to D7BFh
Bit Name
0: No data has been received or
0 is written to the NEWDATA bit
1: A new message is being stored
or has been stored to the mailbox
0: Message valid
1: Message being updated
0: Message is not overwritten or
(3, 4)
overrun
1: Message is overwritten or overrun
0: Transmission is not completed
(pending)
1: Transmission is completed
(success)
0: Transmission is pending or
transmission is not requested
1: From acceptance of transmission
request to completion of
transmission, or error/arbitration
lost
0: Transmission has started,
transmission abort failed because
transmission is completed, or
(3, 4)
transmission abort is not requested
1: Transmission abort is completed
0: One-shot reception or one-shot
transmission disabled
(5)
1: One-shot reception or one-shot
transmission enabled
0: Not configured for reception
(4, 6, 7)
1: Configured for reception
0: Not configured for transmission
(4, 6)
1: Configured for transmission
23. CAN Module
Reset Value
00h
Function
RW
RW
RO
RW
RW
RO
RW
RW
RW
RW
Page 566 of 803

Advertisement

loading