Skip to main content

GetPDUsTPUDPSrcPort

Valid for: CANoe DE • CANoe4SW DE

Function Syntax

Description

This function can only be used within a on PDU handler. If the PDU was received via UDP, with this function the UDP source port can be requested.

Parameters

  • this: Handle to the currently handled (received) PDU object.
  • udpSourcePort: UDP source port.

Return Values

  • 0: Data access successful.
  • -1: Wrong bus system.
  • -2: The requested information was not available. Most probably the PDU was not received by an UDP layer.
  • -3: The PDU object is invalid.
  • -4: PDU is not of RX type.
  • -5: Parameter too small (e.g. array has too less bytes)
  • -6: Message or PDU is not available (any more)

Example

GetPDUsTPIPv4DstAddrGetPDUsTPIPv4SrcAddrGetPDUsTPIPv6DstAddrGetPDUsTPIPv6SrcAddrGetPDUsTPTCPDstPortGetPDUsTPTCPSrcPortGetPDUsTPUDPDstPort