User manual

Table Of Contents
Zynq-7000 AP SoC Technical Reference Manual www.xilinx.com 570
UG585 (v1.11) September 27, 2016
Chapter 18: CAN Controller
If any of the enabled filters (up to four) satisfy this equation, then the Rx message is stored in the
RxFIFO:
If (AFMR & Message_ID) == (AFMR & AFIR) then Capture Message
Each acceptance filter is independently enabled. The filters are selected by the can.AFR register.
•Set can.AFR[UAF4] = 1 to enable AFMR4 and AFID4.
•Set can.AFR[UAF3] = 1 to enable AFMR3 and AFID3.
•Set can.AFR[UAF2] = 1 to enable AFMR2 and AFID2.
•Set can.AFR[UAF1] = 1 to enable AFMR1 and AFID1.
If all can.AFR[UAFx] bits are set = 0, then all received messages are stored in the RxFIFO. The UAF bits
are sampled by the hardware at the start of an incoming message.
Acceptance Filter Mask
The Acceptance Filter Mask registers (AFMR) contain mask bits used for acceptance filtering. The
incoming message identifier portion of a message frame is compared with the message identifier
stored in the Acceptance Filter ID register. The mask bits define which identifier bits stored in the
Acceptance Filter ID register are compared to the incoming message identifier.
There are four AFMRs. These registers are stored in a memory. Reads from AFMRs return 'X's if the
memory is uninitialized. Asserting a software reset or hardware reset does not clear register
contents. These registers can be read from and written to. These registers are written to only when
the corresponding UAF bits in the can.AFR register are 0 and the ACFBSY bit in the can.SR register is
0.
The following conditions govern AFMRs:
Extended Frames All bit fields (AMID [28:18], AMSRR, AMIDE, AMID [17:0] and AMRTR) need to be
defined.
Standard Frames Only AMID [28:18], AMSRR and AMIDE need to be defined. AMID [17:0] and
AMRTR should be written as 0.
Acceptance Filter Identifier
The Acceptance Filter ID registers (AFIR) contain Identifier bits, which are used for acceptance
filtering. There are four Acceptance Filter ID registers.
These registers can be read from and written to. These registers should be written to only when the
corresponding UAF bits in the SR are 0 and the ACFBSY bit in the SR is 0.
The following conditions govern the use of the AFIRs:
Extended Frames All the bit fields (AIID [28..18], AISRR, AIIDE, AIID [17:0] and AIRTR) must be
defined.
Standard Frames Only AIID [28:18], AISRR and AIIDE need to be defined. AIID [17:0] and AIRTR
should be written with 0.