I am using an MK20DV256 for one of my projects. In the hardware(PCB) there are two clock available:
1. A 32 KHz RTC crystal connected to (XTAL32 and EXTAL32)
2. A 12 MHz crystal connected to (XTAL0 and EXTAL0).
We have derived the MCGOUT clock(~70 Mhz) from the FLL operating in FEE mode.
From what I understand I can clock the Flex CAN module from the below options:
1. The 12 Mhz crystal directly(OSCERCLK)
2. ~35.99 Mhz Bus clock.
Below are a few questions that I am trying to get answers to:
1. The clock to choose for the Flex CAN module seems to be dependent on the most accurate clock. How do we calculate the accuracy of the FLL stabilized MCGOUT clock?
2. Are there any other parameters that need to be considered before we choose the MCG clock.
If the required bus speed can be derived from OSCERCLK this should be used since it has lowest jitter and so achieves best CAN operation quality.
Complete K20 solutions for professionals, training and support:http://www.utasker.com/kinetis.html
Thanks for the reply. I am intending to operate at 1 Mbps. Is there a way to quantify jitter?
See data sheet for values.
For 1M CAN speed from 12MHz OSCERCLK set a pre-scaler of 6 and time quanta of 24 for exact 1MHz. This is the value 0x01b70007 in CAN_CTRL1.
Turn-key CANopen for Kinetis - http://www.utasker.com/index.html
CAN simulation: https://www.youtube.com/watch?v=Ha8cv_XEvco