S12ZVML128 Lin Issue

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

S12ZVML128 Lin Issue

3,093件の閲覧回数
itsnewforme
Contributor IV

Hi Team,

I'm using S12ZVL128 for Reprogramming. I've made CANoe as Master and ECU as Slave. After dumping the Srec File using CANoe I'm able to see that all the UDS related test cases are giving positive response with correct data. But, there are some minor errors that are available on trace, please refer snapshot

itsnewforme_0-1676628077253.png

Please Let me know how to resolve this issue.

Thanks in advance

BR

Abhijit

タグ(2)
0 件の賞賛
返信
9 返答(返信)

3,058件の閲覧回数
DanNguyenDuy
NXP Employee
NXP Employee
 
From my point of view, maybe the cause of the problem comes from the time delay between frames. I also would like to share with you some information about the timing of the frame.
 
nxf78987_0-1676962338502.png

 

We always need the minimum time to transmit for each frame, that is minimum frame delay. For example, if master is sending at a baud rate of 19.2 kbps and loading frame data of 8 bytes, the minimum frame delay is 9.14ms and you need to configuration frame delay is 10ms.

So, please recheck the time delay between frames on your side. 

If the problem is still not solved. Could you please share with me your project or the .ldf file and LIN version that you are using? I will try to check on my side and send it back when it's done.

Best regards,

Dan

0 件の賞賛
返信

3,042件の閲覧回数
itsnewforme
Contributor IV

Hi @DanNguyenDuy Thank you for the information. But, still the issue is there. For now I'm uploading the LDF File that we have created for Reprogramming.

Please let me know if you need anything.

Thanks & Regards

Abhijit.

0 件の賞賛
返信

2,992件の閲覧回数
DanNguyenDuy
NXP Employee
NXP Employee

Hi @itsnewforme,

I saw some errors in your example. I fixed and created an example to test based on it. I would like to share it with you(Attached).
Hardware:
      - S12ZVL128
Software:
      - LIN_stack_S12_4_6_6
It seems all the frames have been sent on the bus normally.
nxf78987_0-1677579137680.png

 

Best regards,

Dan

2,945件の閲覧回数
itsnewforme
Contributor IV

Hi, @DanNguyenDuy . The issue is resolved. Actually it was due to wrong implementation of a function to send a LIN Frame From Slave to Master.

In our previous implementation of LIN Send Function we have used Lin Send break and Lin Send Sync Methods (see below image)  due to which it was showing those errors on Canoe Trace Window

itsnewforme_0-1678345323438.png

Now, we have made changes to this function as follows

itsnewforme_1-1678345532126.png

But now we have came across an issue where after transmitting and receiving some amount of LIN frames. our ECU is getting into reset.

can you please help us to resolve this issue

0 件の賞賛
返信

2,933件の閲覧回数
DanNguyenDuy
NXP Employee
NXP Employee

Hi @itsnewforme,

Could you describe detailed when ECU is getting into reset? 

Best regards,

Dan

0 件の賞賛
返信

2,929件の閲覧回数
itsnewforme
Contributor IV

Sure @DanNguyenDuy , we have used CANoe as Master ECU and have developed a tool using it to upload the Srec file. The Tool performs all the UDS related request and then starts transmitting the data in chunks of 256 bytes. So, after every 256 bytes of data is transmitted I'm using the Method linTransmitHeader() to get the positive response. PFA. First image is of CAPL script and second image is of Trace Window

itsnewforme_0-1678429990418.pngitsnewforme_1-1678430070227.png

So, after Transmitting 39 sequences. It is supposed to get a positive response but as the ECU is going into reset it is unable to do so. (you can refer the write window)

itsnewforme_2-1678430223991.png

Please help us to resolve this issue.

I'm also uploading the Zip file of the NXP code that we have used as reference to develop the functions to transmit and receive Lin Frame for s12 microcontroller. 

Thanks in advance

Regards Abhijit.

0 件の賞賛
返信

2,922件の閲覧回数
DanNguyenDuy
NXP Employee
NXP Employee

Hi @itsnewforme,

Unfortunately, I can't support you in this situation because you didn't use our driver.

Best regards,

Dan

0 件の賞賛
返信

2,919件の閲覧回数
itsnewforme
Contributor IV

Yes  we have not used LIN stack, because we have used the implementation provided in the AN5389SW which suggests to use the polling method PFA

itsnewforme_0-1678436889006.pngitsnewforme_1-1678436978798.png

https://www.nxp.com/docs/en/application-note/AN5389.pdf 

https://www.nxp.com/docs/en/application-note-software/AN5389SW.zip 

0 件の賞賛
返信

2,905件の閲覧回数
DanNguyenDuy
NXP Employee
NXP Employee

Hi @itsnewforme,

Because I can't know whether code in those materials are as same as with LIN driver or not. So, I didn't certain that I can help you in this situation.

Best regards,

Dan

0 件の賞賛
返信