How to invoke flexcan event callback

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

How to invoke flexcan event callback

374 Views
chris_010
Contributor I

I use flexcan_1 of S32K312  to communicate with PCANpro,the communication seems well, mcu can receive and send data.  However, the callback function fails to work properly. What is the reason for this? Is there any need to register or monitor the callback function? No relevant APIs were found.

here are my code and configuration.

---- DMA is used for SPI,it does no matter with can.

chris_010_0-1766912460665.png

chris_010_1-1766912489091.png

chris_010_2-1766912692115.png

chris_010_3-1766912722883.png

 

chris_010_4-1766912734801.png

 

 

 

 

Tags (2)
0 Kudos
Reply
1 Reply

332 Views
Senlent
NXP TechSupport
NXP TechSupport

Hi@chris_010

Please refer to the demo in the attachments, the RTD is 5.0.0.

0 Kudos
Reply
%3CLINGO-SUB%20id%3D%22lingo-sub-2269368%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3EHow%20to%20invoke%20flexcan%20event%20callback%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2269368%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EI%20use%20flexcan_1%20of%26nbsp%3BS32K312%26nbsp%3B%20to%20communicate%20with%20PCANpro%EF%BC%8Cthe%20communication%20seems%20well%2C%20mcu%20can%20receive%20and%20send%20data.%26nbsp%3B%26nbsp%3BHowever%2C%20the%20callback%20function%20fails%20to%20work%20properly.%20What%20is%20the%20reason%20for%20this%3F%26nbsp%3BIs%20there%20any%20need%20to%20register%20or%20monitor%20the%20callback%20function%3F%20No%20relevant%20APIs%20were%20found.%3C%2FP%3E%3CP%3Ehere%20are%20my%20code%20and%20configuration.%3C%2FP%3E%3CP%3E----%20DMA%20is%20used%20for%20SPI%EF%BC%8Cit%20does%20no%20matter%20with%20can.%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22chris_010_0-1766912460665.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22chris_010_0-1766912460665.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F371258iB65A9A6B4309E35A%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22chris_010_0-1766912460665.png%22%20alt%3D%22chris_010_0-1766912460665.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22chris_010_1-1766912489091.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22chris_010_1-1766912489091.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F371259iB5DFA5FC90589FB9%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22chris_010_1-1766912489091.png%22%20alt%3D%22chris_010_1-1766912489091.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22chris_010_2-1766912692115.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22chris_010_2-1766912692115.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F371260i4477A6D4D37214E9%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22chris_010_2-1766912692115.png%22%20alt%3D%22chris_010_2-1766912692115.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22chris_010_3-1766912722883.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22chris_010_3-1766912722883.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F371261i66F7CC236D193B40%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22chris_010_3-1766912722883.png%22%20alt%3D%22chris_010_3-1766912722883.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%3CBR%20%2F%3E%3CP%3E%3CSPAN%20class%3D%22lia-inline-image-display-wrapper%20lia-image-align-inline%22%20image-alt%3D%22chris_010_4-1766912734801.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cspan%20class%3D%22lia-inline-image-display-wrapper%22%20image-alt%3D%22chris_010_4-1766912734801.png%22%20style%3D%22width%3A%20400px%3B%22%3E%3Cimg%20src%3D%22https%3A%2F%2Fcommunity.nxp.com%2Ft5%2Fimage%2Fserverpage%2Fimage-id%2F371262i155F15E917659DA4%2Fimage-size%2Fmedium%3Fv%3Dv2%26amp%3Bpx%3D400%22%20role%3D%22button%22%20title%3D%22chris_010_4-1766912734801.png%22%20alt%3D%22chris_010_4-1766912734801.png%22%20%2F%3E%3C%2Fspan%3E%3C%2FSPAN%3E%3C%2FP%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3CBR%20%2F%3E%3C%2FLINGO-BODY%3E%3CLINGO-SUB%20id%3D%22lingo-sub-2269429%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%20translate%3D%22no%22%3ERe%3A%20How%20to%20invoke%20flexcan%20event%20callback%3C%2FLINGO-SUB%3E%3CLINGO-BODY%20id%3D%22lingo-body-2269429%22%20slang%3D%22en-US%22%20mode%3D%22CREATE%22%3E%3CP%3EHi%40%3CSPAN%3Echris_010%3C%2FSPAN%3E%3C%2FP%3E%0A%3CP%3E%3CSPAN%3EPlease%20refer%20to%20the%20demo%20in%20the%20attachments%2C%20the%20RTD%20is%205.0.0.%3C%2FSPAN%3E%3C%2FP%3E%3C%2FLINGO-BODY%3E