1, 2, 3:
The acceptance mask tells the peripheral what bits of the ID to ignore when doing the matching. The filter tells the peripheral what the bits of the ID need to be when they are not being ignored. Does that make sense?
Just to elaborate on
what rjenkinsgb said, it allows you to send messages to just a single device or multi-drop a message to multiple devices. If you did not have a mask to ignore bits in an address, then you would either have to:
a. point-to-point normal messages but when a multi-drop is required you can only point-to-point an identical payload addressed to each device of interest
b. If all devices you wanted to multi-drop were made to shar the same address then you could just multi-drop but then you could never ever single-drop a message when required.
It's like having a family name or an area code. It lets you give identifiers that are unique to each device but also block them together so you can send individual messages or send a single message to everything in a group if necessary.
5. This isn't really objective fact. It's a very elegant interface. Maybe the problem is you are trying to study the CAN through a processor datasheet instead of studying it through a website that just talks conceptually about how CAN works. If you do it through a datasheet you're going to run into all the nitty gritty before you even know the high level concepts of how the CAN bus works.
I had a good CAN bus website bookmarked that went through everything:
https://www.softing.com/home/en/ind...-bus/more-can-bus/index.php?navanchor=3010320
But it doesn't seem to exist at that link anymore. It went through everything. The elecrical layer, the software layer, why certain things existed and what issues they dealt with. What features existed and what they were used for.
But starting with something like this:
https://www.ni.com/white-paper/2732/en/
Is much better than starting in a MCU datasheet.
6. What do you mean by "learn"? How far are you trying to go? If you are trying to set up a peripheral you don't know, then you do the following:
1. first go get a rough conceptual idea of how it works elsewhere.
2. skim that section in the datasheet just get familiarity with the terms and kinds of things in it
3. Go through the register list one at a time and type out each and every configuration bit and register and put a comment beside it of what it is. Just set the bits to write to zero or registers fields to write to zero because you'll come back afterwards and actually set it to what it needs to be. Give it a good comment that will let you at least 75% know what the hell it does the next morning. I comment in what each bit setting does if it's not really obvious from the name so I don't have to look at the datasheet each time.
4. Then after all that now go through that code and set everything you know or kinda know what it needs to be (referencing the rest datasheet if necessary). Mark and skip the things that seem irrelevant to your purposes or you have no idea what they are.
5. Then go back and for each of the irrelevant or unknown things check the datasheet or manuals and figure out what it is.
It's a lot easier by then because you have a good idea of what's in the peripheral and you aren't focusing on a bunch mass of unknown all at the same time ironing out the kinks that you're really not familiar with.