Skip to main content

C2xGetTokenInt

Valid for: CANoe DE

Function Syntax

Description

This function requests the integer value of a token. Form 2 with byte offset returns a part of the token data as integer.

Parameters

  • packet: Handle of a packet that has been created with C2xInitPacket
  • protocolDesignator: Name of the protocol, e.g. geo_cnh
  • tokenDesignator: Name of the token, e.g. lpvSpeed
  • byteOffset: Offset from the beginning of the token in byte
  • length: Length of the integer value, must be 1, 2, 3 or 4 byte
  • networkByteOrder:
    • 0: INTEL (little-endian)
    • 1: MOTOROLA (big-endian)

Return Values

With C2xGetLastError you can check if the function has been processed successfully.
  • 0: —
  • ≠0: Integer value of the token

Example

Node System - PreStart in CAPL Browser
Node Callback Function in CAPL Browser