Skip to main content

AfdxOutputPacket

Valid for: CANoe DE • CANoe:lite DE • CANoe4SW DE • CANoe4SW:lite DE

Function Syntax

long AfdxOutputPacket( long packet ); // form 1
long AfdxOutputPacket( long packet, long txMode, long frag, long vl, long seqNo, long rma ); // form 2

Description

The specified AFDX message is transmitted with this function call. Note that the user has complete control of all the transmission scenarios. If the message is defined in an AFDX database the corresponding message attributes (e.g. timing, redundancy) are used for the transmission. Your CANoe DE product internally uses an AFDX software stack for the message handling. In the following cases the message needs to be defined in a DBC file and the file needs to be assigned to the actual configuration:
  • Form 1 is used
  • Form 2 is used with at least one of the parameters set to the listed value:
    • txMode = 0 (CyclicOff), 1 (CyclicOn)
    • frag = 1 (DoIPFragmentation)
    • vl = 1 (DoAFDXVLScheduling)
    • rma = 0 (DBRelated)

Parameters

  • packet: Handle of the message to send that has been created with AfdxInitPacket.
  • txMode: Set message’s transmission behavior:
    • 0: (CyclicOff) An active cyclic transmission is switched off. The corresponding message is transmitted at least once after this call.
    • 1: (CyclicOn) The message is transmitted cyclically and the cycle time is defined via the attribute AfdxMsgTxRate in the assigned DBC file.
    • 2: (SingleShot) The message is transmitted once.
  • frag: Activate or deactivate IP fragmentation:
    • 0: (NoIPFragmentation) The message is transmitted without fragmentation.
    • 1: (DoIPFragmentation) This parameter value activates the IP fragmentation for a message based on the attributes in the DBC file. The fragment’s size corresponds to the value of the attribute AfdxVLmaxFrame.
  • vl: Activate/deactivate software controlled VL scheduling:
    • 0: (NoAFDXVLScheduling) The corresponding virtual link of this message is not controlled by the AFDX software stack.
    • 1: (DoAFDXVLScheduling) The corresponding virtual link of this message is controlled by the AFDX software stack.
  • seqNo: Activate/deactivate automatic sequence number handling:
    • 0: (NoAFDXSeqNoManagement) The actual sequence number from message’s payload is used.
    • 1: (DoAFDXSeqNoManagement) The sequence number is automatically updated for the message.
  • rma: Activate a specific redundancy handling mode.
    ValueShort NameDescriptionInterface_ID updated?Message duplicated?
    0DBRelatedThe line assignment for the message is derived from the assigned DBC fileXX
    1ForceAThe message is transmitted on the specified line.X
    2ForceBThe message is transmitted on the specified line.X
    3ForceABThe message is transmitted on both lines.XX
    4ForceAonBThe message is transmitted on the other line. The assignment is inverted.X
    5ForceBonAThe message is transmitted on the other line. The assignment is inverted.X
    6ForceABonBAThe message is transmitted on both lines and the line assignment is inverted.XX
    7ForceLineAThe message is transmitted on the specified line.
    8ForceLineBThe message is transmitted on the specified line.
    9ForceLineABThe message is transmitted on both lines.X
    10MACIFRelatedThe line assignment is derived from the given MAC source address.X

Return Values

Example

See example of AfdxInitPacket See Also