Trying to run the Can_Example_S32G274A_M7 on the RDB2 (GoldBox)
SD32 3.5, RTD 4.0.1
Started a new project from the above example
Build the project
Did all steps in as in the HANDS ON CAN : IMPORT CAN EXAMPLE PROJECT in the S32G-VNP-GLDBOX REAL TIME DRIVER EXAMPLE ENABLEMENT GUIDE
Connected the FlexCan0 to FlexCan1 - with the external harness supplied with the RDB2
It looks like the first transmission ends OK, the CanIf_RxIndication callback function is called indeed
but after the 1'st transmit, it is stuck in the Can_Write function which returns BUSY !!
AND - checking the physical CAN BUS lines with oscilloscope does not show that it transmits something
Any suggestions?
Hi Ofer bahar
Hope you are doing well
it seems like you edited in example code. can you check it. also refer can module user manual(RTD_CAN_UM.pdf).
Can_Write checks if hardware transmit object that is identified by the HTH is free. Can_Write checks if another Can_Write is ongoing for the same HTH. The mutex for that HTH is set to 'signaled' the ID, DLC and SDU are put in a format appropriate for the hardware (if necessary) and copied in the appropriate hardware registers or buffers. All necessary control operations to initiate the transmit are done.
The mutex for that HTH is released. The function returns with E_OK.
possible reason for Busy
(1) When hardware transmit object is busy with another transmit request,the function returns with
CAN_BUSY.
(2) A preemptive call of Can_Write has been issued, that could not be handled reentrant (i.e. a call with
the same HTH). the function returns with CAN_BUSY the function is non blocking
(3) The hardware transmit object is busy with another transmit request for an L-PDU that has lower priority
than that for the current request the transmission of the previous L-PDU is cancelled (asynchronously)
the function returns with CAN_BUSY.
Regards ,
Tushar
Hi Tushar
Thanks for your response,
Nevertheless, I hardly can understand what you suggested in order to solve my problem
The same problems happens when with the FlexCan example of the S32DS !
I really appreciate if you could send me a working example that can transmit and receive a on the FlexCAN, running on the Gold Box RDB2 S32G274A
Ofer