This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

MSPM0G3505: WHat would prevent CANFD0 from ever being ready?

Part Number: MSPM0G3505
Other Parts Discussed in Thread: MSPM0G3507

Tool/software:

I have a custom board.  Everything else is working, except for CANFD0.  I wait for CANDFREADY in  SYSCTL->SOCLOCK.SYSSTATUS  But, it is always 0.

I can turn the CANFD0 power on.  But all registers read 0. Except for PWREN

I am assuming this has something to do with the interface clock MCAN_ICLK ?

I am using a 16MHz external crystal.  Running the PLL at 80MHz. MCLK=80MHz w/ 2-waitstates.  CANCLK selected from HFCLK.=16MHz

SYSCTL

HSCLKGOOD=1

SYSPLLGOOD=1

HFCLKGOOD=1

CPUCLK Frequency verified by 1kHz output  of TIMG0.with 

CLKSEL=8 ( BUSCLK)

CLKDIV=1( /2 )

LOAD=40000

I am a bare-metal programmer. So, not using the SDK.  Just the datasheets.

I am using IAR.  If that matters.

I have tried no setting the PAS12/13 i/o pins up, before initializing CANFD0.  No change.

Any ideas? Thanks

  • What I can guide you is that you can find our CANFD demo that created based on the driverlib but that is dose not matter, you can just follow the CANFD configuration flow that we do have all source code for every driverlib APIs so you can also see the register level operation. One demo in the SDK is located at ...mspm0_sdk_2_02_00_05\examples\nortos\LP_MSPM0G3507\driverlib\mcan_multi_message_tx, it do have the IAR version you can open the project with IAR.

  • Thanks.  I found the issue.  I thought I had to enable the power BEFORE I set MCANSS_CLKEN.

    Once I dug through the structure definitions, I realized that it is in a separate space.  I set it, and the lights went on Slight smile