Commit 1ec7c7d7 authored by garciay's avatar garciay
Browse files

Review IVIM, MAPEM/SPATEM and SREM/SSEM

parent a6429f29
......@@ -175,7 +175,7 @@ module LibItsGeoNetworking_Pixits {
* @desc The IUT's upper layer
* @see ETSI TS 102 871-3 Table B.7
*/
modulepar NextHeader PX_GN_UPPER_LAYER := e_btpB;
modulepar NextHeader PX_GN_UPPER_LAYER := e_any;
/**
* @desc Is BTP header present in IUT's UT indication. Only applicable if PX_GN_UPPER_LAYER == e_btpA or e_btpB.
......
......@@ -539,11 +539,11 @@ module LibItsGeoNetworking_Templates {
in template (value) CommonHeader p_commonHeader,
in template (value) ExtendedHeader p_extHeader
) := {
packet := valueof({
commonHeader := p_commonHeader,
extendedHeader := p_extHeader,
packet := {
commonHeader := valueof(p_commonHeader),
extendedHeader := valueof(p_extHeader),
payload := char2oct("DEFAULT_PAYLOAD")
}),
},
securedMsg := omit
}
......@@ -1749,17 +1749,17 @@ module LibItsGeoNetworking_Templates {
in template (value) UInt16 p_seqNumber,
in template (value) GeoBroadcastArea p_broadcastArea
) := {
geoBroadcastHeader := valueof({
seqNumber := p_seqNumber,
geoBroadcastHeader := {
seqNumber := valueof(p_seqNumber),
reserved := c_uInt8Zero,
srcPosVector := p_sourceLongPosVec,
geoAreaPosLatitude := p_broadcastArea.geoBroadcastArea.geoAreaPosLatitude,
geoAreaPosLongitude := p_broadcastArea.geoBroadcastArea.geoAreaPosLongitude,
distanceA := p_broadcastArea.geoBroadcastArea.distanceA,
distanceB := p_broadcastArea.geoBroadcastArea.distanceB,
angle := p_broadcastArea.geoBroadcastArea.angle,
srcPosVector := valueof(p_sourceLongPosVec),
geoAreaPosLatitude := valueof(p_broadcastArea.geoBroadcastArea.geoAreaPosLatitude),
geoAreaPosLongitude := valueof(p_broadcastArea.geoBroadcastArea.geoAreaPosLongitude),
distanceA := valueof(p_broadcastArea.geoBroadcastArea.distanceA),
distanceB := valueof(p_broadcastArea.geoBroadcastArea.distanceB),
angle := valueof(p_broadcastArea.geoBroadcastArea.angle),
reserved2 := c_uInt24Zero
})
}
}
/**
......@@ -1858,17 +1858,17 @@ module LibItsGeoNetworking_Templates {
in template (value) UInt16 p_seqNumber,
in template (value) GeoAnycastArea p_anycastArea
) := {
geoAnycastHeader := valueof({
seqNumber := p_seqNumber,
geoAnycastHeader := {
seqNumber := valueof(p_seqNumber),
reserved := c_uInt8Zero,
srcPosVector := p_sourceLongPosVec,
geoAreaPosLatitude := p_anycastArea.geoAnycastArea.geoAreaPosLatitude,
geoAreaPosLongitude := p_anycastArea.geoAnycastArea.geoAreaPosLongitude,
distanceA := p_anycastArea.geoAnycastArea.distanceA,
distanceB := p_anycastArea.geoAnycastArea.distanceB,
angle := p_anycastArea.geoAnycastArea.angle,
srcPosVector := valueof(p_sourceLongPosVec),
geoAreaPosLatitude := valueof(p_anycastArea.geoAnycastArea.geoAreaPosLatitude),
geoAreaPosLongitude := valueof(p_anycastArea.geoAnycastArea.geoAreaPosLongitude),
distanceA := valueof(p_anycastArea.geoAnycastArea.distanceA),
distanceB := valueof(p_anycastArea.geoAnycastArea.distanceB),
angle := valueof(p_anycastArea.geoAnycastArea.angle),
reserved2 := c_uInt24Zero
})
}
}
/**
......
module LibItsIvim_EncdecDeclarations {
// LibIts
import from IVIM_PDU_Descriptions all;
import from IVIM_PDU_Descriptions language "ASN.1:1997" all;
// LibItsIvim
import from LibItsIvim_TypesAndValues all;
......@@ -29,12 +29,18 @@ module LibItsIvim_EncdecDeclarations {
external function fx_enc_UtIvimInitialize (UtIvimInitialize p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}
external function fx_enc_UtIvimChangePosition (UtIvimChangePosition p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}
/* external function fx_enc_UtIvimChangePosition (UtIvimChangePosition p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}*/
external function fx_enc_UtIvimTrigger (UtIvimTrigger p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}
external function fx_enc_UtIvimUpdate (UtIvimUpdate p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}
external function fx_enc_UtIvimTermination (UtIvimTermination p) return bitstring
with {extension "prototype(convert) encode(UpperTester)"}
external function fx_dec_UtIvimResults (inout bitstring b, out UtIvimResults p) return integer
with {extension "prototype(sliding) decode(UpperTester)"}
......
......@@ -79,7 +79,7 @@ module LibItsIvim_TypesAndValues {
boolean utIvimInitializeResult,
UtIvimTriggerResult utIvimTriggerResult,
UtIvimUpdateResult utIvimUpdateResult,
UtIvimTermination utIvimTerminationResult
boolean utIvimTerminationResult
} with {
variant ""
} // End of type UtIvimResults
......@@ -143,28 +143,8 @@ module LibItsIvim_TypesAndValues {
/**
* @desc Upper Tester result message of termination of an event on Ivim IUT
*/
type boolean UtIvimTerminationResult;
//type boolean UtIvimTerminationResult;
/**
* @desc Upper Tester message to change the position of IUT. Values a relatives
*/
type record UtIvimChangePosition {
Int32 latitude,
Int32 longitude,
Int32 elevation
} with {
variant "FIELDORDER(msb)"
}
/**
* @desc Upper Tester message to change the pseudonym of the DENM IUT
*/
type record UtIvimChangePseudonym {
// empty on purpose
} with {
variant "FIELDORDER(msb)"
}
/**
* @desc Upper Tester message to check event/status on Ivim IUT
*/
......
module LibItsMapemSpatem_EncdecDeclarations {
// LibIts
import from MAPEM_PDU_Descriptions all;
import from SPATEM_PDU_Descriptions all;
import from MAPEM_PDU_Descriptions language "ASN.1:1997" all;
import from SPATEM_PDU_Descriptions language "ASN.1:1997" all;
external function fx_enc_MAPEM (MAPEM pdu) return octetstring
with {extension "prototype(convert) encode(BER:BER_ENCODE_CER)"}
......
......@@ -234,7 +234,7 @@ module LibItsMapemSpatem_Templates {
template (value) MAPEM m_mapemPdu(
in template (value) MapData p_map
) := {
header := m_itsPduHeader( - , - ,ItsPduHeader_messageID_mapem_ ),
header := m_itsPduHeader( - , - ,LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_mapem_ ),
map_ := p_map
}
......@@ -256,7 +256,7 @@ module LibItsMapemSpatem_Templates {
template (value) SPATEM m_spatemPdu(
in template (value) SPAT p_spat
) := {
header := m_itsPduHeader( - , - , ItsPduHeader_messageID_spatem_ ),
header := m_itsPduHeader( - , - , LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_spatem_ ),
spat := p_spat
}
......@@ -283,7 +283,7 @@ module LibItsMapemSpatem_Templates {
*/
template (value) ItsPduHeader m_itsPduHeader(
in template (value) StationID p_stationID := f_getTsStationId(),
in template (value) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
in template (value) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
in template (value) ItsPduHeader.messageID p_messageID
) := {
protocolVersion := p_protocolVersion,
......@@ -299,7 +299,7 @@ module LibItsMapemSpatem_Templates {
*/
template ItsPduHeader mw_itsPduHeader(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ?
) := {
protocolVersion := p_protocolVersion,
......@@ -315,8 +315,8 @@ module LibItsMapemSpatem_Templates {
*/
template ItsPduHeader mw_itsPduHeaderMapem(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ItsPduHeader_messageID_mapem_
template (present) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_mapem_
) := {
protocolVersion := p_protocolVersion,
messageID := p_messageID,
......@@ -331,8 +331,8 @@ module LibItsMapemSpatem_Templates {
*/
template ItsPduHeader mw_itsPduHeaderSpatem(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ItsPduHeader_messageID_spatem_
template (present) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_spatem_
) := {
protocolVersion := p_protocolVersion,
messageID := p_messageID,
......@@ -589,7 +589,8 @@ module LibItsMapemSpatem_Templates {
id := m_intersectionReferenceID, // A globally unique value set, consisting of a regionID and
// intersection ID assignment provides a unique mapping to the intersection MAP in question which provides complete location and approach/move/lane data
revision := PX_INTERSECTIONSTATE_REVISION,
status := IntersectionStatusObject_manualControlIsEnabled_, // General status of the controller(s)
status := LibItsCommon_ASN1_ISDSRC_NamedNumbers.IntersectionStatusObject_manualControlIsEnabled_,
// General status of the controller(s)
moy := omit, // Minute of current UTC year used only with messages to be archived
timeStamp := omit, // The mSec point in the current UTC minute that this message was constructed
enabledLanes := { 1, 2 }, // A list of lanes where the RevocableLane bit has been set which are now active andtherefore part of the current intersection
......
module LibItsSecurity_EncdecDeclarations {
// LibIts
import from IEEE1609dot2BaseTypes language "ASN.1:1997" all;
import from IEEE1609dot2 language "ASN.1:1997" all;
import from EtsiTs103097Module language "ASN.1:1997" all;
import from LibItsSecurity_TypesAndValues all;
/**
* @desc Encoding function for EtsiTs103097Certificate certificate
* @return The encode message in OER format
*/
external function fx_enc_CertificateBase(in IEEE1609dot2.CertificateBase p) return bitstring
with {extension "prototype(convert) encode(PER)"}
//encoding functions
external function fx_enc_SecuredMessage (SecuredMessage p) return bitstring
external function fx_enc_SecuredMessage (LibItsSecurity_TypesAndValues.SecuredMessage p) return bitstring
with {extension "prototype(convert) encode(LibItsSecurity)"}
external function fx_enc_ToBeSignedSecuredMessage (ToBeSignedSecuredMessage p) return bitstring
external function fx_enc_ToBeSignedSecuredMessage (LibItsSecurity_TypesAndValues.ToBeSignedSecuredMessage p) return bitstring
with {extension "prototype(convert) encode(LibItsSecurity)"}
external function fx_enc_Certificate (Certificate p) return bitstring
external function fx_enc_Certificate (LibItsSecurity_TypesAndValues.Certificate p) return bitstring
with {extension "prototype(convert) encode(LibItsSecurity)"}
external function fx_enc_ToBeSignedCertificate (ToBeSignedCertificate p) return bitstring
external function fx_enc_ToBeSignedCertificate (LibItsSecurity_TypesAndValues.ToBeSignedCertificate p) return bitstring
with {extension "prototype(convert) encode(LibItsSecurity)"}
/*
//decoding functions
external function fx_dec_SecuredMessage (inout bitstring b, out SecuredMessage p) return integer
external function fx_dec_SecuredMessage (inout bitstring b, out LibItsSecurity_TypesAndValues.SecuredMessage p) return integer
with {extension "prototype(sliding) decode(LibItsSecurity)"}
external function fx_dec_ToBeSignedSecuredMessage (inout bitstring b, out ToBeSignedSecuredMessage p) return integer
external function fx_dec_ToBeSignedSecuredMessage (inout bitstring b, out LibItsSecurity_TypesAndValues.ToBeSignedSecuredMessage p) return integer
with {extension "prototype(sliding) decode(LibItsSecurity)"}
*/
external function fx_dec_Certificate (inout bitstring b, out Certificate p) return integer
external function fx_dec_Certificate (inout bitstring b, out LibItsSecurity_TypesAndValues.Certificate p) return integer
with {extension "prototype(sliding) decode(LibItsSecurity)"}
/*
external function fx_dec_ToBeSignedCertificate (inout bitstring b, out ToBeSignedCertificate p) return integer
external function fx_dec_ToBeSignedCertificate (inout bitstring b, out LibItsSecurity_TypesAndValues.ToBeSignedCertificate p) return integer
with {extension "prototype(sliding) decode(LibItsSecurity)"}
*/
} // End of module LibItsSecurity_EncdecDeclarations
module LibItsSremSsem_EncdecDeclarations {
import from DSRC all;
import from DSRC language "ASN.1:1997" all;
external function fx_enc_SSM (SignalStatusMessage p) return octetstring
with {extension "prototype(convert) encode(BER:BER_ENCODE_CER)"}
......
......@@ -246,7 +246,7 @@ module LibItsSremSsem_Templates {
template (value) SREM m_sremPdu(
in template (value) SignalRequestMessage p_srm
) := {
header := m_itsPduHeader( - , - ,ItsPduHeader_messageID_srem_ ),
header := m_itsPduHeader( - , - ,LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_srem_ ),
srm := p_srm
}
......@@ -268,7 +268,7 @@ module LibItsSremSsem_Templates {
template (value) SSEM m_ssemPdu(
in template (value) SignalStatusMessage p_ssm
) := {
header := m_itsPduHeader( - , - , ItsPduHeader_messageID_ssem_),
header := m_itsPduHeader( - , - , LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_ssem_),
ssm := p_ssm
}
......@@ -295,7 +295,7 @@ module LibItsSremSsem_Templates {
*/
template (value) ItsPduHeader m_itsPduHeader(
in template (value) StationID p_stationID := f_getTsStationId(),
in template (value) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
in template (value) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
in template (value) ItsPduHeader.messageID p_messageID
) := {
protocolVersion := p_protocolVersion,
......@@ -311,7 +311,7 @@ module LibItsSremSsem_Templates {
*/
template ItsPduHeader mw_itsPduHeader(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ?
) := {
protocolVersion := p_protocolVersion,
......@@ -327,8 +327,8 @@ module LibItsSremSsem_Templates {
*/
template ItsPduHeader mw_itsPduHeaderSrem(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ItsPduHeader_messageID_srem_
template (present) ItsPduHeader.protocolVersion p_protocolVersion := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := LibItsCommon_ASN1_NamedNumbers.ItsPduHeader_messageID_srem_
) := {
protocolVersion := p_protocolVersion,
messageID := p_messageID,
......@@ -343,8 +343,8 @@ module LibItsSremSsem_Templates {
*/
template ItsPduHeader mw_itsPduHeaderSsem(
template (present) StationID p_stationID := ?,
template (present) ItsPduHeader.protocolVersion p_protocolVersion := ItsPduHeader_protocolVersion_currentVersion_,
template (present) ItsPduHeader.messageID p_messageID := ItsPduHeader_messageID_ssem_
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,
messageID := p_messageID,
......
Supports Markdown
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