Commit 5a7e5d25 authored by Yann Garcia's avatar Yann Garcia
Browse files

Update implementation of TCs for TLC

parent 4bec9668
......@@ -125,6 +125,36 @@ module LibItsSremSsem_Functions {
return;
}
/**
* @desc Updates an event from the application layer
* @param p_event The event to trigger.
*/
function f_utCancelationEvent(
in template (value) UtSremCancelation p_event
) runs on ItsSremSsem {
utPort.send ( p_event );
tc_wait.start;
alt {
[] utPort.receive ( UtSremResults: { utSremCancelationResult := true }) {
tc_wait.stop;
}
[] utPort.receive ( UtSremResults: { utSremCancelationResult := false }) {
tc_wait.stop;
f_selfOrClientSyncAndVerdict("SREM cancelation failed", e_error);
}
[] tc_wait.timeout {
log("*** " & testcasename() & ": INFO: Could not receive expected UT message from IUT in time ***");
f_selfOrClientSyncAndVerdict("error", e_timeout);
}
}
//activate sremSsemPort default alts
vc_sremSsemDefaultActive := true;
return;
}
} // End of group utFuntions
group adapterControl {
......@@ -333,7 +363,7 @@ module LibItsSremSsem_Functions {
group sendFunctions {
/**
* @desc Sends a IVI message
* @desc Sends a SSEM message
* @param p_sendMsg The IVI message to send.
* @param p_overrideSeqNo Overrides the sequence number with the stored one.
*/
......
......@@ -26,6 +26,12 @@ module LibItsSremSsem_Pics {
*/
modulepar boolean PICS_SREM_GENERATION := true;
/**
* @desc Support for SREM cancelation
* @see ETSI TS 103 191-1 Table A.5
*/
modulepar boolean PICS_SREM_CANCELATION := true;
/**
* @desc Support for SREM reception
* @see ETSI TS 103 191-1 Table A.5
......@@ -44,6 +50,12 @@ module LibItsSremSsem_Pics {
*/
modulepar boolean PICS_SSEM_RECEPTION := true;
/**
* @desc Support for Short Range communication
* @see ETSI TS 103 191-1 Table A.5
*/
modulepar boolean PICS_SHORT_RANGE := true;
/**
* @desc Support for public transport vehicle
* @see ETSI TS 103 191-1 Table TODO
......
......@@ -17,6 +17,7 @@ module LibItsSremSsem_Pixits {
// LibIts
import from DSRC language "ASN.1:1997" all;
import from DSRC_REGION_noCircular language "ASN.1:1997" all;
// LibItsSremSsem
import from LibItsSremSsem_TypesAndValues all;
......@@ -31,7 +32,9 @@ module LibItsSremSsem_Pixits {
* @desc Used by tester in SREM trigger request
* @see ETSI TS 103 191-3 Table B.9
*/
modulepar RequestImportanceLevel PX_REQUESTIMPORTANCELEVEL := requestImportanceLevel13;
modulepar RequestImportanceLevel PX_REQUESTIMPORTANCELEVEL := requestImportanceLevel3;
modulepar IntersectionID PX_INTERSECTION_ID := 123;
/**
* @desc Used by tester in SREM trigger request
......
......@@ -110,7 +110,7 @@ module LibItsSremSsem_Templates {
*/
template (present) SremInd mw_sremIndWithSecurityParameters(
template (present) SREM p_sremMsg,
template Bit256 p_ssp := *,
template Bit24 p_ssp := *,
template UInt32 p_its_aid := *
) modifies mw_sremInd := {
ssp := p_ssp,
......@@ -193,7 +193,7 @@ module LibItsSremSsem_Templates {
*/
template (present) SsemInd mw_ssemIndWithSecurityParameters(
template (present) SSEM p_ssemMsg,
template Bit256 p_ssp := *,
template Bit24 p_ssp := *,
template UInt32 p_its_aid := *
) modifies mw_ssemInd := {
ssp := p_ssp,
......@@ -217,10 +217,12 @@ module LibItsSremSsem_Templates {
*/
template (value) UtSremTrigger m_utTriggerEvent(
in template (value) BasicVehicleRole p_basicVehicleRole,
in template (value) RequestImportanceLevel p_requestImportanceLevel
in template (value) RequestImportanceLevel p_requestImportanceLevel,
in template (value) IntersectionID p_intersectionId
) := {
basicVehicleRole := p_basicVehicleRole,
requestImportanceLevel := p_requestImportanceLevel
requestImportanceLevel := p_requestImportanceLevel,
intersectionId := p_intersectionId
}
template (value) UtSremUpdate m_utUpdateEvent(
......@@ -233,6 +235,12 @@ module LibItsSremSsem_Templates {
requestImportanceLevel := p_requestImportanceLevel
}
template (value) UtSremCancelation m_UtSremCancelationEvent(
in template (value) RequestID p_requestID
) := {
requestID := p_requestID
}
}
group sremSsemPduTemplates {
......@@ -366,6 +374,14 @@ module LibItsSremSsem_Templates {
id := p_intersectionID // a unique mapping to the intersection in question within the above region of use
}
template IntersectionReferenceID mw_intersectionReferenceID(
template (present) IntersectionID p_intersectionID := ?,
template RoadRegulatorID p_roadRegulatorID := *
) := {
region := p_roadRegulatorID, // a globally unique regional assignment value typical assigned to a regional DOT authority the value zero shall be used for testing needs
id := p_intersectionID // a unique mapping to the intersection in question within the above region of use
}
group sremTemplates {
group sremTemplatesSend {
......@@ -474,63 +490,85 @@ module LibItsSremSsem_Templates {
*/
template (present) SignalRequestMessage mw_sremWellFormatted(
template (present) RequestorDescription p_requestor := ?,
template (present) SignalRequestList p_requests := ?,
template (present) MsgCount p_sequenceNumber := ?,
template MinuteOfTheYear p_timeStamp := *,
template DSecond p_second := *
) modifies mw_defaultSrem := {
timeStamp := p_timeStamp,
second := p_second,
requestor := p_requestor
timeStamp := p_timeStamp,
second := p_second,
sequenceNumber := p_sequenceNumber,
requests := p_requests,
requestor := p_requestor
} // End of template mw_sremWellFormatted
template (present) SignalRequestMessage mw_srem_sequenceNumber(
template (present) MsgCount p_sequenceNumber := ?
)
modifies mw_defaultSrem := {
sequenceNumber := p_sequenceNumber
} // End of template mw_srem_sequenceNumber
template (present) SignalRequestPackage mw_signalRequestPackage(
template (present) SignalRequest p_request := ?
) := {
request := p_request,
minute := *,
second := *,
duration := *,
regional := *
}
template SignalRequest mw_signalRequest(
template (present) IntersectionReferenceID p_id := ?,
template (present) RequestID p_requestID := ?,
template (present) PriorityRequestType p_requestType := priorityRequest,
template (present) IntersectionAccessPoint p_inBoundLane := ?,
template IntersectionAccessPoint p_outBoundLane := *
) := {
id := p_id,
requestID := p_requestID,
requestType := p_requestType,
inBoundLane := p_inBoundLane,
outBoundLane := p_outBoundLane,
regional := *
}
template (present) RequestorDescription mw_requestorDescription(
template (present) VehicleID p_id := ?,
template RequestorType p_type := *,
template RequestorPositionVector p_position := *,
template TransitVehicleStatus p_transitStatus := *,
template TransitVehicleOccupancy p_transitOccupancy := *,
template DeltaTime p_transitSchedule := *
) := {
id := p_id, // The ID used in the BSM or CAM of the requestor
type_ := p_type, // Information regarding all type and class data about the requesting vehicle
position := p_position, // The location of the requesting vehicle
name := *, // A human readable name for debugging use
routeName := *, // A string for transit operations use
transitStatus := p_transitStatus, // current vehicle state (loading, etc.)
transitOccupancy := p_transitOccupancy, // current vehicle occupancy
transitSchedule := p_transitSchedule, // current vehicle schedule adherence
regional := *
} // End of template mw_requestorDescription
template (present) RequestorPositionVector mw_requestor_position(
template (present) Position3D p_position := ?
) := {
position := p_position,
heading := *,
speed := *
} // End of template mw_requestor_position
template RequestorType mw_requestorType(
template (present) BasicVehicleRole p_role := ?,
template RequestSubRole p_subrole := *,
template RequestImportanceLevel p_request := *
) := {
role := p_role, // Basic role of this user at this time
subrole := p_subrole, // A local list with role based items
request := p_request, // A local list with request items
iso3883 := *,
hpmsType := *, // HPMS classification types
regional := *
} // End of template mw_requestorType
} // End of group sremTemplatesRecv
template (present) RequestorDescription mw_requestorDescription(
template (present) VehicleID p_id := ?,
template RequestorType p_type := *,
template RequestorPositionVector p_position := *,
template TransitVehicleStatus p_transitStatus := *,
template TransitVehicleOccupancy p_transitOccupancy := *,
template DeltaTime p_transitSchedule := *
) := {
id := p_id, // The ID used in the BSM or CAM of the requestor
type_ := p_type, // Information regarding all type and class data about the requesting vehicle
position := p_position, // The location of the requesting vehicle
name := *, // A human readable name for debugging use
routeName := *, // A string for transit operations use
transitStatus := p_transitStatus, // current vehicle state (loading, etc.)
transitOccupancy := p_transitOccupancy, // current vehicle occupancy
transitSchedule := p_transitSchedule, // current vehicle schedule adherence
regional := *
} // End of template mw_requestorDescription
template (present) RequestorPositionVector mw_requestor_position(
template (present) Position3D p_position := ?
) := {
position := p_position,
heading := *,
speed := *
} // End of template mw_requestor_position
template RequestorType mw_requestorType(
template (present) BasicVehicleRole p_role := ?,
template RequestSubRole p_subrole := *,
template RequestImportanceLevel p_request := *
) := {
role := p_role, // Basic role of this user at this time
subrole := p_subrole, // A local list with role based items
request := p_request, // A local list with request items
iso3883 := *,
hpmsType := *, // HPMS classification types
regional := *
} // End of template mw_requestorType
} // End of group sremTemplates
group ssemTemplates {
......
......@@ -47,7 +47,7 @@ module LibItsSremSsem_TestSystem {
*/
type port UpperTesterPort message {
out
UtSremInitialize, UtSremTrigger, UtSremUpdate;
UtSremInitialize, UtSremTrigger, UtSremUpdate, UtSremCancelation;
in
UtSremResults, UtSremEventInd , UtSsemEventInd;
} // end UpperTesterPort
......@@ -111,7 +111,7 @@ module LibItsSremSsem_TestSystem {
UInt8 gnTrafficClass optional,
UInt16 btpDestinationPort optional,
UInt16 btpInfo optional,
Bit256 ssp optional,
Bit24 ssp optional,
UInt32 its_aid optional
}
with {
......@@ -129,7 +129,7 @@ module LibItsSremSsem_TestSystem {
UInt8 gnTrafficClass optional,
UInt16 btpDestinationPort optional,
UInt16 btpInfo optional,
Bit256 ssp optional,
Bit24 ssp optional,
UInt32 its_aid optional
}
with {
......
......@@ -20,6 +20,7 @@ module LibItsSremSsem_TypesAndValues {
import from SREM_PDU_Descriptions language "ASN.1:1997" all;
import from SSEM_PDU_Descriptions language "ASN.1:1997" all;
import from DSRC language "ASN.1:1997" all;
import from DSRC_REGION_noCircular language "ASN.1:1997" all;
// LibItsCommon
import from LibItsCommon_TypesAndValues all;
......@@ -38,15 +39,16 @@ module LibItsSremSsem_TypesAndValues {
/**
* @desc Upper Tester results message of the Srem/Ssem IUT
* @member utSremInitialize -
* @member utSremTriggerResult -
* @member utAutoInteropTriggerResult -
* @member utSremChangePositionResult -
* @member utSremInitialize
* @member utSremTriggerResult
* @member utSremUpdateResult
* @member utSremCancelationResult
*/
type union UtSremResults {
boolean utSremInitializeResult,
boolean utSremTriggerResult,
boolean utSremUpdateResult
boolean utSremUpdateResult,
boolean utSremCancelationResult
} with {
variant ""
} // End of type UtSremResults
......@@ -56,7 +58,8 @@ module LibItsSremSsem_TypesAndValues {
*/
type record UtSremTrigger {
BasicVehicleRole basicVehicleRole,
RequestImportanceLevel requestImportanceLevel
RequestImportanceLevel requestImportanceLevel,
IntersectionID intersectionId
} with {
variant "FIELDORDER(msb)"
}
......@@ -74,6 +77,15 @@ module LibItsSremSsem_TypesAndValues {
variant "FIELDORDER(msb)"
}
/**
* @desc Upper Tester message to request cancelation of an event at IUT
*/
type record UtSremCancelation {
RequestID requestID
} with {
variant "FIELDORDER(msb)"
}
/**
* @desc Upper Tester message to check event/status at IUT
*/
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment