Skip to main content
Open topic with navigation CAPL Functions » J1939 » J1939 NL » J1939AppNmtIndication

J1939AppNmtIndication (Callback)

Valid for: CANoe DE • CANoe4SW DE

Function Syntax

dword J1939AppNmtIndication( long busHandle, long address, long flag );

Description

This function is called when an ECU claims an address or an ECU loses its address. The function is also called if no ECU was created yet. With J1939GetRxData() the device name can be copied to a buffer.

Parameters

  • busHandle: bus handle
  • address: address of the ECU or Null-Address
  • flag: reason for calling this function:
    • 1: an ECU starts claiming, Address Claim PG received
    • 2: successfully claimed, 250 ms after Address Claim PG
    • 3: Cannot Claim Address received

Return Values

Example

dword J1939AppNmtIndication( LONG busHandle, LONG address, LONG flag )
{
  char deviceName[8];
  J1939GetRxData( elCount(deviceName), deviceName ); 
  /* user code */
  return 0; 
}