FreeMASTER-over-CAN Communication Plugin using the fm_can_s32k1xx.slx example project on a s32K148

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

FreeMASTER-over-CAN Communication Plugin using the fm_can_s32k1xx.slx example project on a s32K148

998 Views
Bravin_Link
Contributor II

Hello NXP community,

I am currently trying to run the fm_can_s32k1xx.slx example project that is located under the following path: C:\Users\username\AppData\Roaming\MathWorks\MATLAB Add Ons\Toolboxes\NXP_MBDToolbox_S32K1xx\S32_Examples\common\fm

I have proven that this example works on the s32k144EVB using a USB-to-CAN device (ValueCAN) along with the following configuration:

Bravin_Link_0-1689883316279.png

Bravin_Link_3-1689883705449.png

Bravin_Link_2-1689883461599.png

Now I want to establish the same connection on another module that has a s32k148 microchip. It is my understanding that the Tx and Rx pins are the same, so I left the FreeMASTER config block the same.

Additionally, I intend to use the same USB-to-CAN device as the interface between my module and FreeMASTER, so I left the settings in FreeMASTER the same.

The only change that I made was in my Simulink model and it had to do with changing the MBD_S32K1xx_Config_Information block to reflect the new chip:

Bravin_Link_4-1689884043231.png

When I build the changed model and flash it to the module using S32 design studio for Arm version 2.2, I try to hit the "test connection" button in FreeMASTER and get this pop up as a result:

Bravin_Link_5-1689884213919.png

On a side note...I have verified that my module does send and receive CAN messages at this high speed of 1 Mb using FlexCAN Simulink blocks, so I believe there might be a configuration issue. (See images below: While using FlexCAN, I do need to initialize my messages / write the CAN transceiver enable pin High) but I have tried to include both of these in my model, and I am still getting the same result.

Bravin_Link_6-1689884535150.png

Bravin_Link_7-1689884575087.png

Please share if you have any ideas why I am not able to establish a connection between FreeMASTER and the module over CAN. Any help would be greatly appreciated!

0 Kudos
5 Replies

702 Views
Bravin_Link
Contributor II

John,

Those differences in the code are expected due to the changing of the LED pin from PTE22 to PTA8. 

Were you able to find any other discrepancies between the two codes?

Thank you for your time in this matter!

Tags (1)
0 Kudos

691 Views
ruihang_wu
Contributor III
0 Kudos

836 Views
BrandonRosiewicz
Contributor I

Hello John Floros , <john.floros@nxp.com>, 

Attached are the two builds you requested: One with working EV Board / One with Not Working Target Board.  Please let me know if you receive these.  Thanks again for your help and we greatly look forward to your response!

0 Kudos

794 Views
john_floros
NXP Employee
NXP Employee

Brandon,

Not that this the reason for the issue but was the following code difference expected?

john_floros_0-1695309333751.png

 

Regards,

John

0 Kudos

789 Views
BrandonRosiewicz
Contributor I

Bravin Created the builds, but he is OOO until Monday.  Let me get back with you then to confirm.  Thanks

0 Kudos