0% found this document useful (0 votes)
103 views

AUTOSAR SWS FlexRayInterface

Uploaded by

Stefan Ruscanu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
103 views

AUTOSAR SWS FlexRayInterface

Uploaded by

Stefan Ruscanu
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 177

Specification of FlexRay Interface

AUTOSAR CP R20-11

Document Title Specification of FlexRay


Interface
Document Owner AUTOSAR
Document Responsibility AUTOSAR
Document Identification No 27

Document Status published


Part of AUTOSAR Standard Classic Platform
Part of Standard Release R20-11

Document Change History


Date Release Changed by Change Description
2020-11-30 R20-11 AUTOSAR  Editorial changes
Release
Management
2019-11-28 R19-11 AUTOSAR  Clarification on handling of
Release dynamic length LSdus
Management  Changed Document Status from
Final to published
2018-10-31 4.4.0 AUTOSAR  Added bus mirroring support
Release  Changed behavior for TxConflict
Management
 Minor corrections
2017-12-08 4.3.1 AUTOSAR  Runtime error rollout
Release  UL_TxConfirmation replaced with
Management UL_TriggerTransmit in affected
requirements
2016-11-30 4.3.0 AUTOSAR  New feature to get the
Release “TxConflictState”
Management  Introduce reliable TxConfirmation
 Unused bit handling reworked
 Several bug fixes
2015-07-31 4.2.2 AUTOSAR  Minor corrections
Release  Editorial changes
Management
2014-10-31 4.2.1 AUTOSAR  Support for
Release GlobalTimeSynchronization added
Management  Minor corrections
2014-03-31 4.1.3 AUTOSAR  Added Chapter for Production
Release Errors
Management  Editorial Changes

1 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Document Change History


Date Release Changed by Change Description
2013-10-31 4.1.2 AUTOSAR  Minor corrections
Release  Editorial changes
Management
 Removed chapter(s) on change
documentation
2013-03-15 4.1.1 AUTOSAR  Traceability requirements added
Administration  Several Bug fixes
 Editorial Changes
2011-12-22 4.0.3 AUTOSAR  Added User-defined
Administration communication operations
2010-09-30 3.1.5 AUTOSAR  API “FrIf_GetCycleLength” added
Administration  API “FrIf_ReadCCConfig” added
 APIs
FrIf_EnableTransceiverWakeup /
FrIf_DisableTransceiverWakeup
removed
 Configuration parameter
“FrIfByteOrder” added
2010-02-02 3.1.4 AUTOSAR  Added support for FlexRay 3.0
Administration hardware (CCs and transceivers)
 Added functionalities to get
detailed (error) information of the
communications bus
 Added support for single/key-slot
mode
 Added “cancel transmission”
support
 Legal disclaimer revised
2008-08-13 3.1.1 AUTOSAR  Legal disclaimer revised
Administration
2008-02-01 3.0.2 AUTOSAR  Correction of Figure 5.1
Administration

2 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Document Change History


Date Release Changed by Change Description
2007-12-21 3.0.1 AUTOSAR  Simplification of the FlexRay
Administration Interface State Machine due to the
introduction of the new AUTOSAR
SWS FlexRay State Manager
 Cluster-based APIs were removed
due to the introduced AUTOSAR
SWS FlexRay State Manager
 The FlexRay Interface does not
initialize any other modules any
more due to the introduction of the
"flat initialization" for AUTOSAR
release 3.0Document meta
information extended
 Small layout adaptations made
2007-01-24 2.1.15 AUTOSAR  “Advice for users” revised
Administration  Legal disclaimer added
 “Revision Information” added
 Release Notes added
2006-05-16 2.0 AUTOSAR  Second Release
Administration
2005-05-31 1.0 AUTOSAR  Initial Release
Administration

3 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Disclaimer

This work (specification and/or software implementation) and the material contained
in it, as released by AUTOSAR, is for the purpose of information only. AUTOSAR
and the companies that have contributed to it shall not be liable for any use of the
work.
The material contained in this work is protected by copyright and other types of
intellectual property rights. The commercial exploitation of the material contained in
this work requires a license to such intellectual property rights.
This work may be utilized or reproduced without any modification, in any form or by
any means, for informational purposes only. For any other purpose, no part of the
work may be utilized or reproduced, in any form or by any means, without permission
in writing from the publisher.
The work has been developed for automotive applications only. It has neither been
developed, nor tested for non-automotive applications.
The word AUTOSAR and the AUTOSAR logo are registered trademarks.

4 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Table of Content

1 Introduction and Functional Overview ................................................................... 9

2 Information about this Document ......................................................................... 10


2.1 General Hints ................................................................................................ 10
2.2 Acronyms and Abbreviations ........................................................................ 11
3 Related Documentation ....................................................................................... 12
3.1 Input Documents ........................................................................................... 12
3.2 Related Standards and Norms ..................................................................... 13
3.3 Related specification..................................................................................... 13
4 Constraints and Assumptions .............................................................................. 14
4.1 Limitations ..................................................................................................... 14
4.2 Applicability to Car Domains ......................................................................... 15
5 Dependencies to Other Modules ......................................................................... 16
5.1 AUTOSAR Operating System ...................................................................... 16
5.2 All Upper Layer AUTOSAR BSW Modules .................................................. 16
5.3 AUTOSAR PDU-Router ................................................................................ 16
5.4 AUTOSAR FlexRay Network Management.................................................. 17
5.5 AUTOSAR FlexRay Transport Protocol ....................................................... 17
5.6 AUTOSAR Bus Mirroring .............................................................................. 17
5.7 AUTOSAR FlexRay Driver ........................................................................... 17
5.8 AUTOSAR FlexRay Transceiver Driver ....................................................... 17
5.9 File Structure................................................................................................. 18
5.9.1 Header File Structure ............................................................................ 18
6 Requirements Traceability ................................................................................... 19
6.1 Specification Items ........................................................................................ 20
7 Functional Specification ....................................................................................... 22
7.1 FlexRay BSW Stack ..................................................................................... 22
7.2 Indexing Scheme .......................................................................................... 22
7.2.1 Principle ................................................................................................. 22
7.2.2 Supported Indexed Resources .............................................................. 26
7.3 FlexRay Interface State Machine ................................................................. 26
7.3.1 FlexRay Interface Main Function .......................................................... 28
7.4 Implementation Requirements...................................................................... 30
7.5 Configuration description .............................................................................. 31
7.6 Data Communication via FlexRay ................................................................ 31
7.6.1 PDU Packing, PDU update bits, and Frame Construction Plans ......... 32
7.6.2 Dynamic PDU length ............................................................................. 34
7.6.3 AlwaysTransmit ..................................................................................... 34
7.6.4 Realization of the Time-Driven FlexRay Schedule ............................... 35
7.6.5 Communication Operations ................................................................... 37
7.6.6 Transmission with Immediate Buffer Access ........................................ 45
7.7 Error Classification ........................................................................................ 46
7.7.1 Development Errors............................................................................... 46
5 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

7.7.2 Runtime Errors ...................................................................................... 47


7.7.3 Transient Faults ..................................................................................... 47
7.7.4 Production Errors................................................................................... 48
7.7.5 Extended Production Errors .................................................................. 51
8 API Service Specification ..................................................................................... 52
8.1 Imported types .............................................................................................. 52
8.2 Type Definitions ............................................................................................ 53
8.2.1 FrIf_ConfigType ..................................................................................... 53
8.2.2 FrIf_StateType ....................................................................................... 53
8.2.3 FrIf_StateTransitionType ....................................................................... 54
8.3 Function Definitions ...................................................................................... 55
8.3.1 FrIf_Init ................................................................................................... 55
8.3.2 FrIf_ControllerInit ................................................................................... 57
8.3.3 FrIf_SetAbsoluteTimer .......................................................................... 58
8.3.4 FrIf_EnableAbsoluteTimerIRQ .............................................................. 59
8.3.5 FrIf_AckAbsoluteTimerIRQ ................................................................... 60
8.3.6 FrIf_StartCommunication ...................................................................... 61
8.3.7 FrIf_HaltCommunication ........................................................................ 62
8.3.8 FrIf_AbortCommunication ..................................................................... 63
8.3.9 FrIf_GetState ......................................................................................... 65
8.3.10 FrIf_SetState ......................................................................................... 66
8.3.11 FrIf_SetWakeupChannel ....................................................................... 67
8.3.12 FrIf_SendWUP ...................................................................................... 68
8.3.13 FrIf_GetPOCStatus ............................................................................... 69
8.3.14 FrIf_GetGlobalTime ............................................................................... 71
8.3.15 FrIf_AllowColdstart ................................................................................ 72
8.3.16 FrIf_GetMacroticksPerCycle ................................................................. 73
8.3.17 FrIf_GetMacrotickDuration .................................................................... 74
8.3.18 FrIf_Transmit ......................................................................................... 75
8.3.19 FrIf_SetTransceiverMode ...................................................................... 76
8.3.20 FrIf_GetTransceiverMode ..................................................................... 78
8.3.21 FrIf_GetTransceiverWUReason ............................................................ 79
8.3.22 FrIf_ClearTransceiverWakeup .............................................................. 80
8.3.23 FrIf_CancelAbsoluteTimer..................................................................... 82
8.3.24 FrIf_GetAbsoluteTimerIRQStatus ......................................................... 84
8.3.25 FrIf_DisableAbsoluteTimerIRQ ............................................................. 85
8.3.26 FrIf_GetCycleLength ............................................................................. 86
8.4 Optional Function Definitions ........................................................................ 88
8.4.1 FrIf_AllSlots ........................................................................................... 88
8.4.2 FrIf_GetChannelStatus .......................................................................... 89
8.4.3 FrIf_GetClockCorrection ........................................................................ 90
8.4.4 FrIf_GetSyncFrameList ......................................................................... 91
8.4.5 FrIf_GetNumOfStartupFrames .............................................................. 92
8.4.6 FrIf_GetWakeupRxStatus ..................................................................... 93
8.4.7 FrIf_CancelTransmit .............................................................................. 94
8.4.8 FrIf_DisableLPdu ................................................................................... 96
8.4.9 FrIf_GetTransceiverError ...................................................................... 97
8.4.10 FrIf_EnableTransceiverBranch ............................................................. 98
8.4.11 FrIf_DisableTransceiverBranch ........................................................... 100
6 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

8.4.12 FrIf_ReconfigLPdu............................................................................... 102


8.4.13 FrIf_GetNmVector ............................................................................... 103
8.4.14 FrIf_GetVersionInfo ............................................................................. 104
8.4.15 FrIf_ReadCCConfig ............................................................................. 105
8.4.16 FrIf_EnableBusMirroring ..................................................................... 106
8.5 Interrupt Service Routines .......................................................................... 108
8.5.1 FrIf_JobListExec_<FrIfCluster.ShortName> ....................................... 108
8.6 Call-back Notifications ................................................................................ 109
8.6.1 FrIf_CheckWakeupByTransceiver ...................................................... 109
8.7 Scheduled Functions .................................................................................. 110
8.7.1 FrIf_MainFunction_<FrIfCluster.ShortName> ..................................... 110
8.8 Expected Interfaces .................................................................................... 111
8.8.1 Mandatory Interfaces ........................................................................... 111
8.8.2 Optional Interfaces .............................................................................. 113
8.8.3 Configurable Interfaces ....................................................................... 116
9 Sequence Diagrams........................................................................................... 123
9.1 Data Transmission ...................................................................................... 123
9.1.1 TransmitWithImmediateBufferAccess ................................................. 123
9.1.2 TransmitWithDecoupledBufferAccess ................................................ 124
9.1.3 ProvideTxConfirmation ........................................................................ 125
9.2 Data Reception ........................................................................................... 126
9.2.1 ReceiveAndIndicate............................................................................. 126
9.2.2 ReceiveAndStore................................................................................. 127
9.2.3 ProvideRxIndication............................................................................. 128
9.2.4 Cancel Transmission ........................................................................... 129
9.3 Prepare LPDU............................................................................................. 130
10 Configuration Specification............................................................................. 131
10.1 How to Read this Chapter........................................................................... 131
10.2 Containers and Configuration Parameters ................................................. 131
10.2.1 FrIf........................................................................................................ 132
10.2.2 FrIfGeneral........................................................................................... 133
10.2.3 FrIfCluster ............................................................................................ 141
10.2.4 FrIfController ........................................................................................ 151
10.2.5 FrIfTransceiver .................................................................................... 154
10.2.6 FrIfLPdu ............................................................................................... 155
10.2.7 FrIfFrameTriggering............................................................................. 156
10.2.8 FrIfJobList ............................................................................................ 160
10.2.9 FrIfJob .................................................................................................. 161
10.2.10 FrIfCommunicationOperation .......................................................... 163
10.2.11 FrIfFrameStructure........................................................................... 164
10.2.12 FrIfPdusInFrame .............................................................................. 165
10.2.13 FrIfPdu ............................................................................................. 166
10.2.14 FrIfTxPdu ......................................................................................... 167
10.2.15 FrIfRxPdu ......................................................................................... 170
10.2.16 FrIfPduDirection ............................................................................... 172
10.2.17 FrIfConfig ......................................................................................... 172
10.2.18 FrIfClusterDemEventParameterRefs ............................................... 173
10.2.19 FrIfFrameTriggeringDemEventParameterRefs ............................... 175
10.3 Published Information ................................................................................. 176
7 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

11 Not applicable requirements .......................................................................... 177

8 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

1 Introduction and Functional Overview


This specification specifies the functionality, API and the configuration of the
AUTOSAR Basic Software module "FlexRay Interface".

In the AUTOSAR Layered Software Architecture Layered Software Architecture, the


FlexRay Interface belongs to the ECU Abstraction Layer, or more precisely, to the
Communication Hardware Abstraction. This indicates the main task of the FlexRay
Interface:

Provide to upper layers an abstract interface to the FlexRay Communication System.


At least as far as data transmission (i.e. data sending and reception) is concerned,
this interface shall be uniform for all bus systems in Autosar (FlexRay, CAN, LIN).
Thus, the upper layer (Communication Services like PDU Router, Transport Protocol,
and Network Management and others) may access all underlying bus systems for
data transmission in a uniform manner. The configuration of the FlexRay Interface
however is bus-specific, since it takes into account the specific features of the
communication system.
The FlexRay Interface does not directly access the FlexRay hardware (FlexRay
Communication Controller and FlexRay Transceiver), but by means of one or more
hardware-specific Driver modules.

In order to access the FlexRay Communication Controller(s), the FlexRay Interface


uses one or multiple FlexRay Driver modules, which abstract the specific features
and interfaces (CHI) of the respective FlexRay Communication Controller(s).

Likewise, in order to access the FlexRay Transceiver(s), the FlexRay Interface shall
use one or multiple FlexRay Transceiver Driver module(s), which abstract the specific
features and interfaces of the respective FlexRay Transceiver(s)

Therefore, the FlexRay Interface executable code (however, not the configuration
used during runtime) shall be completely independent of the FlexRay Communication
Controller(s) and the FlexRay Transceiver(s).

Note: The FlexRay Interface is specified in a way that allows for object code delivery
of the code module, following the "one-fits-all" principle, i.e. the entire configuration of
the FlexRay Interface can be carried out without modifying any source code. Thus,
the configuration of the FlexRay Interface can be carried out largely without detailed
knowledge of the underlying hardware.

The FlexRay Interface provides to upper layer AUTOSAR BSW modules the
following groups of functions:
 initialization
 data transmission (sending and reception)
 start/halt/abort communication
 FlexRay specific functions (e.g. send wake-up pattern)
 set operation mode
 get status information
 various timer functions
9 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

2 Information about this Document

2.1 General Hints

In general, the FlexRay Interface has no knowledge of the origin of a PDU passed to
it in an API service call.

Therefore, throughout this document, the term "PDU" is being used for PDUs
originating from or sent to:

 AUTOSAR Com (I-PDU) via the PDU-Router, or


 AUTOSAR FlexRay TP (N-PDU), or
 AUTOSAR FlexRay NM
 AUTOSAR XCP

In addition to the above-mentioned AUTOSAR BSW modules, the FrIf shall, with the
functionality described within the specification in hand, also support other non-
AUTOSAR upper layer software modules (Complex Drivers), provided that these
modules interact with the FrIf in the same manner as the upper layer AUTOSAR
BSW modules.

Throughout this document, several scenarios for changing configuration data are
mentioned. They are being used as follows:
 "pre compile time" = carried out before compiling the code of the FlexRay
Interface, since the code generation depends on this setting.
 "at system configuration time" = static configuration parameters stored in
the FlexRay Interface; may be defined after compilation of the code of the
FlexRay Interface ("link time" or "post build time"), but have to be defined
before the first execution of the FlexRay Interface code.
 "during runtime" = dynamically switching (in POC:normal active state of the
FlexRay CC, if supported) between different configuration parameter sets
stored in the static configuration of the FlexRay Interface, or the FlexRay
Driver, respectively.
Everything not explicitly mentioned in this document, should be considered as
implementation-specific.

10 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

2.2 Acronyms and Abbreviations

The following acronyms and abbreviations are used throughout this document:

Acronym: Description:
BSW (AUTOSAR) Basic Software
CAS Collision Avoidance Symbol
CC (FlexRay) Communication Controller
CDD Complex Driver
CHI Controller Host Interface of a FlexRay CC
COM Communication (AUTOSAR BSW module)
ComM Communication Manager (AUTOSAR BSW module)
DEM Diagnostic Event Manager (AUTOSAR BSW module)
DET Default Error Tracer (AUTOSAR BSW module)
FrIf FlexRay Interface (AUTOSAR BSW module)
FrNm FlexRay Network Management (AUTOSAR BSW module)
FrTp FlexRay Transport Layer (AUTOSAR BSW module)
ISR Interrupt Service Routine
MCG Module Configuration Generator
PduR PDU Router (AUTOSAR BSW module)
POC Protocol Operation Control
WUDOP Wake-Up During Operation
WUP Wake-Up Pattern
WUS Wake-Up Symbol
System Designer The person responsible for the configuration of all system
parameters that do not influence the executable code itself (i.e.
the sequence of instructions executed during runtime), but the
data used to configure which operations this executable code
performs on which data and at which points in time.

Abbreviation: Description:
i.e. [lat.] id est = [eng.] that is
e.g. [lat.] exempli gratia = [eng.] for example
N/A not applicable

11 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

3 Related Documentation

3.1 Input Documents

[1] List of Basic Software Modules


AUTOSAR_TR_BSWModuleList.pdf

[2] Layered Software Architecture


AUTOSAR_EXP_LayeredSoftwareArchitecture.pdf

[3] General Requirements on Basic Software Modules


AUTOSAR_SRS_BSWGeneral.pdf

[4] Input for API Specification of AUTOSAR COM Stack

[5] Specification of Communication Stack Types


AUTOSAR_SWS_CommunicationStackTypes.pdf

[6] Requirements on FlexRay


AUTOSAR_SRS_FlexRay.pdf

[7] Specification of FlexRay Driver


AUTOSAR_SWS_FlexRay.pdf

[8] Specification of FlexRay State Manager


AUTOSAR_SWS_FlexRayStateManager.pdf

[9] Specification of FlexRay Transceiver Driver


AUTOSAR_SWS_FlexRayTransceiverDriver.pdf

[10] Specification of FlexRay Transport Layer


AUTOSAR_SWS_FlexRayTransportLayer.pdf

[11] Specification of FlexRay Network Management


AUTOSAR_SWS_FlexRayNetworkManagement.pdf

[12] Specification of PDU Router


AUTOSAR_SWS_PDURouter

[13] Specification of BSW Scheduler


AUTOSAR_SWS_BSW_Scheduler

[14] Specification of ECU Configuration


AUTOSAR_TPS_ECUConfiguration

[15] Specification of Memory Mapping


AUTOSAR_SWS_MemoryMapping
12 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[16] General Specification of Basic Software Modules


AUTOSAR_SWS_BSWGeneral.pdf

3.2 Related Standards and Norms

[17] FlexRay Communications System Protocol Specification Version 2.1


Revision A

[18] FlexRay Communications System Electrical Physical Layer Specification


Version 2.1 Revision A

[19] FlexRay Communications System Protocol Specification Version 3.0

[20] Flexray Communications System Electrical Physical Layer Specification 3.0

3.3 Related specification

AUTOSAR provides a General Specification on Basic Software modules [16] (SWS


BSW General), which is also valid for FlexRay Interface.

Thus, the specification SWS BSW General shall be considered as additional and
required specification for FlexRay Interface.

13 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

4 Constraints and Assumptions

4.1 Limitations

The FlexRay BSW modules are only able to handle a single thread of execution per
Cluster. The execution for a particular Cluster must not be pre-empted by itself for
the same Cluster. The same applies to the execution of the FlexRay Job List
Execution Function.

It is not possible to transmit signals, PDUs, and/or L-SDUs, which exceed the
available buffer size of the used FlexRay CC during normal operation. Longer
signals, PDUs, and/or L-SDUs have to be transmitted using the FlexRay Transport
Protocol.

Note: The FlexRay Interface does not make any PDU payload-dependent routing
decisions.

Note: In order for the AUTOSAR FlexRay BSW (FrIf and FlexRay Driver) modules to
be able to control a FlexRay CC, this CC must allow for configuring its
transmit/receive buffers to support the Cycle Counter Filter Criterion / (Support of
Slot/Cycle Muliplexing)

For 2.1 FlexRay Hardware, the following Cycle Counter Filtering is possible

Cycle Number = (B + n * 2R)mod64

with exactly one tuple of values for B and 2R, where:


 Base Cycle B  [0 … 63]
 Cycle Repetition 2R ; R  [0 … 6]
 Variable n = 0 … 63
 B < 2R

For 3.0 FlexRay Hardware, the Cycle Counter Filtering shall be possible as described
in [19]

14 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

4.2 Applicability to Car Domains

The FlexRay BSW Stack can be used wherever high data rates and fault tolerant
communication (in conjunction with AUTOSAR COM) are required. Of course, it can
also be used for less-demanding use cases, i.e. for low data rates or non-fault-
tolerant communication. Furthermore, it enables the synchronized operation of
several ECUs within a car.

15 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

5 Dependencies to Other Modules

5.1 AUTOSAR Operating System

[SWS_FrIf_05099] ⌈There is one dedicated FlexRay Job List Execution Function for
each FlexRay Cluster. ⌋ ()

[SWS_FrIf_05100] ⌈The FlexRay Interface module shall execute the Flexray Job List
Execution Function. ⌋ ()

Note: It is up to the implementer whether the FlexRay Job List Execution Functions
run in a task context or in an ISR.

5.2 All Upper Layer AUTOSAR BSW Modules

[SWS_FrIf_05050] ⌈The calling of the FlexRay Job List Execution Function by the
FlexRay Interface module synchronously to the FlexRay Global Time shall ensure
that both the indication (to an upper layer BSW module) of received data and the
request (to an upper layer BSW module) for data to be sent occur synchronously to
the FlexRay Global Time. ⌋ (SRS_Fr_05000)

[SWS_FrIf_05148] ⌈The FlexRay Interface module shall ensure data consistency in


its buffers. ⌋ ()

Rationale for SWS_FrIf_05148: If the respective upper layer BSW module does not
operate synchronously to the FlexRay Global Time, these occurrences are
asynchronous to the code execution of this BSW module.

5.3 AUTOSAR PDU-Router

The FrIf module declares and calls some callback functions of the PDU-Router in
order to confirm transmission and notify reception of PDUs.

16 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

5.4 AUTOSAR FlexRay Network Management

The FrIf module declares and calls some callback functions of the FlexRay Network
Management in order to confirm transmission and notify reception of PDUs.

5.5 AUTOSAR FlexRay Transport Protocol

The FrIf module declares and calls some callback functions of the FlexRay Transport
Protocol in order to confirm transmission and notify reception of PDUs.

5.6 AUTOSAR Bus Mirroring


The FrIf module calls a callback function of the Bus Mirroring module in order to
report received and transmitted frames, which in turn calls some service functions of
the FrIf module to acquire the network state.

5.7 AUTOSAR FlexRay Driver

The FrIf module has a tight relation to the FlexRay Driver since many of the FlexRay-
related services offered by the FrIf module to upper layer BSW modules are actually
carried out by the FlexRay Driver BSW module. For those services, the FrIf module
mainly performs only an abstraction of the communication hardware specific
information (e.g. the topology of the FlexRay Communication System) and then calls
the respective FlexRay Driver with the appropriate parameters.

The FlexRay Driver module has to be the only BSW module which has to run
necessarily synchronous to the FlexRay Interface.

5.8 AUTOSAR FlexRay Transceiver Driver

The FrIf module has a tight relation to the FlexRay Transceiver Driver since calls of
API services of the FlexRay Transceiver Driver are also routed through the FrIf
module in order to abstract the communication hardware specific information (e.g.
the topology of the FlexRay Communication System).

17 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

5.9 File Structure

5.9.1 Header File Structure

Please refer to the chapter 5.1.7 Header file structure in “SWS_BSWGeneral” [16].

[SWS_FrIf_05087] ⌈The FrIf module source code file(s) shall include SchM_FrIf.h if
data consistency mechanisms of the BSW scheduler are required as described in
[13]. ⌋ ()

[SWS_FrIf_05090] ⌈The header file FrIf.h shall contain a software and specification
version number. ⌋ (SRS_BSW_00004)

[SWS_FrIf_05095] ⌈ Mirror.h contains the declaration of the API service the Bus
Mirroring module offers to the FlexRay Interface. This header is only included if Bus
Mirroring is enabled (see FrIfBusMirroringSupport).⌋ (SRS_BSW_00004)

18 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

6 Requirements Traceability
Requirement Description Satisfied by
SRS_BSW_00004 All Basic SW Modules shall perform a pre-processor SWS_FrIf_05090,
check of the versions of all imported include files SWS_FrIf_05095
SRS_BSW_00101 The Basic Software Module shall be able to initialize SWS_FrIf_05003
variables and hardware in a separate initialization
function
SRS_BSW_00170 The AUTOSAR SW Components shall provide SWS_FrIf_05089
information about their dependency from faults, signal
qualities, driver demands
SRS_BSW_00171 Optional functionality of a Basic-SW component that is SWS_FrIf_05089
not required in the ECU shall be configurable at pre-
compile-time
SRS_BSW_00304 All AUTOSAR Basic Software Modules shall use the SWS_FrIf_05001
following data types instead of native C data types
SRS_BSW_00334 All Basic Software Modules shall provide an XML file that SWS_FrIf_05089
contains the meta data
SRS_BSW_00336 Basic SW module shall be able to shutdown SWS_FrIf_05006
SRS_BSW_00342 It shall be possible to create an AUTOSAR ECU out of SWS_FrIf_05078
modules provided as source code and modules provided
as object code, even mixed
SRS_BSW_00345 BSW Modules shall support pre-compile configuration SWS_FrIf_05069
SRS_BSW_00348 All AUTOSAR standard types and constants shall be SWS_FrIf_05001
placed and organized in a standard type header file
SRS_BSW_00353 All integer type definitions of target and compiler specific SWS_FrIf_05001
scope shall be placed and organized in a single type
header
SRS_BSW_00358 The return type of init() functions implemented by SWS_FrIf_05003
AUTOSAR Basic Software Modules shall be void
SRS_BSW_00361 All mappings of not standardized keywords of compiler SWS_FrIf_05001
specific scope shall be placed and organized in a
compiler specific type and keyword header
SRS_BSW_00375 Basic Software Modules shall report wake-up reasons SWS_FrIf_05036
SRS_BSW_00378 AUTOSAR shall provide a boolean type SWS_FrIf_05001
SRS_BSW_00404 BSW Modules shall support post-build configuration SWS_FrIf_05069
SRS_BSW_00405 BSW Modules shall support multiple configuration sets SWS_FrIf_05003
SRS_BSW_00407 Each BSW module shall provide a function to read out SWS_FrIf_05002
the version information of a dedicated module
implementation
SRS_BSW_00411 All AUTOSAR Basic Software Modules shall apply a SWS_FrIf_05002
naming rule for enabling/disabling the existence of the
API
SRS_BSW_00414 Init functions shall have a pointer to a configuration SWS_FrIf_05003
structure as single parameter
SRS_Fr_05000 Synchronous SW Modules shall be supported SWS_FrIf_05050
SRS_Fr_05007 The FlexRay Interface shall be able to communicate with SWS_FrIf_05053
at least four FlexRay CCs via the appropriate FlexRay
19 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Driver(s)
SRS_Fr_05010 Each PDU shall have one PDU-ID SWS_FrIf_05052
SRS_Fr_05013 The local Memory Space shall be initialized SWS_FrIf_05003
SRS_Fr_05015 The FlexRay Interface shall provide a software interface SWS_FrIf_05005
to start-up a specific FlexRay CC
SRS_Fr_05016 A FlexRay CC Communication shall be aborted when SWS_FrIf_05007
wanted
SRS_Fr_05018 The FlexRay Interface shall provide a software interface SWS_FrIf_05011
to send a wake-up pattern on a channel or CC
SRS_Fr_05022 FlexRay CC POC Status shall be available SWS_FrIf_05014
SRS_Fr_05027 A PDU shall be transmitted via the FlexRay SWS_FrIf_05063
communication system
SRS_Fr_05031 A FlexRay CC shall be initialized and configured SWS_FrIf_05004
SRS_Fr_05039 The Operation Mode of a FlexRay Transceiver shall be SWS_FrIf_05034
set
SRS_Fr_05042 The FlexRay Interface shall allow switching from one SWS_FrIf_05061
configuration to another one in Normal Active Mode
SRS_Fr_05056 Configuration of the FlexRay Interface shall be done at SWS_FrIf_05054
System Configuration Time
SRS_Fr_05063 A FlexRay CC Communication shall be halted when SWS_FrIf_05006
wanted
SRS_Fr_05096 Communication controllers shall be assigned to FlexRay SWS_FrIf_05060
Driver.
SRS_Fr_05097 The FlexRay Interface shall be able to communicate with SWS_FrIf_05057
at least four FlexRay Drivers
SRS_Fr_05126 PDU Update/Valid Information shall be handled SWS_FrIf_05056
SRS_Fr_05130 The FlexRay Interface shall support PDU transmission SWS_FrIf_05058
buffer queues
SRS_Fr_05157 The Operation Mode of a FlexRay Transceiver shall be SWS_FrIf_05035
available
SRS_Fr_05158 The wake-up reason of a specific FlexRay Transceiver SWS_FrIf_05036
device shall be available
SRS_Fr_05161 Pending Wake-up Events of a Transceiver shall be SWS_FrIf_05039
cleared if necessary
SRS_Fr_05170 PDUs received via the FlexRay communication system SWS_FrIf_05062
shall be retrieved

6.1 Specification Items


The following Items shall be seen as implementation hints only!

Functional Specification

Abstraction of FlexRay Transceivers FrIf05105,


FrIf05106
20 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Usage of Controller and Channel Index FrIf05106


Usage of zero-based index SWS_FrIf_05107
Usage of FR Cluster Index FrIf05108
Configuration Data FrIf05109
Usage of PDU index SWS_FrIf_05110
Support one of both or both FlexRay Channels SWS_FrIf_05111
Support of at least four FlexRay Clusters SWS_FrIf_05112
Support of at least one absolute timer per FlexRay CCs SWS_FrIf_05113

FlexRay Interface State Machine

One State Machine per Cluster SWS_FrIf_05115


FrIf_State offline during initialization SWS_FrIf_05117

FlexRay Interface Main Function

One Main Function for each FlexRay Cluster SWS_FrIf_05119


Main Function tasks FrIf05120

Data Communication via FlexRay

Packaging of multible PDUs in one FR Frame SWS_FrIf_05121


Frame construction plan (layout) SWS_FrIf_05122
Frame construction plan (config) SWS_FrIf_05123
Transmission rule SWS_FrIf_05124
Update Information per PDU SWS_FrIf_05125
Location of Update Information SWS_FrIf_05126
Configuration of Update Information SWS_FrIf_05127
Indication in case of no update information SWS_FrIf_05128
Transmission with Immediate Buffer Access SWS_FrIf_05129
Ensure synchronous buffer access SWS_FrIf_05130
Sortation of Communication Job SWS_FrIf_05131
Communication Job properties FrIf05368
Communication Job execution start time SWS_FrIf_05133
Actions specified by Communication Operation SWS_FrIf_05134
Communication Operation properties FrIf05369
Job List Execution Function nameing SWS_FrIf_05136
Job List synchronously to global time SWS_FrIf_05137
Job List Execution Function actions SWS_FrIf_05138

21 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7 Functional Specification

7.1 FlexRay BSW Stack

As part of the AUTOSAR Layered Software Architecture according to [2], the


FlexRay BSW modules also form a layered software stack.
Figure 7-1 depicts the basic structure of this FlexRay BSW stack. The FrIf module
accesses several CCs using the FlexRay Driver layer, which can be made up of
several FlexRay Drivers modules. The FlexRay Transceivers are not shown in this
figure; however, the structure that applies to the FlexRay Drivers and the FlexRay
CCs analogously applies to the FlexRay Transceiver Drivers and the FlexRay
Transceivers.

FlexRay Interface

Software
FlexRay Driver FlexRay Driver FlexRay Driver
Vendor A Vendor B Vendor C

Hardware
FlexRay CC FlexRay CC FlexRay CC FlexRay CC FlexRay CC
Type A Type A Type B Type C Type C

FlexRay physical medium

Figure 7-1: Basic Structure of the FlexRay BSW Stack

7.2 Indexing Scheme

7.2.1 Principle

22 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Most of the FrIf module’s API services used for accessing the numerous (hardware
and software) resources1 map to corresponding API services of the underlying
FlexRay Driver(s), or FlexRay Transceiver Driver(s), respectively.

In order to select those resources spread over the various entities2 accessed via the
FrIf module, the FlexRay-related AUTOSAR BSW modules use an indexing scheme
that is exemplarily described in Figure 7-2 and Figure 7-3.

Definition ControllerIndex: The ConctrollerIndex is an abstract, unique, zero-based


consecutive index to achieve the abstraction of the FlexRay Communication
Controllers, independent of their type, location, and access method.

Definition ClusterIndex: The ClusterIndex is an abstract, unique, zero-based


consecutive index to achieve the abstraction of the FlexRay Clusters, independent of
their type, location, and access method.

Definition ChannelIndex: The ChannelIndex has either the value FR_CHANNEL_A


or FR_CHANNEL_B. In combination with the ControlerIndex, the corresponding
FlexRay Transceiver is identified.

[SWS_FrIf_05052] ⌈The FrIf module shall achieve the abstraction (of the CCs and
Drivers) by providing to the upper layer BSW modules an abstract, unique, zero-
based consecutive index for each sort of resource, independent of their type,
location, and access method. ⌋ (SRS_Fr_05010)

Rationale: The FrIf module achieves the abstraction (of the CCs and Drivers) by
providing these abstract indices to the upper layer BSW modules.

The FrIf module API service uses the abstract index passed to it by the upper layer
BSW module to retrieve:
1. the function pointer to a corresponding lower layer BSW module's API
service from a static configuration data table containing function pointers to all
API services of all lower layer BSW modules called by the FrIf module, and
2. the translated index used in the call to the lower layer BSW module's API
service from a static configuration data table.

Since this static configuration data table contains function pointers to the lower layer
BSW module’s API services, it obviously has to be linked against the linked and
located code of the lower layer BSW modules.

The FrIf module then calls the corresponding lower layer BSW module's API service
via the function pointer and passes the translated index in the API call.

The function descriptions in chapter 8 specify the required calls of corresponding


lower layer BSW module's API services in detail.

1
E.g. timers, configuration data sets, etc.
2
FlexRay Drivers, FlexRay Communication Controllers, FlexRay Transceiver Drivers, and FlexRay
Transceivers
23 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

ECU

FrIf

FrIf_ClstIdx = 0 FrIf_ClstIdx = 1

FrIf_CtrlIdx = 0 FrIf_CtrlIdx = 1 FrIf_CtrlIdx = 2

Fr #0 Fr #1 Fr #0
Fr_CtrlIdx = 0 Fr_CtrlIdx = 0 Fr_CtrlIdx = 1
FlexRay CC FlexRay CC FlexRay CC
Type A Type B Type A

AT Fr_AbsTimerIdx = 0 AT Fr_AbsTimerIdx = 0 AT Fr_AbsTimerIdx = 0

AT Fr_AbsTimerIdx = 1 AT Fr_AbsTimerIdx = 1

RT Fr_RelTimerIdx = 0 RT Fr_RelTimerIdx = 0

Fr_ChnlIdx = FR_CHANNEL_A

Fr_ChnlIdx = FR_CHANNEL_B

Figure 7-2: CC Indexing Scheme of the FlexRay Interface

[SWS_FrIf_05060] ⌈In order to abstract for upper layer BSW modules the various
CCs, which the FrIf module controls via the FlexRay Driver modules, the FrIf module
offers an abstract, unique, zero-based consecutive index FrIfCtrlIdx as configuration
parameter, which maps to a tuple of FlexRay Driver API Service function pointer and
CC index Fr_CtrlIdx. ⌋ (SRS_Fr_05096)

24 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

ECU
FrIf
FrIf_ClstIdx = 0 FrIf_ClstIdx = 1

FrIf_CtrlIdx = 0 FrIf_CtrlIdx = 1 FrIf_CtrlIdx = 2

FrIf_ChnlIdx = FrIf_ChnlIdx = FrIf_ChnlIdx =


FR_CHANNEL_A FR_CHANNEL_B FR_CHANNEL_A FR_CHANNEL_B FR_CHANNEL_A FR_CHANNEL_B

FrTrcv #0 FrTrcv #1 FrTrcv #0 FrTrcv #1


FrTrcv_TrcvIdx FrTrcv_TrcvIdx FrTrcv_TrcvIdx FrTrcv_TrcvIdx
=0 =0 =1 =1
FlexRay Transceiver FlexRay TransceiverFlexRay Transceiver FlexRay Transceiver

Type A Type B Type A Type B

FR_CHANNEL_A

FR_CHANNEL_B

Figure 7-3: Flexray Transceiver Indexing Scheme of the FlexRay Interface

In order to abstract for upper layer BSW modules the various FlexRay Transceiver
modules, which the FrIf module accesses via the FlexRay Transceiver Driver
modules, the FrIf module takes advantage of the fact that each FlexRay Transceiver
module is unambiguously assigned to a specific Channel on a specific FlexRay CC.

Therefore, the FrIf module abstracts the various FlexRay Transceivers by a


combination of the two indices FrIf_CtrlIdx (Controller Index) and FrIf_ChnlIdx
(Channel Index) and maps this to a tuple of FlexRay Transceiver Driver API Service
function pointer and FlexRay Transceiver index FrTrcv_TrcvIdx. (Transceiver Index)

The function descriptions in chapter 8 specify the required mapping of upper layer
BSW module's parameters to corresponding lower layer BSW module's API services
in detail.”

[SWS_FrIf_05107] ⌈Besides hardware and software resources, the FrIf module also
numbers the logical structure elements presented by FlexRay with an abstract,
unique, zero-based consecutive index.

The static configuration data of the FrIf module contains a data structure that
specifies which FlexRay CC modules and which FlexRay Transceiver modules are
connected to which Clusters, or in other words, that maps each value of FrIf_ClstIdx
to (one, or in general) a set of values for FrIf_CtrlIdx and tuples of (FrIfCtrlIIdx,
FrIf_ChnlIdx). ⌋ ()

25 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05110] ⌈The FrIf module shall number all PDUs to be transmitted with an
abstract, unique, zero-based consecutive index TxPduId. ⌋ ()

Note:This index is used in the FrIf API service FrIf_Transmit() and allows the FrIf
module to quickly identify (e.g. by a table look-up) the PDU that is passed to it by an
upper layer BSW module, and to process it accordingly.

7.2.2 Supported Indexed Resources

[SWS_FrIf_05057] ⌈It shall be possible that the FrIf module can be configured to
support at least four (possibly different) FlexRay Drivers to access the FlexRay
Communication Controllers. ⌋ (SRS_Fr_05097)

[SWS_FrIf_05053] ⌈It shall be possible that the FrIf module can be configured using
the parameter FRIF_CTRL_IDX to support at least four (possibly different) FlexRay
CCs. ⌋ (SRS_Fr_05007)

[SWS_FrIf_05111] ⌈It shall be possible that the FrIf module can be configured to
support one of both or both FlexRay Channels as specified in [17]. ⌋ ()

[SWS_FrIf_05112] ⌈It shall be possible that the FrIf module can be configured using
the parameter FRIF_CLST_IDX to support at least four FlexRay Clusters. ⌋ ()

[SWS_FrIf_05113] ⌈It shall be possible that the FrIf module can be configured using
the parameter FRIF_ABS_TIMER_IDX to support at least one absolute timer per
FlexRay CCs. ⌋ ()

7.3 FlexRay Interface State Machine

[SWS_FrIf_05115] ⌈
In order to allow to control the communication operations of the FlexRay system, the
FrIf module shall implement a behavior, which is defined using a simple state
machine (one per FlexRay cluster), called FlexRay Interface State Machine

Initial

(1)
(2)
FRIF_STATE_OFFLINE FRIF_STATE_ONLINE
(3)

26 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Figure 7-4: FlexRay Interface State Machine

Figure 7-4 shows the states and transistions that are visible to the user of a FrIf
module. The two different states, which are defined as FrIf type FrIf_StateType (see
8.2.2), represent the communication capabilities of a FrIf module.

State Description
FRIF_STATE_OFFLINE No communication services are executed (see chapter 7.6
for details)
FRIF_STATE_ONLINE All communication services (reception, transmission,
transmission confirmation) are executed (see chapter 7.6
for details).
⌋ ()

[SWS_FrIf_05117] ⌈During initialization of the FrIf by executing FrIf_Init() the


FrIf_State for each cluster shall be initialized with state ‘FRIF_STATE_OFFLINE’.

The transitions are requested by an API service FrIf_SetState() which takes the
Cluster to process on and the Transistion name to invoke. ⌋ ()

[SWS_FrIf_05118] ⌈If the FrIf module’s environment calls the function FrIf_SetState
with parameter FrIf_StateTransition = FRIF_GOTO_ONLINE and if the current state
for the requested cluster is FRIF_STATE_OFFLINE, the FrIf module shall take the
current state of the requested cluster to FRIF_STATE_ONLINE.” (refer to figure 7-4
transsition (2)).
If the FrIf module’s environment calls the function FrIf_SetState with parameter
FrIf_StateTransition = FRIF_GOTO_ OFFLINE and if the current state for the
requested cluster is FRIF_STATE_ONLINE, the FrIf module shall take the current
state of the requested cluster to FRIF_STATE_OFFLINE.” (refer to figure 7-4
transition (3)).
Otherwise, do not perform a state transition.
Transition Name

(see Figure 7-4)


Description
Transitions

FRIF_GOTO_ONLINE (2) Transition resulting in FrIf_State


FRIF_STATE_ONLINE
FRIF_GOTO_OFFLINE (3) Transition resulting in FrIf_State
FRIF_STATE_OFFLINE

⌋ ()

27 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05501] ⌈If the API FrIf_SetState with parameter FRIF_STATE_OFFLINE


is called, the FlexRay Interface module shall check the parameter "TxConfCounter"
for every PDU. If the value for the corresponding PDU is greater than 0, the FlexRay
Interface shall call the upper layer using the API <UL>_TxConfirmation(id,
E_NOT_OK). ⌋ ()

Note: It has to be ensured that the FlexRay Interface does not lose the
TxConfCounter values at the point in time the API FrIf_SetState with parameter
FRIF_STATE_OFFLINE is called.

7.3.1 FlexRay Interface Main Function

The FlexRay Interface Main Function needs to be called cyclically from a task body
provided by the BSW Scheduler with a calling period
(FRIF_MAINFUNCTION_PERIOD) depending on the FlexRay Cycle length and
configurable at system configuration time.

Since the Cycle length of each Cluster is independent, the desired calling period of
the FlexRay Interface Main Function might differ from Cluster to Cluster, except for
“Transmission with Immediate Buffer Access”.

[SWS_FrIf_05119] ⌈The FrIf module shall provide one dedicated FlexRay Interface
Main Function for each FlexRay Cluster that is controlled by that FrIf module. ⌋ ()

[SWS_FrIf_05283] ⌈The API names of the FlexRay Interface Main Functions shall
obey the following pattern:

FrIf_MainFunction_<FrIfCluster.ShortName> where FrIfCluster.ShortName is the


Short Name of the corresponding FrIfCluster. ⌋ ()

[SWS_FrIf_15120] ⌈The Main Function monitors and controls the continuous


execution of the FlexRay Job List Execution Function including the
(re)synchronization if the current FlexRay Interface State Machine is
FRIF_STATE_ONLINE. ⌋ ()

[SWS_FrIf_01124] ⌈If Bus Mirroring is enabled globally (see


FrIfBusMirroringSupport), then call Fr_GetChannelStatus for all controllers of each
FlexRay cluster for which mirroring has been activated with a call to
FrIf_EnableBusMirroring(), merge the states reported for the controllers of one
cluster with a binary OR, and then call Mirror_ReportFlexRayChannelStatus() with
the cluster, Fr_ChannelAStatusPtr, and Fr_ChannelBStatusPtr to report the
aggregated channel states to the Bus Mirroring module.⌋ ()

[SWS_FrIf_25120] ⌈If one of the optional cluster-specific configuration parameters


FRIF_E_NIT_CH_A, FRIF_E_NIT_CH_B, FRIF_E_SW_CH_A, FRIF_E_SW_CH_B
or FRIF_E_ACS_CH_A, FRIF_E_ACS_CH_B exists, then call
28 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIf_GetChannelStatus for each FlexRay controller of the cluster and report the
status to DEM as described below. ⌋ ()

[SWS_FrIf_35120] ⌈If the optional configuration parameter FRIF_E_NIT_CH_A


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_NIT_CH_A, DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel A NIT status data
vSS!SyntaxError, vSS!Bviolation) is set or as Dem_SetEventStatus
(FRIF_E_NIT_CH_A, DEM_EVENT_STATUS_PREPASSED) when none of these
error bits is set. ⌋ ()

[SWS_FrIf_45120] ⌈If the optional configuration parameter FRIF_E_NIT_CH_B


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_NIT_CH_B, DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel B NIT status data
vSS!SyntaxError, vSS!Bviolation) is set or as Dem_SetEventStatus
(FRIF_E_NIT_CH_B, DEM_EVENT_STATUS_PREPASSED) when none of these
error bits is set. ⌋ ()

[SWS_FrIf_55120] ⌈If the optional configuration parameter FRIF_E_SW_CH_A


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_SW_CH_A, DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel A symbol window status
data vSS!SyntaxError, vSS!Bviolation, vSS!TxConflict) is set or as
Dem_SetEventStatus (FRIF_E_SW_CH_A, DEM_EVENT_STATUS_PREPASSED)
when none of these error bits is set. ⌋ ()

[SWS_FrIf_65120] ⌈If the optional configuration parameter FRIF_E_SW_CH_B


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_SW_CH_B, DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel B symbol window status
data vSS!SyntaxError, vSS!Bviolation vSS!TxConflict) is set or as
Dem_SetEventStatus (FRIF_E_SW_CH_B, DEM_EVENT_STATUS_PREPASSED)
when none of these error bits is set. ⌋ ()

[SWS_FrIf_75120] ⌈If the optional configuration parameter FRIF_E_ACS_CH_A


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_ACS_CH_A , DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel A aggregated channel
status vSS!SyntaxError, vSS!ContentError, vSS!Bviolation, vSS!TxConflict) is set or
as Dem_SetEventStatus (FRIF_E_ACS_CH_A,
DEM_EVENT_STATUS_PREPASSED) when none of these error bits is set. ⌋ ()

[SWS_FrIf_85120] ⌈If the optional configuration parameter FRIF_E_ACS_CH_B


exists, then the channel status information shall be reported to DEM as
Dem_SetEventStatus (FRIF_E_ACS_CH_B, DEM_EVENT_STATUS_PREFAILED)
when any of the error bits of a single controller (Channel B aggregated channel
status vSS!SyntaxError, vSS!ContentError, vSS!Bviolation, vSS!TxConflict) is set or

29 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

as Dem_SetEventStatus (FRIF_E_ACS_CH_B,
DEM_EVENT_STATUS_PREPASSED) when none of these error bits is set. ⌋ ()

[SWS_FrIf_95120] ⌈If a loss of the JobList’s synchronization (see JobListAsyncFlag)


or a miss of execution was detected, the following steps shall be performed:

1. Get the global time (FrIf_GetGlobalTime())


- If FrIf_GetGlobalTime() returns E_NOT_OK, stop here
- If FrIf_GetGlobalTime() returns E_OK, continue with step 2
2. add some ‘time buffer’ (i.e. some timespan which takes jitter into account)
3. search the FlexRay Job List for the next job, i.e. that job with an invocation
time greater than the current global time + ‘time buffer’.
4. set the JobListPointer to that job and program the absolute timer with this job's
invocation time (now the FlexRay Job List is synchronized again)
5. clear the JobListAsyncFlag
6. Enable the absolute timer interrupt
⌋ ()

7.4 Implementation Requirements

[SWS_FrIf_05096] ⌈The FlexRay Interface executable code (however, not the


configuration used during runtime) shall be completely independent of the FlexRay
Communication Controller(s) and the FlexRay Transceiver(s). ⌋ ( )

[SWS_FrIf_05069] ⌈The FrIf module shall support pre-compile time, link-time and
post-build-time configuration. ⌋ (SRS_BSW_00404, SRS_BSW_00345)

[SWS_FrIf_05284] ⌈The FrIf module shall implement link-time and post-build-time


configuration data as read-only data structures. ⌋ ()

[SWS_FrIf_05285] ⌈The FrIf module shall immediately reference link-time


configuration data by the implementation, ⌋ ()

[SWS_FrIf_05078] ⌈The FrIf module shall implement the API functions specified by
the FrIf SWS as real C code functions and shall not implement the API functions as
macros. ⌋ (SRS_BSW_00342)

Note:The rationale of SWS_FrIf_05078 is to allow object code module integration.

[SWS_FrIf_05244] ⌈
The FrIf module shall pad transmitted PDUs that are located on a FrIf L-Sdu where
FrIfAllowDynamicLSduLength is set to false, if the size is smaller than the configured
size of the PDU. Padding shall be done with the configured FrIfUnusedBitValue.
⌋ ()

30 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.5 Configuration description

[SWS_FrIf_05089] ⌈The FrIf module shall provide an XML file that contains the data
which is required for the SW identification (it shall contain the vendor identification,
module ID and software version information), configuration and integration process.
This file should describe vendor specific configuration parameters as well as it should
contain recommended configuration parameter values.

The description of the configuration and initialization data itself is not part of this
specification but very implementation specific. ⌋ (SRS_BSW_00171, SRS_BSW_00170,
SRS_BSW_00334)

7.6 Data Communication via FlexRay

FlexRay in general is a deterministic time-driven communication system.

Each datum that should be transmitted or received has to be scheduled at system


configuration time.

This even holds true for data that - from the application’s point of view - are
considered event-driven.

Note: When looking only at specific instances of the AUTOSAR FlexRay software
modules running on a specific ECU it is not possible to "anticipate" the exact point in
time when a certain FlexRay frame is being sent (or received, respectively) in the
Dynamic Segment of the FlexRay Cycle.

[SWS_FrIf_05054] ⌈The FrIf module shall define the resources (e.g. a buffer in the
FlexRay Communication Controller or FlexRay Driver) needed for data transmission
(or reception, respectively) at system configuration time specifically for data
transmission (or reception, respectively). ⌋ (SRS_Fr_05056)

Note: There is no true spontaneous event-driven data communication on FlexRay.


Even application data that occur at unpredictable points in time (i.e. "event-driven"),
and that should be transmitted via FlexRay, have to be scheduled for transmission at
system configuration time.

31 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.6.1 PDU Packing, PDU update bits, and Frame Construction Plans

In accordance with basic AUTOSAR rules, the API services that the FrIf module
provides to upper layer BSW modules for data transmission and data reception are
PDU-based.

[SWS_FrIf_05121] ⌈The FrIf module shall be capable of packing multiple PDUs into
one FlexRay Frame. ⌋ ()

Rationale for SWS_FrIf_05121: Bus-independent AUTOSAR PDUs have a maximal


length of 8 bytes, but according to [17] a FlexRay Frame can contain as many as 254
bytes of payload data.

Note: It is also allowed to define PDUs which are larger than 8 bytes. Please be
aware that PDUs greater than 8 bytes are not bus independent any more!

[SWS_FrIf_05122] ⌈The FrIf module shall take the information on how to pack PDUs
into FlexRay Frames from the so-called Frame Construction Plans. The rules
defining how to pack PDUs into FlexRay Frames are defined at system configuration
time ⌋ ()

[SWS_FrIf_05123] ⌈The Frame Construction Plan shall be stored in the static


configuration of the FrIf module (configuration parameter FrIfFrameStructure, see
FrIf05370). ⌋ ()

[SWS_FrIf_05124] ⌈If multiple PDUs are packed into a single FlexRay Frame and if
the FrIf module recognizes the update of at least one of the contained PDUs, then
the FrIf module shall transmit this FlexRay Frame. ⌋ ()

Note: As a result, the space associated with PDUs in this FlexRay Frame that have
not been updated by the upper layer BSW module will also be transmitted. This does
not necessarily mean that the previous values of those PDUs are transmitted. On the
contrary, in case the parameter ‘FrIfUnusedBitValue’ does not exist, arbitrary values
for those PDUs will be transmitted.

[SWS_FrIf_05723] ⌈In case the parameter ‘FrIfUnusedBitValue‘ exists, all the


unused bits within the Frame Construction Plan shall be set to the configured value
‘FrIfUnusedBitValue‘ while assembling the frame on sender side. ⌋ ()

[SWS_FrIf_05725] ⌈The FlexRayInterface shall ensure that unused spaces within


the frame construction plan only contain deterministic values (instead of possible
random data).
For this purpose, the value given by the parameter 'FrIfUnusedBitValue' shall be
used to fill unused spaces with this value.⌋ ()

[SWS_FrIf_05125] ⌈It shall be possible to configure (configuration parameter


FrIfPduUpdateBitOffset, see FrIf06071) for each PDU a dedicated PDU update bits in
the FlexRay Frame.The FrIf module shall identify the position of the PDU update bits
32 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

for each PDU using the information stored in configuration parameter


FrIfPduUpdateBitOffset. ⌋ ()

[SWS_FrIf_05056] ⌈The receiving FrIf module shall evaluate the PDU Update-bit (if
configured) to recognize the update of the PDU associated with this PDU update bits
⌋ (SRS_Fr_05126)

Rationale: In order for the receiving FrIf module to be able to determine which of the
PDUs in a received FlexRay Frame have actually been updated by the upper layer
BSW module (by a call of FrIf_Transmit()) on the transmitter side, additional update
information, so called PDU update bits within the FlexRay Frame, shall be
transmitted to the receiving FrIf module.

Note: A details description of the update bits handling is described in the


Communication Operation, chapter 7.6.3.1 “TransmitWithDecoupledBufferAccess”

[SWS_FrIf_05126] ⌈This PDU update bits shall be located at an arbitrary bit position
in the Frame Construction Plan that is not occupied by any PDU. ⌋ ()

[SWS_FrIf_05127] ⌈The configuration of update bitss for the PDUs and the definition
of the location of the update bitss within the FlexRay Frame are performed at system
configuration time [Configuration Parameter FrIfPduUpdateBitOffset, see FrIf06071] ⌋
()

[SWS_FrIf_05128] ⌈If no update bit is configured for a specific PDU, the FrIf module
shall assume this PDU to be always valid and the FrIf module shall always indicate
its reception to the upper layer BSW module on the receiver side. ⌋ ()

[SWS_FrIf_05758] ⌈In case the parameter ‘FrIfAllowDynamicLSduLength’ exists and


is set to TRUE for the associated frame triggering for reception, PDUs in non-
received areas (PDU offset > actual L-SDU length) shall not be indicated to upper
layer(s).
⌋ ()

[SWS_FrIf_05129] ⌈If Transmission with Immediate Buffer Access is used, only one
PDU is allowed per FlexRay Frame (L-SDU). ⌋ ()

Note: Therefore, PDU update bits can be omitted for Transmission with Immediate
Buffer Access.

33 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.6.2 Dynamic PDU length

[SWS_FrIf_05093] ⌈In case the parameter ‘FrIfAllowDynamicLSduLength’ (see


FrIf06049) is set to true for the associated frame triggering, the FrIf module passes
the actual used L-PDU length to the driver (Fr_TransmitTxLPdu()), taking into
account the following parameters for each PDU:
- the position of the PDU within the L-PDU
- the position of the update-bit information (if configured)

If FrIfImmediate equals TRUE, the actual length of the respective PDU shall be as
passed via FrIf_Transmit().
If FrIfImmediate equals FALSE, the actual length of the respective PDU shall be as
passed via <UL_TriggerTransmit>()
⌋ ()

Note: If FrIfAllowDynamicLSduLength is set to false, the FrIf module just passes the
length information according to the frame construction plan to the FlexRay driver.

[SWS_FrIf_05094] ⌈The FrIf shall only indicate PDUs in received areas (PDU offset
<= actual L-PDU length) to upper layer(s). ⌋ ()

7.6.3 AlwaysTransmit

Note: According to [17], a FlexRay CC might only support the so-called “continuous
transmission mode” where a message is transmitted continuously until the host
explicitly invalidates the transmit buffer. If such a FlexRay CC is being used for
transmission, and the receiving FrIf should still be able to determine which of the
PDUs in a received FlexRay Frame have actually been updated by an upper layer
BSW module on the transmitter side, a special mechanism is needed in the
transmitting FrIf, called AlwaysTransmit (configuration parameter
FrIfAlwaysTransmit, see ECUC_FrIf_06050). If AlwaysTransmit is enabled for an L-
PDU that is transmitted using the Communication Operation
DECOUPLED_TRANSMISSION, the FlexRay Driver’s API service
Fr_TransmitTxLPdu() is always called for this L-PDU, independent from any PDUs in
this L-PDU having been updated by an upper layer BSW module. This enables
resetting the PDU update bits in the FlexRay CC’s transmit buffer, even if none of the
PDUs in the FlexRay Frame have actually been updated by an upper layer BSW
module, and thus ensures the correct interpretation of the received Frame contents
by the receiving FrIf.

Note: Since:
 in general, the transmit mode of a FlexRay CC can be configured (“continuous
mode” / “single shot mode”), and
34 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

 AlwaysTransmit can be configured independently per L-PDU, and


 update bits can be configured independently per PDU,
the FrIf module can be tailored to exhibit exactly the behavior required by a certain
use case,

however, it is the responsibility of the System Designer to select the correct


configuration of all these parameters. An incorrect configuration will lead to undesired
results.

7.6.4 Realization of the Time-Driven FlexRay Schedule

According to [17], a FlexRay CC is not required to provide mechanisms in hardware


to ensure asynchronous access to its transmit and receive buffers e.g. by providing
shadow buffers that may be accessed asynchronously by the AUTOSAR FlexRay
software modules.

[SWS_FrIf_05130] ⌈The FrIf module shall call all functions accessing the transmit
and receive buffers (i.e. performing data transmission or reception, respectively)
synchronously (i.e. synchronized to the FlexRay Global Time) ⌋ ()

Rationale for SWS_FrIf_05130: The access of FrIf module functions to transmit and
receive buffers only at well-defined points in time3 avoids concurrent access to the
buffers by the hardware and the software.

Note: In order to provide this necessary synchronicity, the FrIf module defines for
each Cluster a FlexRay Job List [Configuration Parameter FrIfJobList, see
FrIf05367].

The Cluster's FlexRay Job List is executed by its Job List Execution Function (see
8.5.1) using an absolute timer [Configuration Parameter FrIfAbsTimerRef, see
FrIf06063] of a FlexRay CC connected to the respective Cluster.

7.6.4.1 FlexRay Job List

[SWS_FrIf_05131] ⌈Definition: A FlexRay Job List is a list of (maybe different)


Communication Jobs sorted according to their respective execution start time.

Each Communication Job [Configuration Parameter FrIfJob, see FrIf05368] contains


the following properties:
 Job start time by means of
o FlexRay Communication Cycle [Configuration Parameter FrIfCycle, see
FrIf06064]
o Macrotick Offset within the Communication Cycle [Configuration
Parameter FrIfMacrotick, see FrIf06065].

3
In FlexRay Global Time
35 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

 A list of Communication Operations [Configuration Parameter


FrIfCommunicationOperation, see FrIf05369] sorted according to a
configurable Communication operation index [Configuration Parameter
FrIfCommunicationOperationIdx, see FrIf06068]. The sorting order defines the
order of execution of the Communication Operations within a FlexRay
Communication Job.
⌋ ()

[SWS_FrIf_05133] ⌈The FrIf module shall call the respective Cluster's FlexRay Job
List Execution Function to execute each FlexRay Communication Job at the
execution start time assigned to that Communication Job⌋ ()

[SWS_FrIf_05134] ⌈The FrIf module shall process the actions determined by the
Communication Operations assigned to each FlexRay Communication Job

Each Communication Operation (see FrIf05369) contains the following properties:


 Communication Operation Index [Configuration Parameter
FrIfCommunicationOperationIdx, see ECUC_FrIf_06068], which determines
the execution order of the Communication Operations.
 Communication Action [Configuration Parameter FrIfCommunicationAction,
see FrIf06067], which specifies the actual action to perform (see 7.6.5):
o DECOUPLED_TRANSMISSION
o TX_CONFIRMATION
o RECEIVE_AND_STORE
o RX_INDICATION
o RECEIVE_AND_INDICATE
o PREPARE_LPDU
 A reference to a frame triggering (L-PDU) which is associated with the
Communication Action to perform [Configuration parameter FrIfLPduIdx, see
FrIf06058]4. ⌋ ()

7.6.4.2 FlexRay Job List Execution Function

Since the Communication Schedule of each FlexRay Cluster is independent, there is


one dedicated FlexRay Job List and one dedicated FlexRay Job List Execution
Function for each FlexRay Cluster that is controlled by the FlexRay Interface.

The Copy Operation into/from the FlexRay CCs are scheduled within the FlexRay
JobLists’ communication operations
[SWS_FrIf_05136] ⌈The API names of the FlexRay Job List Execution Functions
shall obey the following pattern:

FrIf_JobListExec_<FrIfCluster.ShortName> where FrIfCluster.ShortName is the Short


Name of the corresponding FrIfCluster. ⌋ ()

4
The LPDU is identified by a LPdu Index, which has a 1:1 association to a frame triggering for
historical reasons. To obtain compatibility this configuration structure is not changed here. The L-PDU
index is identified with a zero-based and dense index, which shall be used as the parameter
Fr_LPduIdx passed to the AUTOSAR FlexRay Driver when processing LPdus.
36 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05137] ⌈The FlexRay Job List Execution Function shall execute the
Cluster's FlexRay Job List Jobs synchronously to the Cluster’s global time (i.e. at
well-defined points in time). ⌋ ()

[SWS_FrIf_05138] ⌈Upon invocation, the FlexRay Job List Execution Function shall
perform the following steps:
1. Retrieve the FlexRay Global Time from the FlexRay CC providing the Cluster’s
absolute timer interrupt.
2. If the FlexRay Global Time cannot be retrieved or the global time delay compared
to the jobs start time is larger than a maximum delay [Configuration Parameter
FrIfMaxIsrDelay, see FrIf06004], the execution of the FlexRay Job List is
considered to be asynchronous to the FlexRay Global Time and thus the following
actions are performed:
 Either set a flag (JobListAsyncFlag) indicating that the execution of the
FlexRay Job List of this Cluster is asynchronous or directly resynchronize
the Joblist as described in SWS_FrIf_95120
 If the JobListAsyncFlag was set, call the Runtime error
FRIF_E_JLE_SYNC
 Disable absolute Timer Interrupt
 Terminate the execution of this FlexRay Job.

Otherwise, the FlexRay Job List Execution Function continues with step 3.

3. Retrieve the ordered list of Communication Operations of the current Job pointed
to by the current job-pointer.

4. Forward the current job-pointer to the next job-list entry. If the job-pointer was
pointed at the end of the job-list, wrap around and set it to the first job-list entry.

5. Retrieve the execution start time of the job marked by the job-pointer and set the
absolute timer to this job’s start time in order to invoke the FlexRay Job List
Execution Function again.

6. Execute the retrieved Communication Operations.


⌋ ()
Note: In order to keep the runtime of the JLEF short, it is acceptable to implement the
described functionality of the JLEF into a separate, high priority task which has to be
activeded immediately in the JLEF.

7.6.5 Communication Operations

This chapter describes each Communication Operation that is executed within the
Job List Execution Function.

37 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.6.5.1 TransmitWithDecoupledBufferAccess

[SWS_FrIf_05058] ⌈The FrIf module shall be capable of Transmit Request queuing


by using the TrigTxCounter. ⌋ (SRS_Fr_05130)

Note: Only the amount of transmit requests are stored, not the data itself.

[SWS_FrIf_05063] ⌈If the related CC is in FrIf_State FRIF_STATE_ONLINE for a


Communication Operation DECOUPLED_TRANSMISSION, then the Job List
Execution Function shall execute this Communication Operation. Otherwise, the Job
List Execution Function shall ignore this Communication Operation. ⌋ (SRS_Fr_05027)

[SWS_FrIf_05287] ⌈For a Communication Operation


DECOUPLED_TRANSMISSION the Job List Execution Function shall perform the
following steps

1. Iterate over all PDUs contained in the FrIfFrameStructure (see FrIf05370) of


the associated frame triggering of this Communication Operation and
a. Check whether TrigTxCounter is > 0 or FrIfNoneMode == true for the
PDU. If not, clear the update-bit for this PDU [Configuration Parameter
FrIfPduUpdateBitOffset, see FrIf06071] and proceed with the next PDU,
otherwise continue with the following steps:
i. Decrement TrigTxCounter only if TrigTxCounter > 0. If the value
of TrigTxCounter = 0, do not decrement.
ii. Call the upper layer’s function <UL>_TriggerTransmit() with the
associated PDUId (defined by the upper layer) and pass a
pointer to a temporary buffer within the FrIf that assembles the L-
SDU. The pointer shall consider the byte offset [Configuration
Parameter FrIfPduOffset, see FrIf06070]] of the PDU within the
frame. If <UL>_TriggerTransmit() returns E_NOT_OK, the
TrigTxCounter value has to be rolled back to the previous value.
iii. Remember that a transmission for this PDU is pending if a
transmission confirmation is needed for this PDU [Configuration
Parameter FrIfConfirm, see FrIf06075] increment
TxConfCounter, where the maximum value is limited by static
configuration [Configuration Parameter FrIfCounterLimit, see
FrIf06076]. If the FrIfCounterLimit has been reached, the
FrIfCounterLimit value is kept and not incremented any more.
iv. Set the update-bit if configured for this PDU [Configuration
Parameter FrIfPduUpdateBitOffset, see FrIf06071]. In case the
API <UL>_TriggerTransmit() does not return E_OK, or the API
FrIf_CancelTransmit ()for the corresponding PDU has been
called, reset the update-bit to “not updated”.
2. If at least one PDU was requested for transmission or for at least one PDU
FrIfNoneMode == true and <UL>_TriggerTransmit returned E_OK or the frame
is configured to be always transmitted [Configuration Parameter
FrIfAlwaysTransmit == true] then the FlexRay Driver’s API service
Fr_TransmitTxLPdu() is called:
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b. Fr_LPduIdx is set to the configured L-PDU index [Configuration Parameter
38 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIfLPduIdx, see FrIf06058] associated with the Communication Operation


c. Fr_LSduPtr is set to the temporary FrIf L-SDU assembling buffer.
d. Fr_LSduLength is set to the L-SDU length [Configuration Parameter
FrIfLSduLength, see FrIf06054]
e. Fr_SlotAssignmentPtr is set to a temporary slot assignment buffer if Bus
Mirroring is enabled globally (see FrIfBusMirroringSupport), otherwise to the
NULL_PTR.
3. If Bus Mirroring is enabled globally (see FrIfBusMirroringSupport) and has
been activated with a call to FrIf_EnableBusMirroring() for the Fr_CtrlIdx and
Fr_TransmitTxLPdu() returned E_OK (indicating that the transmission
succeeded), call Mirror_ReportFlexRayFrame() with “controllerId” set to
Fr_CtrlIdx, , “slotId”, “cycle”, and “channel” taken from Fr_SlotAssignmentPtr,
“frame” constructed from Fr_LSduPtr and Fr_LSduLength, and “txConflict” set
to false.

4. In case the Driver’s API Fr_TransmitTxLPdu() returned E_NOT_OK (indicating


that the transmission failed) changes on TrigTxCounter and TxConfCounter
must be rolled back (see 4. and 5.) for each PDU contained in the FlexRay L-
SDU.

All described actions in SWS_FrIf_05287 are depicted in detail in the sequence chart
in chapter 9.1.2.

In case the parameter ‘FrIfAllowDynamicLSduLength’ exists and is set to TRUE for


the associated frame triggering, the actual L-SDU length, that is passed to the driver
(Fr_TransmitTxLPdu()), shall be determined (i.e. shortened as much as possible)
taking into account the following for those PDUs only, which have been indicated via
<UL_TriggerTransmit>():
- the position of the respective PDU within the L-SDU
- the actual length of the respective PDU as passed via <UL_TriggerTransmit>()

The shortened L-Sdu shall always contain all configured update bits.

This ensures that on one hand all the needed information for disassembling the L-
SDU is available on receiver side (PDU(s) itself and the corresponding update-bit(s)
if configured), and on the other hand that the payload can be reduced as much as
possible by talking the position of all the required data for disassembling contained in
the frame construction plan into account when shortening the L-SDU to be passed to
the driver. ⌋ ()

7.6.5.2 ProvideTxConfirmation

This Communication Operation provides a Tx confirmation and optionally checks the


occurrence of a Tx conflict.

[SWS_FrIf_05064] ⌈If the related CC is in FrIf_State FRIF_STATE_ONLINE for a


Communication Operation TX_CONFIRMATION, then the Job List Execution
39 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Function shall execute this Communication Operation. Otherwise, the Job List
Execution Function shall ignore this Communication Operation. ⌋ ()

[SWS_FrIf_05288] ⌈ “For a Communication Operation TX_CONFIRMATION the Job


List Execution Function shall perform the following steps:
1. Call the FlexRay Driver’s API function Fr_CheckTxLPduStatus():
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b. Fr_LPduIdx is set to the configured L-PDU buffer index [Configuration
Parameter FrIfLPduIdx, see FrIf06058] associated with the
Communication Operation.
c. Fr_SlotAssignmentPtr is set to a temporary slot assignment buffer if
Bus Mirroring is enabled globally (see FrIfBusMirroringSupport),
otherwise to the NULL_PTR.

2. If the transmission was performed (output parameter *Fr_TxLPduStatusPtr


is set to FR_TRANSMITTED) then iterate over all PDUs contained in the
FrIfFrameStructure (see FrIf05370) of the associated frame triggering. If
TxConfCounter for a PDU is 0 proceed with the next PDU, otherwise
a. If FrIfConfirm == true, call the upper layer’s function
<UL_TxConfirmation(E_OK)> with the asociated PDUId (defined by the
upper layer).
b. If FrIfConfirm == true , decrement TxConfCounter.
3. If the transmission was performed but a TxConflict occurred (output
parameter *Fr_TxLPduStatusPtr is set to FR_TRANSMITTED_CONFLICT)
then iterate over all PDUs contained in the FrIfFrameStructure (see
FrIf05370) of the associated frame triggering. If TxConfCounter for a PDU is
0 proceed with the next PDU, otherwise
a. If FrIfConfirm == true, call the upper layer’s function
<UL_TxConfirmation(E_NOT_OK)> with the asociated PDUId (defined
by the upper layer).
b. If FrIfConfirm == true , decrement TxConfCounter.
4. If Bus Mirroring is enabled globally (see FrIfBusMirroringSupport) and has
been activated with a call to FrIf_EnableBusMirroring() for the Fr_CtrlIdx and
the API Fr_CheckTxLpduStatus() returns "FR_TRANSMITTED_CONFLICT”,
call Mirror_ReportFlexRayFrame() with “controllerId” set to Fr_CtrlIdx,
“slotId”, “cycle”, and “channel” taken from Fr_SlotAssignmentPtr, “frame” set
to the NULL_PTR, and “txConflict” set to true.
5. If the API Fr_CheckTxLpduStatus() returns
"FR_TRANSMITTED_CONFLICT” and the <UL_TxConflictNotification> is
configured via FrIfTxConflictNotificationName (ECUC_FrIf_06122), call this
function for the same LPduIdx. ⌋ ()

7.6.5.3 ReceiveAndStore

[SWS_FrIf_05289] ⌈If the related CC is in FrIf_State FRIF_STATE_ONLINE for a


Communication Operation RECEIVE_AND_STORE, then the Job List Execution
Function shall execute this Communication Operation. Otherwise, the Job List
Execution Function shall ignore this Communication Operation. ⌋ ()
40 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05290] ⌈For a Communication Operation RECEIVE_AND_STORE the


Job List Execution Function shall perform the following steps:
1. Call the FlexRay Driver’s API function Fr_ReceiveRxLPdu():
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b. Fr_LPduIdx is set to the configured L-PDU index [Configuration
Parameter FrIfLPduIdx, see FrIf06058] associated with the
Communication Operation.
c. Fr_LSduPtr is set to a temporary buffer.
d. Fr_SlotAssignmentPtr is set to a temporary slot assignment buffer if
Bus Mirroring is enabled globally (see FrIfBusMirroringSupport),
otherwise to the NULL_PTR.

2. If Bus Mirroring is enabled globally (see FrIfBusMirroringSupport) and has


been activated with a call to FrIf_EnableBusMirroring() for the Fr_CtrlIdx and
an L-PDU was received (Output parameter *Fr_LPduStatusPtr !=
FR_NOT_RECEIVED), call Mirror_ReportFlexRayFrame() with “controllerId”
set to Fr_CtrlIdx, “slotId”, “cycle”, and “channel” taken from
Fr_SlotAssignmentPtr, “frame” constructed from Fr_LSduPtr and
Fr_LSduLengthPtr, and “txConflict” set to false.

3. If a L-PDU was received (Output parameter *Fr_LPduStatusPtr !=


FR_NOT_RECEIVED) iterate over all PDUs contained in the
FrIfFrameStructure (see FrIf05370) of the associated frame triggering and:
a. If an update bit was configured for the PDU [Configuration Parameter
FrIfPduUpdateBitOffset, see FrIf06071] and the update bit for the PDU
is not set, continue with the next PDU. Otherwise,
b. Copy the PDU Payload from the temporary buffer considering the PDU
offset within the L-SDU [Configuration Parameter FrIfPduOffset, see
FrIf06070] into a FrIf PDU-related static buffer.
c. Store the actual received PDU length
d. Mark the PDU-related static buffer as up-to-date.
4. if *Fr_LPduStatusPtr == FR_RECEIVED_MORE_DATA_AVAILABLE restart at
number 1 again. Otherwise the communication operation has finished. ⌋ ()

7.6.5.4 ProvideRxIndication

[SWS_FrIf_05062] ⌈If the related CC is in FrIf_State FRIF_STATE_ONLINE for a


Communication Operation RX_INDICATION, then the Job List Execution Function
shall execute this Communication Operation. Otherwise, the Job List Execution
Function shall ignore this Communication Operation. ⌋ (SRS_Fr_05170)

[SWS_FrIf_05291] ⌈For a Communication Operation RX_INDICATION the Job List


Execution Function shall perform the following steps:
1. Iterate over all PDU-related static buffers of PDUs contained in the
FrIfFrameStructure (see FrIf05370) of the associated frame triggering
2. If the PDU-related static buffer is marked as outdated, continue with the next
PDU. Otherwise if the buffer is marked up-to-date,

41 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

a. Call the upper layer’s function <UL>_RxIndication() with the PDU Id the
receiving module expects and PduInfoPtr which contains the received
data address and received data length.
b. Mark the PDU-related static buffer as outdated. ⌋ ()

7.6.5.5 ReceiveAndIndicate

[SWS_FrIf_05292] ⌈If the related CC is in FrIf_State FRIF_STATE_ONLINE for a


Communication Operation RECEIVE_AND_INDICATE, then the Job List Execution
Function shall execute this Communication Operation. Otherwise, the Job List
Execution Function shall ignore this Communication Operation. ⌋ ()

[SWS_FrIf_05293] ⌈For a Communication Operation RECEIVE_AND_INDICATE


the Job List Execution Function shall perform the following steps:

1) Calculate values for input parameters:


a) Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b) Fr_LPduIdx is set to the configured L-PDU index [Configuration Parameter
FrIfLPduIdx, see FrIf06058] associated with the Communication Operation.
c) Fr_LSduPtr is set to a temporary buffer.
d) Fr_SlotAssignmentPtr is set to a temporary slot assignment buffer if Bus
Mirroring is enabled globally (see FrIfBusMirroringSupport), otherwise to the
NULL_PTR.

2) Initialize ComOpLoopCounter to 0.

3) As long as ComOpLoopCounter < FrIfRxComOpMaxLoop do


a) Call Fr_ReceiveRxLPdu with the parameters calculated in 1)
b) If *Fr_LPduStatusPtr != FR_NOT_RECEIVED then continue at 3)c), otherwise
the communication operation has finished.
c) If Bus Mirroring is enabled globally (see FrIfBusMirroringSupport) and has
been activated with a call to FrIf_EnableBusMirroring() for the Fr_CtrlIdx, call
Mirror_ReportFlexRayFrame() with “controllerId” set to Fr_CtrlIdx, “slotId”,
“cycle”, and “channel” taken from Fr_SlotAssignmentPtr, “frame” constructed
from Fr_LSduPtr and Fr_LSduLengthPtr, and “txConflict” set to false.
Otherwise, continue at 3)d).

d) For each Pdu contained in the FrIfFrameStructure (see FrIf05370) of the


associated frame triggering do
-) If an update bit was configured for the PDU [Configuration Parameter
FrIfPduUpdateBitOffset, see FrIf06071] and the update bit for the PDU is not
set, continue with the next PDU. Otherwise
-) Call the upper layer's function <UL>_RxIndication() with the PDU Id the
receiving module expects and a pointer to the Pdu-Info structure containing
the Pdu length and a reference to the temporary buffer considering the PDU
offset within the L-SDU [Configuration Parameter FrIfPduOffset, see
FrIf06070]] as parameters.

42 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

e) if *Fr_LPduStatusPtr == FR_RECEIVED_MORE_DATA_AVAILABLE then


increment ComOpLoopCounter and restart at 3)a), otherwise the
communication operation has finished.
⌋ ()

43 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.6.5.6 PREPARE_LPDU

The Communication Operation PREPARE_LPDU enables hardware optimization


purposes (hardware buffer re-configuration)

[SWS_FrIf_05294] ⌈The Communication Operation PREPARE_LPDU performs the


following steps:
1. Call the FlexRay Driver’s API function Fr_PrepareLPdu():
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b. Fr_LPduIdx is set to the configured L-PDU index [Configuration
Parameter FrIfLPduIdx, see FrIf06058] associated with the
Communication Operation. ⌋ ()

[SWS_FrIf_05061] ⌈
The Communication Operation PREPARE_LPDU enables hardware optimization
purposes. Its purpose is to enable certain FlexRay CC hardware resources (e.g. a
CC’s message buffer) to be prepared (configured) for the transmission/reception of a
certain L-PDU.

This Communication Operation enables the FlexRay Driver to optimize the usage of
hardware resources if available at appropriate point of times. However, it is the
responsibility of the FlexRay Driver to decide and validate ressource allocation
optimizations based on the PREPARE_LPDU Communication Operations. Practically
the usage of this Communication Operation will introduce some runtime-overhead
even if the FlexRay Driver does not use the opportunity for reconfiguration. ⌋
(SRS_Fr_05042)

7.6.3.7 FREE_OP_A

User-defined communication operation in order to support hardware specific or


additional communication controller features to increase performance. Use cases are
communication controllers with serial connection or DMA-transfers.

7.6.3.8 FREE_OP_B

User-defined communication operation in order to support hardware specific or


additional communication controller features to increase performance. Use cases are
communication controllers with serial connection or DMA-transfers.

44 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.6.6 Transmission with Immediate Buffer Access

[SWS_FrIf_15295] ⌈
The FlexRay Job List Execution Function does not initiate transmission with
immediate buffer access. Instead, the actions described here are carried out in the
context of the FrIf_Transmit() API service, which in turn is called by an upper layer
BSW module. ⌋ ()

[SWS_FrIf_05295] ⌈The FlexRay Interface shall perform a PDU transmission with


immediate buffer access (see 9.1), only if the following restriction regarding static
configuration apply:
 The PDU must be the only PDU in a FlexRay Frame (L-SDU). It is not
packed into a FlexRay Frame together with other PDUs (i.e., the mapping
between this PDU and the respective L-SDU is a 1:1 association).
 The PDU must be located at the beginning of the L-SDU.
 There is no update-bit for immediate PDUs configured. ⌋ ()

[SWS_FrIf_05296] ⌈If an upper layer module calls FrIf_Transmit() with TxPduId


being configured for an immediate PDU, the AUTOSAR module FlexRay Interface
shall perform the following steps for an immediate PDU transmission within the
context of the FrIf_Transmit() API service Driver’s API function Fr_TransmitTxLPdu():
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2
b. Fr_LPduIdx is set to the configured L-PDU index [Configuration
Parameter FrIfLPduIdx, see FrIf06058] associated with the TxPduId.
c. Fr_LSduPtr is set to the Pdu Payload pointer contained in the
PduInfoPtr passed as parameter to FrIf_Transmit.
d. If the parameter FrIfAllowDynamicLSduLength=TRUE, the actual length
of the respective PDU shall be as passed via FrIf_Transmit().
e. Fr_SlotAssignmentPtr is set to a temporary slot assignment buffer if
Bus Mirroring is enabled globally (see FrIfBusMirroringSupport),
otherwise to the NULL_PTR.

In case the Driver’s API Fr_TransmitTxLPdu() returned E_OK (indicating that the
transmission request succeeded) the TxConfCounter is incremented for the
respective PDU. The maximum value of TxConfCounter is limited by static
configuration [Configuration Parameter FrIfCounterLimit, see FrIf06076]). If Bus
Mirroring is enabled globally (see FrIfBusMirroringSupport) and has been
activated with a call to FrIf_EnableBusMirroring() for the Fr_CtrlIdx, call
Mirror_ReportFlexRayFrame() with “controllerId” set to Fr_CtrlIdx, , “slotId”,
“cycle”, and “channel” taken from Fr_SlotAssignmentPtr, “frame” constructed from
Fr_LSduPtr and Fr_LSduLength, and “txConflict” set to false.

In case the Driver’s API Fr_TransmitTxLPdu() returned E_NOT_OK do not modify


the current counter value of TxConfCounter. ⌋ ()

45 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.7 Error Classification

7.7.1 Development Errors

[SWS_FrIf_05145]⌈
Type of error Related error code Error value

Invalid pointer FRIF_E_PARAM_POINTER 0x01

Invalid Controller index FRIF_E_INV_CTRL_IDX 0x02

Invalid Cluster index FRIF_E_INV_CLST_IDX 0x03

Invalid Channel index FRIF_E_INV_CHNL_IDX 0x04

Invalid timer index FRIF_E_INV_TIMER_IDX 0x05

Invalid FrIf_TxPdu Index FRIF_E_INV_TXPDUID 0x06

Invalid LPdu Index FRIF_E_INV_LPDU_IDX 0x07

FrIf not initialized FRIF_E_UNINIT 0x08

Invalid state requested FRIF_E_INV_FRIF_STATE 0x0A

Invalid Frame ID FRIF_E_INV_FRAME_ID 0x0B

Initialization failed FRIF_E_INIT_FAILED 0x0C

Invalid Pdu length FRIF_E_INV_PDULENGTH 0x0D

⌋()

Table 7-1: Definition of Development Errors

46 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.7.2 Runtime Errors

[SWS_FrIf_05432]⌈
Error
Type of error Related error code
value

Job List Execution lost synchronization to the FlexRay Global FRIF_E_JLE_


0x01
Time SYNC

⌋()

Table 7-2: Definition of Runtime Errors

7.7.3 Transient Faults

Therer are no transient faults.

47 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

7.7.4 Production Errors

[SWS_FrIf_05146] ⌈

Type or error Related error code Value [hex]


error detection in NIT on channel A FRIF_E_NIT_CH_A Assigned by DEM
error detection in NIT on channel B FRIF_E_NIT_CH_B Assigned by DEM
error detection in SW on channel A FRIF_E_SW_CH_A Assigned by DEM
error detection in SW on channel B FRIF_E_SW_CH_B Assigned by DEM
error detection in ACS on channel A FRIF_E_ACS_CH_A Assigned by DEM
error detection in ACS on channel B FRIF_E_ACS_CH_B Assigned by DEM
⌋ ()

Table 7-3: Definition of Production Errors

[SWS_FrIf_05426]⌈
Error Name: FRIF_E_NIT_CH_A
Short Description: Error detection in NIT on channel A
Long Description: This production error shall be issued when an error in NIT on
channel A was detected
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_NIT_CH_A,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel A
NIT status data vSS!SyntaxError,
vSS!Bviolation) is set (SWS_FrIf_35120)
Detection Criteria:
Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_NIT_CH_A,
DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel A NIT status data vSS!SyntaxError,
vSS!Bviolation) is set (SWS_FrIf_35120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
⌋()
[SWS_FrIf_05427]⌈
Error Name: FRIF_E_NIT_CH_B
Short Description: Error detection in NIT on channel B
48 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Long Description: This production error shall be issued when an error in NIT on
channel B was detected
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_NIT_CH_B,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel B
NIT status data vSS!SyntaxError,
vSS!Bviolation) is set (SWS_FrIf_45120)
Detection Criteria:
Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_NIT_CH_B,
DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel B NIT status data vSS!SyntaxError,
vSS!Bviolation) is set (SWS_FrIf_45120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
⌋()

[SWS_FrIf_05428]⌈
Error Name: FRIF_E_SW_CH_A
Short Description: Error detection in SW on channel A
Long Description: This production error shall be issued when an error in SW on
channel A was detected.
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_SW_CH_A,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel A
symbol window status data vSS!SyntaxError,
vSS!Bviolation, vSS!TxConflict) is set
(SWS_FrIf_55120)
Detection Criteria:
Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_SW_CH_A,
DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel A symbol window status data
vSS!SyntaxError, vSS!Bviolation,
vSS!TxConflict) is set (SWS_FrIf_55120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
49 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

⌋()

[SWS_FrIf_05429]⌈
Error Name: FRIF_E_SW_CH_B
Short Description: Error detection in SW on channel B
Long Description: This production error shall be issued when an error in SW on
channel B was detected.
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_SW_CH_B,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel B
symbol window status data vSS!SyntaxError,
vSS!Bviolation, vSS!TxConflict) is set
(SWS_FrIf_65120)
Detection Criteria:
Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_SW_CH_B,
DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel B symbol window status data
vSS!SyntaxError, vSS!Bviolation,
vSS!TxConflict) is set (SWS_FrIf_65120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
⌋()

[SWS_FrIf_05431]⌈
Error Name: FRIF_E_ACS_CH_A
Short Description: Error detection in ACS on channel A
Long Description: This production error shall be issued when an error in ACS
on channel A was detected
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_ACS_CH_A ,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel A
Detection Criteria: aggregated channel status vSS!SyntaxError,
vSS!ContentError, vSS!Bviolation,
vSS!TxConflict) is set (SWS_FrIf_75120)
Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_ACS_CH_A ,
50 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel A aggregated channel status
vSS!SyntaxError, vSS!ContentError,
vSS!Bviolation, vSS!TxConflict) is set
(SWS_FrIf_75120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
⌋()

[SWS_FrIf_05430]⌈
Error Name: FRIF_E_ACS_CH_B
Short Description: Error detection in ACS on channel B
Long Description: This production error shall be issued when an error in ACS
on channel B was detected
Recommended DTC: N/A
Fail The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_SW_CH_B,
DEM_EVENT_STATUS_PREFAILED) when any
of the error bits of a single controller (Channel B
symbol window status data vSS!SyntaxError,
vSS!Bviolation, vSS!TxConflict) is set
(SWS_FrIf_85120)
Detection Criteria: Pass The channel status information shall be reported
to DEM as Dem_SetEventStatus
(FRIF_E_ACS_CH_B ,
DEM_EVENT_STATUS_PREPASSED) when
none of the error bits of a single controller
(Channel B aggregated channel status
vSS!SyntaxError, vSS!ContentError,
vSS!Bviolation, vSS!TxConflict) is set
(SWS_FrIf_85120)
Secondary Parameters: N/A
Time Required: N/A
Monitor Frequency continuous
MIL illumination: N/A
⌋()

7.7.5 Extended Production Errors

There are no extended production errors.

51 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8 API Service Specification

8.1 Imported types

In this chapter all types included from the following files are listed:

[SWS_FrIf_05001]⌈
Module Header File Imported Type

ComStack_Types.h PduIdType

ComStack_Types ComStack_Types.h PduInfoType

ComStack_Types.h PduLengthType

Rte_Dem_Type.h Dem_EventIdType
Dem
Rte_Dem_Type.h Dem_EventStatusType

Fr_GeneralTypes.h Fr_ChannelType

Fr_GeneralTypes.h Fr_ErrorModeType

Fr_GeneralTypes.h Fr_POCStateType

Fr_GeneralTypes.h Fr_POCStatusType

Fr_GeneralTypes.h Fr_RxLPduStatusType
Fr
Fr_GeneralTypes.h Fr_SlotAssignmentType

Fr_GeneralTypes.h Fr_SlotModeType

Fr_GeneralTypes.h Fr_StartupStateType

Fr_GeneralTypes.h Fr_TxLPduStatusType

Fr_GeneralTypes.h Fr_WakeupStatusType

Fr_GeneralTypes.h FrTrcv_TrcvModeType
FrTrcv
Fr_GeneralTypes.h FrTrcv_TrcvWUReasonType

Std_Types.h Std_ReturnType
Std
Std_Types.h Std_VersionInfoType

⌋(SRS_BSW_00348, SRS_BSW_00353, SRS_BSW_00361, SRS_BSW_00304,


SRS_BSW_00378)

52 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.2 Type Definitions

This chapter lists the data types that the FlexRay Interface defines.

8.2.1 FrIf_ConfigType

[SWS_FrIf_05301]⌈
Name FrIf_ConfigType

Kind Structure

Implementation specific

Elements Type --

Comment --

This type contains the implementation-specific post build time configuration structure.
Description
Only pointers of this type are allowed.

Available
FrIf.h
via

⌋()

8.2.2 FrIf_StateType

[SWS_FrIf_05755]⌈
Name FrIf_StateType

Kind Enumeration

FRIF_STATE_ The FlexRay CC is not ready for communication, the Flex


--
OFFLINE Ray cluster is not synchronized.
Range
FRIF_STATE_ The FlexRay CC is ready for communication, the FlexRay
--
ONLINE cluster is synchronized.

Description Variables of this type are used to represent the FrIf_State of a FlexRay CC.

Available
FrIf.h
via

⌋()
53 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

8.2.3 FrIf_StateTransitionType

[SWS_FrIf_05303]⌈
Name FrIf_StateTransitionType

Kind Enumeration

FRIF_GOTO_ Literal for requesting transition into FRIF_STATE_


--
OFFLINE OFFLINE
Range
FRIF_GOTO_ Literal for requesting transition into FRIF_STATE_
--
ONLINE ONLINE state.

Description Variables of this type are used to represent the FrIf_State of a FlexRay CC.

Available
FrIf.h
via

⌋()

54 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3 Function Definitions

This is a list of API services (functions) the FrIf module provides to upper layer BSW
modules.

8.3.1 FrIf_Init

[SWS_FrIf_05003]⌈
Service Name FrIf_Init

void FrIf_Init (
Syntax const FrIf_ConfigType* FrIf_ConfigPtr
)

Service ID [hex] 0x02

Sync/Async Synchronous

Reentrancy Non Reentrant

FrIf_Config Base pointer to the configuration structure of the FlexRay


Parameters (in)
Ptr Interface.

Parameters
None
(inout)

Parameters (out) None

Return value void --

Description Initializes the FlexRay Interface.

Available via FrIf.h

⌋(SRS_BSW_00405, SRS_BSW_00101, SRS_BSW_00358, SRS_BSW_00414,


SRS_Fr_05013)

Note:
The AUTOSAR ECU StateManager calls this FlexRay Interface API service with the
address of the static configuration structure of the FrIf module in parameter
FrIf_ConfigPtr.

[SWS_FrIf_05156] ⌈The function FrIf_Init shall carry out the following actions:
1) Configure the FlexRay Interface module: initialize the local
memory space used to store the PDU data and the PDU
properties and state variables and the FlexRay Interface State
Machine.

55 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

2) The initialization of the memory space has to make sure that


the PDU-related static buffer status is set to "outdated"⌋ ()

56 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.2 FrIf_ControllerInit

[SWS_FrIf_05004]⌈
Service Name FrIf_ControllerInit

Std_ReturnType FrIf_ControllerInit (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x03
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Initialized a FlexRay CC.

Available via FrIf.h

⌋(SRS_Fr_05031)

[SWS_FrIf_05158] ⌈If parameter FrIf_CtrlIdx of FrIf_ControllerInit has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_ControllerInit shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05159] ⌈The function FrIf_ControllerInit shall wrap the FlexRay Driver


API function Fr_ControllerInit() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Calling Fr_ControllerInit() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

57 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05160] ⌈Caveats of FrIf_ControllerInit: The FlexRay Interface module has


to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003⌋ ()

8.3.3 FrIf_SetAbsoluteTimer

[SWS_FrIf_05021]⌈
Service Name FrIf_SetAbsoluteTimer

Std_ReturnType FrIf_SetAbsoluteTimer (
uint8 FrIf_CtrlIdx,
uint8 FrIf_AbsTimerIdx,
Syntax uint8 FrIf_Cycle,
uint16 FrIf_Offset
)

Service ID
0x19
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.

FrIf_Abs
Index of the absolute timer to address.
Parameters TimerIdx
(in)
FrIf_Cycle FlexRay Cycle number to be set.

FrIf_Offset Number of Macroticks to be set.

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_SetAbsoluteTimer().

Available via FrIf.h

⌋()

[SWS_FrIf_05234] ⌈If parameter FrIf_CtrlIdx of FrIf_SetAbsoluteTimer has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_SetAbsoluteTimer shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()
58 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05235] ⌈The function FrIf_SetAbsoluteTimer shall wrap This API service


of the FlexRay Interface wraps the FlexRay Driver API function
Fr_SetAbsoluteTimer() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Setting parameters
-3) Fr_AbsTimerIdx to FrIf_AbsTimerIdx
-4) Fr_Cycle to FrIf_Cycle
-5) Fr_Offset to FrIf_Offset
-6) Calling Fr_SetAbsoluteTimer() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

[SWS_FrIf_05236] ⌈Caveats of FrIf_SetAbsoluteTimer: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.4 FrIf_EnableAbsoluteTimerIRQ

[SWS_FrIf_05025]⌈
Service Name FrIf_EnableAbsoluteTimerIRQ

Std_ReturnType FrIf_EnableAbsoluteTimerIRQ (
uint8 FrIf_CtrlIdx,
Syntax
uint8 FrIf_AbsTimerIdx
)

Service ID
0x1d
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Abs
Index of the absolute timer to address.
TimerIdx

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.
59 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Description Wraps the FlexRay Driver API function Fr_EnableAbsoluteTimerIRQ().

Available via FrIf.h

⌋()

[SWS_FrIf_05246] ⌈If parameter FrIf_CtrlIdx of FrIf_EnableAbsoluteTimerIRQ has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_EnableAbsoluteTimerIRQ shall
report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05247] ⌈The function FrIf_EnableAbsoluteTimerIRQ shall wrap the


FlexRay Driver API function Fr_EnableAbsoluteTimerIRQ() by:
1. Translating (based on static FrIf module configuration) the FlexRay CC index
FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-specific CC index Fr_CtrlIdx).
2. Setting parameters
 Fr_AbsTimerIdx to FrIf_AbsTimerIdx
3. Calling Fr_EnableAbsoluteTimerIRQ() of the determined FlexRay Driver module
with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05248] ⌈Caveats of FrIf_EnableAbsoluteTimerIRQ: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

8.3.5 FrIf_AckAbsoluteTimerIRQ

[SWS_FrIf_05029]⌈
Service Name FrIf_AckAbsoluteTimerIRQ

Std_ReturnType FrIf_AckAbsoluteTimerIRQ (
uint8 FrIf_CtrlIdx,
Syntax
uint8 FrIf_AbsTimerIdx
)

Service ID
0x21
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Abs
Index of the absolute timer to address.
TimerIdx

Parameters
None
(inout)
60 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_AckAbsoluteTimerIRQ()

Available via FrIf.h

⌋()

[SWS_FrIf_05258] ⌈If parameter FrIf_CtrlIdx of FrIf_AckAbsoluteTimerIRQ has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_AckAbsoluteTimerIRQ shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05259] ⌈The function FrIf_AckAbsoluteTimerIRQ shall wrap the FlexRay


Driver API function Fr_AckAbsoluteTimerIRQ() by:
1. Translating (based on static FrIf module configuration) the FlexRay CC index
FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-specific CC index Fr_CtrlIdx).
2. Setting parameters
 Fr_AbsTimerIdx to FrIf_AbsTimerIdx
3. Calling Fr_AckAbsoluteTimerIRQ() of the determined FlexRay Driver module with
the parameters determined as described above. ⌋ ()

[SWS_FrIf_05260] ⌈Caveats of FrIf_AckAbsoluteTimerIRQ: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.6 FrIf_StartCommunication

[SWS_FrIf_05005]⌈
Service Name FrIf_StartCommunication

Std_ReturnType FrIf_StartCommunication (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x04
[hex]

Sync/Async Asynchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx
61 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_StartCommunication().

Available via FrIf.h

⌋(SRS_Fr_05015)

[SWS_FrIf_05161] ⌈If parameter FrIf_CtrlIdx of FrIf_StartCommunication has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_StartCommunication shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05162] ⌈The function FrIf_StartCommunication shall wrap the FlexRay


Driver API function Fr_StartCommunication() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Calling Fr_StartCommunication() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

[SWS_FrIf_05163] ⌈Caveats of FrIf_StartCommunication: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003⌋ ()

8.3.7 FrIf_HaltCommunication

[SWS_FrIf_05006]⌈
Service Name FrIf_HaltCommunication

Std_ReturnType FrIf_HaltCommunication (
Syntax uint8 FrIf_CtrlIdx
)

Service ID 0x05
62 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[hex]

Sync/Async Asynchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_HaltCommunication().

Available via FrIf.h

⌋(SRS_BSW_00336, SRS_Fr_05063)

[SWS_FrIf_05164] ⌈If parameter FrIf_CtrlIdx of FrIf_HaltCommunication has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_HaltCommunication shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05165] ⌈The function FrIf_HaltCommunication shall wrap the FlexRay


Driver API function Fr_HaltCommunication() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Calling Fr_HaltCommunication() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

[SWS_FrIf_05166] ⌈Caveats of FrIf_HaltCommunication: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003⌋ ()

8.3.8 FrIf_AbortCommunication

[SWS_FrIf_05007]⌈
63 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Service Name FrIf_AbortCommunication

Std_ReturnType FrIf_AbortCommunication (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x06
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_AbortCommunication().

Available via FrIf.h

⌋(SRS_Fr_05016)

[SWS_FrIf_05167] ⌈If parameter FrIf_CtrlIdx of FrIf_AbortCommunication has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_AbortCommunication shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05168] ⌈The function FrIf_AbortCommunication shall wrap the FlexRay


Driver API function Fr_AbortCommunication() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Calling Fr_AbortCommunication() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

[SWS_FrIf_05169] ⌈Caveats of FrIf_AbortCommunication: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003⌋ ()

64 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.9 FrIf_GetState

[SWS_FrIf_05170]⌈
Service Name FrIf_GetState

Std_ReturnType FrIf_GetState (
uint8 FrIf_ClstIdx,
Syntax FrIf_StateType* FrIf_StatePtr
)

Service ID
0x07
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

Parameters (in) FrIf_ClstIdx Index of the cluster addressed.

Parameters
None
(inout)

Parameters Pointer to a memory location where the retrieved FrIfState will be


FrIf_StatePtr
(out) stored

E_OK: Function was successfully executed. State transition


Std_Return- request was accepted.
Return value
Type E_NOT_OK: Function execution failed due to detected errors.
State transition request was not accepted.

Description Get current FrIf state.

Available via FrIf.h

⌋()

[SWS_FrIf_05171] ⌈If parameter FrIf_ClstIdx of FrIf_GetState has an invalid value


and if development error detection is enabled (i.e. FrIfDevErrorDetect equals ON),
the function FrIf_GetState shall report development error code
FRIF_E_INV_CLST_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05172] ⌈If parameter FrIf_StatePtr of FrIf_GetState equals NULL_PTR


and if development error detection is enabled (i.e. FrIfDevErrorDetect equals ON),
the function FrIf_GetState shall report development error code
FRIF_E_PARAM_POINTER to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05173] ⌈Caveats of FrIf_GetState: The FlexRay Interface module has to


be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003⌋ ()

65 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.10 FrIf_SetState

[SWS_FrIf_05174]⌈
Service Name FrIf_SetState

Std_ReturnType FrIf_SetState (
uint8 FrIf_ClstIdx,
Syntax FrIf_StateTransitionType FrIf_StateTransition
)

Service ID
0x08
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant

FrIf_ClstIdx Index of the cluster addressed.


Parameters (in)
FrIf_State
Requested FrIf state transition.
Transition

Parameters
None
(inout)

Parameters
None
(out)

E_OK: Function was successfully executed. State transition


Std_Return- request was accepted.
Return value
Type E_NOT_OK: Function execution failed due to detected errors.
State transition request was not accepted.

Description Requests FrIf state machine transition.

Available via FrIf.h

⌋()

[SWS_FrIf_05175] ⌈If parameter FrIf_ClstIdx of FrIf_SetState has an invalid value


and if development error detection is enabled (i.e. FrIfDevErrorDetect equals ON),
the function FrIf_SetState shall report development error code
FRIF_E_INV_CLST_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05037] ⌈If parameter FrIf_StateTransition of FrIf_SetState has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_SetState shall report development error code
FRIF_E_INV_FRIF_STATE to the Det_ReportError service of the DET module.⌋ ()

[SWS_FrIf_05176] ⌈Caveats of FrIf_SetState: The FlexRay Interface module has to


be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003⌋ ()

66 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.11 FrIf_SetWakeupChannel

[SWS_FrIf_05010]⌈
Service Name FrIf_SetWakeupChannel

Std_ReturnType FrIf_SetWakeupChannel (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx
)

Service ID
0x09
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Chnl Index of the FlexRay Channel to address in scope of the FlexRay
Idx controller FrIf_CtrlIdx.

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Wraps the FlexRay Driver API function Fr_SetWakeupChannel(). The enum value
Description
"FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋()

[SWS_FrIf_05500] ⌈If parameter FrIf_CtrlIdx of FrIf_SetWakeupChannel has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_SetWakeupChannel shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05177] ⌈If parameter FrIf_ChnlIdx of FrIf_SetWakeupChannel has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_SetWakeupChannel shall report development error
code FRIF_E_INV_CHNL_IDX to the Det_ReportError service of the DET module. ⌋
()

67 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05178] ⌈The function FrIf_SetWakeupChannel shall wrap the FlexRay


Driver API function Fr_SetWakeupChannel() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Setting parameters Fr_ChnlIdx to FrIf_ChnlIdx
-3) Calling Fr_SetWakeupChannel() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

[SWS_FrIf_05179] ⌈Caveats of FrIf_SetWakeupChannel: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.12 FrIf_SendWUP

[SWS_FrIf_05011]⌈
Service Name FrIf_SendWUP

Std_ReturnType FrIf_SendWUP (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x0a
[hex]

Sync/Async Asynchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_SendWUP().

Available via FrIf.h

⌋(SRS_Fr_05018)
68 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05180] ⌈If parameter FrIf_CtrlIdx of FrIf_SendWUP has an invalid value


and if development error detection is enabled (i.e. FrIfDevErrorDetect equals ON),
the function FrIf_SendWUP shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05181] ⌈The function FrIf_SendWUP shall wrap the FlexRay Driver API
function Fr_SendWUP() by:
- 1) Translating (based on static FrIf module configuration)
the FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay
Driver | Driver-specific CC index Fr_CtrlIdx).
- 2) Calling Fr_SendWUP() of the determined FlexRay Driver
module with the parameters determined as described above.
⌋ ()

[SWS_FrIf_05182] ⌈Caveats of FrIf_SendWUP: The FlexRay Interface module has


to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003. ⌋ ()

8.3.13 FrIf_GetPOCStatus

[SWS_FrIf_05014]⌈
Service Name FrIf_GetPOCStatus

Std_ReturnType FrIf_GetPOCStatus (
uint8 FrIf_CtrlIdx,
Syntax Fr_POCStatusType* FrIf_POCStatusPtr
)

Service ID
0x0d
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters FrIf_
Pointer to a memory location where output value will be stored.
(out) POCStatusPtr

E_OK: The call of the FlexRay Driver's API service has returned
E_OK.
Std_Return-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
Type
returned E_NOT_OK, or an error has been detected in
development mode.

69 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Description Wraps the FlexRay Driver API function Fr_GetPOCStatus().

Available via FrIf.h

⌋(SRS_Fr_05022)

[SWS_FrIf_05190] ⌈If parameter FrIf_CtrlIdx of FrIf_GetPOCStatus has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_GetPOCStatus shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05192] ⌈The function FrIf_GetPOCStatus shall wrap the FlexRay Driver


API function Fr_GetPOCStatus() by:
- 1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
- 2) Setting parameters Fr_POCStatusPtr to FrIf_POCStatusPtr
- 3) Calling Fr_GetPOCStatus() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05193] ⌈Caveats of FrIf_GetPOCStatus: The FlexRay Interface module


has to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003. ⌋ ()

70 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.14 FrIf_GetGlobalTime

[SWS_FrIf_05015]⌈
Service Name FrIf_GetGlobalTime

Std_ReturnType FrIf_GetGlobalTime (
uint8 FrIf_CtrlIdx,
Syntax uint8* FrIf_CyclePtr,
uint16* FrIf_MacroTickPtr
)

Service ID
0x0e
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

FrIf_Cycle
Pointer to a memory location where output value will be stored.
Ptr
Parameters
(out)
FrIf_Macro
Pointer to a memory location where output value will be stored.
TickPtr

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_Return-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
Type
returned E_NOT_OK, or an error has been detected in development
mode.

Wraps the FlexRay Driver API function Fr_GetGlobalTime().


Description
Important Note: FrIf_GetGlobalTime may be called within an exclusive area.

Available via FrIf.h

⌋()

[SWS_FrIf_05194] ⌈If parameter FrIf_CtrlIdx of FrIf_GetGlobalTime has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_GetGlobalTime shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

71 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05195] ⌈The function FrIf_GetGlobalTime shall wrap the FlexRay Driver


API function Fr_GetGlobalTime() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Setting parameters
-3) Fr_CylcePtr to FrIf_CyclePtr
Fr_MacroTickPtr to FrIf_MacroTickPtr
-4) Calling Fr_GetGlobalTime() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05196] ⌈Caveats of FrIf_GetGlobalTime: The FlexRay Interface module


has to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003. ⌋ ()

8.3.15 FrIf_AllowColdstart

[SWS_FrIf_05017]⌈
Service Name FrIf_AllowColdstart

Std_ReturnType FrIf_AllowColdstart (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x10
[hex]

Sync/Async Asynchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_AllowColdstart().

Available via FrIf.h

72 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

⌋()

[SWS_FrIf_05200] ⌈If parameter FrIf_CtrlIdx of FrIf_AllowColdstart has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_AllowColdstart shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05201] ⌈The function FrIf_AllowColdstart shall wrap the FlexRay Driver


API function Fr_AllowColdstart() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Calling Fr_AllowColdstart() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05202] ⌈Caveats: The FlexRay Interface module has to be initialized with


a call of FrIf_Init() before this API service may be called, see SWS_FrIf_05003. ⌋ ()

8.3.16 FrIf_GetMacroticksPerCycle

[SWS_FrIf_05018]⌈
Service Name FrIf_GetMacroticksPerCycle

uint16 FrIf_GetMacroticksPerCycle (
Syntax uint8 FrIf_CtrlIdx
)

Service ID [hex] 0x11

Sync/Async Synchronous

Reentrancy Reentrant

Parameters (in) FrIf_CtrlIdx Index of the FlexRay CC to address.

Parameters (inout) None

Parameters (out) None

Return value uint16 Number of Macroticks per Cycle

Description Retrieves the amount of Macroticks per Cycle

Available via FrIf.h

⌋()

73 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05203] ⌈If parameter FrIf_CtrlIdx of FrIf_GetMacroticksPerCycle has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetMacroticksPerCycle shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module.

This API service of the FlexRay Interface retrieves the number of Macroticks per
FlexRay Cycle of the FlexRay Cluster with index FrIf_CtrlIdx out of the static
configuration. ⌋ ()

[SWS_FrIf_05204] ⌈Caveats of FrIf_GetMacroticksPerCycle: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.17 FrIf_GetMacrotickDuration

[SWS_FrIf_05019]⌈
Service Name FrIf_GetMacrotickDuration

uint16 FrIf_GetMacrotickDuration (
Syntax uint8 FrIf_CtrlIdx
)

Service ID [hex] 0x31

Sync/Async Synchronous

Reentrancy Reentrant

Parameters (in) FrIf_CtrlIdx Index of the FlexRay CC to address.

Parameters (inout) None

Parameters (out) None

Return value uint16 Duration of one Macrotick in ns

Description Retrieves the Duration of a Macrotick in ns

Available via FrIf.h

⌋()

[SWS_FrIf_05191] ⌈If parameter FrIf_CtrlIdx of FrIf_GetMacrotickDuration: has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetMacrotickDuration: shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module.

This API service of the FlexRay Interface retrieves duration of one Macrotick in
nanoseconds of the FlexRay Cluster with index FrIf_CtrlIdx out of the static
configuration. ⌋ ()
74 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05754] ⌈Caveats of FrIf_GetMacrotickDuration: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003⌋ ()

8.3.18 FrIf_Transmit

[SWS_FrIf_05033]⌈
Service Name FrIf_Transmit

Std_ReturnType FrIf_Transmit (
PduIdType TxPduId,
Syntax const PduInfoType* PduInfoPtr
)

Service ID [hex] 0x49

Sync/Async Synchronous

Reentrancy Reentrant for different PduIds. Non reentrant for the same PduId.

TxPduId Identifier of the PDU to be transmitted


Parameters (in)
Length of and pointer to the PDU data and pointer to Meta
PduInfoPtr
Data.

Parameters
None
(inout)

Parameters (out) None

Std_Return- E_OK: Transmit request has been accepted.


Return value
Type E_NOT_OK: Transmit request has not been accepted.

Description Requests transmission of a PDU.

Available via FrIf.h

⌋()

[SWS_FrIf_05318]
FrIf_Transmit() shall return E_NOT_OK in case the FrIf's state is
FRIF_STATE_OFFLINE.

[SWS_FrIf_05205] ⌈If parameter TxPduId of FrIf_Transmit has an invalid value and if


development error detection is enabled (i.e. FrIfDevErrorDetect equals ON), the
function FrIf_Transmit shall report development error code FRIF_E_INV_TXPDUID
to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05207] ⌈If the parameter FrIfAllowedDynamicSduLength is set to false


and/or if the parameter FrIfImmediate is set to true for the passed TxPduId, the
75 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

passed SduDataPtr in parameter PduInfoPtr of FrIf_Transmit shall be checked for


NULL_PTR in case development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON). If in this case the passed SduDataPtr equals NULL_PTR, the function
FrIf_Transmit shall report the development error code FRIF_E_PARAM_POINTER to
the Det_ReportError service of the DET module.

In case of decoupled transmission the PDU with index TxPduId is not yet passed to
the underlying FlexRay Driver module for transmission. FrIf only remembers the
PDU's transmission request (increment TrigTxCounter5). This decoupling mechanism
between the call of FrIf_Transmit() and the execution of the FrIfCommunicationAction
(see FrIf06067) has some implications:
 The upper layer BSW module may operate asynchronously to the FlexRay
Communication System and thus may call FrIf_Transmit() at any point in time.
 The upper layer BSW module must permanently buffer the PDU's payload date
and must be able to handle a call of its <UL_TriggerTransmit>() API service at
(from the BSW's point of view) any arbitrary point in time. ⌋ ()

[SWS_FrIf_05208] ⌈In case of immediate transmission the function FrIf_Transmit


shall pass the PDU (single PDU, no Update bit) to the underlying FlexRay Driver
module immediately for transmission. ⌋ ()

[SWS_FrIf_05757] ⌈
"If parameter TxPduId is configured for an immediate PDU, and if configuration
parameter FrIfAllowDynamicLSduLength is set to FALSE, the provided length in
PduInfoPtr shall be compared with the static configured length (see
ECUC_FrIf_06054).
If the length information does not match, FrIf_Transmit() shall return E_NOT_OK and
shall not perform the immediate PDU transmission. If development error detection is
enabled (i.e. FrIfDevErrorDetect equals ON), the function FrIf_Transmit() shall report
development error code FRIF_E_INV_PDULENGTH to the Det_ReportError service
of the DET module. ⌋ ()

[SWS_FrIf_05209] ⌈Caveats of FrIf_Transmit: The FlexRay Interface module has to


be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003⌋ ()

8.3.19 FrIf_SetTransceiverMode

[SWS_FrIf_05034]⌈
Service Name FrIf_SetTransceiverMode

Std_ReturnType FrIf_SetTransceiverMode (
Syntax uint8 FrIf_CtrlIdx,
Fr_ChannelType FrIf_ChnlIdx,

5
Limited by static configuration [Configuration Parameter FrIfCounterLimit, see FrIf06076]
76 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

FrTrcv_TrcvModeType FrIf_TrcvMode
)

Service ID
0x13
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.

Index of the FlexRay Channel to address in scope of the FlexRay


Parameters FrIf_ChnlIdx
controller FrIf_CtrlIdx.
(in)
FrIf_Trcv
Transceiver mode to be set.
Mode

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Transceiver Driver's API service


Std_Return- has returned E_OK.
Return value
Type E_NOT_OK: The call of the FlexRay Transceiver Driver's API
service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_SetTransceiverMode().


Description
The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋(SRS_Fr_05039)

[SWS_FrIf_05210] ⌈If parameter FrIf_CtrlIdx of FrIf_SetTransceiverMode has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_SetTransceiverMode shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05211] ⌈If parameter FrIf_ChnlIdx of FrIf_SetTransceiverMode has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_SetTransceiverMode shall report development error
code FRIF_E_INV_CHNL_IDX to the Det_ReportError service of the DET module. ⌋
()

[SWS_FrIf_05212] ⌈The function FrIf_SetTransceiverMode shall wrap the FlexRay


Transceiver Driver API function FrTrcv_SetTransceiverMode() by:
1. Translating (based on static FrIf module configuration) the tuple (FlexRay CC
index FrIf_CtrlIdx | FlexRay Channel index FrIf_ChnlIdx) into a tuple (FlexRay
Transceiver Driver | Driver-specific Transceiver index FrTrcv_TrcvIdx).
2. Setting parameters
 FrTrcv_TrcvMode to FrIf_TrcvMode

77 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

3. Calling FrTrcv_SetTransceiverMode() of the determined FlexRay Driver module


with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05213] ⌈Caveats of FrIf_SetTransceiverMode: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.20 FrIf_GetTransceiverMode

[SWS_FrIf_05035]⌈
Service Name FrIf_GetTransceiverMode

Std_ReturnType FrIf_GetTransceiverMode (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx,
FrTrcv_TrcvModeType* FrIf_TrcvModePtr
)

Service ID
0x14
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) Index of the FlexRay Channel to address in scope of the FlexRay
FrIf_ChnlIdx
controller FrIf_CtrlIdx.

Parameters
None
(inout)

Parameters FrIf_TrcvMode
Pointer to a memory location where output value will be stored.
(out) Ptr

E_OK: The call of the FlexRay Transceiver Driver's API service


Std_Return- has returned E_OK.
Return value
Type E_NOT_OK: The call of the FlexRay Transceiver Driver's API
service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_GetTransceiverMode().


Description
The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋(SRS_Fr_05157)

[SWS_FrIf_05214] ⌈If parameter FrIf_CtrlIdx of FrIf_GetTransceiverMode has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetTransceiverMode shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()
78 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05215] ⌈If parameter FrIf_ChnlIdx of FrIf_GetTransceiverMode has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetTransceiverMode shall report development error
code FRIF_E_INV_CHNL_IDX to the Det_ReportError service of the DET module. ⌋
()

[SWS_FrIf_05216] ⌈The function FrIf_GetTransceiverMode shall wrap the FlexRay


Transceiver Driver API function FrTrcv_GetTransceiverMode() by:
1. Translating (based on static FrIf module configuration) the tuple (FlexRay CC
index FrIf_CtrlIdx | FlexRay Channel index FrIf_ChnlIdx) into a tuple (FlexRay
Transceiver Driver | Driver-specific Transceiver index FrTrcv_TrcvIdx).
2. Setting parameters
 FrTrcv_TrcvModePtr to FrIf_TrcvModePtr
3. Calling FrTrcv_GetTransceiverMode() of the determined FlexRay Driver module
with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05217] ⌈Caveats of FrIf_GetTransceiverMode: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

8.3.21 FrIf_GetTransceiverWUReason

[SWS_FrIf_05036]⌈
Service Name FrIf_GetTransceiverWUReason

Std_ReturnType FrIf_GetTransceiverWUReason (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx,
FrTrcv_TrcvWUReasonType* FrIf_TrcvWUReasonPtr
)

Service ID
0x15
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) Index of the FlexRay Channel to address in scope of the Flex
FrIf_ChnlIdx
Ray controller FrIf_CtrlIdx.

Parameters
None
(inout)

Parameters FrIf_Trcv Pointer to a memory location where output value will be


(out) WUReasonPtr stored.

79 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

E_OK: The call of the FlexRay Transceiver Driver's API


service has returned E_OK.
Return value Std_ReturnType
E_NOT_OK: The call of the FlexRay Transceiver Driver's
API service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_GetTransceiver


Description
WUReason(). The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋(SRS_BSW_00375, SRS_Fr_05158)

[SWS_FrIf_05218] ⌈If parameter FrIf_CtrlIdx of FrIf_GetTransceiverWUReason has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_GetTransceiverWUReason shall
report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05219] ⌈If parameter FrIf_ChnlIdx of FrIf_GetTransceiverWUReason has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_GetTransceiverWUReason shall
report development error code FRIF_E_INV_CHNL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05220] ⌈The function FrIf_GetTransceiverWUReason shall wrap the


FlexRay Transceiver Driver API function FrTrcv_GetTransceiverWUReason() by:
1. Translating (based on static FrIf module configuration) the tuple (FlexRay CC
index FrIf_CtrlIdx | FlexRay Channel index FrIf_ChnlIdx) into a tuple (FlexRay
Transceiver Driver | Driver-specific Transceiver index FrTrcv_TrcvIdx).
2. Setting parameters
 FrTrcv_TrcvWUReasonPtr to FrIf_WUReasonPtr
3. Calling FrTrcv_GetTransceiverWUReason() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05221] ⌈Caveats of FrIf_GetTransceiverWUReason: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

8.3.22 FrIf_ClearTransceiverWakeup

[SWS_FrIf_05039]⌈
Service Name FrIf_ClearTransceiverWakeup

Std_ReturnType FrIf_ClearTransceiverWakeup (
uint8 FrIf_CtrlIdx,
Syntax
Fr_ChannelType FrIf_ChnlIdx
)

Service ID 0x18

80 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) Index of the FlexRay Channel to address in scope of the FlexRay
FrIf_ChnlIdx
controller FrIf_CtrlIdx.

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Transceiver Driver's API service


Std_Return- has returned E_OK.
Return value
Type E_NOT_OK: The call of the FlexRay Transceiver Driver's API
service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_ClearTransceiver


Description
Wakeup(). The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋(SRS_Fr_05161)
[SWS_FrIf_05230] ⌈If parameter FrIf_CtrlIdx of FrIf_ClearTransceiverWakeup has an
invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_ClearTransceiverWakeup shall report development
error code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET
module. ⌋ ()

[SWS_FrIf_05231] ⌈If parameter FrIf_ChnlIdx of FrIf_ClearTransceiverWakeup has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_ClearTransceiverWakeup shall
report development error code FRIF_E_INV_CHNL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05232] ⌈The function FrIf_ClearTransceiverWakeup shall wrap the


FlexRay Transceiver Driver API function FrTrcv_ClearTransceiverWakeup() by:
-1) Translating (based on static FrIf module configuration) the
tuple (FlexRay CC index FrIf_CtrlIdx | FlexRay Channel index
FrIf_ChnlIdx) into a tuple (FlexRay Transceiver Driver | Driver-
specific Transceiver index FrTrcv_TrcvIdx).
-2) Calling FrTrcv_ClearTransceiverWakeup() of the determined
FlexRay Driver module with the parameters determined as
described above. ⌋ ()

[SWS_FrIf_05233] ⌈Caveats of FrIf_ClearTransceiverWakeup: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()
81 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.23 FrIf_CancelAbsoluteTimer

[SWS_FrIf_05023]⌈
Service Name FrIf_CancelAbsoluteTimer

Std_ReturnType FrIf_CancelAbsoluteTimer (
uint8 FrIf_CtrlIdx,
Syntax uint8 FrIf_AbsTimerIdx
)

Service ID
0x1b
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Abs
Index of the absolute timer to address.
TimerIdx

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_CancelAbsoluteTimer() .

Available via FrIf.h

⌋()
[SWS_FrIf_05240] ⌈If parameter FrIf_CtrlIdx of FrIf_CancelAbsoluteTimer has an
invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_CancelAbsoluteTimer shall report development error
code FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05241] ⌈The function FrIf_CancelAbsoluteTimer shall wrap the FlexRay


Driver API function Fr_CancelAbsoluteTimer() by:
-1) Translating (based on static FrIf module configuration) the
FlexRay CC index FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-
specific CC index Fr_CtrlIdx).
-2) Setting parameters Fr_AbsTimerIdx to FrIf_AbsTimerIdx
-3) Calling Fr_CancleAbsoluteTimer() of the determined FlexRay
Driver module with the parameters determined as described
above. ⌋ ()

82 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05242] ⌈Caveats of FrIf_CancelAbsoluteTimer: The FlexRay Interface


module has to be initialized with a call of FrIf_Init() before this API service may be
called, see SWS_FrIf_05003. ⌋ ()

83 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.3.24 FrIf_GetAbsoluteTimerIRQStatus

[SWS_FrIf_05027]⌈
Service Name FrIf_GetAbsoluteTimerIRQStatus

Std_ReturnType FrIf_GetAbsoluteTimerIRQStatus (
uint8 FrIf_CtrlIdx,
Syntax uint8 FrIf_AbsTimerIdx,
boolean* FrIf_IRQStatusPtr
)

Service ID
0x1f
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Abs
Index of the absolute timer to address.
TimerIdx

Parameters
None
(inout)

Parameters FrIf_
Pointer to a memory location where output value will be stored.
(out) IRQStatusPtr

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_Return-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
Type
returned E_NOT_OK, or an error has been detected in
development mode.

Description Wraps the FlexRay Driver API function Fr_GetAbsoluteTimerIRQStatus()

Available via FrIf.h

⌋()

[SWS_FrIf_05252] ⌈If parameter FrIf_CtrlIdx of FrIf_GetAbsoluteTimerIRQStatus has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_GetAbsoluteTimerIRQStatus shall
report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05253] ⌈The function FrIf_GetAbsoluteTimerIRQStatus shall wrap the


FlexRay Driver API function Fr_GetAbsoluteTimerIRQStatus() by:
1. Translating (based on static FrIf module configuration) the FlexRay CC index
FrIf_CtrlIdx into a tuple (FlexRay Driver | Driver-specific CC index Fr_CtrlIdx).
2. Setting parameters
 Fr_AbsTimerIdx to FrIf_AbsTimerIdx
84 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

 Fr_IRQStatusPtr to FrIf_IRQStatusPtr
3. Calling Fr_GetAbsoluteTimerIRQStatus() of the determined FlexRay Driver
module with the parameters determined as described above. ⌋ ()

[SWS_FrIf_05254] ⌈Caveats of FrIf_GetAbsoluteTimerIRQStatus: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

8.3.25 FrIf_DisableAbsoluteTimerIRQ

[SWS_FrIf_05031]⌈
Service Name FrIf_DisableAbsoluteTimerIRQ

Std_ReturnType FrIf_DisableAbsoluteTimerIRQ (
uint8 FrIf_CtrlIdx,
Syntax
uint8 FrIf_AbsTimerIdx
)

Service ID
0x23
[hex]

Sync/Async Synchronous

Reentrancy non reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Abs
Index of the absolute timer to address.
TimerIdx

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_DisableAbsoluteTimerIRQ().

Available via FrIf.h

⌋()

[SWS_FrIf_05264] ⌈If parameter FrIf_CtrlIdx of FrIf_DisableAbsoluteTimerIRQ has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_DisableAbsoluteTimerIRQ shall
85 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError


service of the DET module. ⌋ ()

[SWS_FrIf_05266] ⌈Caveats of FrIf_DisableAbsoluteTimerIRQ: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

8.3.26 FrIf_GetCycleLength

[SWS_FrIf_05239]⌈
Service Name FrIf_GetCycleLength

uint32 FrIf_GetCycleLength (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x3a
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

Return value uint32 Time in unit of nanoseconds

This API returns the configured time of the configuration parameter "GdCycle" in
Description
nanoseconds for the FlexRay controller with index FrIf_CtrlIdx.

Available via FrIf.h

⌋()

[SWS_FrIf_05237] ⌈If parameter FrIf_CtrlIdx of FrIf_GetCycleLength has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_GetCycleLength shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

86 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05238] ⌈Caveats of FrIf_GetCycleLength: The FlexRay Interface module


has to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003. ⌋ ()

87 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.4 Optional Function Definitions

8.4.1 FrIf_AllSlots

[SWS_FrIf_05020]⌈
Service Name FrIf_AllSlots

Std_ReturnType FrIf_AllSlots (
Syntax uint8 FrIf_CtrlIdx
)

Service ID
0x33
[hex]

Sync/Async Synchronous

Reentrancy non reentrant

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Driver's API service has returned E_
Std_- OK.
Return value Return- E_NOT_OK: The call of the FlexRay Driver's API service has
Type returned E_NOT_OK, or an error has been detected in development
mode.

Description Wraps the FlexRay Driver API function Fr_AllSlots

Available via FrIf.h

⌋()

[SWS_FrIf_05412] ⌈The function FrIf_AllSlots shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfAllSlotsSupport
(derived from configuration parameter FrIfAllSlotsSupport, see ECUC_FrIf_06108) ⌋
()

[SWS_FrIf_05706] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_AllSlots is called before the FrIf was initialized successfully, the
function FrIf_AllSlots shall raise the development error FRIF_E_UNINIT and return
E_NOT_OK. ⌋ ()
88 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05707] ⌈If development error detection for the Fr module is enabled: the
function FrIf_AllSlots shall check the parameter FrIf_CtrlIdx for being valid. If
FrIf_CtrlIdx is invalid, the function FrIf_AllSlots shall raise the development error
FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.2 FrIf_GetChannelStatus

[SWS_FrIf_05030]⌈
Service Name FrIf_GetChannelStatus

Std_ReturnType FrIf_GetChannelStatus (
uint8 FrIf_CtrlIdx,
Syntax uint16* FrIf_ChannelAStatusPtr,
uint16* FrIf_ChannelBStatusPtr
)

Service ID [hex] 0x26

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

Index of FlexRay CC within the context of the FlexRay


Parameters (in) FrIf_CtrlIdx
Interface.

Parameters
None
(inout)

FrIf_Channel Address where the bitcoded channel A status information


AStatusPtr shall be stored.
Parameters
(out)
FrIf_Channel Address where the bitcoded channel B status information
BStatusPtr shall be stored.

E_OK: API call finished successfully. E_NOT_OK: API call


Return value Std_ReturnType
aborted due to errors.

Wraps the FlexRay Driver API function Fr_GetChannelStatus() and gets the
Description
channel status information.

Available via FrIf.h

⌋()

[SWS_FrIf_05413] ⌈The function FrIf_GetChannelStatus shall be pre compile time


configurable ON/OFF by the configuration parameter
FrIfGetGetChannelStatusSupport
(derived from configuration parameter FrIfGetGetChannelStatusSupport, see
ECUC_FrIf_06105) ⌋ ()

89 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05708] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetChannelStatus is called before the FrIf module was initialized
successfully, the function FrIf_GetChannelStatus shall raise the development error
FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05709] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetChannelStatus shall check the parameter FrIf_CtrlIdx for being valid.
If FrIf_CtrlIdx is invalid, the function FrIf_GetChannelStatus shall raise the
development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.3 FrIf_GetClockCorrection

[SWS_FrIf_05071]⌈
Service Name FrIf_GetClockCorrection

Std_ReturnType FrIf_GetClockCorrection (
uint8 FrIf_CtrlIdx,
Syntax sint16* FrIf_RateCorrectionPtr,
sint32* FrIf_OffsetCorrectionPtr
)

Service ID [hex] 0x29

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

Index of FlexRay CC within the context of the FlexRay


Parameters (in) FrIf_CtrlIdx
Interface.

Parameters
None
(inout)

FrIf_RateCorrection Address where the current rate correction value shall be


Ptr stored.
Parameters
(out)
FrIf_Offset Address where the current offset correction value shall be
CorrectionPtr stored.

E_OK: API call finished successfully. E_NOT_OK: API call


Return value Std_ReturnType
aborted due to errors.

Wraps the FlexRay Driver API function Fr_GetClockCorrection () and gets the
Description
current clock correction values.

Available via FrIf.h

⌋()
[SWS_FrIf_05414] ⌈The function FrIf_GetClockCorrection shall be pre compile time
configurable ON/OFF by the configuration parameter FrIfGetClockCorrectionSupport
(derived from configuration parameter FrIfGetClockCorrectionSupport, see
90 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

ECUC_FrIf_06106) ⌋ ()

[SWS_FrIf_05711] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetClockCorrection is called before the FrIf was initialized
successfully, the function FrIf_GetClockCorrection shall raise the development error
FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05712] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetClockCorrection shall check the parameter FrIf_CtrlIdx for being
valid. If FrIf_CtrlIdx is invalid, the function FrIf_GetClockCorrection shall raise the
development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.4 FrIf_GetSyncFrameList

[SWS_FrIf_05072]⌈
Service
FrIf_GetSyncFrameList
Name

Std_ReturnType FrIf_GetSyncFrameList (
uint8 FrIf_CtrlIdx,
uint8 FrIf_ListSize,
uint16* FrIf_ChannelAEvenListPtr,
Syntax uint16* FrIf_ChannelBEvenListPtr,
uint16* FrIf_ChannelAOddListPtr,
uint16* FrIf_ChannelBOddListPtr
)

Service ID
0x2a
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

FrIf_CtrlIdx Index of FlexRay CC within the context of the FlexRay Interface.

Parameters Size of the arrays passed via parameters: FrIf_ChannelAEvenListPtr


(in) FrIf_List FrIf_ChannelBEvenListPtr FrIf_ChannelAOddListPtr FrIf_Channel
Size BOddListPtr. The service must ensure to not write more entries into
those arrays than granted by this parameter.

Parameters
None
(inout)

Address the list of syncframes on channel A within the even


FrIf_
communication cycle is written to. The exact number of elements
Channel
written to the list is limited by parameter FrIf_ListSize. Unused list
Parameters AEvenList
elements are filled with the value '0' to indicate that no more
(out) Ptr
syncframe has been seen.

FrIf_ Address the list of syncframes on channel B within the even

91 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Channel communication cycle is written to. The exact number of elements


BEvenList written to the list is limited by parameter FrIf_ListSize. Unused list
Ptr elements are filled with the value '0' to indicate that no more
syncframe has been seen.

Address the list of syncframes on channel A within the odd


FrIf_
communication cycle is written to. The exact number of elements
Channel
written to the list is limited by parameter FrIf_ListSize. Unused list
AOddList
elements are filled with the value '0' to indicate that no more
Ptr
syncframe has been seen.

Address the list of syncframes on channel B within the odd


FrIf_
communication cycle is written to. The exact number of elements
Channel
written to the list is limited by parameter FrIf_ListSize. Unused list
BOddList
elements are filled with the value '0' to indicate that no more
Ptr
syncframe has been seen.

Std_- E_OK: API call finished successfully. E_NOT_OK: API call aborted
Return value
ReturnType due to errors.

Wraps the FlexRay Driver API function Fr_GetSyncFrameList and gets a list of
Description syncframes received or transmitted on channel A and channel B via the even and
odd communication cycle.

Available via FrIf.h

⌋()

[SWS_FrIf_05415] ⌈The function FrIf_GetSyncFrameList shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfGetSyncFrameListSupport
(derived from configuration parameter FrIfGetSyncFrameListSupport, see
ECUC_FrIf_06107) ⌋ ()

[SWS_FrIf_05715] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetSyncFrameList is called before the Fr was initialized
successfully, the function FrIf_GetSyncFrameList shall raise the development error
FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05716] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetSyncFrameList shall check the parameter FrIf_CtrlIdx for being
valid. If FrIf_CtrlIdx is invalid, the function FrIf_GetSyncFrameList shall raise the
development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.5 FrIf_GetNumOfStartupFrames

[SWS_FrIf_05073]⌈
Service Name FrIf_GetNumOfStartupFrames

Syntax Std_ReturnType FrIf_GetNumOfStartupFrames (

92 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

uint8 FrIf_CtrlIdx,
uint8* FrIf_NumOfStartupFramesPtr
)

Service ID
0x34
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

Parameters Index of FlexRay CC within the context of the FlexRay


FrIf_CtrlIdx
(in) Interface.

Parameters
None
(inout)

Parameters FrIf_NumOfStartup Address where the number of startup frames seen within the
(out) FramesPtr last even/odd cycle pair shall be stored.

E_OK: API call finished successfully. E_NOT_OK: API call


Return value Std_ReturnType
aborted due to errors.

Wraps the FlexRay Driver API function Fr_GetNumOfStartupFrames and gets a list
Description of the current number of startup frames seen on the cluster. See variable vStartup
Pairs of [12] for details.

Available via FrIf.h

⌋()

[SWS_FrIf_05416] ⌈The function FrIf_GetNumOfStartupFrames shall be pre compile


time configurable ON/OFF by the configuration parameter
FrIfGetNumOfStartupFramesSupport (derived from configuration parameter
FrIfGetNumOfStartupFramesSupport, see ECUC_FrIf_06104) ⌋ ()

[SWS_FrIf_05721] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetNumOfStartupFrames is called before the FrIf was initialized
successfully, the function FrIf_GetNumOfStartupFrames shall raise the development
error FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05722] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetNumOfStartupFrames shall check the parameter FrIf_CtrlIdx for
being valid. If FrIf_CtrlIdx is invalid, the function FrIf_GetNumOfStartupFrames shall
raise the development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.6 FrIf_GetWakeupRxStatus

[SWS_FrIf_05102]⌈
Service Name FrIf_GetWakeupRxStatus

93 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Std_ReturnType FrIf_GetWakeupRxStatus (
uint8 FrIf_CtrlIdx,
Syntax uint8* FrIf_WakeupRxStatusPtr
)

Service ID
0x2b
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

Parameters
FrIf_CtrlIdx Index of FlexRay CC within the context of the FlexRay Driver.
(in)

Parameters
None
(inout)

Address where bitcoded wakeup reception status shall be stored.


Parameters FrIf_Wakeup
Bit 0: Wakeup received on channel A indicator Bit 1: Wakeup
(out) RxStatusPtr
received on channel B indicator Bit 2-7: Unused

Std_Return- E_OK: API call finished successfully. E_NOT_OK: API call aborted
Return value
Type due to errors.

Wraps the FlexRay Driver API function Fr_GetWakeupRxStatus and gets the
Description
wakeup received information from the FlexRay controller.

Available via FrIf.h

⌋()

[SWS_FrIf_05417] ⌈The function FrIf_GetWakeupRxStatus shall be pre compile time


configurable ON/OFF by the configuration parameter
FrIfGetWakeupRxStatusSupport (derived from configuration parameter
FrIfGetWakeupRxStatusSupport, see ECUC_FrIf_06111) ⌋ ()

[SWS_FrIf_05700] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetWakeupRxStatus is called before the Fr was initialized
successfully, the function FrIf_GetWakeupRxStatus shall raise the development error
FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05701] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetWakeupRxStatus shall check the parameter FrIf_CtrlIdx for being
valid. If FrIf_CtrlIdx is invalid, the function FrIf_GetWakeupRxStatus shall raise the
development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.7 FrIf_CancelTransmit

[SWS_FrIf_05070]⌈
94 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Service Name FrIf_CancelTransmit

Std_ReturnType FrIf_CancelTransmit (
Syntax PduIdType TxPduId
)

Service ID [hex] 0x4a

Sync/Async Synchronous

Reentrancy Reentrant for different PduIds. Non reentrant for the same PduId.

Parameters (in) TxPduId Identification of the PDU to be cancelled.

Parameters
None
(inout)

Parameters (out) None

E_OK: Cancellation was executed successfully by the


Std_Return- destination module.
Return value
Type E_NOT_OK: Cancellation was rejected by the destination
module.

Requests cancellation of an ongoing transmission of a PDU in a lower layer


Description
communication module.

Available via FrIf.h

⌋()

[SWS_FrIf_05713] ⌈The function FrIf_CancelTransmit shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfCancelTransmitSupport
(derived from configuration parameter FrIfCancelTransmitSupport, see
ECUC_FrIf_00002) ⌋ ()

[SWS_FrIf_05703] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_CancelTransmit is called before the FrIf was initialized successfully,
the function FrIf_CancelTransmit shall raise the development error FRIF_E_UNINIT
and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05704] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_CancelTransmit shall check the parameter TxPduId for being valid. If
TxPduId is invalid, the function FrIf_CancelTransmit shall raise the development error
FRIF_E_INV_TXPDUID and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05705] ⌈For Transmit Cancellation, the following steps are performed:

1. Decrement TrigTxCounter for the IPDU that shall be canceled.


2. If TxConfCounter > 0 for this PDU, contine with step 3). Else, stop here.
3. Call FlexRay Driver’s API function Fr_CancelTxLPdu():
a. Fr_CtrlIdx is derived according to the indexing scheme descibed in 7.2

95 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

b. Fr_LPduIdx is set to the configured L-PDU buffer index [Configuration


Parameter FrIfLPduIdx, see FrIf06058] associated with the
Communication Operation.
4. Increment TrigTxCounter (limited by FrIfCounterLimit) for all other I-PDUs
within that L-PDU that have a TxConfCounter > 0.
5. Decrement TxConfCounter for all other I-PDUs within that L-PDU that have a
TxConfCounter > 0.
6. Decrement the TxConfCounter for the IPDU that has been initiated by the
CancelTransmit API call. ⌋ ()

8.4.8 FrIf_DisableLPdu

[SWS_FrIf_05710]⌈
Service Name FrIf_DisableLPdu

Std_ReturnType FrIf_DisableLPdu (
uint8 FrIf_CtrlIdx,
Syntax
uint16 FrIf_LPduIdx
)

Service ID
0x28
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same device

Index of FlexRay CC within the context of the FlexRay


FrIf_CtrlIdx
Interface.
Parameters (in)
FrIf_LPduIdx This index is used to uniquely identify a FlexRay frame

Parameters
None
(inout)

Parameters
None
(out)

E_OK: API call finished successfully.


Return value Std_ReturnType
E_NOT_OK: API call aborted due to errors.

Wraps the FlexRay Driver Function Fr_DisableLPdu. It disables the hardware


Description
resource of an LPdu for transmission/reception.

Available via FrIf.h

⌋()

[SWS_FrIf_05418] ⌈The function FrIf_DisableLPdu shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfDisableLPduSupport

96 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

(derived from configuration parameter FrIfDisableLPduSupport, see


ECUC_FrIf_06110) ⌋ ()

[SWS_FrIf_05717] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_DisableLPdu is called before the FrIf was initialized successfully, the
function FrIf_DisableLPdu shall raise the development error FRIF_E_UNINIT and
return E_NOT_OK. ⌋ ()

[SWS_FrIf_05714] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_DisableLPdu shall check the parameter FrIf_CtrlIdx for being valid. If
FrIf_CtrlIdx is invalid, the function FrIf_DisableLPdu shall raise the development error
FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

8.4.9 FrIf_GetTransceiverError

[SWS_FrIf_05032]⌈
Service Name FrIf_GetTransceiverError

Std_ReturnType FrIf_GetTransceiverError (
uint8 FrIf_CtrlIdx,
Fr_ChannelType FrIf_ChnlIdx,
Syntax uint8 FrIf_BranchIdx,
uint32* FrIf_BusErrorState
)

Service ID
0x35
[hex]

Sync/Async Synchronous

Reentrancy Function is non reentrant for the same channel of the same controller.

FrIf_CtrlIdx Index of the FlexRay CC to address.

Index of the FlexRay Channel to address in scope of the FlexRay


Parameters FrIf_ChnlIdx
controller FrIf_CtrlIdx.
(in)
FrIf_Branch This zero based index identifies the branch of the (active star)
Idx transceiver to which the API call has to be applied.

Parameters
None
(inout)

Parameters FrIf_BusError
Address where the transceiver error state is stored.
(out) State

Std_Return- E_OK: API call finished successfully.


Return value
Type E_NOT_OK: API call aborted due to errors

Wraps the FlexRay Transceiver Driver API function FrTrcv_GetTransceiverError.


Description
The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

97 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

⌋()

[SWS_FrIf_05419] ⌈The function FrIf_GetTransceiverError shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfGetTransceiverErrorSupport
(derived from configuration parameter FrIfGetTransceiverErrorSupport, see
ECUC_FrIf_06101) ⌋ ()

[SWS_FrIf_05718] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_GetTransceiverError is called before the FrIf was initialized
successfully, the function FrIf_GetTransceiverError shall raise the development error
FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05719] ⌈If development error detection for the FrIf module is enabled: the
function FrIf_GetTransceiverError shall check the parameter FrIf_CtrlIdx for being
valid. If FrIf_CtrlIdx is invalid, the function FrIf_GetTransceiverError shall raise the
development error FRIF_E_INV_CTRL_IDX and return E_NOT_OK. ⌋ ()

[SWS_FrIf_05720] ⌈If parameter FrIf_ChnlIdx of FrIf_GetTransceiverError has an


invalid value and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetTransceiverError shall report development error
code FRIF_E_INV_CHNL_IDX to the Det_ReportError service of the DET module. ⌋
()

[SWS_FrIf_05728] ⌈The function FrIf_GetTransceiverError shall wrap the FlexRay


Transceiver Driver API function FrTrcv_GetTransceiverError by:
1. Translating (based on static FrIf module configuration) the tuple (FlexRay CC
index FrIf_CtrlIdx | FlexRay Channel index FrIf_ChnlIdx) into a tuple (FlexRay
Transceiver Driver | Driver-specific Transceiver index FrTrcv_TrcvIdx).
2. Setting parameters
 FrTrcv_BranchIdx to FrIf_BranchIdx
 FrTrcv_BusErrorState to FrIf_BusErrorState
3. Calling FrTrcv_GetTransceiverError of the determined FlexRay Transceiver
module with the parameters determined as described above. ⌋ ()

8.4.10 FrIf_EnableTransceiverBranch

[SWS_FrIf_05085]⌈
Service Name FrIf_EnableTransceiverBranch

Std_ReturnType FrIf_EnableTransceiverBranch (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx,
uint8 FrIf_BranchIdx
)

98 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Service ID
0x36
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.

Index of the FlexRay Channel to address in scope of the FlexRay


Parameters FrIf_ChnlIdx
controller FrIf_CtrlIdx.
(in)
FrIf_Branch This zero based index identifies the branch of the (active star)
Idx transceiver to which the API call has to be applied.

Parameters
None
(inout)

Parameters
None
(out)

E_OK: The call of the FlexRay Transceiver Driver's API service has
Std_Return- returned E_OK.
Return value
Type E_NOT_OK: The call of the FlexRay Transceiver Driver's API
service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_EnableTransceiver


Description
Branch. The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋()

[SWS_FrIf_05420] ⌈The function FrIf_EnableTransceiverBranch shall be pre compile


time configurable ON/OFF by the configuration parameter
FrIfEnableTransceiverBranchSupport (derived from configuration parameter
FrIfEnableTransceiverBranchSupport, see ECUC_FrIf_06103) ⌋ ()

[SWS_FrIf_05302] ⌈If parameter FrIf_CtrlIdx of FrIf_EnableTransceiverBranch has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_EnableTransceiverBranch shall
report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05304] ⌈If parameter FrIf_ChnlIdx of FrIf_EnableTransceiverBranch has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_EnableTransceiverBranch shall
report development error code FRIF_E_INV_CHNL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05306] ⌈The function FrIf_EnableTransceiverBranch shall wrap the


FlexRay Transceiver Driver API function FrIf_EnableTransceiverBranch by:
1. Translating (based on static FrIf module configuration) the
tuple (FlexRay CC index FrIf_CtrlIdx | FlexRay Channel index
99 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIf_ChnlIdx) into a tuple (FlexRay Transceiver Driver | Driver-


specific Transceiver index FrTrcv_TrcvIdx).

2) Setting parameter: FrTrcv_BranchIdx to FrIf_BranchIdx

3) Calling FrTrcv_EnableTransceiverBranch of the determined


FlexRay Driver module with the parameters determined as
described above. ⌋ ()

[SWS_FrIf_05307] ⌈If development error detection for the FrIf module is enabled: if
the function FrIf_EnableTransceiverBranch is called before the Fr was initialized
successfully, the function FrIf_EnableTransceiverBranch shall raise the development
error FRIF_E_UNINIT and return E_NOT_OK. ⌋ ()

8.4.11 FrIf_DisableTransceiverBranch

[SWS_FrIf_05028]⌈
Service Name FrIf_DisableTransceiverBranch

Std_ReturnType FrIf_DisableTransceiverBranch (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx,
uint8 FrIf_BranchIdx
)

Service ID
0x37
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.

Index of the FlexRay Channel to address in scope of the FlexRay


Parameters FrIf_ChnlIdx
controller FrIf_CtrlIdx.
(in)
FrIf_Branch This zero based index identifies the branch of the (active star)
Idx transceiver to which the API call has to be applied.

Parameters
None
(inout)

Parameters
None
(out)

Std_Return- E_OK: The call of the FlexRay Transceiver Driver's API service has
Return value
Type returned E_OK.

100 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

E_NOT_OK: The call of the FlexRay Transceiver Driver's API


service has returned E_NOT_OK.

Wraps the FlexRay Transceiver Driver API function FrTrcv_DisableTransceiver


Description
Branch. The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋()

[SWS_FrIf_05421] ⌈The function FrIf_DisableTransceiverBranch shall be pre


compile time configurable ON/OFF by the configuration parameter
FrIfDisableTransceiverBranchSupport (derived from configuration parameter
FrIfDisableTransceiverBranchSupport, see ECUC_FrIf_06102) ⌋ ()

[SWS_FrIf_05425] ⌈The function FrIf_DisableTransceiverBranch shall be pre


compile time configurable ON/OFF by the configuration parameter
FrIfDisableTransceiverBranchSupport (derived from configuration parameter
FrIfDisableTransceiverBranchSupport, see ECUC_FrIf_06102) ⌋ ()

[SWS_FrIf_05756] ⌈If parameter FrIf_CtrlIdx of FrIf_DisableTransceiverBranch has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_DisableTransceiverBranch shall
report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05243] ⌈If parameter FrIf_ChnlIdx of FrIf_DisableTransceiverBranch has


an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_DisableTransceiverBranch shall
report development error code FRIF_E_INV_CHNL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05305] ⌈The function FrIf_DisableTransceiverBranch shall wrap the


FlexRay Transceiver Driver API function FrIf_DisableTransceiverBranch by:
1)Translating (based on static FrIf module configuration) the tuple
(FlexRay CC index FrIf_CtrlIdx | FlexRay Channel index
FrIf_ChnlIdx) into a tuple (FlexRay Transceiver Driver | Driver-
specific Transceiver index FrTrcv_TrcvIdx)
2) Setting parameter: FrTrcv_BranchIdx to FrIf_BranchIdx
3) Calling FrTrcv_DisableTransceiverBranch() of the determined
FlexRay Driver module with the parameters determined as
described above. ⌋ ()

[SWS_FrIf_05308] ⌈Caveats of FrIf_DisableTransceiverBranch: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

101 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.4.12 FrIf_ReconfigLPdu

[SWS_FrIf_05048]⌈
Service Name FrIf_ReconfigLPdu

Std_ReturnType FrIf_ReconfigLPdu (
uint8 FrIf_CtrlIdx,
uint16 FrIf_LPduIdx,
uint16 FrIf_FrameId,
Fr_ChannelType FrIf_ChnlIdx,
Syntax uint8 FrIf_CycleRepetition,
uint8 FrIf_CycleOffset,
uint8 FrIf_PayloadLength,
uint16 FrIf_HeaderCRC
)

Service ID [hex] 0

Sync/Async Synchronous

Reentrancy Non Reentrant

FrIf_CtrlIdx Index of FlexRay CC within the context of the FlexRay Driver.

FrIf_LPduIdx This index is used to uniquely identify a FlexRay frame.

FrIf_FrameId FlexRay Frame ID the FrIf_LPdu shall be configured to.

FrIf_ChnlIdx FlexRay Channel the FrIf_LPdu shall be configured to.

FrIf_Cycle Cycle Repetition part of the cycle filter mechanism FrIf_LPdu


Parameters (in)
Repetition shall be configured to.

Cycle Offset part of the cycle filter mechanism FrIf_LPdu shall


FrIf_CycleOffset
be configured to.

FrIf_Payload Payloadlength in units of bytes the FrIf_LPduIdx shall be


Length configured to.

FrIf_HeaderCRC Header CRC the FrIf_LPdu shall be configured to.

Parameters
None
(inout)

Parameters
None
(out)

E_OK: API call finished successfully.


Return value Std_ReturnType
E_NOT_OK: API call aborted due to errors.

Calls the FlexRay Driver's API Fr_ReconfigLPdu. The enum value "FR_
Description
CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋()

102 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05422] ⌈The function FrIf_ReconfigLPdu shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfReconfigLPduSupport
(derived from configuration parameter FrIfReconfigLPduSupport, see
ECUC_FrIf_06109) ⌋ ()

[SWS_FrIf_05309] ⌈If parameter FrIf_CtrlIdx of FrIf_ReconfigLPdu has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_ReconfigLPdu shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05310] ⌈If parameter FrIf_ChnlIdx of FrIf_ReconfigLPdu has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_ReconfigLPdu shall report development error code
FRIF_E_INV_CHNL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05311] ⌈If parameter FrIf_LPduIdx of FrIf_ReconfigLPdu has an invalid


value (i.e. outside of LPdu range or if FrIfReconfigurable of this LPdu is not set to
TRUE) and development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the FrIf_ReconfigLPdu shall report development error code
FRIF_E_INV_LPDU_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05312] ⌈If parameter FrIf_FrameId of FrIf_ReconfigLPdu has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the FrIf_ReconfigLPdu shall report development error code
FRIF_E_INV_FRAME_ID to the Det_ReportError service of the DET module. ⌋ ()

8.4.13 FrIf_GetNmVector

[SWS_FrIf_05016]⌈
Service Name FrIf_GetNmVector

Std_ReturnType FrIf_GetNmVector (
uint8 FrIf_CtrlIdx,
Syntax
uint8* FrIf_NmVectorPtr
)

Service ID
0x0f
[hex]

Sync/Async Synchronous

non reentrant for identical values of FrIf_CtrlIdx, reentrant for different values of Fr
Reentrancy
If_CtrlIdx

Parameters
FrIf_CtrlIdx Index of the FlexRay CC to address.
(in)

103 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Parameters
None
(inout)

Parameters FrIf_Nm
Pointer to a memory location where output value will be stored.
(out) VectorPtr

E_OK: The call of the FlexRay Driver's API service has returned E_
OK.
Std_-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
ReturnType
returned E_NOT_OK, or an error has been detected in development
mode.

Description Derives the FlexRay NM Vector.

Available via FrIf.h

⌋()

[SWS_FrIf_05423] ⌈The function FrIf_GetNmVector shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfGetNmVectorSupport
(derived from configuration parameter FrIfGetNmVectorSupport, see
FrIf06100_Conf) ⌋ ()

[SWS_FrIf_05197] ⌈If parameter FrIf_CtrlIdx of FrIf_GetNmVector has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_GetNmVector shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

[SWS_FrIf_05198] ⌈The function FrIf_GetNmVector wraps the FlexRay Driver API


Fr_GetNmVector function. ⌋ ()

[SWS_FrIf_05199] ⌈Caveats of FrIf_GetNmVector: The FlexRay Interface module


has to be initialized with a call of FrIf_Init() before this API service may be called, see
SWS_FrIf_05003⌋ ()

8.4.14 FrIf_GetVersionInfo

[SWS_FrIf_05002]⌈
Service Name FrIf_GetVersionInfo

void FrIf_GetVersionInfo (
Syntax Std_VersionInfoType* FrIf_VersionInfoPtr
)

Service ID [hex] 0x01

Sync/Async Synchronous

Reentrancy Reentrant
104 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parameters (in) None

Parameters
None
(inout)

Parameters FrIf_Version Pointer to a memory location where the FlexRay Interface


(out) InfoPtr version information shall be stored.

Return value void --

Description Returns the version information of this module.

Available via FrIf.h

⌋(SRS_BSW_00407, SRS_BSW_00411)
[SWS_FrIf_05424] ⌈The function FrIf_GetVersionInfo shall be pre compile time
configurable ON/OFF by the configuration parameter FrIfVersionInfoApi (derived
from configuration parameter FrIfVersionInfoApi, see ECUC_FrIf_06083) ⌋ ()

[SWS_FrIf_05151] ⌈If parameter FrIf_VersionInfoPtr of FrIf_GetVersionInfo equals


NULL_PTR and if development error detection is enabled (i.e. FrIfDevErrorDetect
equals ON), the function FrIf_GetVersionInfo shall report development error code
FRIF_E_PARAM_POINTER to the Det_ReportError service of the DET module. ⌋ ()

8.4.15 FrIf_ReadCCConfig

[SWS_FrIf_05313]⌈
Service Name FrIf_ReadCCConfig

Std_ReturnType FrIf_ReadCCConfig (
uint8 FrIf_CtrlIdx,
Syntax uint8 FrIf_ConfigParamIdx,
uint32* FrIf_ConfigParamValuePtr
)

Service ID
0x3b
[hex]

Sync/Async Synchronous

Reentrancy Non Reentrant for the same FlexRay CC, reentrant for different FlexRay CCs

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Config
Index of the configuration parameter to read.
ParamIdx

Parameters
None
(inout)

Parameters FrIf_Config Pointer to a memory location where output value will be stored.

105 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

(out) ParamValuePtr

E_OK: The call of the FlexRay Driver's API service has returned
E_OK.
Std_Return-
Return value E_NOT_OK: The call of the FlexRay Driver's API service has
Type
returned E_NOT_OK, or an error has been detected in
development mode.

Description Wraps the FlexRay Driver API function Fr_ReadCCConfig().

Available via FrIf.h

⌋()

[SWS_FrIf_05314] ⌈The function FrIf_ReadCCConfig wraps the FlexRay Driver API


Fr_ReadCCConfig function. ⌋ ()

[SWS_FrIf_05315] ⌈If parameter FrIf_CtrlIdx of FrIf_ReadCCConfig has an invalid


value and if development error detection is enabled (i.e. FrIfDevErrorDetect equals
ON), the function FrIf_ReadCCConfig shall report development error code
FRIF_E_INV_CTRL_IDX to the Det_ReportError service of the DET module. ⌋ ()

8.4.16 FrIf_EnableBusMirroring

[SWS_FrIf_05726]⌈
Service
FrIf_EnableBusMirroring
Name

Std_ReturnType FrIf_EnableBusMirroring (
uint8 FrIf_ClstIdx,
Syntax boolean FrIf_MirroringActive
)

Service ID
0x4b
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_ClstIdx Index of the FlexRay cluster to address.

Parameters TRUE: Mirror_ReportFlexRayFrame will be called for each frame


FrIf_
(in) received or transmitted on the addressed FlexRay CC. FALSE:
Mirroring
Mirror_ReportFlexRayFrame will not be called for the addressed Flex
Active
Ray CC.

Parameters
None
(inout)

Parameters None

106 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

(out)

E_OK: Mirroring mode was changed.


Std_-
Return value E_NOT_OK: Wrong FrIf_CtrlIdx, or mirroring is globally disabled (see
ReturnType
FrIfBusMirroringSupport).

Enables or disables mirroring for all FlexRay controllers connected to the addressed
Description
FlexRay cluster.

Available via FrIf.h

⌋()

[SWS_FrIF_05727] ⌈The function FrIf_EnableBusMirroring shall be pre compile time


configurable ON/OFF by the configuration parameter FrIfBusMirroringSupport (see
ECUC_FrIf_06124).⌋ ()

107 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.5 Interrupt Service Routines

8.5.1 FrIf_JobListExec_<FrIfCluster.ShortName>

[SWS_FrIf_05040]⌈
Service Name FrIf_JobListExec_<FrIfCluster.ShortName>

void FrIf_JobListExec_<FrIfCluster.ShortName> (
Syntax void
)

Service ID [hex] 0x32

Sync/Async Synchronous

Reentrancy Non Reentrant

Parameters (in) None

Parameters (inout) None

Parameters (out) None

Return value None

Description Processes the FlexRay Job List of the FlexRay Cluster with index ClstIdx.

Available via FrIf.h

⌋()

Note:
For a detailed description of this API service, please refer to chapter 7.6.4.2.

[SWS_FrIf_05270] ⌈The function FrIf_JobListExec_<FrIfCluster.ShortName> shall


exist once per FlexRay Cluster of a FlexRay Interface module. ⌋ ()

[SWS_FrIf_05271] ⌈The function name of each instance of


FrIf_JobListExec_<FrIfCluster.ShortName> shall contain the short name of the
respective FlexRay Cluster (FrIfCluster).

For each FlexRay Cluster (identified by index ClstIdx), the respective API service
FrIf_JobListExec_<FrIfCluster.ShortName> must be registered in the AUTOSAR OS
as the ISR of an absolute timer of a FlexRay CC connected to the FlexRay Cluster
with index ClstIdx, if the CC does not guarantee asynchronous buffer access. ⌋ ()

Note: If the CC guarantees asynchronous buffer access, the execution of


FrIf_JobListExec<FrIfCluster.ShortName> can run in a regular OS task.
108 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05272] ⌈Caveats of FrIf_JobListExec_<FrIfCluster.ShortName>: The


FlexRay Interface module has to be initialized with a call of FrIf_Init() before this API
service may be called, see SWS_FrIf_05003. ⌋ ()

8.6 Call-back Notifications

This is a list of functions provided for other modules.

8.6.1 FrIf_CheckWakeupByTransceiver

[SWS_FrIf_05041]⌈
Service Name FrIf_CheckWakeupByTransceiver

void FrIf_CheckWakeupByTransceiver (
uint8 FrIf_CtrlIdx,
Syntax Fr_ChannelType FrIf_ChnlIdx
)

Service ID
0x39
[hex]

Sync/Async Synchronous

Reentrancy Reentrant

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in) FrIf_Chnl Index of the FlexRay Channel to address in scope of the FlexRay
Idx controller FrIf_CtrlIdx.

Parameters
None
(inout)

Parameters
None
(out)

Return value None

Wraps the FlexRay Transceiver Driver API function FrTrcv_CheckWakeupBy


Description
Transceiver(). The enum value "FR_CHANNEL_AB" shall not be used.

Available via FrIf.h

⌋()

[SWS_FrIf_05274] ⌈If parameter FrIf_CtrlIdx of FrIf_CheckWakeupByTransceiver


has an invalid value and if development error detection is enabled (i.e.
109 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIfDevErrorDetect equals ON), the function FrIf_CheckWakeupByTransceiver shall


report development error code FRIF_E_INV_CTRL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05275] ⌈If parameter FrIf_ChnlIdx of FrIf_CheckWakeupByTransceiver


has an invalid value and if development error detection is enabled (i.e.
FrIfDevErrorDetect equals ON), the function FrIf_CheckWakeupByTransceiver shall
report development error code FRIF_E_INV_CHNL_IDX to the Det_ReportError
service of the DET module. ⌋ ()

[SWS_FrIf_05276] ⌈The function FrIf_CheckWakeupByTransceiver shall wrap the


FlexRay Transceiver Driver API function FrTrcv_CheckWakeupByTransceiver() by:
-1) Translating (based on static FrIf module configuration) the
tuple (FlexRay CC index FrIf_CtrlIdx | FlexRay Channel index
FrIf_ChnlIdx) into a tuple (FlexRay Transceiver Driver | Driver-
specific Transceiver index FrTrcv_TrcvIdx).
-2) Calling FrTrcv_CheckWakeupByTransceiver() of the
determined FlexRay Driver module with the parameters
determined as described above. ⌋ ()

[SWS_FrIf_05277] ⌈Caveats of FrIf_CheckWakeupByTransceiver: The FlexRay


Interface module has to be initialized with a call of FrIf_Init() before this API service
may be called, see SWS_FrIf_05003. ⌋ ()

8.7 Scheduled Functions

8.7.1 FrIf_MainFunction_<FrIfCluster.ShortName>

[SWS_FrIf_05042]⌈
Service Name FrIf_MainFunction_<FrIfCluster.ShortName>

void FrIf_MainFunction_<FrIfCluster.ShortName> (
Syntax void
)

Service ID
0x27
[hex]

This function will be called cyclically by a task body provided by the BSW
Description
Scheduler.

Available via SchM_FrIf.h

⌋()

110 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Note:
This cyclically executed API service of the FlexRay Interface serves the following
purposes:
 Program the absolute timer interrupt in order to start the execution of
FrIf_JobListExec_<FrIfCluster.ShortName>() if the CC does not support asynchronous
buffer access.
 Monitoring the proper (in time) execution of the
FrIf_JobListExec_<FrIfCluster.ShortName>() and resynchronize the Joblist if
necessary.

Please refere to chapter 7.3 for a detailed description.

Pre condition: The function FrIf_MainFunction_<FrIfCluster.ShortName> is cyclically


called from a task body provided by the BSW Scheduler module.

Since the duration of a FlexRay Cycle may be different for two Clusters of an ECU,
the calling period (parameter FrIfMainFunctionPeriod) of this API service shall be
configurable independently for each Cluster at system configuration time.

The parameter FrIfMainFunctionPeriod determines for each FlexRay cluster of a


FlexRay Interface module the calling period, which is provided for the BSW scheduler
module.

[SWS_FrIf_05278] ⌈The function FrIf_MainFunction_<FrIfCluster.ShortName> shall


exist once per FlexRay Cluster of a FlexRay Interface module. ⌋ ()

[SWS_FrIf_05279] ⌈The function name of each instance of


FrIf_MainFunction_<FrIfCluster.ShortName> shall contain the short name of the
respective FlexRay Cluster (FrIfCluster). ⌋ ()

8.8 Expected Interfaces


This chapter lists all API services required from other BSW modules.

8.8.1 Mandatory Interfaces

This chapter defines all API services which are required from other BSW modules to
fulfill the core functionality of the FlexRay Interface.

[SWS_FrIf_05043]⌈
Header
API Function Description
File

Service to report runtime errors. If a callout has been


Det_ReportRuntimeError Det.h
configured then this callout shall be called.

Fr_AbortCommunication Fr.h Invokes the CC CHI command 'FREEZE'.

111 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Fr_AckAbsoluteTimerIRQ Fr.h Resets the interrupt condition of an absolute timer.

Fr_AllowColdstart Fr.h Invokes the CC CHI command 'ALLOW_COLDSTART'.

Fr_CancelAbsoluteTimer Fr.h Stops an absolute timer.

Fr_CheckTxLPduStatus Fr.h Checks the transmit status of the LSdu.

Fr_ControllerInit Fr.h Initialzes a FlexRay CC.

Fr_DisableAbsoluteTimerI-
Fr.h Disables the interrupt line of an absolute timer.
RQ

Fr_EnableAbsoluteTimerI-
Fr.h Enables the interrupt line of an absolute timer.
RQ

Fr_GetAbsoluteTimerIRQ-
Fr.h Gets IRQ status of an absolute timer.
Status

Gets the current global FlexRay time.


Fr_GetGlobalTime Fr.h Important Note: Fr_GetGlobalTime may be called within an
exclusive area.

Fr_GetPOCStatus Fr.h Gets the POC status.

Fr_HaltCommunication Fr.h Invokes the CC CHI command 'DEFERRED_HALT'.

Fr_ReceiveRxLPdu Fr.h Receives data from the FlexRay network.

Fr_SendWUP Fr.h Invokes the CC CHI command 'WAKEUP'.

Fr_SetAbsoluteTimer Fr.h Sets the absolute FlexRay timer.

Fr_SetWakeupChannel Fr.h Sets a wakeup channel.

Fr_StartCommunication Fr.h Starts communication.

Fr_TransmitTxLPdu Fr.h Transmits data on the FlexRay network.

FrTrcv_CheckWakeupBy-
FrTrcv.h --
Transceiver

FrTrcv_ClearTransceiver-
FrTrcv.h This function clears a pending wake up event.
Wakeup

FrTrcv_GetTransceiver-
FrTrcv.h This function returns the actual state of the transceiver.
Mode

FrTrcv_GetTransceiverW-
FrTrcv.h This function returns the wakeup reason.
UReason

FrTrcv_SetTransceiver-
FrTrcv.h This service sets the transceiver mode.
Mode

⌋()

112 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.8.2 Optional Interfaces

This chapter defines all API services which are required from other BSW modules to
fulfill an optional functionality of the FlexRay Interface

[SWS_FrIf_05044]⌈
Header
API Function Description
File

Called by SW-Cs or BSW modules to report monitor status information


to the Dem. BSW modules calling Dem_SetEventStatus can safely
Dem_SetEvent-
Dem.h ignore the return value. This API will be available only if ({Dem/Dem
Status
ConfigSet/DemEventParameter/DemEventReportingType} ==
STANDARD_REPORTING)

Det_Report-
Det.h Service to report development errors.
Error

Fr_AllSlots Fr.h Invokes the CC CHI command 'ALL_SLOTS'.

Fr_CancelTxL- Cancels the already pending transmission of a LPdu contained in a


Fr.h
Pdu controllers physical transmit resource (e.g. message buffer).

Fr_DisableLPdu Fr.h Disables the hardware resource of a LPdu for transmission/reception.

Fr_GetChannel-
Fr.h Gets the channel status information.
Status

Fr_GetClock- Gets the current clock correction values. See variables vInterimRate
Fr.h
Correction Correction and vInterimOffsetCorrection of [12] for details.

Fr_GetNm-
Fr.h Gets the network management vector of the last communication cycle.
Vector

Fr_GetNumOf- Gets the current number of startup frames seen on the cluster. See
Fr.h
StartupFrames variable vStartupPairs of [12] for details.

Gets a list of syncframes received or transmitted on channel A and


Fr_GetSync-
Fr.h channel B via the even and odd communication cycle. See variables vs
FrameList
SyncIdListA and vsSyncIdListB of [12] for details.

Fr_GetWakeup-
Fr.h Gets the wakeup received information from the FlexRay controller.
RxStatus

Fr_PrepareL-
Fr.h Prepares a LPdu.
Pdu

Fr_ReadCC- Reads a FlexRay protocol configuration parameter for a particular Flex


Fr.h
Config Ray controller out of the module's configuration.

Reconfigures a given LPdu according to the parameters (FrameId,


Fr_ReconfigL-
Fr.h Channel, CycleRepetition, CycleOffset, PayloadLength, HeaderCRC) at
Pdu
runtime.

FrArTp_Rx- FrNm_ Indication of a received PDU from a lower layer communication


Indication FrIf.h interface module.

113 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Within this API, the upper layer module (called module) shall check
whether the available data fits into the buffer size reported by PduInfo
FrArTp_Trigger- FrNm_ Ptr->SduLength. If it fits, it shall copy its data into the buffer provided by
Transmit FrIf.h PduInfoPtr->SduDataPtr and update the length of the actual copied
data in PduInfoPtr->SduLength. If not, it returns E_NOT_OK without
changing PduInfoPtr.

FrArTp_Tx- The lower layer communication interface module confirms the


FrTp.h
Confirmation transmission of a PDU, or the failure to transmit a PDU.

FrNm_Rx- FrNm_ Indication of a received PDU from a lower layer communication


Indication FrIf.h interface module.

Within this API, the upper layer module (called module) shall check
whether the available data fits into the buffer size reported by PduInfo
FrNm_Trigger- FrNm_ Ptr->SduLength. If it fits, it shall copy its data into the buffer provided by
Transmit FrIf.h PduInfoPtr->SduDataPtr and update the length of the actual copied
data in PduInfoPtr->SduLength. If not, it returns E_NOT_OK without
changing PduInfoPtr.

FrNm_Tx- The lower layer communication interface module confirms the


FrTp.h
Confirmation transmission of a PDU, or the failure to transmit a PDU.

FrTp_Rx- FrNm_ Indication of a received PDU from a lower layer communication


Indication FrIf.h interface module.

Within this API, the upper layer module (called module) shall check
whether the available data fits into the buffer size reported by PduInfo
FrTp_Trigger- FrNm_ Ptr->SduLength. If it fits, it shall copy its data into the buffer provided by
Transmit FrIf.h PduInfoPtr->SduDataPtr and update the length of the actual copied
data in PduInfoPtr->SduLength. If not, it returns E_NOT_OK without
changing PduInfoPtr.

FrTp_Tx- The lower layer communication interface module confirms the


FrTp.h
Confirmation transmission of a PDU, or the failure to transmit a PDU.

FrTrcv_Disable-
This function disables the specified branch on the addressed (active
Transceiver- FrTrcv.h
star) transceiver.
Branch

FrTrcv_Enable-
This function enables the specified branch on the addressed (active
Transceiver- FrTrcv.h
star) transceiver.
Branch

All mandatory errors defined by the FlexRay EPL [5] which are
FrTrcv_Get-
supported by the FlexRay transceiver hardware can be accessed via
Transceiver- FrTrcv.h
this API:In addition to errors on the physical layer and local to the ECU
Error
hardware, a global error flag is provided.

Mirror_Report-
Mirror.h Reports a received or transmitted FlexRay frame or a Tx conflict.
FlexRayFrame

PduR_FrIfRx- PduR_ Indication of a received PDU from a lower layer communication


Indication FrIf.h interface module.

Within this API, the upper layer module (called module) shall check
whether the available data fits into the buffer size reported by PduInfo
PduR_FrIf- PduR_
Ptr->SduLength. If it fits, it shall copy its data into the buffer provided by
TriggerTransmit FrIf.h
PduInfoPtr->SduDataPtr and update the length of the actual copied
data in PduInfoPtr->SduLength. If not, it returns E_NOT_OK without

114 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

changing PduInfoPtr.

PduR_FrIfTx- PduR_ The lower layer communication interface module confirms the
Confirmation FrIf.h transmission of a PDU, or the failure to transmit a PDU.

Xcp_FrIfRx- Indication of a received PDU from a lower layer communication


Xcp.h
Indication interface module.

Within this API, the upper layer module (called module) shall check
whether the available data fits into the buffer size reported by PduInfo
Xcp_FrIf- Ptr->SduLength. If it fits, it shall copy its data into the buffer provided by
Xcp.h
TriggerTransmit PduInfoPtr->SduDataPtr and update the length of the actual copied
data in PduInfoPtr->SduLength. If not, it returns E_NOT_OK without
changing PduInfoPtr.

Xcp_FrIfTx- The lower layer communication interface module confirms the


Xcp.h
Confirmation transmission of a PDU, or the failure to transmit a PDU.

⌋()

115 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.8.3 Configurable Interfaces

This chapter lists all interfaces where the target API service of any upper layer, which
require one or more of these mentioned interfaces to be called has to be set up by
static configuration of the FlexRay Interface. The target function is usually a call-back
function. The names of these kinds of interfaces are not fixed because they are
configurable.

These call-back services are specified and implemented in the upper layer BSW
modules, which use the FlexRay Interface according to [2]. The specific call-back
notification is specified in the corresponding AUTOSAR SWS document (see chapter
3).

In addition to upper layer AUTOSAR BSW modules, the FrIf can, with the
functionality described within this specification, also support other non-AUTOSAR
upper layer software modules (CDs), provided that these modules interact with the
FrIf in the same manner as the upper layer AUTOSAR BSW modules. In particular,
those non-AUTOSAR modules need to provide APIs as described in this chapter.

[SWS_FrIf_05729] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to FR_AR_TP, <UL_RxIndication> must be
FrArTp_RxIndication.⌋ ()

[SWS_FrIf_05730] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to FR_NM, <UL_RxIndication> must be
FrNm_RxIndication.⌋ ()

[SWS_FrIf_05731] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to FR_TP, <UL_RxIndication> must be
FrTp_RxIndication.⌋ ()

[SWS_FrIf_05732] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to PDUR, <UL_RxIndication> must be
PduR_FrIfRxIndication.⌋ ()

[SWS_FrIf_05733] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to XCP , <UL_RxIndication> must be
Xcp_FrIfRxIndication.⌋ ()

[SWS_FrIf_05434] ⌈Configuration of <UL_RxIndication>: If the parameter


FrIfUserRxIndicationUL is set to FR_TSYN, <UL_RxIndication> must be
FrTSyn_RxIndication. ⌋ ()

116 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

[SWS_FrIf_05734] ⌈Configuration of <UL_TxConfirmation>: If the parameter


FrIfUserTxUL is set to FR_AR_TP, <UL_TxConfirmation> must be
FrArTp_TxConfirmation.⌋ ()

[SWS_FrIf_05735] ⌈Configuration of <UL_TxConfirmation>: If the parameter


FrIfUserTxUL is set to FR_NM, <UL_TxConfirmation> must be
FrNm_TxConfirmation.⌋ ()

[SWS_FrIf_05736] ⌈Configuration of <UL_TxConfirmation>: If the parameter


FrIfUserTxUL is set to FR_TP, <UL_TxConfirmation> must be
FrTp_TxConfirmation.⌋ ()

[SWS_FrIf_05737] ⌈Configuration of <UL_TxConfirmation>: If the parameter


FrIfUserTxUL is set to PDUR, <UL_TxConfirmation> must be
PduR_FrIfTxConfirmation.⌋ ()

[SWS_FrIf_05738] ⌈Configuration of <UL_TxConfirmation>: If the parameter


FrIfUserTxUL is set to XCP , <UL_TxConfirmation> must be
Xcp_FrIfTxConfirmation.⌋ ()

[SWS_FrIf_05739] ⌈Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to FR_AR_TP, <UL_TriggerTransmit> must be
FrArTp_TriggerTransmit. ⌋ ()

[SWS_FrIf_05740] ⌈ Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to FR_NM, <UL_TriggerTransmit> must be
FrNm_TriggerTransmit. ⌋ ()

[SWS_FrIf_05741] ⌈ Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to FR_TP, <UL_TriggerTransmit> must be
FrTp_TriggerTransmit. ⌋ ()

[SWS_FrIf_05742] ⌈ Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to PDUR, <UL_TriggerTransmit> must be
PduR_TriggerTransmit. ⌋ ()

[SWS_FrIf_05743] ⌈ Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to XCP, <UL_TriggerTransmit> must be Xcp_TriggerTransmit. ⌋
()

[SWS_FrIf_05759] ⌈ Configuration of <UL_TriggerTransmit>: If the parameter


FrIfUserTxUL is set to FR_TSYN, <UL_TriggerTransmit> must be
FrTSyn_TriggerTransmit. ⌋ ()
117 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

8.8.3.1 <UL_RxIndication>

[SWS_FrIf_05045]⌈
Service Name <User_RxIndication>

void <User_RxIndication> (
PduIdType RxPduId,
Syntax const PduInfoType* PduInfoPtr
)

Sync/Async Synchronous

Reentrancy Reentrant for different PduIds. Non reentrant for the same PduId.

RxPdu
ID of the received PDU.
Id
Parameters
(in) Contains the length (SduLength) of the received PDU, a pointer to a
Pdu
buffer (SduDataPtr) containing the PDU, and the MetaData related to this
InfoPtr
PDU.

Parameters
None
(inout)

Parameters
None
(out)

Return value None

Description Indication of a received PDU from a lower layer communication interface module.

Available via configurable

⌋()

Note:
During the execution of this API service, the upper layer BSW module that is the final
recipient of this PDU is expected to retrieve (i.e. copy) the SDU (i.e. the payload of
the PDU) by means of the pointer PduInfoPtr which contains the received data
address and received data length.

Caveats of <UL_RxIndication>: This API service is called during the execution of the
FlexRay Job List Execution Function.

8.8.3.2 <UL_TxConfirmation>

[SWS_FrIf_05046]⌈
Service Name <User_TxConfirmation>

void <User_TxConfirmation> (
PduIdType TxPduId,
Syntax
Std_ReturnType result
)

118 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Sync/Async Synchronous

Reentrancy Reentrant for different PduIds. Non reentrant for the same PduId.

TxPduId ID of the PDU that has been transmitted.


Parameters (in)
E_OK: The PDU was transmitted. E_NOT_OK: Transmission of the
result
PDU failed.

Parameters
None
(inout)

Parameters
None
(out)

Return value None

The lower layer communication interface module confirms the transmission of a


Description
PDU, or the failure to transmit a PDU.

Available via configurable

⌋()
Caveats of <UL_TxConfirmation>: This API service is called during the execution of
the FlexRay Job List Execution Function.

8.8.3.3 <UL_TriggerTransmit>

[SWS_FrIf_05047]⌈
Service
<User_TriggerTransmit>
Name

Std_ReturnType <User_TriggerTransmit> (
PduIdType TxPduId,
Syntax PduInfoType* PduInfoPtr
)

Sync/Async Synchronous

Reentrancy Reentrant for different PduIds. Non reentrant for the same PduId.

Parameters
TxPduId ID of the SDU that is requested to be transmitted.
(in)

Contains a pointer to a buffer (SduDataPtr) to where the SDU data shall


Parameters
PduInfoPtr be copied, and the available buffer size in SduLengh. On return, the
(inout)
service will indicate the length of the copied SDU data in SduLength.

Parameters
None
(out)

E_OK: SDU has been copied and SduLength indicates the number of
Std_-
copied bytes.
Return value Return-
E_NOT_OK: No SDU data has been copied. PduInfoPtr must not be
Type
used since it may contain a NULL pointer or point to invalid data.

Description Within this API, the upper layer module (called module) shall check whether the

119 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

available data fits into the buffer size reported by PduInfoPtr->SduLength. If it fits, it
shall copy its data into the buffer provided by PduInfoPtr->SduDataPtr and update
the length of the actual copied data in PduInfoPtr->SduLength. If not, it returns E_
NOT_OK without changing PduInfoPtr.

Available via configurable

⌋()
Caveats of <UL_TriggerTransmit>: This API service is called during the execution of
the FlexRay Job List Execution Function.

8.8.3.4 <Free_Op_A>

[SWS_FrIf_05316]⌈
Service Name <Free_Op_A>

void <Free_Op_A> (
uint8 FrIf_CtrlIdx,
Syntax
uint16 FrIf_LPduIdx
)

Sync/Async Synchronous

Reentrancy Reentrant for different FrIf_LPduIdx, non reentrant for same FrIf_LPduIdx

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in)
FrIf_LPduIdx This index is used to uniquely identify a FlexRay frame.

Parameters
None
(inout)

Parameters
None
(out)

Return value None

User defined communication operation in order to support hardware specific or


Description
additional communication controller features to increase performance.

Available via FrIf_Externals.h

⌋()
Caveats of <Free_Op_A>: This API service is called during the execution of the
FlexRay Job List Execution Function.

120 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

8.8.3.5 <Free_Op_B>

[SWS_FrIf_05317]⌈
Service Name <Free_Op_B>

void <Free_Op_B> (
uint8 FrIf_CtrlIdx,
Syntax uint16 FrIf_LPduIdx
)

Sync/Async Synchronous

Reentrancy Reentrant for different FrIf_LPduIdx, non reentrant for same FrIf_LPduIdx

FrIf_CtrlIdx Index of the FlexRay CC to address.


Parameters
(in)
FrIf_LPduIdx This index is used to uniquely identify a FlexRay frame.

Parameters
None
(inout)

Parameters
None
(out)

Return value None

User defined communication operation in order to support hardware specific or


Description
additional communication controller features to increase performance.

Available via FrIf_Externals.h

⌋()
Caveats of <Free_Op_B>: This API service is called during the execution of the
FlexRay Job List Execution Function.

8.8.3.6 <UL_TxConflictNotification>

[SWS_FrIf_91001]⌈
Service Name <UL_TxConflictNotification>

void <UL_TxConflictNotification> (
uint8 FrIf_CtrlIdx,
Syntax
uint16 FrIf_LPduIdx
)

Sync/Async Synchronous

Reentrancy Reentrant for different FrIf_LPduIdx. Non reentrant for the same FrIf_LPduIdx.

FrIf_CtrlIdx ID of the addressed FlexRay CC


Parameters (in)
FrIf_LPduIdx ID of the transmitted FlexRay frame

Parameters (inout) None

Parameters (out) None

Return value None


121 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Description Notification in case a TxConflict has been detected.

Available via FrIf_Externals.h

⌋()

122 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9 Sequence Diagrams
The sequence diagrams in this chapter show the basic operations carried out in a
FlexRay Cluster's FlexRay Job List Execution Function when executing the various
Communication Operations. They also show the interaction of the FrIf with the upper
layer BSW module and with the underlying FlexRay Driver.

Please note that the sequence diagrams are an extension for illustrational purposes
to ease understanding of the specification.

9.1 Data Transmission

9.1.1 TransmitWithImmediateBufferAccess

UpperLayerforFrIf FrIf: FrIf Fr: Fr

FrIf_Transmit(Std_ReturnType, PduIdType,
const PduInfoType *)

Use TxPduId to find out appropriate


FlexRay Driver, Fr_CtrlIdx and Fr_LPDU()

Use PduInfoPtr to find out Fr_SduPtr and


Fr_LSduLength()

Fr_TransmitTxLPdu(Std_ReturnType, uint8, uint16,


const uint8*, uint8, Fr_SlotAssignmentType**)

Fr_TransmitTxLSdu()

opt Fr_TransmitTxLSdu() returned E_OK

[Pdu's TxConfCounter < PDU's


CounterLimit]:Increment PDU's
TxConfCounter()

FrIf_Transmit()

Figure 9-1: TransmitWithImmediateBufferAccess

123 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.1.2 TransmitWithDecoupledBufferAccess

Upper Layer for Interrupt Service FrIf: FrIf Fr: Fr


FrIf Routine

FrIf_Transmit(Std_ReturnType, PduIdType, const PduInfoType *)

[PDU's TrigTxCounter < PDU's


CounterLimit] : Increment PDU's
FrIf_Transmit() TrigTxCounter()

FrIf_JobListExec_<FrIfCluster.ShortName> First Joblist Handling


()

Set Fr_SduPtr to a temporary L-SDU buffer in the FrIf()

loop
Determine PDU's Byte Offset in Fram and PDU-owning
Upper Layer, Set FrIf_SduPtr = Fr_LSduPtr + ByteOffset()

alt PDU's TrigTxCounter > 0 || (FrIfNodeMode == true)

[YES]
<UL_TriggerTransmit>(TxPduId, FrIf_SduPtr)

<UL_TriggerTransmit>()

[PDU's TxConfCounter < PDU's


CounterLimit] : Increment PDU's
TXConfCounter()

Decrement PDU's TrigTxCounter()

[Update-Bit configured for this


PDU] : Mark PDU's Update-Bit as
"up-to-date"()
[NO]

[Update-Bit configured for this PDU] : Mark


PDU's Update-Bit as "outdated"()

alt opt(AlwaysTransmit == TRUE) || (At least one PDU is up-to-date)

Fr_TransmitTxLPdu(Std_ReturnType, uint8, uint16, const


uint8*, uint8, Fr_SlotAssignmentType**)
"PDU is up-to-date"
meand "PDU's Update
Bit is marked as up to Fr_TransmitTxLSdu()
date"

[Fr_TransmitTxSdu() returned E_NOT_OK] :


Roll back the changed values for
TxConfCounter for each PDU that is uo-to-date
in this Frame and the TriggerTxCounter for
each PDU that is up-to-date in this Frame

FrIf_JobListExec_<FrIfCluster.ShortName>()

Figure 9-2: TransmitWithDecoupledBufferAccess

124 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.1.3 ProvideTxConfirmation

Upper Layer for FrIf Interrupt Service Routine «module» «module»


FrIf Fr

FrIf_JobListExec_<FrIfCluster.ShortName>
() FrIf Joblist Handling

Determine DriverIdx, Fr_LPduIdx, and Fr_CtrlIdx for


checking the TxLSdu Status()

Set Fr_TxLSduStatusPtr to &FrIf_TxLSduStatus()

Fr_CheckTxLPduStatus(return, Fr_CtrlIdx, Fr_LPduIdx,


Fr_TxLPduStatusPtr, Fr_SlotAssignmentPtr)

Use Fr_LPduIdx to find out actual transmit buffer of


CC Fr_CtrlIdx()

Check Tx Status of Buffer()

Fr_CheckTxLSduStatus()

opt Fr_TxLSduStatus == FR_TRANSMITTED

loop For each PDU in this Frame

opt PDU's TxConfCounter > 0 && TxConfirmation is configured for this PDU
Determine FrTxPduId and
PDU-owning Upper Layer()

<UL_TxConfirmation>(PduIdType, Std_ReturnType)

<UL_TxConfirmation>()
Decrement PDU's
TxConfCounter()

FrIf_JobListExecution_<ClstIdx>()

Figure 9-3: ProvideTxConfirmation

125 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.2 Data Reception

9.2.1 ReceiveAndIndicate

Upper Layer for FrIf Interrupt Service Routine «module» «module»


FrIf Fr

FrIf_JobListExec_<FrIfCluster.ShortName>()
FrIf Jobllist Handling

Determine DriverIdx, Fr_LPduIdx, and


Fr_CtrlIdx for receiving()

Set FrSduPtr to a temporary L-SDU


buffer in the FrIf()

Set Fr_LSduStatusPtr to &FrIf_LSduStatus;


Set Fr_LSduLengthPtr to &FrIf_LSduLength()

Fr_ReceiveRxLPdu(Std_ReturnType, uint8, uint16,


uint8**, Fr_RxLPduStatusType**, uint8**,
Fr_SlotAssignmentType**)
Use Fr_LPduIdx to find out actual receive
buffer of CC Fr_CtrlIdx()

Use Fr_LSduPtr and Fr_LSduLength to copy L-


SDU from CC receive buffer()

Write the L-SDU's receive status to *Fr_RxLSduStatusPtr; Write the


length of the recieved L-SDU to *Fr_LSduLengthPtr()

Fr_ReceiveRxLSdu()

opt Fr_LSduStatus == FR_RECEIVED

loop For each PDU in this Frame


Determine FrRxPduId and Byte
Offset of PDU in Frame()

alt PDU's FRIF_PDU_UPDATE_BIT_OFFSET == .1

[FALSE]

opt PDU is marked as "up-to-date"

<UL_RxIndication>(PduIdType, const uint8*)

Copy PDU to
internal location()

<UL_RxIndication>()

[TRUE]

Act as if Update Bit was configured and PDU was marked as


up-to-date

FrIf_JobListExec_<FrIfCluster.ShortName>()

Figure 9-4: ReceiveAndIndicate

126 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.2.2 ReceiveAndStore

Interrupt Service Routine «module» «module»


FrIf Fr

FrIf_JobListExec_<FrIfCluster.ShortName> FrIf Joblist Handling


()

Determine DriverIdx, Fr_LPduIdx, and


Fr_CtrlIdx for receiving()

Set FrSduPtr to a temporary L-SDU buffer in


the FrIf()

Set Fr_LSduStatusPtr to &FrIf_LSduStatus;


Set Fr_LSduLengthPtr to &FrIf_LSduLength()

Std_ReturnType:=Fr_ReceiveRxLSdu(Fr_LPduIdx, Fr_CtrlIdx,
Fr_LSduPtr, Fr_LSduLengthPtr)

Use Fr_LPduIdx to find out actual receive buffer of


CC Fr_CtrlIdx()

Use Fr_LSduPtr and Fr_LSduLength to copy L-


SDU from CC receive buffer()

Write the L-SDU's receive status to "Fr_RxLSduStatusPtr; Write


the length of the received L-SDU to "Fr_LSduLengthPtr()

Fr_ReceiveRxLSdu()

opt Fr_LSduStatus == FR_RECEIVED

loop For each PDU in this Frame

Determine Fr_RxPduId and


ByteOffset of PDU in Frame()

alt PDU's FRIF_PDU_UPDATE_BIT_OFFSET == .1

[FALSE]

opt PDU is marked as "up-to-date"

Copy payload from (Fr_LSduTempBuffer +


ByteOffset) to PDU's dedicated local buffer in
the FrIf

Memorize that PDU's FrIf buffer


has been updated()

[TRUE]

Act as if Update Info was contained


and PDU was up-to-date.

FrIf_JobListExec_<FrIfCluster.ShortName>
()

Figure 9-5: ReceiveAndStore

127 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.2.3 ProvideRxIndication

Upper Layer for FrIf Interrupt Service Routine «module»


FrIf

FrIf_JobListExec_<FrIfCluster.ShortName>
()
FrIf Joblist Handling

loop For each PDU in this Frame


Determine Fr_RxPduId and
PDU-owning Upper Layer()

opt PDU is marked as "up-to-date"

Set FrIf_SduPtr to PDU's


local buffer in the FrIf()
<UL_RxIndication>(PduIdType, const uint8*)

Copy PDU to internal location


and process PDU()

<UL_RxIndication>()

Reset Information that PDU's


FrIf buffer has been updated()

FrIf_JobListExec_<FrIfCluster.ShortName>
()

Figure 9-6: ProvideRxIndication

128 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.2.4 Cancel Transmission

Figure 9-7: Cancel Transmission

129 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

9.3 Prepare LPDU

Upper Layer for FrIf «module» «module»


FrIf Fr

FrIf_JobListExec_<FrIfCluster.ShortName>
()
Fr_PrepareLPdu(Fr_CtrlIdx, Fr_LPduIdx)

Figure out the physical resource (e.g. a buffer),


mapped to the processing of the FlexRay frame
identified by Fr_LPduIdx

[Buffer reconfiguration necessary]: Configure the physical


resource (a buffer) appropriate for Fr_LPduIdx operation
(SlotId, Cycle filter, payload length, header CRC, etc) if the
MCG uses the reconfiguration feature

Fr_PrepareLPdu()

FrIf_JobListExec_<FrIfCluster.ShortName>
()

Figure 9-8: Prepare LPdu

130 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

10 Configuration Specification
This chapter defines configuration parameters and their clustering into containers.
Chapter 10.1 gives information to help understanding the subsequent chapters.
Chapter 10.2 specifies the structure (containers) and the parameters of the FlexRay
Interface.
Chapter 9.3 specifies published information of the FlexRay Interface.

10.1 How to Read this Chapter

For details refer to the chapter 10.1 “Introduction to configuration specification” in


SWS_BSWGeneral.

10.2 Containers and Configuration Parameters

The following chapters summarize all configuration parameters. The detailed


meanings of the parameters are described in chapter 7 and chapter 8

The listed configuration items can be derived from a network description database,
which is based on the EcuConfigurationTemplate. The configuration tool has to
extract all information to configure the FrIf module.

Note:
The configuration tool must check the consistency of the configuration at
configuration time.

Note:
These dependencies between FlexRay Interface and FlexRay Driver configuration
must be provided at configuration time by the configuration tools.

131 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

10.2.1 FrIf

SWS Item ECUC_FrIf_06087 :


Module Name FrIf
Module Description Configuration of the FrIf (FlexRay Interface) module.
Post-Build Variant Support true
Supported Config Variants VARIANT-LINK-TIME, VARIANT-POST-BUILD, VARIANT-PRE-COMPILE

Included Containers
Container Name Multiplicity Scope / Dependency
This container contains the configuration parameters and sub
FrIfConfig 1
containers of the AUTOSAR FrIf module.
This container contains the general configuration parameters
FrIfGeneral 1
of the FlexRay Interface.

FrIf: EcucModuleDef +container FrIfGeneral:


upperMultiplicity = 1 EcucParamConfContainerDef
lowerMultiplicity = 0

FrIfConfig: EcucParamConfContainerDef FrIfMaxPduCnt:


+parameter EcucIntegerParamDef

lowerMultiplicity = 0
upperMultiplicity = 1

FrIfPdusInFrame:
FrIfFrameStructure: EcucParamConfContainerDef
EcucParamConfContainerDef +subContainer
+container +subContainer upperMultiplicity = *
upperMultiplicity = * lowerMultiplicity = 1
lowerMultiplicity = 1
FrIfRxPdu:
EcucParamConfContainerDef
FrIfPduDirection: +choice
upperMultiplicity = 1
FrIfPdu: EcucChoiceContainerDef lowerMultiplicity = 0
+subContainer EcucParamConfContainerDef
+subContainer
upperMultiplicity = *
lowerMultiplicity = 1 +choice FrIfTxPdu:
EcucParamConfContainerDef

upperMultiplicity = 1
lowerMultiplicity = 0
+subContainer

FrIfCluster: EcucParamConfContainerDef FrIfJob:


+subContainer FrIfJobList: +subContainer
EcucParamConfContainerDef
upperMultiplicity = * EcucParamConfContainerDef
lowerMultiplicity = 1 upperMultiplicity = *
lowerMultiplicity = 1

+subContainer

FrIfController: EcucParamConfContainerDef

upperMultiplicity = *
lowerMultiplicity = 1

+subContainer +subContainer +subContainer

FrIfTransceiver: FrIfFrameTriggering: FrIfLPdu: FrIfLPduIdx:


EcucParamConfContainerDef EcucParamConfContainerDef EcucParamConfContainerDef EcucIntegerParamDef
+parameter
upperMultiplicity = * upperMultiplicity = * symbolicNameValue = true
upperMultiplicity = 2 lowerMultiplicity = 1 lowerMultiplicity = 1 max = 4095
lowerMultiplicity = 1 min = 0

Figure 10-1: FlexRay Interface Module

132 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

10.2.2 FrIfGeneral

SWS Item ECUC_FrIf_05360 :


Container Name FrIfGeneral
Parent Container FrIf
This container contains the general configuration parameters of the
Description
FlexRay Interface.
Configuration Parameters

SWS Item ECUC_FrIf_06112 :


Name FrIfAbsTimerIdx
Parent Container FrIfGeneral
Description Maximum number of supported absolute timers.
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06108 :


Name FrIfAllSlotsSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable of
switching from key-slot / single-slot mode to all slot mode.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06124 :


Name FrIfBusMirroringSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable
reporting received/transmitted frames to the Bus Mirroring module.
Multiplicity 1
Type EcucBooleanParamDef
Default value false
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00002 :

133 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Name FrIfCancelTransmitSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to request the
cancellation of the I-PDU transmission to FrDrv.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06080 :


Name FrIfDevErrorDetect
Parent Container FrIfGeneral
Description Switches the development error detection and notification on or off.
 true: detection and notification is enabled.

 false: detection and notification is disabled.


Multiplicity 1
Type EcucBooleanParamDef
Default value false
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06110 :


Name FrIfDisableLPduSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to disables the
hardware resource of a LPdu for transmission/reception.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06102 :


Name FrIfDisableTransceiverBranchSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to disable branches
of an active star.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
134 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Scope / Dependency scope: local

SWS Item ECUC_FrIf_06103 :


Name FrIfEnableTransceiverBranchSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable branches
of an active star.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06118 :


Name FrIfFreeOpAApiName
Parent Container FrIfGeneral
Description API name that is called when FREE_OP_A is selected as communication
operation. See also chapter 8.8.3 Configurable Interfaces.
Multiplicity 0..1
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06119 :


Name FrIfFreeOpBApiName
Parent Container FrIfGeneral
Description API name that is called when FREE_OP_B is selected as communication
operation. See also chapter 8.8.3 Configurable Interfaces.
Multiplicity 0..1
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
135 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06120 :


Name FrIfFreeOpsHeader
Parent Container FrIfGeneral
Description Defines header file for configurable FREE_OP_A / FREE_OP_B functions.
Multiplicity 0..1
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06106 :


Name FrIfGetClockCorrectionSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable of
polling the FlexRay Driver to getting CC clock correction values.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06105 :


Name FrIfGetGetChannelStatusSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable of
polling the FlexRay Driver to getting error information about the FlexRay
communications bus.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06114 :


Name FrIfGetNmVectorSupport
136 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parent Container FrIfGeneral


Description Configuration parameter to enable/disable FrIf support to request the
FlexRay hardware NMVector.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06104 :


Name FrIfGetNumOfStartupFramesSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable of
polling the FlexRay Driver for the actual number of received startup frames
on the bus.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06107 :


Name FrIfGetSyncFrameListSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable of
polling the FlexRay Driver to getting a list of actual received sync frames.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06101 :


Name FrIfGetTransceiverErrorSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to get the FlexRay
Transceiver errors by calling the FlexRay Transceiver module.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06111 :


137 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Name FrIfGetWakeupRxStatusSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to get the wakeup
received information from the FlexRay controller.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06081 :


Name FrIfNumClstSupported
Parent Container FrIfGeneral
Description Maximum number of FlexRay Clusters that the FlexRay Interface supports.
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06082 :


Name FrIfNumCtrlSupported
Parent Container FrIfGeneral
Description Maximum number of FlexRay CCs that the FlexRay Interface supports
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06116 :


Name FrIfPublicCddHeaderFile
Parent Container FrIfGeneral
Description Defines header files for callback functions which shall be included in case
of CDDs. Range of characters is 1.. 32.
Multiplicity 0..*
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity Configuration Pre-compile time X All Variants
138 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Class Link time --


Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06117 :


Name FrIfReadCCConfigApi
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable the optional FrIf_ReadCCConfig
API.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06109 :


Name FrIfReconfigLPduSupport
Parent Container FrIfGeneral
Description Configuration parameter to enable/disable FrIf support to enable/disable
the reconfiguration of a given LPdu according to the parameters (FrameId,
Channel, CycleRepetition, CycleOffset, PayloadLength, HeaderCRC) at
runtime.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06123 :


Name FrIfTxConflictNotificationHeaderName
Parent Container FrIfGeneral
Description Configuration of the header file name that defines the
UL_TxConflictNotification.
Multiplicity 0..1
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
139 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-build time --
Scope / Dependency scope: local
dependency: FrIfTxConflictNotificationName

SWS Item ECUC_FrIf_06122 :


Name FrIfTxConflictNotificationName
Parent Container FrIfGeneral
Description Configuration of the API name that is called in case a TxConflict has been
detected.
Multiplicity 0..1
Type EcucStringParamDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local
dependency: FrIfTxConflictNotificationHeaderName

SWS Item ECUC_FrIf_00001 :


Name FrIfUnusedBitValue
Parent Container FrIfGeneral
Description Set unused bits of transmitted Pdus to a defined value.
Multiplicity 0..1
Type EcucIntegerParamDef
Range 0 .. 1
Default value --
Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity ConfigurationPre-compile time X All Variants
Class Link time --
Post-build time --
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06083 :


Name FrIfVersionInfoApi
Parent Container FrIfGeneral
Description Enables/disables the existence of the FrIf_GetVersionInfo() API service
true: FrIf_GetVersionInfo() API service exists
false: FrIf_GetVersionInfo() API service does not exist
Multiplicity 1
Type EcucBooleanParamDef
Default value false
Post-Build Variant Value false
140 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Value Configuration Class Pre-compile time X All Variants


Link time --
Post-build time --
Scope / Dependency scope: local

No Included Containers

10.2.3 FrIfCluster

SWS Item ECUC_FrIf_05366 :


Container Name FrIfCluster
Parent Container FrIfConfig
This container specifies a FrIf Cluster and all related data which is required
Description to enable communication of the Cluster. A Cluster may consist of more
than one Controller.
Post-Build Variant
false
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE, VARIANT-
Class LINK-TIME, VARIANT-POST-BUILD
Link time --
Post-build time --
Configuration Parameters

SWS Item ECUC_FrIf_06002 :


Name FrIfClstIdx
Parent Container FrIfCluster
Description This parameter provides a zero-based consecutive index of the FlexRay
Clusters. Upper layer BSW modules and the FrIf itself use this index to
identify a FlexRay Cluster.
Multiplicity 1
Type EcucIntegerParamDef (Symbolic Name generated for this parameter)
Range 0 .. 63
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00003 :


Name FrIfDetectNITError
Parent Container FrIfCluster
Description Indicates whether NIT error status of each cluster shall be detected or not.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06006 :


141 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Name FrIfGChannels
Parent Container FrIfCluster
Description The channels that are used by the cluster.
Implementation Type: Fr_ChannelType
Multiplicity 1
Type EcucEnumerationParamDef
Range FR_CHANNEL_A Cluster uses channel A
FR_CHANNEL_AB Cluster uses channel A and B

Implementation Type: Fr_ChannelType


FR_CHANNEL_B Cluster uses channel B
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

SWS Item ECUC_FrIf_06008 :


Name FrIfGColdStartAttempts
Parent Container FrIfCluster
Description Maximum number of times a node in the cluster is permitted to attempt to
start the cluster by initiating schedule synchronization
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 31
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06086 :


Name FrIfGCycleCountMax
Parent Container FrIfCluster
Description Maximum cycle counter value in a given cluster.
Remark: Set to 63 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 7 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06020 :


Name FrIfGdActionPointOffset
Parent Container FrIfCluster
Description Number of macroticks the action point is offset from the beginning of a
static slot.
Multiplicity 1
Type EcucIntegerParamDef
142 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Range 1 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_06021 :


Name FrIfGdBit
Parent Container FrIfCluster
Description Nominal bit time in seconds
Multiplicity 1
Type EcucEnumerationParamDef
Range T100NS --
T200NS --
T400NS --
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

SWS Item ECUC_FrIf_06024 :


Name FrIfGdCasRxLowMax
Parent Container FrIfCluster
Description Upper limit of the CAS acceptance windows [gdBit]
Remark: Range 67 to 99 for FlexRay Protocol 2.1 Rev. A compliance
Multiplicity 1
Type EcucIntegerParamDef
Range 28 .. 254
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06025 :


Name FrIfGdCycle
Parent Container FrIfCluster
Description Length of the cycle, expressed in [s]
Remark: Lower limit 0.000024 for FlexRay Protocol 3.0 compliance.
Multiplicity 1
Type EcucFloatParamDef
Range [2.4E-5 .. 0.016]
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06026 :


143 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Name FrIfGdDynamicSlotIdlePhase
Parent Container FrIfCluster
Description Duration of the idle phase within a dynamic slot [Minislots].
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 2
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00012 :


Name FrIfGdIgnoreAfterTx
Parent Container FrIfCluster
Description Duration for which the bitstrobing is paused after transmission [gdBit].
Remark: Set to 0 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 15
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06027 :


Name FrIfGdMacrotick
Parent Container FrIfCluster
Description Duration of the cluster wide nominal macrotick, expressed in s
Multiplicity 1
Type EcucFloatParamDef
Range [1E-6 .. 6E-6]
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06033 :


Name FrIfGdMinislot
Parent Container FrIfCluster
Description Duration of a minislot [Macroticks]
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

144 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

SWS Item ECUC_FrIf_06032 :


Name FrIfGdMiniSlotActionPointOffset
Parent Container FrIfCluster
Description Number of Macroticks the Minislot action point is offset from the beginning
of a Minislot [Macroticks].
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 31
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06034 :


Name FrIfGdNit
Parent Container FrIfCluster
Description Duration of the Network Idle Time [Macroticks]
Remark: Upper limit 805 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 15978
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06035 :


Name FrIfGdSampleClockPeriod
Parent Container FrIfCluster
Description Sample clock period
Multiplicity 1
Type EcucEnumerationParamDef
Range T12_5NS --
T25NS --
T50NS --
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

SWS Item ECUC_FrIf_06036 :


Name FrIfGdStaticSlot
Parent Container FrIfCluster
Description Duration of a static slot [Macroticks].
Remark: Range 4-661 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 3 .. 664
Default value --
145 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-Build Variant Value true


Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06037 :


Name FrIfGdSymbolWindow
Parent Container FrIfCluster
Description Duration of the symbol window [Macroticks].
Remark: Range 0-142 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 162
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00011 :


Name FrIfGdSymbolWindowActionPointOffset
Parent Container FrIfCluster
Description Number of macroticks the action point offset is from the beginning of the
symbol window [Macroticks].
Remark: Set to GdActionPointOffset for FlexRay Protocol 2.1 Rev. A
compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06038 :


Name FrIfGdTSSTransmitter
Parent Container FrIfCluster
Description Number of bits in the Transmission Start Sequence [gdBits].
Remark: Lower limit 3 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06039 :


Name FrIfGdWakeupRxIdle
Parent Container FrIfCluster
146 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Description Number of bits used by the node to test the duration of the 'idle' or HIGH
phase of a received wakeup [gdBit]. Remarks: This parameter maps to
FlexRay Protocol 2.1 Rev. A parameter gdWakeupSymbolRxIdle. Lower
limit 14 for FlexRay Protocol 2.1 Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 8 .. 59
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06040 :


Name FrIfGdWakeupRxLow
Parent Container FrIfCluster
Description Number of bits used by the node to test the duration of the LOW phase of
a received wakeup [gdBit].
Remarks: This parameter maps to FlexRay Protocol 2.1 Rev. A parameter
gdWakeupSymbolRxLow. Lower limit 11 for FlexRay Protocol 2.1 Rev. A
compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 8 .. 59
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06041 :


Name FrIfGdWakeupRxWindow
Parent Container FrIfCluster
Description The size of the window used to detect wakeups [gdBit].
Remarks: This parameter maps to FlexRay Protocol 2.1 Rev. A parameter
gdWakeupSymbolRxWindow. Upper limit 301 for FlexRay Protocol 2.1
Rev. A compliance.
Multiplicity 1
Type EcucIntegerParamDef
Range 76 .. 485
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06043 :


Name FrIfGdWakeupTxActive
Parent Container FrIfCluster
Description Number of bits used by the node to transmit the LOW phase of awakeup
symbol and the HIGH and LOW phases of a WUDOP [gdBit].
Remarks: This parameter maps to FlexRay Protocol 2.1 Rev. A parameter
gdWakeupSymbolTxLow.

147 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Multiplicity 1
Type EcucIntegerParamDef
Range 15 .. 60
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06042 :


Name FrIfGdWakeupTxIdle
Parent Container FrIfCluster
Description Number of bits used by the node to transmit the 'idle' part of a
wakeup symbol [gdBit].

Remarks: This parameter maps to FlexRay Protocol 2.1 Rev. A


parameter gdWakeupSymbolTxIdle.
Multiplicity 1
Type EcucIntegerParamDef
Range 45 .. 180
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06009 :


Name FrIfGListenNoise
Parent Container FrIfCluster
Description Upper limit for the start up listen timeout and wake up listen timeout in the
presence of noise. It is used as a multiplier of the node
parameter pdListenTimeout.
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 16
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06010 :


Name FrIfGMacroPerCycle
Parent Container FrIfCluster
Description Number of macroticks in a communication cycle.
Note: Lower limit 10 for FlexRay Protocol 2.1 Rev. A compliance
Multiplicity 1
Type EcucIntegerParamDef
Range 8 .. 16000
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
148 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-build time X VARIANT-POST-BUILD


Scope / Dependency scope: local

SWS Item ECUC_FrIf_06011 :


Name FrIfGMaxWithoutClockCorrectFatal
Parent Container FrIfCluster
Description Threshold used for testing the vClockCorrectionFailed counter. Defines the
number of consecutive even/odd Cycle pairs with missing clock correction
terms that will cause the protocol to transition from the POC:normal active
or POC:normal passive state into the POC:halt state. [Even/odd cycle
pairs].
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06012 :


Name FrIfGMaxWithoutClockCorrectPassive
Parent Container FrIfCluster
Description Threshold used for testing the vClockCorrectionFailed counter. Defines the
number of consecutive even/odd Cycle pairs with missing clock correction
terms that will cause the protocol to transition from the POC:normal active
state to the POC:normal passive state. [Even/Odd cycle pairs]
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 15
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06013 :


Name FrIfGNetworkManagementVectorLength
Parent Container FrIfCluster
Description Length of the Network Management vector in a cluster [bytes]
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 12
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06014 :


Name FrIfGNumberOfMinislots
Parent Container FrIfCluster
Description Number of minislots in the dynamic segment
149 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Remark: Upper limit 7986 for FlexRay Protocol 2.1 Rev. A compliance
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 7988
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06015 :


Name FrIfGNumberOfStaticSlots
Parent Container FrIfCluster
Description Number of static slots in the static segment
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 1023
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06018 :


Name FrIfGPayloadLengthStatic
Parent Container FrIfCluster
Description Payload length of a static frame [16 bit words]
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 127
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06019 :


Name FrIfGSyncFrameIDCountMax
Parent Container FrIfCluster
Description Maximum number of distinct syncframe identifiers present in a given
cluster. This parameter maps to FlexRay Protocol 2.1 Rev. A parameter
gSyncNodeMax.
Multiplicity 1
Type EcucIntegerParamDef
Range 2 .. 15
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06003 :


150 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Name FrIfMainFunctionPeriod
Parent Container FrIfCluster
Description The execution cycle of the FrIf_MainFunction_<FrIfCluster.ShortName>()
in seconds. The FrIf does not require this information but the BSW
scheduler, which invokes the cluster main functions, needs it in order to
plan its tasks.
Multiplicity 1
Type EcucFloatParamDef
Range ]0 .. INF[
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME, VARIANT-POST-
BUILD
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00004 :


Name FrIfSafetyMargin
Parent Container FrIfCluster
Description Additional timespan in macroticks which takes jitter into account to be able
to set the JobListPointer to the next possible job which can be executed in
case the FlexRay Job List Execution Function has be resynchronized.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 1024000
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

Included Containers
Container Name Multiplicity Scope / Dependency
Container for the references to DemEventParameter
elements which shall be invoked using the API
Dem_SetEventStatus in case the corresponding error
FrIfClusterDemEventParameterRef
0..1 occurs. The EventId is taken from the referenced
s
DemEventParameter's DemEventId symbolic value. The
standardized errors are provided in this container and
can be extended by vendor-specific error references.
This container contains the configuration of FlexRay
FrIfController 1..*
CC.
This container specifies a list of all FlexRay Jobs of the
FrIfJobList 1 Cluster to be performed by
FrIf_JobListExec_<FrIfCluster.ShortName>().

10.2.4 FrIfController

SWS Item ECUC_FrIf_05363 :


Container Name FrIfController
Parent Container FrIfCluster
151 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Description This container contains the configuration of FlexRay CC.


Post-Build Variant
false
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE, VARIANT-
Class LINK-TIME, VARIANT-POST-BUILD
Link time --
Post-build time --
Configuration Parameters

SWS Item ECUC_FrIf_06045 :


Name FrIfCtrlIdx
Parent Container FrIfController
Description This parameter provides a zero-based consecutive index of the FlexRay
Communication Controllers. Upper layer BSW modules and the FrIf itself
use this index to identify a FlexRay CC.
Multiplicity 1
Type EcucIntegerParamDef (Symbolic Name generated for this parameter)
Range 0 .. 31
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_06044 :


Name FrIfFrCtrlRef
Parent Container FrIfController
Description Reference to a Controller, which is handled by a specific Driver. This
reference is unique for the ECU.
Multiplicity 1
Type Symbolic name reference to [ FrController ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

Included Containers
Container Name Multiplicity Scope / Dependency
A Frame triggering contains the communication parameters of
FrIfFrameTriggering 1..* the FlexRay Frame as well as a reference to the Frame
Construction Plan.
FrIfLPdu 1..* Reference to a L-PDU index
Up to two FlexRay Transceivers may connect a Controller to a
FrIfTransceiver 1..2 Cluster. This container realizes a Controller-Transceiver
assignment.

152 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIfCtrlIdx:
EcucIntegerParamDef
FrIfController: +parameter
EcucParamConfContainerDef symbolicNameValue = true
min = 0
upperMultiplicity = * max = 31
lowerMultiplicity = 1
FrController:
+reference FrIfFrCtrlRef: EcucReferenceDef +destination EcucParamConfContainerDef +parameter FrCtrlIdx: EcucIntegerParamDef
upperMultiplicity = * symbolicNameValue = true
requiresSymbolicNameValue = true lowerMultiplicity = 1 min = 0
max = 255

FrIfFrTrcvChannelRef: FrTrcvChannel:
FrIfTransceiver: +reference +destination
EcucReferenceDef EcucParamConfContainerDef
EcucParamConfContainerDef
requiresSymbolicNameValue = true upperMultiplicity = *
upperMultiplicity = 2
lowerMultiplicity = 1
lowerMultiplicity = 1

+subContainer
FrIfClusterChannel: +literal FRIF_CHANNEL_A:
EcucEnumerationParamDef EcucEnumerationLiteralDef
+parameter

+literal FRIF_CHANNEL_B:
EcucEnumerationLiteralDef

Figure 10-2: FlexRay Interface Controller (hardware reference)

153 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIfController: FrIfFrameTriggering: FrIfFrameStructure:


+reference FrIfFrameStructureRef: +destination EcucParamConfContainerDef
EcucParamConfContainerDef EcucParamConfContainerDef EcucReferenceDef
upperMultiplicity = * upperMultiplicity = * upperMultiplicity = *
lowerMultiplicity = 1 lowerMultiplicity = 1 lowerMultiplicity = 1

FrIfBaseCycle:
+parameter EcucIntegerParamDef

max = 63
min = 0

FrIfCycleRepetition:
+parameter EcucIntegerParamDef

max = 64
min = 1

FrIfSlotId: EcucIntegerParamDef
+parameter
max = 2047
min = 1

FrIfLSduLength:
+parameter EcucIntegerParamDef

max = 254
+subContainer min = 0 FRIF_CHANNEL_A:
+literal EcucEnumerationLiteralDef
FrIfChannel:
EcucEnumerationParamDef
+literal FRIF_CHANNEL_B:
EcucEnumerationLiteralDef

+parameter

+literal FRIF_CHANNEL_AB:
EcucEnumerationLiteralDef

+parameter FrIfMessageId:
FrIfAlwaysTransmit:
EcucIntegerParamDef
EcucBooleanParamDef
+parameter
lowerMultiplicity = 0
+parameter upperMultiplicity = 1
FrIfAllowDynamicLSduLength:
min = 0
EcucBooleanParamDef
max = 65535

+parameter
FrIfPayloadPreamble:
EcucBooleanParamDef

FRIF_E_LPDU_SLOTSTATUS:
FrIfFrameTriggeringDemEventParameterRefs: EcucReferenceDef
+reference
+subContainer EcucParamConfContainerDef
lowerMultiplicity = 0
upperMultiplicity = 1 upperMultiplicity = 1
lowerMultiplicity = 0 requiresSymbolicNameValue = true

+destination FrIfVBTriggeringRef: +destination


EcucReferenceDef
DemEventParameter:
EcucParamConfContainerDef
+reference
upperMultiplicity = 65535
lowerMultiplicity = 1

FrIfLPdu:
EcucParamConfContainerDef
FrIfLPduIdx: EcucIntegerParamDef
upperMultiplicity = * +parameter
lowerMultiplicity = 1 symbolicNameValue = true
+subContainer max = 4095
min = 0

+parameter FrIfReconfigurable:
EcucBooleanParamDef

Figure 10-3: FlexRay Interface Controller (data reference)

10.2.5 FrIfTransceiver

SWS Item ECUC_FrIf_05391 :


Container Name FrIfTransceiver
Parent Container FrIfController
Up to two FlexRay Transceivers may connect a Controller to a Cluster.
Description
This container realizes a Controller-Transceiver assignment.
Configuration Parameters

154 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

SWS Item ECUC_FrIf_06062 :


Name FrIfClusterChannel
Parent Container FrIfTransceiver
Description This parameter identifies to which one of the two Channels (A, B, A and B) of the
Cluster the Transceiver is connected. FrIfClusterChannel shall map to
Fr_ChannelType: FRIF_CHANNEL_A == FR_CHANNEL_A FRIF_CHANNEL_B
== FR_CHANNEL_B FR_CHANNEL_AB shall not be used.
Multiplicity 1
Type EcucEnumerationParamDef
Range FRIF_CHANNEL_A Channel A
FRIF_CHANNEL_B Channel B
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

SWS Item ECUC_FrIf_06061 :


Name FrIfFrTrcvChannelRef
Parent Container FrIfTransceiver
Description Reference to a Transceiver Driver Channel. This reference is unique for
the ECU.
Multiplicity 1
Type Symbolic name reference to [ FrTrcvChannel ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

No Included Containers

10.2.6 FrIfLPdu

SWS Item ECUC_FrIf_05364 :


Container Name FrIfLPdu
Parent Container FrIfController
Description Reference to a L-PDU index
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Configuration Parameters

SWS Item ECUC_FrIf_06058 :


Name FrIfLPduIdx
Parent Container FrIfLPdu
Description This parameter identifies the L-PDU in the interaction between FlexRay
Interface and FlexRay Driver.
155 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Multiplicity 1
Type EcucIntegerParamDef (Symbolic Name generated for this parameter)
Range 0 .. 4095
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00008 :


Name FrIfReconfigurable
Parent Container FrIfLPdu
Description This parameter specifies that this LPdu is reconfigurable using
FrIf_ReconfigLPdu. This means that this LPdu can be assigned to a
different FrameTriggering at runtime. However, this reconfiguration is
limited by hardware constraints. The direction of the LPdu cannot be
reconfigured.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06057 :


Name FrIfVBTriggeringRef
Parent Container FrIfLPdu
Description Reference to the assigned Frame triggering.
Multiplicity 1
Type Reference to [ FrIfFrameTriggering ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

No Included Containers

10.2.7 FrIfFrameTriggering

SWS Item ECUC_FrIf_06090 :


Container Name FrIfFrameTriggering
Parent Container FrIfController
A Frame triggering contains the communication parameters of the FlexRay
Description
Frame as well as a reference to the Frame Construction Plan.
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
156 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Configuration Parameters

SWS Item ECUC_FrIf_06049 :


Name FrIfAllowDynamicLSduLength
Parent Container FrIfFrameTriggering
Description Allows L-PDU length reduction ('FrIfLSduLength' defines max. length) and
indicates that the related CC buffer has to be reconfigured for the actual
length and Header-CRC before transmission of the L-PDU.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00013 :


Name FrIfAlwaysTransmit
Parent Container FrIfFrameTriggering
Description Defines whether the driver's API function Fr_TransmitTxLPdu() shall
always be called for this L-PDU.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06051 :


Name FrIfBaseCycle
Parent Container FrIfFrameTriggering
Description This parameter contains the FlexRay Base Cycle used to transmit this
FlexRay Frame.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06052 :


Name FrIfChannel
Parent Container FrIfFrameTriggering
Description This parameter contains the FlexRay Channel used to transmit this FlexRay
Frame.
Multiplicity 1
Type EcucEnumerationParamDef
Range FRIF_CHANNEL_A Channel A
FRIF_CHANNEL_AB Channel A and B
FRIF_CHANNEL_B Channel B
157 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

SWS Item ECUC_FrIf_06053 :


Name FrIfCycleRepetition
Parent Container FrIfFrameTriggering
Description This parameter contains the FlexRay Cycle Repetition used to transmit this
FlexRay Frame.
Possible values for FlexRay Protocol version 2.1: 1,2,4,8,16,32,64
Possible values for FlexRay Protocol version 3.0:
1,2,4,5,8,10,16,20,32,40,50,64
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 64
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06054 :


Name FrIfLSduLength
Parent Container FrIfFrameTriggering
Description The payload length of the Frame is given here. This parameter is required
for validation if configured PDUs and update information fits into the Frame
at configuration time [bytes].
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 254
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local
dependency: The parameter depends on the low level parameters of the
FlexRay CC.

SWS Item ECUC_FrIf_00010 :


Name FrIfMessageId
Parent Container FrIfFrameTriggering
Description The first two bytes of the payload segment of the FlexRay frame format for
frames transmitted in the
dynamic segment can be used as receiver filterable data called the
message ID.
Multiplicity 0..1
Type EcucIntegerParamDef
Range 0 .. 65535
Default value --
Post-Build Variant true

158 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06055 :


Name FrIfPayloadPreamble
Parent Container FrIfFrameTriggering
Description Switching the Payload Preamble bit.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06056 :


Name FrIfSlotId
Parent Container FrIfFrameTriggering
Description This parameter contains the FlexRay Slot ID used to transmit this FlexRay
Frame.
Multiplicity 1
Type EcucIntegerParamDef
Range 1 .. 2047
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06048 :


Name FrIfFrameStructureRef
Parent Container FrIfFrameTriggering
Description Reference to the Construction Plan of the FlexRay Frame.
Multiplicity 1
Type Reference to [ FrIfFrameStructure ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

Included Containers
Container Name Multiplicity Scope / Dependency
Container for the references to
FrIfFrameTriggeringDemEventParameterRef DemEventParameter elements which shall be
0..1
s invoked using the API Dem_SetEventStatus in
case the corresponding error occurs. The
159 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

EventId is taken from the referenced


DemEventParameter's DemEventId symbolic
value. The standardized errors are provided in
this container and can be extended by vendor-
specific error references.

10.2.8 FrIfJobList

SWS Item ECUC_FrIf_05367 :


Container Name FrIfJobList
Parent Container FrIfCluster
This container specifies a list of all FlexRay Jobs of the Cluster to be
Description
performed by FrIf_JobListExec_<FrIfCluster.ShortName>().
Configuration Parameters

SWS Item ECUC_FrIf_06063 :


Name FrIfAbsTimerRef
Parent Container FrIfJobList
Description Reference to the absolute timer to be used to trigger the interrupt whose
ISR contains the FrIf_JobListExec_<FrIfCluster.ShortName>() function.
Multiplicity 1
Type Symbolic name reference to [ FrAbsoluteTimer ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

Included Containers
Container Name Multiplicity Scope / Dependency
A job may contain more than one operation that are executed
FrIfJob 1..*
at a specific point in time.

160 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

FrIfCluster:
EcucParamConfContainerDef

upperMultiplicity = *
lowerMultiplicity = 1

+subContainer
FrIfAbsTimerRef: EcucReferenceDef FrAbsoluteTimer: FrAbsTimerIdx:
+destination EcucParamConfContainerDef EcucIntegerParamDef
FrIfJobList: +reference +parameter
requiresSymbolicNameValue = true
EcucParamConfContainerDef upperMultiplicity = * symbolicNameValue = true
lowerMultiplicity = 1 max = 254
min = 0

FrIfCommunicationOperationIdx:
FrIfCommunicationOperation:
+parameter EcucIntegerParamDef
EcucParamConfContainerDef
max = 255
+subContainer upperMultiplicity = *
min = 0
lowerMultiplicity = 1
FrIfJob:
+literal DECOUPLED_TRANSMISSION:
EcucParamConfContainerDef
FrIfCommunicationAction: EcucEnumerationLiteralDef
upperMultiplicity = * EcucEnumerationParamDef
lowerMultiplicity = 1 +literal
TX_CONFIRMATION:
EcucEnumerationLiteralDef

+literal
RECEIVE_AND_INDICATE:
EcucEnumerationLiteralDef

+literal RX_INDICATION:
EcucEnumerationLiteralDef
+parameter

+literal
RECEIVE_AND_STORE:
EcucEnumerationLiteralDef

+subContainer +literal
PREPARE_LPDU:
EcucEnumerationLiteralDef

+literal
FREE_OP_A:
EcucEnumerationLiteralDef

+literal
FREE_OP_B:
EcucEnumerationLiteralDef

+reference FrIfLPdu:
FrIfLPduIdxRef: +destination
EcucParamConfContainerDef
EcucReferenceDef
upperMultiplicity = *
lowerMultiplicity = 1
FrIfRxComOpMaxLoop:
+parameter EcucIntegerParamDef

min = 1
max = 512
lowerMultiplicity = 0
FrIfCycle: EcucIntegerParamDef upperMultiplicity = 1
+parameter
max = 63
min = 0

FrIfMacrotick: EcucIntegerParamDef
+parameter
min = 0
max = 10240000

FrIfMaxIsrDelay:
+parameter EcucIntegerParamDef

min = 0
max = 10240000

Figure 10-4: FlexRay Inferface JobList

10.2.9 FrIfJob

SWS Item ECUC_FrIf_05368 :


Container Name FrIfJob
Parent Container FrIfJobList
A job may contain more than one operation that are executed at a specific
Description
point in time.
Post-Build Variant
true
Multiplicity
161 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE


Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Configuration Parameters

SWS Item ECUC_FrIf_06064 :


Name FrIfCycle
Parent Container FrIfJob
Description The FlexRay Cycle in which the communication operation will execute this
job
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 63
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06065 :


Name FrIfMacrotick
Parent Container FrIfJob
Description Macrotick offset in the Cycle [Macrotick]
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 10240000
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06004 :


Name FrIfMaxIsrDelay
Parent Container FrIfJob
Description The maximum delay in macroticks the
FrIf_JobListExec_<FrIfCluster.ShortName>() function is processed after
the absolute timer interrupt was triggered.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 10240000
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

Included Containers
Container Name Multiplicity Scope / Dependency
A separate operation which is part of a FlexRay Job and
FrIfCommunicationOperation 1..*
defines what type of action is executed.

162 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

10.2.10 FrIfCommunicationOperation

SWS Item ECUC_FrIf_05369 :


Container Name FrIfCommunicationOperation
Parent Container FrIfJob
A separate operation which is part of a FlexRay Job and defines what type
Description
of action is executed.
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Configuration Parameters

SWS Item ECUC_FrIf_06067 :


Name FrIfCommunicationAction
Parent Container FrIfCommunicationOperation
Description The action to be performed in the FlexRay Operation
Multiplicity 1
Type EcucEnumerationParamDef
Range DECOUPLED_TRANSMISSION Decoupled transmission
FREE_OP_A User defined communication operation.
FREE_OP_B User defined communication operation.
PREPARE_LPDU Prepare message buffer of CC
RECEIVE_AND_INDICATE Immediate reception
RECEIVE_AND_STORE Decoupled reception
RX_INDICATION Reception indication
TX_CONFIRMATION Transmission confirmation with optional
TxConflict check
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency dependency: FrIfCommunicationAction can be configured as PREPARE_LPDU
only if FrPrepareLPduSupport (ECUC_Fr_00453) is configured as TRUE.

SWS Item ECUC_FrIf_06068 :


Name FrIfCommunicationOperationIdx
Parent Container FrIfCommunicationOperation
Description For each FlexRay Communication Job, this index spans a range of zero-
based consecutive values and thus defines the order of the FlexRay
Communication Operation in the respective FlexRay Communication Job.
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 255
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_00007 :


Name FrIfRxComOpMaxLoop
163 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parent Container FrIfCommunicationOperation


Description Defines the maximum number of loops for the receive
RECEIVE_AND_INDICATE (Use case: emptying a FIFO).
Please note that the parameter is mandatory if FrIfCommunicationAction
parameter is set to RECEIVE_AND_INDICATE. For all other operations
this parameter can be ignored.
Multiplicity 0..1
Type EcucIntegerParamDef
Range 1 .. 512
Default value --
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06066 :


Name FrIfLPduIdxRef
Parent Container FrIfCommunicationOperation
Description Reference to a L-PDu index
Multiplicity 1
Type Reference to [ FrIfLPdu ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

No Included Containers

10.2.11 FrIfFrameStructure

SWS Item ECUC_FrIf_05370 :


Container Name FrIfFrameStructure
Parent Container FrIfConfig
The Frame structure specifies a Construction Plan how a Frame is
Description
assembled with PDUs and their respective Update-Bits.
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Configuration Parameters

SWS Item ECUC_FrIf_06113 :


Name FrIfByteOrder
Parent Container FrIfFrameStructure
164 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Description This parameter defines the ByteOrder of all Pdus that are mapped into the Frame.
The absolute position of a Pdu in the Frame is
determined by the definition of the ByteOrder parameter:
If BIG_ENDIAN is specified, the FrIfPduOffset indicates the position of the most
significant bit in the Frame.
If LITTLE_ENDIAN is specified, the FrIfPduOffset indicates the position of the least
significant bit in the Frame.
Multiplicity 1
Type EcucEnumerationParamDef
Range BIG_ENDIAN --
LITTLE_ENDIAN --
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: local
Dependency

Included Containers
Container Name Multiplicity Scope / Dependency
This container holds all the information about a PDU in a
FrIfPdusInFrame 1..*
FlexRay Frame.

10.2.12 FrIfPdusInFrame

SWS Item ECUC_FrIf_05371 :


Container Name FrIfPdusInFrame
Parent Container FrIfFrameStructure
Description This container holds all the information about a PDU in a FlexRay Frame.
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Configuration Parameters

SWS Item ECUC_FrIf_06070 :


Name FrIfPduOffset
Parent Container FrIfPdusInFrame
Description The value specifies the offset of the PDU within the Frame [bytes].
Multiplicity 1
Type EcucIntegerParamDef
Range 0 .. 253
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local
dependency: This parameter depends on the number of PDUs contained
in the Frame, PDU length, and Update-Bits of other PDUs in the Frame. In
165 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

addition, if the Frame will is sent in static segment, this parameter depends
on GPayloadLengthStatic.

SWS Item ECUC_FrIf_06071 :


Name FrIfPduUpdateBitOffset
Parent Container FrIfPdusInFrame
Description This value specifies where the PDU's Update-Bit is stored in the Frame (bit
location of PDU's Update-Bit in the FlexRay Frame).
Multiplicity 0..1
Type EcucIntegerParamDef
Range 0 .. 2031
Default value --
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local
dependency: This parameter depends on the number of PDUs contained
in the Frame, PDU length, and Update-Bits of other PDUs in the Frame. In
addition, if the Frame will is sent in static segment, this parameter depends
on GPayloadLengthStatic.

SWS Item ECUC_FrIf_06069 :


Name FrIfPduRef
Parent Container FrIfPdusInFrame
Description This is the reference to the local definition of a PDU.
Multiplicity 1
Type Reference to [ FrIfPdu ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

No Included Containers

10.2.13 FrIfPdu

SWS Item ECUC_FrIf_05372 :


Container Name FrIfPdu
Parent Container FrIfConfig
Contains PDU information. A PDU may be either a transmission PDU or a
Description
reception PDU.
Post-Build Variant
true
Multiplicity
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
166 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-build time X VARIANT-POST-BUILD


Configuration Parameters

Included Containers
Container Name Multiplicity Scope / Dependency
FrIfPduDirection 1 A PDU is either transmit or receive

10.2.14 FrIfTxPdu

SWS Item ECUC_FrIf_05374 :


Container Name FrIfTxPdu
Parent Container FrIfPduDirection
Description This container specifies transmission PDUs.
Configuration Parameters

SWS Item ECUC_FrIf_06075 :


Name FrIfConfirm
Parent Container FrIfTxPdu
Description Defines whether the transmission of a PDU should be checked and
confirmed to the PDU owning BSW module. If "FrIfUserTxUL" is configured
as FR_TSYN then this parameter has to be set to FALSE for this PDU.
Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local
dependency: FrIfUserTxUL

SWS Item ECUC_FrIf_06076 :


Name FrIfCounterLimit
Parent Container FrIfTxPdu
Description This value states the maximum number of indication of ready PDU data to
the FrIf (i.e. maximum number of invocations of FrIf_Transmit) without an
intermediate transmission of the PDU.
Multiplicity 0..1
Type EcucIntegerParamDef
Range 1 .. 255
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06077 :


Name FrIfImmediate
Parent Container FrIfTxPdu
Description Defines whether the PDU is transmitted immediate or decoupled.

167 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Multiplicity 1
Type EcucBooleanParamDef
Default value --
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_06050 :


Name FrIfNoneMode
Parent Container FrIfTxPdu
Description Using the "None-Mode" which means that there is no API FrIf_Transmit
call of the upper layer for this PDU.
Multiplicity 0..1
Type EcucBooleanParamDef
Default value false
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local
dependency: FrIfImmediate

SWS Item ECUC_FrIf_00014 :


Name FrIfTxConfirmationName
Parent Container FrIfTxPdu
Description This parameter defines the name of the <User_TxConfirmation>. This
parameter depends on the parameter FrIfUserTxUL. If FrIfUserTxUL
equals FR_TP, FR_AR_TP, FR_NM, PDUR or XCP, the name of the
<User_TxConfirmation> is fixed. If FrIfUserTxUL equals CDD, the name of
the <User_TxConfirmation> is selectable.
Multiplicity 0..1
Type EcucFunctionNameDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_06078 :


Name FrIfTxPduId
168 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Parent Container FrIfTxPdu


Description The global PDU identifier, which has to be used by the upper layer BSW
module. The identifier has to be zero based and consecutive.
Multiplicity 1
Type EcucIntegerParamDef (Symbolic Name generated for this parameter)
Range 0 .. 65535
Default value --
Post-Build Variant Value false
Value Configuration Class Pre-compile time X All Variants
Link time --
Post-build time --
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_06084 :


Name FrIfUserTriggerTransmitName
Parent Container FrIfTxPdu
Description This parameter defines the name of the <User_TriggerTransmit>. This
parameter depends on the parameter FrIfUserTxUL. If FrIfUserTxUL
equals FR_TP, FR_AR_TP, FR_NM, PDUR, FR_TSYN or XCP the name
of the <User_TriggerTransmit> is fixed. If FrIfUserTxUL equals CDD, the
name of the <User_TriggerTransmit> is selectable.
Multiplicity 0..1
Type EcucFunctionNameDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU
dependency: FrIfImmediate

SWS Item ECUC_FrIf_00015 :


Name FrIfUserTxUL
Parent Container FrIfTxPdu
Description This parameter defines the upper layer (UL) module to which the trigger of the Pdu
to be transmitted (via the <User_TriggerTransmit>) or the confirmation of the
successfully transmitted Pdu has to be routed (via the <User_TxConfirmation>).
Please note that handle IDs which are used in callback functions are defined by the
upper layer module.
Multiplicity 1
Type EcucEnumerationParamDef
Range CDD Complex Driver
FR_AR_TP FR AUTOSAR TP
FR_NM FR NM
FR_TP FR ISO TP
FR_TSYN Global Time Synchronization over
FlexRay
PDUR PDU Router

169 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

XCP Extended Calibration Protocol


Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: ECU
Dependency dependency: FrIfConfirm

SWS Item ECUC_FrIf_06074 :


Name FrIfTxPduRef
Parent Container FrIfTxPdu
Description Reference to the external PDU definition.
Multiplicity 1
Type Reference to [ Pdu ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

No Included Containers

FrIfTxPduId: Pdu:
EcucIntegerParamDef EcucParamConfContainerDef
FrIfPduDirection:
FrIfConfig: EcucParamConfContainerDef EcucChoiceContainerDef FrIfTxPdu:
+parameter symbolicNameValue = true lowerMultiplicity = 0
EcucParamConfContainerDef
min = 0 upperMultiplicity = *
upperMultiplicity = 1 max = 65535
lowerMultiplicity = 0

+reference FrIfTxPduRef: EcucReferenceDef +destination

+subContainer

FrIfPdu:
EcucParamConfContainerDef +parameter FrIfConfirm:
EcucBooleanParamDef
upperMultiplicity = *
lowerMultiplicity = 1 +parameter FrIfImmediate:
EcucBooleanParamDef

FrIfCounterLimit:
+subContainer EcucIntegerParamDef
+parameter
min = 1
max = 255
lowerMultiplicity = 0
FrIfTxConfirmationName:
upperMultiplicity = 1 +parameter EcucFunctionNameDef

upperMultiplicity = 1
FrIfUserTriggerTransmitName: lowerMultiplicity = 0
+parameter EcucFunctionNameDef

upperMultiplicity = 1
lowerMultiplicity = 0
+choice
XCP:
FrIfUserTxUL: +literal EcucEnumerationLiteralDef
EcucEnumerationParamDef

+literal PDUR:
EcucEnumerationLiteralDef

+literal
FR_NM:
EcucEnumerationLiteralDef

+parameter +literal
FR_TP:
EcucEnumerationLiteralDef

+literal
CDD:
EcucEnumerationLiteralDef

+literal
FR_AR_TP:
EcucEnumerationLiteralDef

+literal
FR_TSYN:
EcucEnumerationLiteralDef

FrIfNoneMode:
+parameter EcucBooleanParamDef

lowerMultiplicity = 0
upperMultiplicity = 1
FrIfRxPdu: defaultValue = false
+choice
EcucParamConfContainerDef

upperMultiplicity = 1
lowerMultiplicity = 0

10.2.15 FrIfRxPdu

SWS Item ECUC_FrIf_05373 :


170 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Container Name FrIfRxPdu


Parent Container FrIfPduDirection
Description Receive PDU
Configuration Parameters

SWS Item ECUC_FrIf_00016 :


Name FrIfRxIndicationName
Parent Container FrIfRxPdu
Description This parameter defines the name of the <User_RxIndication>. This
parameter depends on the parameter FrIfUserRxIndicationUL. If
FrIfUserRxIndicationUL equals FR_TP, FR_AR_TP, FR_NM, PDUR,
FR_TSYN or XCP, the name of the <User_RxIndication> is fixed. If
FrIfUserRxIndicationUL equals CDD, the name of the <User_RxIndication>
is selectable.
Multiplicity 0..1
Type EcucFunctionNameDef
Default value --
maxLength --
minLength --
regularExpression --
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

SWS Item ECUC_FrIf_00017 :


Name FrIfUserRxIndicationUL
Parent Container FrIfRxPdu
Description This parameter defines the upper layer (UL) module to which the indication of the
successfully received FrIfRxPdu has to be routed via <User_RxIndication>. This
<User_RxIndication> has to be invoked when the indication of the configured
FrIfRxPdu will be received by a Rx indication event from the FR Driver module. If
no upper layer (UL) module is configured, no <User_RxIndication> has to be called
in case of a Rx indication event of the FrIfRxPdu from the FR Driver module.
Multiplicity 1
Type EcucEnumerationParamDef
Range CDD Complex Driver
FR_AR_TP FR AR TP
FR_NM FR NM
FR_TP FR ISO TP
FR_TSYN Global Time Synchronization over
FlexRay
PDUR PDU Router
XCP Extended Calibration Protocol
Post-Build Variant
true
Value
Value Pre-compile time X VARIANT-PRE-COMPILE
Configuration Link time X VARIANT-LINK-TIME
Class Post-build time X VARIANT-POST-BUILD
Scope / scope: ECU
Dependency
171 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

SWS Item ECUC_FrIf_06073 :


Name FrIfRxPduRef
Parent Container FrIfRxPdu
Description Reference to the external PDU definition.
Multiplicity 1
Type Reference to [ Pdu ]
Post-Build Variant Value true
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: ECU

No Included Containers

10.2.16 FrIfPduDirection

SWS Item ECUC_FrIf_06072 :


Choice container Name FrIfPduDirection
Parent Container FrIfPdu
Description A PDU is either transmit or receive

Container Choices
Container Name Multiplicity Scope / Dependency
FrIfRxPdu 0..1 Receive PDU
FrIfTxPdu 0..1 This container specifies transmission PDUs.

10.2.17 FrIfConfig

SWS Item ECUC_FrIf_06001 :


Container Name FrIfConfig
Parent Container FrIf
This container contains the configuration parameters and sub containers of
Description
the AUTOSAR FrIf module.
Configuration Parameters

SWS Item ECUC_FrIf_06121 :


Name FrIfMaxPduCnt
Parent Container FrIfConfig
Description Maximum number of Pdus. This parameter is needed only in case of post-
build loadable implementation using static memory allocation.
Multiplicity 0..1
Type EcucIntegerParamDef
Range 0 ..
18446744073709551615
Default value --
172 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-Build Variant
false
Multiplicity
Post-Build Variant Value false
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME, VARIANT-POST-
BUILD
Post-build time --
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME, VARIANT-POST-
BUILD
Post-build time --
Scope / Dependency scope: local

Included Containers
Container Name Multiplicity Scope / Dependency
This container specifies a FrIf Cluster and all related data
FrIfCluster 1..* which is required to enable communication of the Cluster. A
Cluster may consist of more than one Controller.
The Frame structure specifies a Construction Plan how a
FrIfFrameStructure 1..* Frame is assembled with PDUs and their respective Update-
Bits.
Contains PDU information. A PDU may be either a
FrIfPdu 1..*
transmission PDU or a reception PDU.

10.2.18 FrIfClusterDemEventParameterRefs

SWS Item ECUC_FrIf_06091 :


Container Name FrIfClusterDemEventParameterRefs
Parent Container FrIfCluster
Container for the references to DemEventParameter elements which shall
be invoked using the API Dem_SetEventStatus in case the corresponding
error occurs. The EventId is taken from the referenced
Description
DemEventParameter's DemEventId symbolic value. The standardized
errors are provided in this container and can be extended by vendor-
specific error references.
Configuration Parameters

SWS Item ECUC_FrIf_06097 :


Name FRIF_E_ACS_CH_A
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in ACS on channel A was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD

173 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE


Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06098 :


Name FRIF_E_ACS_CH_B
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in ACS on channel B was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06093 :


Name FRIF_E_NIT_CH_A
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in NIT on channel A was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06094 :


Name FRIF_E_NIT_CH_B
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in NIT on channel B was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity Configuration Pre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
174 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

Post-build time X VARIANT-POST-BUILD


Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06095 :


Name FRIF_E_SW_CH_A
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in SW on channel A was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

SWS Item ECUC_FrIf_06096 :


Name FRIF_E_SW_CH_B
Parent Container FrIfClusterDemEventParameterRefs
Description Reference to the DemEventParameter which shall be issued when an error
in SW on channel B was detected. If the reference is not configured the
error shall not be reported.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

No Included Containers

10.2.19 FrIfFrameTriggeringDemEventParameterRefs

SWS Item ECUC_FrIf_06099 :


Container Name FrIfFrameTriggeringDemEventParameterRefs
Parent Container FrIfFrameTriggering
Container for the references to DemEventParameter elements which shall
Description
be invoked using the API Dem_SetEventStatus in case the corresponding
175 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface
Specification of FlexRay Interface
AUTOSAR CP R20-11

error occurs. The EventId is taken from the referenced


DemEventParameter's DemEventId symbolic value. The standardized
errors are provided in this container and can be extended by vendor-
specific error references.
Configuration Parameters

SWS Item ECUC_FrIf_00009 :


Name FRIF_E_LPDU_SLOTSTATUS
Parent Container FrIfFrameTriggeringDemEventParameterRefs
Description Reference to DEM event Id that is reported when FlexRay driver module
detects slot errors. If this parameter is not configured, no event reporting
happens.
Multiplicity 0..1
Type Symbolic name reference to [ DemEventParameter ]
Post-Build Variant
true
Multiplicity
Post-Build Variant Value true
Multiplicity ConfigurationPre-compile time X VARIANT-PRE-COMPILE
Class Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Value Configuration Class Pre-compile time X VARIANT-PRE-COMPILE
Link time X VARIANT-LINK-TIME
Post-build time X VARIANT-POST-BUILD
Scope / Dependency scope: local

No Included Containers

10.3 Published Information


For details refer to the chapter 10.3 “Published Information” in SWS_BSWGeneral.

176 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface


Specification of FlexRay Interface
AUTOSAR CP R20-11

11 Not applicable requirements


[SWS_FrIf_06118] ⌈These requirements are not applicable to this specification.
(SRS_BSW_00159, SRS_BSW_00167, SRS_BSW_00387, SRS_BSW_00416, SRS_BSW_00168,
SRS_BSW_00423, SRS_BSW_00424, SRS_BSW_00425, SRS_BSW_00426, SRS_BSW_00427,
SRS_BSW_00428, SRS_BSW_00429, BSW00431, SRS_BSW_00432, BSW00434,
SRS_BSW_00417, SRS_BSW_00386, SRS_BSW_00161, SRS_BSW_00162, SRS_BSW_00005,
SRS_BSW_00415, SRS_BSW_00164, SRS_BSW_00325, SRS_BSW_00326, SRS_BSW_00413,
SRS_BSW_00347, SRS_BSW_00373, SRS_BSW_00335, SRS_BSW_00410, SRS_BSW_00314,
SRS_BSW_00370, SRS_BSW_00328, SRS_BSW_00312, SRS_BSW_00006, SRS_BSW_00377,
SRS_BSW_00306, SRS_BSW_00371, SRS_BSW_00376, SRS_BSW_00329, SRS_BSW_00330, ,
SRS_BSW_00331, SRS_BSW_00009, SRS_BSW_00172, SRS_BSW_00010, SRS_BSW_00333,
SRS_BSW_00341, BSW05078, BSW05101, BSW05163, BSW05164, BSW05165, BSW05067,
BSW05068, BSW05069, BSW05153, BSW05035, BSW05038, BSW05162, BSW05113, BSW05102,
SRS_Fr_05009) ⌋

177 of 177 Document ID 27: AUTOSAR_SWS_FlexRayInterface

You might also like