I am using MBDT 1.5 for the S32k3x4. I have build a simple model with a couple of transmit and receive messages over CAN 0 module and have configured freemaster over the same. After flashing the SW on the target HW initially i am able see the messages over the bus(delay and drop in message periodicity observed), but the moment i establish a connection over FreeMaster over CAN 0, the message transmission and reception over the bus is halted and is restored only after resetting the VCU. Also not able to establish connection over FreeMaster using any other CAN channel except for CAN0 and CAN4.
Hello Team,
Thankyou for your response. Now I have configured 3 CAN modules for testing, CAN0 solely for Freemaster over CAN, and others (CAN1 and CAN2) for message TX and RX and both of them work but only for a certain amount of time. The CAN transmission and reception as well the FM over CAN is halted abruptly due to unknown reasons. Please look into it. Thanking you.
Hello,
Can you please tell if there is a microcontroller reset happening or just the CAN communication stops?
Thank you
Hello @Adrian_Gherca ,
After conducting some tests on the board, it is observed that all the peripherals work normally but only for a certain amount of time(a couple of minutes), after that all the peripherals stop working and the board needs a reset. I even tried debugging and monitoring the CAN controller registers using S32DS but no change was observed in the MCR register of CAN0 module(MCR-MDIS , FRZ and HALT were 0 after the peripherals stopped working). Thanking you.
While debugging in S32 Design Studio, please search for, and set a brakepoint, in this function: HardFault_Handler (in file exceptions.c)
If possible, when this brakepoint is reached please run the backtrace command in the Debugger Console of S32DS and write here the results.
Also, please try changing the Mode, in the FreeMASTER Configuration tab of the Config block, to Short Interrupt.
Thank you.
Hello @Adrian_Gherca ,
Here are the results after backtracing over S32DS debugger Console.
#0 HardFault_Handler () at C:/Users/User/Desktop/CAN_TEST/CAN_TEST/CAN_Test_Config/Project_Settings/Startup_Code/exceptions.c:96
#1 <signal handler called>
#2 0x00010000 in ?? ()
#3 0x00441c66 in __aeabi_cdcmple () at ../../../../../../src_gcc/libgcc/config/arm/ieee754-df.S:1210
#4 0x0049b718 in Can_aControllerConfig ()
Backtrace stopped: previous frame identical to this frame (corrupt stack?)
Please look into this. Waiting or you response.
Hello,
We are investigating the problem and an answer/solution will be provided. Unfortunately I cannot provide a due date for this.
Hello and thank for your interest in using our toolbox and the FreeMASTER over CAN feature.
In MBDT 1.5.0, FreeMASTER over CAN support was added with the mention that the CAN instance used by the FreeMASTER debugging tool cannot be used for any other purpose. This means that if CAN 0 is assigned in the FreeMASTER block the application must use another CAN instance for communicating over CAN (e.g. CAN 4).
Therefore, new CanControllers (equivalent to new instances) need to be created in the configuration project (S32 Configuration Tool) in order to have them available in the drop down list of the FreeMASTER config block. These new CanControllers are each one connected to different tranceivers, each with its own specific initialization procedure, e.g. setting the En and Stb pins and more.
Also, for every new CAN instance (CanController) introduced, the Tx and Rx pins associated with that instance need to be configured as well.
Please check this article for a complete tutorial on how to do this.
Just letting you know that in the MBDT 1.6.0 release, a new version of FreeMASTER over can will be available that allows using the same CAN instance for the FreeMASTER debugging tool as well as for the rest of the application.