How to configure a Event trigger frame in .ldf file

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

How to configure a Event trigger frame in .ldf file

1,899 Views
angang_hao
Contributor II

Hello'

I am wondering whether you have some experience about "Event Trigger Frame" configuration. When I try to add a Event Trigger Frame in .ldf file.

the associated frames are not available to map to new added  Event Trigger Frame. So this process is only finished with failed. 

I am wondering is there anything special for the unconditional frame which will be mapped to to "Event Trigger Frame". Why is the associated frames not available for the Event Trigger Frame?

pastedImage_1.png

0 Kudos
6 Replies

1,736 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello angang.hao@autoliv.com,

I'm posting an answer from our LIN Stack SW team:

The associated frames (unconditional frames) need to meet the following conditions to added Event Trigger Frame.
- The publisher of frame is the slave node.
- All signal_offset values of frames need to be greater than 8(because a first byte use to fill the PID of associated frames).

Eg:

MotorState_Cycl     :  0x4, VectorSlave2_1      ,    8 {

                               MotorTemp           , 8;

                               MotorLinError       , 40;

}

Note:
All frame_name identifiers shall exist in the frame identifier set and refer to unconditional frames.

All frames in one CollisionResolver_Table need to have the same length.
You can see chapter 9.2.4.3 in LIN_Specification_Package_2.2A.pdf for more details.

Regards,

Daniel

0 Kudos

1,736 Views
angang_hao
Contributor II

Hello Daniel Martynek,

Thank you, thank you so much, my friend!  Now I know how to use it .

In my current project, I want to send one Lin frame using Lin Master node to control slave node. And in some cases, the time between 2 frames is very short , maybe 10 or 20 million seconds.  And in some cases,  the time between 2 frames is very long almost 4 or 5 seconds. So I am considering using the event trigger frame to send this frame when there is a transmition required. 

But Now I think it is not suitable for me to use the event trigger frame to solve my problem.

because as is told in "LIN_Specification_Package_2.2A.pdf", it should "• Be published by different slave nodes".

Do you have any idea or suggestion for my question if the frame is sent by master? Does that mean I have to use "cycle send type" to send this Lin frame?

Thank you again for you powerfully support!

0 Kudos

1,736 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello angang.hao@autoliv.com,

You can control the time when each frame is sent with the Schedule table.
I understand that you have a lot of control signal which are sent from master to slave and it require more than one frame. 
E.g.

signal_1 ,signal_2 in frame_1 (send from master to slave)
signal_3 ,signal_4 in frame_2 (send from master to slave)
signal_5 ,signal_6 in frame_3 (send from master to slave)

There are two ways to send these frames.
The first way: 
With normal schedule table, e.g.

table_1
{
        frame_1       50ms;
        frame_2       50ms;
        frame_3       50ms;
}
Then, each frame will be resent after 150ms (frame_1 , frame_2, frame_3, then again frame_1 , frame_2, frame_3, ...).
    
The second way:

With use of sporadic frames,


Sporadic_frames

{
       SporadicControlFrame: frame_1, frame_2, frame_3;
}

table_1
{
       SporadicControlFrame       50ms;
}
    

This way, the LinStack will check every 50ms if any of the signals in the corresponding frames (frame_1, frame_2, frame_3) is updated and it will send the frame.
Note that when the checking process happens, the highest priority frame will be sent.

 

AN5122 Using NXP’s LIN Driver with the MagniV Family

pastedImage_3.png

 

I guess you want to use the second way.

BR, Daniel

0 Kudos

1,736 Views
angang_hao
Contributor II

Hello Daniel Martynek,

I really appreciate you for your powerful support. Now I am very clear about what I need to do next. I will use the the sporadic to realize my requirement in code.

Thank you so much, my dear friend!

One more question about Lin communication.

Do you have any idea about how to change the value  of "sync break delimiter length"? 

This is 1 bit length in my project now and when I connect 2 slaves, 1 master to the LIN bus line, an "incorrect  sync delimiter length" error will be reported. I think I need make it longer than 1 bit since as is told in LIN_specication_package2.2A, it is recommend using delimiter that is longer than one nominal bit-time.

Am I right about this error? and do you have any suggestion or comment about this error?

pastedImage_1.png

pastedImage_1.png

Thanks again, my dear friend!

0 Kudos

1,736 Views
danielmartynek
NXP TechSupport
NXP TechSupport

Hello angang.hao@autoliv.com,

I'm sorry for the delay.

It seems to be already answered in one of your other threads:

Lin stack issue:incorrect sync delimiter length 

Regards,

Daniel

0 Kudos

1,736 Views
angang_hao
Contributor II

Hello Daniel Martynek,

Yes, exactly. And acturally I found the rootcase of this issue which was caused by a unsuitable capacitance. After I changed it from 1nf to 220pf, this issue was solved.

Thank you for you feedback!

0 Kudos