Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Menu
Open sidebar
TTCN-3 Libraries
LibIts
Commits
ab150139
Commit
ab150139
authored
Sep 10, 2020
by
Yann Garcia
Browse files
Finalizee implementation of SREM Generation TCs
parent
5a7e5d25
Changes
4
Hide whitespace changes
Inline
Side-by-side
ttcn/SremSsem/LibItsSremSsem_Functions.ttcn
View file @
ab150139
...
...
@@ -19,6 +19,7 @@ module LibItsSremSsem_Functions {
// LibIts
import
from
ITS_Container
language
"ASN.1:1997"
all
;
import
from
DSRC
language
"ASN.1:1997"
all
;
import
from
IEEE1609dot2BaseTypes
language
"ASN.1:1997"
all
;
// LibItsCommon
import
from
LibItsCommon_TypesAndValues
all
;
...
...
@@ -26,6 +27,9 @@ module LibItsSremSsem_Functions {
import
from
LibItsCommon_Functions
all
;
import
from
LibItsCommon_Pixits
all
;
// LibItsSecurity
import
from
LibItsSecurity_Functions
all
;
// LibItsSremSsem
import
from
LibItsSremSsem_TestSystem
all
;
import
from
LibItsSremSsem_TypesAndValues
all
;
...
...
@@ -339,10 +343,25 @@ module LibItsSremSsem_Functions {
* @desc Brings the IUT into an initial state.
* @return FncRetCode
*/
function
f_prInitialState
()
runs
on
ItsSremSsem
return
FncRetCode
{
function
f_prInitialState
(
in
charstring
p_certificate_id
:=
""
)
runs
on
ItsSremSsem
return
FncRetCode
{
var
FncRetCode
v_ret
:=
e_success
;
f_utInitializeIut
(
m_sremSsemInitialize
);
// Initialize IUT with given certificate
if
(
p_certificate_id
!=
""
)
{
// Initialize IUT with given certificate
var
HashedId8
v_hashedId8
:=
'0000000000000000'O
;
fx_readCertificateDigest
(
"CERT_SRM_SSP_NONE"
,
v_hashedId8
);
if
(
'0000000000000000'O
==
v_hashedId8
)
{
// Certificate not found
log
(
"*** "
&
testcasename
()
&
": Required IUT certificate is not found on the test system ***"
);
return
e_timeout
;
}
f_utInitializeIut
(
m_sremSsemInitialize
(
v_hashedId8
));
}
else
{
f_utInitializeIut
(
m_sremSsemInitialize
);
}
f_prDefault
();
return
v_ret
;
}
...
...
ttcn/SremSsem/LibItsSremSsem_Pics.ttcn
View file @
ab150139
...
...
@@ -25,7 +25,13 @@ module LibItsSremSsem_Pics {
* @see ETSI TS 103 191-1 Table A.5
*/
modulepar
boolean
PICS_SREM_GENERATION
:=
true
;
/**
* @desc Support for SREM generation
* @see ETSI TS 103 191-1 Table A.5
*/
modulepar
boolean
PICS_SREM_TRANSMISSION_RATE
:=
true
;
/**
* @desc Support for SREM cancelation
* @see ETSI TS 103 191-1 Table A.5
...
...
@@ -55,7 +61,9 @@ module LibItsSremSsem_Pics {
* @see ETSI TS 103 191-1 Table A.5
*/
modulepar
boolean
PICS_SHORT_RANGE
:=
true
;
modulepar
float
PICS_T_GENSREMMIN
:=
0.5
;
/**
* @desc Support for public transport vehicle
* @see ETSI TS 103 191-1 Table TODO
...
...
ttcn/SremSsem/LibItsSremSsem_Pixits.ttcn
View file @
ab150139
...
...
@@ -26,7 +26,7 @@ module LibItsSremSsem_Pixits {
* @desc MsgCount for SREM sending
* @see ETSI TS 103 191-3 Table B.9
*/
modulepar
BasicVehicleRole
PX_BASICVEHICLEROLE
:=
emergency
;
modulepar
BasicVehicleRole
PX_BASICVEHICLEROLE
:=
basicVehicle
;
/**
* @desc Used by tester in SREM trigger request
...
...
@@ -51,4 +51,8 @@ module LibItsSremSsem_Pixits {
id
:=
0
};
modulepar
charstring
PX_SREM_CERTIFICATE_X
:=
"CERT_IUT_SREM_SSP_01"
;
modulepar
octetstring
PX_SREM_CERTIFICATE_X_SSP
:=
'024000'O
;
modulepar
BasicVehicleRole
PX_SREM_CERTIFICATE_X_ROLE
:=
publicTransport
;
}
// end LibItsSremSsem_Pixits
ttcn/SremSsem/LibItsSremSsem_Templates.ttcn
View file @
ab150139
...
...
@@ -21,6 +21,7 @@ module LibItsSremSsem_Templates {
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
;
import
from
IEEE1609dot2BaseTypes
language
"ASN.1:1997"
all
;
// LibItsCommon
import
from
LibItsCommon_TypesAndValues
all
;
...
...
@@ -208,8 +209,10 @@ module LibItsSremSsem_Templates {
* @desc Send template for Upper Tester event initialization
* @member hashedId8 In case of secured mode set, hashedId8 indicate which certificate the IUT shall use
*/
template
(
value
)
UtSremInitialize
m_sremSsemInitialize
:=
{
hashedId8
:=
'0000000000000000'O
template
(
value
)
UtSremInitialize
m_sremSsemInitialize
(
in
HashedId8
p_hashedId8
:=
'0000000000000000'O
)
:=
{
hashedId8
:=
p_hashedId8
}
/**
...
...
@@ -347,9 +350,9 @@ module LibItsSremSsem_Templates {
* @param p_protocolVersion The expected protocol version (Default: current SREM SSEM protocol version)
* @param p_messageID The expected message id (Default: SSEM id)
*/
template
ItsPduHeader
mw_itsPduHeaderSsem
(
template
(
present
)
StationID
p_stationID
:=
?
,
template
(
present
)
ItsPduHeader
.
protocolVersion
p_protocolVersion
:=
LibItsCommon_ASN1_NamedNumbers
.
ItsPduHeader_protocolVersion_currentVersion_
,
template
(
present
)
ItsPduHeader
mw_itsPduHeaderSsem
(
template
(
present
)
StationID
p_stationID
:=
?
,
template
(
present
)
ItsPduHeader
.
protocolVersion
p_protocolVersion
:=
LibItsCommon_ASN1_NamedNumbers
.
ItsPduHeader_protocolVersion_currentVersion_
,
template
(
present
)
ItsPduHeader
.
messageID
p_messageID
:=
LibItsCommon_ASN1_NamedNumbers
.
ItsPduHeader_messageID_ssem_
)
:=
{
protocolVersion
:=
p_protocolVersion
,
...
...
@@ -407,6 +410,17 @@ module LibItsSremSsem_Templates {
regional
:=
omit
}
/**
* @desc Send template for SREM Message
*/
template
(
omit
)
SignalRequestMessage
m_srem
(
in
template
(
value
)
RequestorDescription
p_requestorDescription
,
in
template
(
omit
)
SignalRequestList
p_requests
:=
omit
)
modifies
m_defaultSrem
:=
{
requests
:=
p_requests
,
requestor
:=
p_requestorDescription
}
template
(
value
)
SignalRequestPackage
m_signalRequestPackage
(
in
template
(
value
)
SignalRequest
p_request
)
:=
{
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment