Skip to main content

C2xTestWaitForSignalMatch

Valid for: CANoe DE

Function Syntax

  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, int64 tokenValue, long timeout) // form 1
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, int64 tokenValue, char* stationName, long timeout) // form 2
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, long dataSize, byte* data, long timeout) // form 3
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, long dataSize, byte* data, char* stationName, long timeout) // form 4
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, char* namedBit, long tokenValue, long timeout) // form 5
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, char* namedBit, long tokenValue, char* stationName, long timeout) // form 6
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, long bitPosition, long tokenValue, long timeout) // form 7
  • long C2xTestWaitForSignalMatch (char* protocolDesignator, char* tokenDesignator, long bitPosition, long tokenValue, char* stationName, long timeout) // form 8

Description

Waits for the occurrence of the first Car2x message with a signal that matches the given value. Should the message not occur before the expiration of the time aTimeout, the wait condition is resolved nevertheless.

Parameters

  • protocolDesignator: Protocol designator of the Car2x message that should be awaited.
  • tokenDesignator: Token designator of the Car2x message that should be awaited.
  • tokenValue: Token value that should be awaited.
  • dataSize: Length of the token data that should be awaited in bytes.
  • data: Token data that should be awaited.
  • namedBit: Name of a bit in a bitstring that should be awaited.
  • bitPosition: Position of a bit in a bitstring that should be awaited. The first bit has the bit position 0.
  • stationName: Name of the sender station of the Car2x message that should be awaited.
  • aTimeout: Maximum time that should be waited [ms]. Transmission of 0: no timeout controlling.

Return Values

  • -1: General error, for example, functionality is not available.
  • 0: Resume due to timeout.
  • 1: Resume due to event occurred.

Example

C2xTestJoinSignalInRangeC2xTestJoinSignalMatchC2xTestWaitForSignalInRange