Hi SHU,
I found some very simple CAN example code directly for S12G:
There is AN4455, MC9S12G128 Demonstration Lab Training. Inside the zip file, you can find CAN_Demo project.
Check the links below.
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN4455.pdf
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN4455SW.zip
Moreover, very helpful application note could be AN3034 Using MSCAN on the HCS12 family. It could be used as a reference.
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN3034.pdf
Note: this application note was created for older S12 MCUs with msCANv2. S12G have msCANv3, but there are minimum differences.
Hope this helps!
=========================================
this answer is for you, if it helps, please click on "Correct Answer" button. thanks!
Best Regards,
Zhang Jun
Hi SHU,
I found some very simple CAN example code directly for S12G:
There is AN4455, MC9S12G128 Demonstration Lab Training. Inside the zip file, you can find CAN_Demo project.
Check the links below.
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN4455.pdf
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN4455SW.zip
Moreover, very helpful application note could be AN3034 Using MSCAN on the HCS12 family. It could be used as a reference.
http://cache.freescale.com/files/microcontrollers/doc/app_note/AN3034.pdf
Note: this application note was created for older S12 MCUs with msCANv2. S12G have msCANv3, but there are minimum differences.
Hope this helps!
=========================================
this answer is for you, if it helps, please click on "Correct Answer" button. thanks!
Best Regards,
Zhang Jun