Skip to main content
Open topic with navigation CAPL Functions » LIN » linTime2Bits_ns

linTime2Bits_ns

Valid for: CANoe DE • CANoe4SW DE

Function Syntax

  • dword linTime2Bits_ns(int64 time): // form 1
  • dword linTime2Bits_ns(dword channel, int64 time); // form 2

Description

This function converts specified system times to bit times. The conversion is done using the current baudrate on the channel determined by the CAPL program context. Note: Calling this function with the explicit channel is only possible from a CAPL program defined in the Measurement Setup.

Parameters

  • time: System time to be converted [in ns].
  • channel: Channel number, whose baudrate will be used.

Return Values

Resulting bit time.

Example

Extract sync break length of LIN frames
on linFrame *
{
  dword bitTimeSyncBreak;
  bitTimeSyncBreak = linTime2Bits_ns(this.breakLen);
}
linBits2Time_ns