FlexCAN_Deinit function i.mx RT 1064

キャンセル
次の結果を表示 
表示  限定  | 次の代わりに検索 
もしかして: 

FlexCAN_Deinit function i.mx RT 1064

ソリューションへジャンプ
1,302件の閲覧回数
ecorini
Contributor I

Hi, i'm trying to stop CAN putting MDIS=1 and then reinit on the 1064 board, to play with low power mode.

I'm using flexcan_interrupt_transfer example.

There is an hardfault when executing FLEXCAN_Init() function. Are there any particular operations that need to be executed before re-initialization of CAN peripheral?

 /*...*/
 
 /* stop FlexCAN peripheral */
 FLEXCAN_Deinit(EXAMPLE_CAN);
 /* re-init FlexCAN peripheral */
 FLEXCAN_Init(EXAMPLE_CAN, &flexcanConfig, EXAMPLE_CAN_CLK_FREQ);
 
 /*...*/

Thanks in advance

Emanuele

ラベル(1)
タグ(2)
0 件の賞賛
返信
1 解決策
1,238件の閲覧回数
FelipeGarcia
NXP Employee
NXP Employee

Hello Emanuele,

 

I have modified flexcan_loopback example and tested your situation. Unfortunately, I did not see the hardfault you mentioned when executing FLEXCAN_Init.

 

Could you please test the example attached. When loopback is running, if you press SW8 on the board, the example executes FLEXCAN_Deinit and FLEXCAN_Init. After that the example worked correctly on my side.

 

Please let me know your findings.

 

Best regards,

Felipe

元の投稿で解決策を見る

2 返答(返信)
1,239件の閲覧回数
FelipeGarcia
NXP Employee
NXP Employee

Hello Emanuele,

 

I have modified flexcan_loopback example and tested your situation. Unfortunately, I did not see the hardfault you mentioned when executing FLEXCAN_Init.

 

Could you please test the example attached. When loopback is running, if you press SW8 on the board, the example executes FLEXCAN_Deinit and FLEXCAN_Init. After that the example worked correctly on my side.

 

Please let me know your findings.

 

Best regards,

Felipe

1,238件の閲覧回数
ecorini
Contributor I

You example it's working also on my side. Probably there is something wrong on my project

Thank you very much.

0 件の賞賛
返信