Search tips

apple banana
Find rows that contain at least one of the two words.

+apple +juice
Find rows that contain both words.

+apple macintosh
Find rows that contain the word 'apple', but rank rows higher if they also contain 'macintosh'.

+apple -macintosh
Find rows that contain the word 'apple' but not 'macintosh'.

+apple ~macintosh
Find rows that contain the word 'apple', but if the row also contains the word 'macintosh', rate it lower than if row does not. This is "softer" than a search for '+apple -macintosh', for which the presence of 'macintosh' causes the row not to be returned at all.

+apple +(>turnover >strudel)
Find rows that contain the words 'apple' and 'turnover', or 'apple' and 'strudel' (in any order), but rank 'apple turnover' higher than 'apple strudel'.

Find rows that contain words such as 'apple', 'apples', 'applesauce', or 'applet'.

"some words"
Find rows that contain the exact phrase 'some words' (for example, rows that contain 'some words of wisdom' but not "some noise words").

By continuing to use this site you agree to the use of cookies. For more information and to find out how to change this click here. Accept Cookies
Please enable cookies in your browser for this website.
Advanced search

Creating a CAPL PDU Gateway Between Two Ethernet Networks

Last updated: 2020-05-13

How can I set up a gateway for PDUs between two Ethernet networks using AUTOSAR databases ≥ 4.2.1?


The gateway can be realized by routing the PDUs and works similar to a frame-based approach. Key to the gateway is the CAPL function TriggerPDU2(), which uses the following syntax:

long TriggerPDU2 ( PDU * obj, dword dstBusContext, char DBName[], char TXNode[], char PDUName[], dword ShortHeaderID, dword LongHeaderID, dword Flags, dword PduLength);


  • obj: PDU object (or keyword this of on PDU event handler)
  • dstBusContext: bus context of destination bus in simulation setup
  • DBName: Name of database (optional, e.g. empty string "")
  • TXNode: Name of TX node in database (optional, e.g. empty string "")
  • PDUName: Name of the PDU in the database to be used in order to identify PDU on destination bus (prio 3)
  • ShortHeaderID: Short header ID to be used in order to identify PDU on destination bus (prio 2)
  • LongHeaderID: Long header ID to be used in order to identify PDU on destination bus (prio 1)
  • Flags: reserved, should be set to 0 (0x10 allows payload length manipulation)
  • PduLength: reserved; should be set to payload length of PDU in [Byte]

Return values:

  •  0: successful
  • -1: any name parameter invalid (null)
  • -2: PDU obj invalid (null)
  • -3: destination channel is invalid
  • -4: measurement is not running
  • -5: PDU server of TX node is not present (TX node not present on destination bus in simulation setup)

Please see this script. It’s also part of this sample configuration.

  pdu Eth1::VGW::EMotorStatus pduTx;

  // Contexts
  dword ctx_Eth1;
  dword ctx_Eth2;
  dword ctx_Other;

on prestart
  ctx_Eth1 = getBusNameContext( "Eth1" );
  ctx_Eth2 = getBusNameContext( "Eth2" );  

on PDU Eth1::VGW::EMotorStatus  
  long ret;
  write ("Got PDU %s",;
  ret=triggerPDU2( pduTx, ctx_Eth2, "Vehicle_Ethernet2", "VGW",, pduTx.ShortHeaderID, pduTx.LongHeaderID, pduTx.ValidationFlags,pduTx.PduLength);  //triggerPDU2 CAPL Function used for forwarding any PDU to another bus but this function not documented in CANoe help yet.


This script is valid for AUTOSAR databases ≥ version 4.2.1.

Article Options
Views: 118