Hi Frank,
LIN
You may refer to LIN stack driver on the web in the Device Drivers section, see link below.
There are examples for the S12ZVML31 LIN master and slave
S12ZVM Mixed-Signal MCUs|MagniV|NXP
Also, application note AN5201 can be useful:
Integrating the LIN driver with BLDC sensorless motor controller:
https://www.nxp.com/docs/en/application-note/AN5201.pdf
SW:
https://www.nxp.com/docs/en/application-note-software/AN5201SW.zip
CAN
AN4975 Using MSCAN on the MagniV Family:
https://www.nxp.com/docs/en/application-note/AN4975.pdf
SW:
http://www.nxp.com/files/microcontrollers/doc/app_note/AN4975SW.zip
Note: The S12ZVML does not have CAN physical layer.
I hope it helps you.
Best Regards,
Diana