n LIN sample code, What is the function "timerGetTimeIntervalCallback0" operating?

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

n LIN sample code, What is the function "timerGetTimeIntervalCallback0" operating?

Contributor III

In LIN sample code, I want to know operation of the function "timerGetTimeIntervalCallback0".

What is purpose of the function?

0 Kudos
1 Reply

NXP TechSupport
NXP TechSupport


The function returns a number of nanoseconds passed since the last call of the function.

I would like to add some information from the SDK team.

This function must return time period between two consecutive calls in nanoseconds and if this function is called for the first time, it will start the timer to measure time. When an event (such as detecting a falling edge of a dominant signal while a node is in sleep mode) occurs, LIN driver will call timerGetTimeIntervalCallback to start time measurement. Then on the rising edge of that signal, LIN driver will call the timerGetTimeIntervalCallback function to get time interval of that dominant signal in nanoseconds. If Autobaud feature is enabled, LIN driver uses timerGetTimeIntervalCallback to measure two bit time length between two consecutive falling edges of the sync byte in order to evaluate Master's baudrate.

I hope it helps you.

Best Regards,


0 Kudos