TC1796
Peripheral Units (Vol. 2 of 2)
Controller Area Network (MultiCAN) Controller
User’s Manual
22-29
V2.0, 2007-07
MultiCAN, V2.0
22.3.6
Message Object List Structure
22.3.6.1 Basics
The message objects of the MultiCAN module are organized in double-chained lists,
where each message object has a pointer to the previous message object in the list as
well as a pointer to the next message object in the list. The MultiCAN module provides
eight lists. Each message object is allocated to one of these lists. In the example in
, the three message objects (3, 5, and 16) are allocated to the list with
index 2 (List Register LIST2).
Figure 22-12 Example Allocation of Message Objects to a List
Bit field BEGIN in the List Register (for definition, see
) points to the first
element in the list (object 5 in the example), and bit field END points to the last element
in the list (object 3 in the example). The number of elements in the list is indicated by bit
field SIZE of the List Register (SIZE = number of list elements - 1, thus SIZE = 2 for the
3 elements in the example). The EMPTY bit of the List Register indicates whether or not
a list is empty (EMPTY = 0 in the example, because list 2 is not empty).
Each message object n has a pointer PNEXT in its Message Object n Control Register
MOCTRn (see
) that points to the next message object in the list, and a
pointer PPREV that points to the previous message object in the list. PPREV of the first
message object points to the message object itself because the first message object has
no predecessor (in the example message object 5 is the first message object in the list,
MCA05838
Message
Object 5
PPREV = 5
PNEXT = 16
LIST = 2
Message
Object 16
PPREV = 5
PNEXT = 3
LIST = 2
Message
Object 3
PPREV = 16
PNEXT = 3
LIST = 2
Register LIST2
EMPTY = 0
BEGIN = 5
END = 3
SIZE = 2