MC68336/376
CAN 2.0B CONTROLLER MODULE (TouCAN)
MOTOROLA
USER’S MANUAL
Rev. 15 Oct 2000
13-7
Likewise, a buffer is deactivated by writing the appropriate deactivation code to the
control/status word for that buffer. Deactivation of a buffer is typically done when the
user desires to reconfigure the buffer, for example to change the buffer’s function (RX
to TX or TX to RX). Deactivation should also be done before changing a receive
buffer’s message identifier or before loading a new message to be transmitted into a
transmit buffer.
For more details on activation and deactivation of message buffers, and the effects on
13.4.1.6 Message Buffer Lock/Release/Busy Mechanism
In addition to the activation/deactivation mechanism, the TouCAN also utilizes a lock/
release/busy mechanism to assure data coherency during the receive process. The
mechanism includes a lock status for each message buffer, and utilizes the two serial
message buffers to facilitate frame transfers within the TouCAN.
Reading the control/status word of a receive message buffer triggers the lock for that
buffer. While locked, a received message cannot be transferred into that buffer from
one of the SMBs.
If a message transfer between the message buffer and a serial message buffer is in
progress when the control/status word is read, the BUSY status will be indicated in the
code field, and the lock will not be activated.
The user can release the lock on a message buffer in one of two ways. Reading the
control/status word of another message buffer will lock that buffer, releasing the pre-
viously locked buffer. A global release can also be performed on any locked message
buffer by reading the free-running timer.
Once a lock is released, any message transfers between an SMB and a message buff-
er which was delayed due to that buffer being locked will take place. For more details
on the message buffer locking mechanism, and the effects on message buffer opera-
13.4.2 Receive Mask Registers
The receive mask registers are used as acceptance masks for received frame IDs.
The following masks are defined:
A global mask, used for receive buffers 0-13
Two separate masks for buffers 14 and 15
The value of the mask registers should not be changed during normal operation. If the
mask register data is changed after the masked identifier of a received message is
matched to a locked message buffer, that message will be transferred into that mes-
sage buffer once it is unlocked, regardless of whether that message’s masked
identifier still matches the receive buffer identifier. Table 13-6 shows mask bit values.