LIN is not working as a Master in S32K

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

LIN is not working as a Master in S32K

415 Views
emb02
Contributor IV

Hi,
I am checking the LIN communication in the S32K144 MCU for both slave and master modes. When I assign my device (S32K144) as a slave, it works properly.
However, when I assign my device (S32K144) as a master and continuously send headers from the master (S32K144), the slave device indicates that a message is received, even though I am not sending any messages from the slave device.

I am using the example code from S32DS for both master and slave. In the master example code, a button interrupt is used for sending the header to the slave.

Could you please provide me an example code for the master that does not use a button interrupt? Alternatively, could you suggest a solution for this issue?

 

I'm utilizing it.

S32DS version 3.5

SDK 4.0.1

NXP GCC 10.2 toolchain for Arm 32-bit bare metal

 

Thank you.

0 Kudos
Reply
1 Reply

396 Views
PetrS
NXP TechSupport
NXP TechSupport

Hi,

which S32DS example do you refer to in fact, baremetal or using LINStack? How is your connection? Do you have 2 boards connected, one as master, second as slave?
Have you tried to measure LIN bus to see real frames?
How to understand you words "the slave device indicates that a message is received, even though I am not sending any messages from the slave device." If slave is receiving a frame it does not send anything. It should send a response if master is requesting data.
For example in lin_master_baremetal example upon button press it either publishes data to slave or requests from slave, this is toggled for each button press.
If you do not want a button isr, you can simply call LIN_DRV_MasterSendHeader at your desired place, e.g in some timer interrupt or within main loop.

BR, Petr

0 Kudos
Reply