KEAZ128 MSCAN_Deinit failed

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

KEAZ128 MSCAN_Deinit failed

426 次查看
alai1
Contributor I

Hi,

The mscan module initial by setting CANE bit of register CANCTL1 to 1, after that,  if I try to deinit the mscan with setting CANE to 0,  but fail. I try SDK function or act as datasheet said by setting mscan to initial mode, the two way can't set CANE to 0, I debugging by keil S32DS IDE. The only way that can set CANE bit to 0 is reset mcu. My question is that my operation is wrong or not? How can I set the CANE bit to 0 while it already is 1?    

0 项奖励
回复
2 回复数

417 次查看
Robin_Shen
NXP TechSupport
NXP TechSupport

Hi 

The CANE bit can only be written once.

CANE write once KEA.png

How about disable the clock of CAN module? SIM_SCGC &=~(uint32_t)(SIM_SCGC_MSCAN_MASK); //disable clock 

Can power consumption be reduced?


Best Regards,
Robin

0 项奖励
回复

398 次查看
alai1
Contributor I
My point is disable can module then release the TX and RX pin. After that set the RX pin as kbi pin and use the kbi interrupt to wake up the mcu. The point you said disable clock of can module I already try, but the RX pin interrupt can't wake up can module.
0 项奖励
回复