Central locking system test
Version
1.0
Description
Tests the states of the Central Locking System (CLS) that are depending on the lock/unlock requests by
using the remote control within the key, and that are depending on the velocity and the crash sensor of the
vehicle.
Test Designers
Name Department
Peter Tester Test1
John Sample Test2
-1-
Table Of Contents
1 Variant Properties...........................................................................................................................................3
2 Test Execution Tree ........................................................................................................................................4
3 Test Execution Tree Elements ........................................................................................................................5
4 Reusable Functions......................................................................................................................................14
5 Curve Checkpoints .......................................................................................................................................16
-2-
1 Variant Properties
Name Value
Region US
Coverage Medium
-3-
2 Test Execution Tree
Test static requirements of the door control unit (page 5)
Lock statically (page 5)
Unlock statically (page 5)
Crash detection while engine is moving (page 6)
Test velocity dependent requirements of the door control unit (page 7)
Lock by increasing velocity (page 7)
No unlock when slowing down (page 8)
Check locking behavior with velocity waveform (page 9)
Apply crash with different velocities (page 9)
Crash detection when car is moving (page 9)
Lock dependent on velocity and crash detection (page 10)
Lock with car moving/not moving (page 11)
Comfort close (page 11)
Open and comfort close (page 11)
Diagnostics (page 12)
Ambiguous request KeyUp/KeyDown with engine off (page 12)
Ambiguous request KeyUp/KeyDown with engine running (page 12)
Variant coding (page 13)
-4-
3 Test Execution Tree Elements
3.1 Test static requirements of the door control unit
3.1.1 Lock statically
Test static requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
Trace Items
Name Readable ID
lock statically 3298790000
Preparation
Initialize all signals
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=idle
Wait for 500 ms
Main Part
Ensure initial state 'Unlocked'
Set LockRequest=Request_unlock, wait for 200 ms and check LockState==Unlocked
Request to lock the car (engine off). Check if the car is locked.
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=Request_lock, wait for
LockRequestWaitTime ms and check LockState==Locked
Request to lock the car (engine running). Check if the car is locked.
Set EngineRunning=1, Velocity=0, CrashDetected=0, LockRequest=Request_lock, wait for
LockRequestWaitTime ms and check LockState==Locked
Completion
Reset all signals
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=idle
Wait for 500 ms
3.1.2 Unlock statically
Test static requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
-5-
Test static requirements of the door control unit \ Unlock statically
Trace Items
Name Readable ID
unlock statically 3298800000
Preparation
Initialize all signals
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=idle
Wait for 500 ms
Main Part
Ensure initial state 'Locked'
Set LockRequest=Request_lock, wait for 200 ms and check LockState==Locked
Request to unlock the car (engine off). Check if the car will be unlocked.
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=Request_unlock, wait for
LockRequestWaitTime ms and check LockState==Unlocked
Request to unlock the car (engine running). Check if the car will be unlocked.
Set EngineRunning=1, Velocity=0, CrashDetected=0, LockRequest=Request_unlock, wait for
LockRequestWaitTime ms and check LockState==Unlocked
Completion
Reset all signals
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=idle
Wait for 500 ms
3.1.3 Crash detection while engine is moving
Test static requirements of the door control unit
Call CrashDetection (engineOn=0,velocity=40), (engineOn=0,velocity=60), (engineOn=1,velocity=40), ...
CrashDetection(engineOn={engineOn},velocity={velocity})
Combinatorics: Combinatorial
Test Case Attributes
Name Value
Lifecycle reopened
Note Use parameters from parameter file instead of single
values
Trace Items
Name Readable ID
crash detection when car is moving 3298840000
engineOn velocity
0 40
1 60
-6-
Test velocity dependent requirements of the door control unit
3.2 Test velocity dependent requirements of the door control unit
Preparation
(Fixture Preparation)
Check max. cycle time of message 'CentralLockingSystemState' 110 ms
Check cycle time of CentralLockingSystemState to be within [<min> .. 110 ms]
Main Part
Lock by increasing velocity (page 7)
No unlock when slowing down (page 8)
Check locking behavior with velocity waveform (page 9)
The following test sequence is only relevant for Coverage 'Medium' and 'Full'
Apply crash with different velocities (page 9)
Lock dependent on velocity and crash detection (page 10)
Lock with car moving/not moving (page 11)
3.2.1 Lock by increasing velocity
Test velocity dependent requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
Trace Items
Name Readable ID
lock by increasing velocity 3298820000
Preparation
Initialize all signals (page 15)
Call ResetSignals ()
Ensure initial state 'Unlocked'
Set LockRequest=Request_unlock, wait for 200 ms and check LockState==Unlocked
Main Part
Start engine
Set EngineRunning=1
Accelerate to velocity lower than the lock-velocity
Call AccelerateDecelerateToTargetSpeed (targetSpeed=20)
Wait for 500 ms
Check no automatic lock with velocity lower than the lock-velocity
Check LockState==Unlocked
Accelerate to velocity higher than lock-velocity
Call AccelerateDecelerateToTargetSpeed (targetSpeed=60)
Wait for 500 ms
-7-
Test velocity dependent requirements of the door control unit
Check automatic lock with velocity higher than lock-velocity
Check LockState==Locked
Decelerate until stopped
Call AccelerateDecelerateToTargetSpeed (targetSpeed=0)
Completion
Reset all signals (page 15)
Call ResetSignals ()
3.2.2 No unlock when slowing down
Test velocity dependent requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
Trace Items
Name Readable ID
no unlock by slowing down 3298830000
Preparation
Initialize all signals (page 15)
Call ResetSignals ()
Main Part
Ensure initial state 'Unlocked'
Set LockRequest=Request_unlock, wait for 200 ms and check LockState==Unlocked
Start engine
Set EngineRunning=1
Wait for 500 ms
For loopIterator=0..5, increment=1
Speed up
Wait for 500 ms
Check lock state at a speed of 150 km/h
Check LockState==Locked
Decelerate
While ( Velocity>0 )
Slow down
Wait for 500 ms
Check lock state is still 'Locked' after halt
Check LockState==Locked
Check lock state behavior on engine stop - dependent on country setting
If ( UnlockDoorOnEngineStop==1 )
Check automatic unlock
-8-
Test velocity dependent requirements of the door control unit
Check LockState==Unlocked
else
Check no automatic unlock
Check LockState==Locked
Add capture of graphic window to the report
Call testReportAddWindowCapture (window=Graphic, data=, title=Velocity dependent lock state:)
Completion
Reset all signals (page 15)
Call ResetSignals ()
3.2.3 Check locking behavior with velocity waveform
Test velocity dependent requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
Trace Items
Name Readable ID
lock by increasing velocity 3298820000
no unlock by slowing down 3298830000
Initialize all signals (page 15)
Call ResetSignals ()
Stimulate velocity via 'StimulateVelocity' and execute checkpoints from 'ExpectedLockState'
Waveform stimulation of Velocity with LockAutomaticallyTester::StimulateVelocity,
LockAutomaticallyTester::ExpectedLockState and wait until stimulus is finished
Curve 'LockAutomaticallyTester::ExpectedLockState' contains checkpoints (page 16)
3.2.4 Apply crash with different velocities
Test velocity dependent requirements of the door control unit
Variant Dependencies
( Coverage>=Medium )
Iterate through all velocities defined in the parameter file; execute test with corresponding velocities
For Each currVelocity in VelocityList
Crash detection when car is moving (page 9)
3.2.5 Crash detection when car is moving
Test velocity dependent requirements of the door control unit \ Apply crash with different velocities
-9-
Test velocity dependent requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle finished
Note
Set the test case name dynamically, containing the current velocity
Set test case name
Initialize all input signals (page 15)
Call ResetSignals ()
Set velocity to execute test with
Set Velocity=currVelocity
Apply a crash. Check if the car has been opened
Set CrashDetected=1, wait for 500 ms and check LockState==Unlocked
Reset the crash signal
Set CrashDetected=0
Wait for 500 ms
Reset all signals (page 15)
Call ResetSignals ()
3.2.6 Lock dependent on velocity and crash detection
Test velocity dependent requirements of the door control unit
Test Case Attributes
Name Value
Lifecycle in implementation
Note Use test sequence with loop around test cases
instead?
Trace Items
Name Readable ID
lock by increasing velocity 3298820000
no unlock by slowing down 3298830000
Iterate through all relevant locking test vectors
For Each testVector in DoorLockData
Initialize all signals (page 15)
Call ResetSignals ()
Set EngineRunning=testVector.Engine
Wait for 500 ms
Ensure initial state 'Unlocked'
Set LockRequest=Request_unlock, wait for 500 ms and check LockState==Unlocked
Apply test vector of stimulation and expected values
Set Velocity=testVector.Velocity, CrashDetected=testVector.CrashDetected, wait for 250 ms and check
LockState==testVector.LockState
- 10 -
Test velocity dependent requirements of the door control unit
Reset all signals (page 15)
Call ResetSignals ()
3.2.7 Lock with car moving/not moving
Test velocity dependent requirements of the door control unit
Call LockingBehavior (engineRunning=0,isMoving=0,crash=1,expectedLockState=Locked),
(engineRunning=0,isMoving=1,crash=1,expectedLockState=Unlocked),
(engineRunning=1,isMoving=0,crash=0,expectedLockState=Locked), ...
For engine = {engineRunning}, moving = {isMoving} and applied crash = {crash}, check lock state ==
{expectedLockState} (page 14)
Combinatorics: Sequential
Test Case Attributes
Name Value
Lifecycle finished
Note Candidate for classification tree.
engineRunning isMoving crash expectedLockState Trace Items
0 0 1 Locked
0 1 1 Unlocked crash detection when car is
moving
1 0 0 Locked
1 1 1 Unlocked crash detection when car is
moving
3.3 Comfort close
3.3.1 Open and comfort close
Comfort close
Test Case Attributes
Name Value
Lifecycle finished
Note
Preparation
Initialize all signals (page 15)
Call ResetSignals ()
Check max. cycle time of message 'CentralLockingSystemState' 110 ms
Check cycle time of CentralLockingSystemState to be within [<min> .. 110 ms]
Check max. cycle time of message 'WindowState' 110 ms
Check cycle time of WindowState to be within [<min> .. 110 ms]
Main Part
- 11 -
Comfort close \ Open and comfort close
Open the window
Set KeyDown=1
Wait for 5000 ms
Release key
Set KeyDown=0
Wait for 100 ms
Try the comfort close and check if the window is really closing
Set LockRequest=Comfort_lock, wait for 4000 ms and check WindowMotion==currently_closing
Check if the window stops moving when the car is opened again
Set LockRequest=Request_unlock, wait for 100 ms and check WindowMotion==not_moving
Completion
Reset window state
Set WindowMotion=not_moving, WindowPosition=0
Reset all signals (page 15)
Call ResetSignals ()
3.4 Diagnostics
Variant Dependencies
( Coverage==Full )
Diagnostics for door control unit is tested with window lifter
3.4.1 Ambiguous request KeyUp/KeyDown with engine off
Diagnostics
Call AmbiguousKeyRequest (engineRunning=0) (page 14)
Test Case Attributes
Name Value
Lifecycle ready for review
Note Use test case list instead?
3.4.2 Ambiguous request KeyUp/KeyDown with engine running
Diagnostics
Call AmbiguousKeyRequest (engineRunning=1) (page 14)
Test Case Attributes
Name Value
Lifecycle ready for review
Note Use test case list instead?
- 12 -
Diagnostics
3.4.3 Variant coding
Diagnostics
Test Case Attributes
Name Value
Lifecycle finished
Note
Clear fault memory of SUT in order to get a defined precondition
For SUT clear fault memory
Activate Extended Session
Send service ExtendedDiagnosticSession_Start with request parameters and check response parameters
Write Variant Coding while ECU is locked --> Expected result: Security access denied
Send service Coding_Write with request parameters Codingstring.CountryType=USA,
Codingstring.SpecialAdjustment=0x42 and check response parameters RC==Security access denied
Check whether the corresponding DTC was stored (Variant Coding Illegal Access)
For SUT retrieve DTCs: Check for DTC P000002 with status bits and extended data parameters
Unlock ECU using configured Seed & Key DLL
Unlock diagnostic session for SUT
Clear fault memory again
For SUT clear fault memory
Write Variant Coding while ECU is unlocked (CountryType=USA, SpecialAdjustment=0x77) --> should work
this time
Send service Coding_Write with request parameters Codingstring.CountryType=USA,
Codingstring.SpecialAdjustment=0x77 and check response parameters
Check that the corresponding DTC was not set (Variant Coding Illegal Access)
For SUT retrieve DTCs: Check for Not Allowed DTC P000002 with status bits and extended data parameters
Check if Variant Coding was correctly written (CountryType==USA, SpecialAdjustment==0x77,
VehicleType==Coupe)
Send service Coding_Read with request parameters and check response parameters
Codingstring.CountryType==USA, Codingstring.SpecialAdjustment==0x77,
Codingstring.VehicleType==Coupe
- 13 -
4 Reusable Functions
4.1 AmbiguousKeyRequest
Checks that a corresponding fault memory entry is created when ambiguous values of KeyUp and KeyDown
occur
Parameters
engineRunning
Preparation
Initialize signals
Set KeyDown=0, KeyUp=0
Main Part
Set EngineRunning=engineRunning
Clear fault memory of SUT
For SUT clear fault memory
Concurrently set request KeyUp and KeyDown
Set KeyUp=1, KeyDown=1, wait for 100 ms and check WindowMotion==not_moving
Check that a the corresponding DTC has been created
For SUT check number of DTCs ==1 and check expected available status bits Test Failed=true, Failed Since
Last Clear=true
Reset fault memory
For SUT clear fault memory
Completion
Reset signals
Set KeyDown=0, KeyUp=0
4.2 LockingBehavior
Parameters
engineRunning, isMoving, crash, expectedLockState
Preparation
Initialize all input signals (page 15)
Call ResetSignals ()
Main Part
Set EngineRunning=engineRunning
Set lock state to be locked
Set LockRequest=Request_lock
- 14 -
LockingBehavior
Set velocity if the car is moving
If ( isMoving==1 )
Set Velocity=100
Wait for 200 ms
Apply crash state from the parameter. Check the LockState
Set CrashDetected=crash, wait for 500 ms and check LockState==expectedLockState
Completion
Reset all signals (page 15)
Call ResetSignals ()
4.3 ResetSignals
Resets all input signals of the door lock tests
Reset all signals
Set EngineRunning=0, Velocity=0, CrashDetected=0, LockRequest=idle
No acceleration/deceleration
Set Accelerate=0, Decelerate=0
Wait for 500 ms
- 15 -
5 Curve Checkpoints
5.1 ExpectedLockState
This curve checks whether the door is locked upon exceeding the lock velocity and is not unlocked upon
slowing down.
0 ms: Initialize
Set EngineRunning=1, CrashDetected=0, LockState=currentCheckpointValue, LockRequest=idle
1350 ms: Check doors are 'unlocked'
Check doors are 'unlocked'
Check LockState==currentCheckpointValue
1750 ms: Check doors are 'locked'
Check doors are 'unlocked'
Check LockState==currentCheckpointValue
2150 ms: Check doors are still 'locked'
Check doors are 'unlocked'
Check LockState==currentCheckpointValue
- 16 -