Hello,
One example of the TJA1145 initialization can be found in the MBD Toolbox for BMS, which you can download and install for free. Please note that the MBD Toolbox for BMS works only with MBD Toolbox for S32K3 version 1.4.0.
However, I attached a few imagines of the initialization part for the TJA1145, but also for the SPI configuration. Make sure you follow the schematic for your board, so you initialize the correct SPI instance and properly select the chip select pin.
Best regards,
Sorin Bancila