AUTOSAR CP SRS CoreTest
AUTOSAR CP SRS CoreTest
AUTOSAR CP R23-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.
1 Scope of Document
This document defines general rules and requirements for Core Test specification in
AUTOSAR. It shall be used as a basis for each requirements document.
Care has been taken to insure consistency between the Core test, RAM test and
Flash test SRS documents.
2 Conventions to be Used
The representation of requirements in AUTOSAR documents follows the table
specified in [TPS_STDT_00078].
Acronym: Description:
CPU Central Processing Unit
MPU Memory Protection Unit
L1 1st level memory
L2 2nd level memory
MCU Microcontroller Unit
BIST Built in Self Test
IRQ Interrupt Request
Core A CPU plus closely located functional resources
Atomic sequence/ Sequence of software code execution which must not be
atomic part interrupted at any time
Partial test A partial test is defined as the test of one or more ‘hardware
resources’. (A partial test is interruptible because it is executed
in background mode).
PCB Printed Circuit Board
External device A physical external entity; e.g. a second microcontroller
Resource A core internal unit which executes a unique functionality (e.g.
IRQ-controller)
Checksum/ A numerical representation of the result of a test execution or
signature atomic sequence of a test execution.
Caller/calling entity The caller/calling entity is located on a higher AUTOSAR or ISO
layer. It is the user of the API call.
Term: Description:
Background test Background test is called periodically by a SW-scheduler.
Foreground test Foreground test is called via users call.
Golden (Ref.) Reference value used for comparison (e.g.
Value Checksum/Signature)
Good Case The execution finished without reporting an error
As this is a document from professionals for professionals, all other terms are
expected to be known.
4 Functional Overview
This module describes the requirements for an API specifying test cases in
accordance with the automotive norm. It covers periodic as well as start-up tests.
This is meant to be integrated in the overall safety concept and will not give the
required diagnostic coverage on its own.
It shall be allowed to cancel the background mode and start a foreground mode. It
shall not be possible to have both modes being executed at the same time. If a
background task is running and a foreground task is requested, the background task
should be cancelled (e.g. at the end of an atomic sequence) before calling the
foreground task.
The test computes both steps and returns pass/fail status, or just computes the
checksum and provide a notification of completion to the calling entity. This is to allow
a higher degree of flexibility in the implementation of test and supervision concepts.
The Core is defined as the central processing unit (CPU), all dedicated memory and
bus interfaces (TCM, L1, L2 cache, system bus, etc.) and all dedicated supporting
functionality (e.g. interrupt controller, debug, etc.). Throughout this document the
expression 'Core' is used for referencing to this definition. A very generic block
8 of 25 Document ID 258: AUTOSAR_CP_SRS_CoreTest
Requirements on Core Test
AUTOSAR CP R23-11
diagram is shown below. Cores which implement more than one generic CPU should
have more than one core test entity.
Interrupt
Debug interface
controller
CPU
Tighty Coupled
Memory
Interface(s)
Instruction Data
Cache
MPU Cache
System
Bus
Interface(s)
CORE
The requirements are derived from the automotive standards. Busses have to be
tested including arbitration, MMU/MPU, caches, tightly coupled memories, general
purpose and dedicated registers, numerical execution units, including address
generation and interrupts plus exception handling.
The corresponding tests are listed in the automotive standard. APIs are foreseen for
techniques defined as test by the automotive standard, with exception of boundary
scan test which will not be in the scope of this document
Not covered are permanent monitoring techniques nor redundant hardware
techniques (e.g. lock-step CPU). If present and requiring software support, they may
have to be addressed by MCAL complex drivers.
Note: The Core test initiates diagnostic events only. It shall be used to detect static
hardware errors at runtime. Transient faults and intermittent faults are not covered
and cannot be detected by dedicated test-software support.
Note: A Core test reports errors in all dedicated memory and bus interfaces (TCM,
L1, L2 cache, system bus, etc.) and all dedicated supporting functionality (e.g.
interrupt controller, debug, etc.) to the diagnostic event manager (DEM). For the CPU
(e.g. ALU, Prefetch queue) inside a core – only a successful execution of a test or an
atomic part of the test (“Good case”) can be reported. The errors cases for the CPU
inside the core cannot be reliably reported to DEM. Events at DEM have to be
defined accordingly. Results/errors are reported though the DEM API (BSW,
Dem_SetEventStatus() ).
Note: The Core test implementation shall be focused to test the core itself with no
interference to the application implementation itself. Anyhow some performance and
9 of 25 Document ID 258: AUTOSAR_CP_SRS_CoreTest
Requirements on Core Test
AUTOSAR CP R23-11
timing effort shall be considered due to core test computation needs. Anyhow, this
needs to be handled by upper entities/layers as seen relative to the Core test driver
executing on lower layers or any caller of MCAL core test driver and therefore is out
of scope of a driver implementation.
It shall be possible to execute a Core test on every equal instance of a core inside a
silicon device. The Core test itself and the API do not have to be aware of the system
architecture itself due to its fact of being a driver located on lower AUTOSAR layers.
Additionally a Core test have not to be aware of the number of cores which co-exist in
the overall system architecture and is only focused on one single core entity (i.e. if
there are multi-cores, then the user-application has to schedule multiple entities of
the same test for each core).
Therefore there has to be a clear distinction between the expressions ‘Multi-
microcontroller’ and ‘multi-core’. Multi-Microcontroller system designs are out of
scope of a core test and its driver API due to the nature of being a driver and a driver
API.
Interrupt Interrupt
Debug interface Debug interface
controller controller
System System
Bus Bus
Interface (s)
CORE Interface (s)
CORE
Microcontroller/ECU
As a summary, the core test is a local MCAL driver and as such it has no horizontal
view to the system architecture design as well as to other microcontrollers or upper
layer services.
There is no resource managing entity available in AUTOSAR upper layers (e.g. ISO
7-layer model - session management). It is necessary to temporarily free a local core
resource (e.g. IRQ controller) from application usage to avoid unwanted behavior and
interference between test and application during runtime. There is no managing
entity available within AUTOSAR architecture to actively handle this requirement prior
starting to execute a core test (Feb/2008, R3.0). An MCAL driver cannot handle
resource management due to its state of being a driver located in lower AUTOSAR
layers. The ECU state manager might be extended to handle this as an additional
state or mode.
Today AUTOSAR does not support runtime testing; therefore no test managing entity
is available in AUTOSAR upper layers. Due to the intentionally missing ability of an
MCAL driver to directly access test results being executed on other cores (e.g. Multi-
microcontroller systems), a test managing entity is needed in upper AUTOSAR layers
architecture to handle test result processing (local, external) and related reactions of
the overall system architecture.
4.1.3.3 Limitations
5 Requirements Tracing
Requirement Description Satisfied by
RS_BRF_00129 AUTOSAR shall support SRS_CoreTst_14115, SRS_CoreTst_14116
data corruption detection and
protection
RS_BRF_01048 AUTOSAR module design SRS_CoreTst_14111, SRS_CoreTst_14130
shall support modules to
cooperate in a multitasking
environment
RS_BRF_01056 AUTOSAR BSW modules SRS_CoreTst_14112, SRS_CoreTst_14113,
shall provide standardized SRS_CoreTst_14131
interfaces
RS_BRF_01064 AUTOSAR BSW shall SRS_CoreTst_14119
provide callback functions in
order to access upper layer
modules
RS_BRF_01096 AUTOSAR shall support SRS_CoreTst_14134
start-up and shutdown of
ECUs
RS_BRF_01136 AUTOSAR shall support SRS_CoreTst_14101, SRS_CoreTst_14102
variants of configured BSW
data resolved after system
start-up
RS_BRF_01232 AUTOSAR OS shall support SRS_CoreTst_14123
isolation and protection of
application software and
BSW
RS_BRF_01296 AUTOSAR RTE shall SRS_CoreTst_14133
support and handle single
and multiple instantiation of
Software Components
RS_BRF_01320 AUTOSAR RTE shall SRS_CoreTst_14114
schedule SWC and BSW
modules
RS_BRF_01400 AUTOSAR RTE shall offer SRS_CoreTst_14114
configurable test hooks
RS_BRF_01472 AUTOSAR shall support SRS_CoreTst_14123, SRS_CoreTst_14126,
modes SRS_CoreTst_14133, SRS_CoreTst_14134
RS_BRF_02024 AUTOSAR shall provide SRS_CoreTst_14117
mechanisms to protect the
system from unauthorized
use
RS_BRF_02160 AUTOSAR diagnostic shall SRS_CoreTst_14130
allow external testers to
control active functionality of
the ECU
RS_BRF_02168 AUTOSAR diagnostics shall SRS_CoreTst_14117
provide a central
classification and handling of
abnormal operative
conditions
RS_BRF_02224 AUTOSAR shall support run- SRS_CoreTst_14104, SRS_CoreTst_14105,
12 of 25 Document ID 258: AUTOSAR_CP_SRS_CoreTest
Requirements on Core Test
AUTOSAR CP R23-11
time hardware tests SRS_CoreTst_14106, SRS_CoreTst_14107,
SRS_CoreTst_14108, SRS_CoreTst_14109,
SRS_CoreTst_14110, SRS_CoreTst_14131,
SRS_CoreTst_14134
6 Requirements Specification
6.1 Functional Requirements
6.1.1 Configuration
[SRS_CoreTst_14124] The implementation of the Core test shall have to comply with
the IEC61508 (rejected)
⌈
Type: valid
Description: The implementation of the Core test will have to comply with the IEC61508
Software Requirements to achieve certification. This affects both the
development process and the programming techniques.
Rationale: Mandated by IEC61508
Use Case: --
Dependencies: --
Supporting Material: BRF 00001 - 00100 ( ID )
7 References
7.1 Deliverables of AUTOSAR
[AUTOSAR_GLOSSARY] Glossary,
AUTOSAR_FO_TR_Glossary.pdf