as far as I understand, the Controllers on the Arduino boards come pre-programmed with some kind of Firmware. One Part of this Firmware ist the Bootloader, ok. But here must be something, that pre-configures the Controller for to fit to the special board it comes with. That is, how the SERCOM ist configuret, what function the each pin is assigned to etc. Where is the code that does that? Currently, i design a custom board based on the MKR Zero and have to change the pin assignment so that i can operate it as an SPI-slave. And i need to know how i have to prepare the SAM so that is in the same condition as the ones delivered with the boards.