h8s-2646 Renesas Electronics Corporation., h8s-2646 Datasheet - Page 608

no-image

h8s-2646

Manufacturer Part Number
h8s-2646
Description
Renesas 16-bit Single-chip Microcomputer H8s Family/h8s/2600 Series
Manufacturer
Renesas Electronics Corporation.
Datasheet
Section 15 Controller Area Network (HCAN)
• Message transmission completion and interrupt
• Message transmission cancellation
• Message retransmission
Rev. 5.00 Sep 22, 2005 page 582 of 1136
REJ09B0257-0500
mailbox 1 > mailbox 15). CAN bus arbitration is then carried out for the messages in the
transmit buffer, and message transmission is performed when the bus is acquired.
When b is selected, if a number of messages are designated as waiting for transmission (TXPR
= 1), the message with the highest priority set in the message identifier (MCx[5] to MCx[8]) is
stored in the transmit buffer. CAN bus arbitration is then carried out for the message in the
transmit buffer, and message transmission is performed when the transmission right is
acquired. When the TXPR bit is set, internal arbitration is performed again, the highest-priority
message is found and stored in the transmit buffer, CAN bus arbitration is carried out in the
same way, and message transmission is performed when the transmission right is acquired.
When a message is transmitted error-free using the above procedure, The corresponding
acknowledge bit (TXACK1 to TXACK15) in the transmit acknowledge register (TXACK) and
transmit wait bit (TXPR1 to TXPR15) in the transmit wait register (TXPR) are automatically
initialized. When the corresponding bits (MBIMR1 to MBIMR15) of the mailbox interrupt
mask register (MBIMR) and the mailbox empty interrupt (IRR8) of the interrupt mask register
(IMR) are set to enable interrupts, they can issue an interrupt to the CPU.
Transmission cancellation can be specified for a message stored in a mailbox as a transmit wait
message. A transmit wait message is canceled by setting the bit for the corresponding mailbox
(TXCR1 to TXCR15) to 1 in the transmit cancel register (TXCR). When cancellation is
executed, the transmit wait register (TXPR) is automatically reset, and the corresponding bit is
set to 1 in the abort acknowledge register (ABACK). An interrupt to the CPU can be requested.
Also, if the mailbox empty interrupt (IRR8) is enabled for the bits (MBIMR1 to MBIMR15)
corresponding to the mailbox interrupt mask register (MBIMR) and interrupt mask register
(IMR), interrupts may be sent to the CPU.
However, a transmit wait message cannot be canceled at the following times:
a. During internal arbitration or CAN bus arbitration
b. During data frame or remote frame transmission
Also, transmission cannot be canceled by clearing the transmit wait register (TXPR). Figure
15.8 shows a flowchart of transmit message cancellation.
If transmission of a transmit message is aborted in the following cases, the message is
retransmitted automatically:
a. CAN bus arbitration failure (failure to acquire the bus)
b. Error during transmission (bit error, stuff error, CRC error, frame error, ACK error)

Related parts for h8s-2646