Loading ttcn/DCC/LibItsDcc_Functions.ttcn +54 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,8 @@ module LibItsDcc_Functions { connect(p_utComp:syncPort, self:syncPort); connect(p_itsInDcc:syncPort, self:syncPort); connect(p_itsRrxDcc:syncPort, self:syncPort); connect(p_itsInDcc:checkPort, mtc:checkPort); connect(p_itsRrxDcc:checkPort, mtc:checkPort); //Map map(p_utComp:utPort, system:utPort); Loading @@ -56,6 +58,8 @@ module LibItsDcc_Functions { disconnect(p_utComp:syncPort, self:syncPort); disconnect(p_itsInDcc:syncPort, self:syncPort); disconnect(p_itsRrxDcc:syncPort, self:syncPort); disconnect(p_itsInDcc:checkPort, mtc:checkPort); disconnect(p_itsRrxDcc:checkPort, mtc:checkPort); // Unmap unmap(p_utComp:utPort, system:utPort); Loading Loading @@ -580,4 +584,54 @@ module LibItsDcc_Functions { } // End of function f_iN_AllRequestedFramesSentOn2Channels } // End of group inFunctions group checkFunctions { function f_checkExpectedFrames() runs on ItsDccMts return FncRetCode { var FncRetCode v_ret := e_success; var integer v_framesIn := -1; var integer v_framesRxx := -1; timer t_check := PX_TSYNC_TIME_LIMIT; t_check.start; alt { [v_framesIn==-1] checkPort.receive(integer:?) from vc_itsInDcc -> value v_framesIn { t_check.stop; if (v_framesRxx != -1) { t_check.start; repeat; } } [v_framesRxx==-1] checkPort.receive(integer:?) from vc_itsRrxDcc -> value v_framesRxx { t_check.stop; if (v_framesIn != -1) { t_check.start; repeat; } } [] t_check.timeout { log("**** " & __SCOPE__ & ": Timeout while waiting for number of frames indication ****") ; return e_error; } } if (v_framesIn != v_framesRxx) { v_ret := e_error; } return v_ret; } // End of function f_checkExpectedFrames } // End of group checkFunctions group externalFunction { /** * @desc Returns the string representation of the float value * @param p_float The float value * @return The string representation of the float value */ external function fx_float2str(float p_float) return charstring; } } // End of module LibItsDcc_Functions No newline at end of file ttcn/DCC/LibItsDcc_Pixits.ttcn +25 −4 Original line number Diff line number Diff line Loading @@ -7,6 +7,8 @@ */ module LibItsDcc_Pixits { import from LibItsDcc_TypesAndValues {type ProfileTimeAspects;} group acceptableTransmissionPower { /** * @desc Give an acceptable Transmission power for the CCH in the Relaxed state. Value in dBm. Loading Loading @@ -229,4 +231,23 @@ module LibItsDcc_Pixits { */ modulepar octetstring PIXIT_REFERENCE_BURST; group testcaseDataTables { /** * @desc Give the content of Table 7. * @see ETSI TS 102 917-2 Table 7 */ modulepar ProfileTimeAspects PIXIT_TABLE_7_TC_STS_REL_01_03 := { { 0, 20.0, 50.0 }, { 1, 10.0, 95.0 }, { 2, 10.0, 95.0 }, { 3, 4.0, 250.0 }, { 4, 2.0, 500.0 }, { 5, 1.0, 1000.0 }, { 6, 0.2, 5000.0 }, { 7, 0.1, 10000.0 }, { 8, 0.1, 10000.0 } } } } // End of module LibItsDcc_Pixits No newline at end of file ttcn/DCC/LibItsDcc_TestSystem.ttcn +34 −3 Original line number Diff line number Diff line Loading @@ -45,6 +45,13 @@ module LibItsDcc_TestSystem { in RrxInd; } // End of port InPort /** * @desc Check Port used for intercomponent exchange of data to check */ type port CheckPort message { inout all; } } // end portDefinitions group componentDefinitions { Loading Loading @@ -86,6 +93,7 @@ module LibItsDcc_TestSystem { // IN ports port InPort inPort; port CheckPort checkPort; //timers Loading @@ -103,8 +111,9 @@ module LibItsDcc_TestSystem { */ type component ItsRrxDcc extends ItsBaseComponent { // IN ports // RRX ports port RrxPort rrxPort; port CheckPort checkPort; //timers Loading @@ -117,6 +126,28 @@ module LibItsDcc_TestSystem { } // End of component ItsInDcc /** * @desc Test component for ITS DCC MTC */ type component ItsDccMts extends ItsBaseMtc { // MTC ports port CheckPort checkPort; //timers //component variables var UtComp vc_utComp; var ItsInDcc vc_itsInDcc; var ItsRrxDcc vc_itsRrxDcc; //default var default vc_default := null; //global variables } // End of component ItsDccMts } // End of group componentDefinitions group upperTester { Loading ttcn/DCC/LibItsDcc_TypesAndValues.ttcn +48 −0 Original line number Diff line number Diff line Loading @@ -86,6 +86,54 @@ module LibItsDcc_TypesAndValues { } // End of group subFields group moduleParTables { type integer ProfileType(0..infinity); type record ProfileTimeAspect { ProfileType profile, float messageInterval, //in Hz float tOff //in ms } type record of ProfileTimeAspect ProfileTimeAspects; type record ChannelTimeAspect { ChannelState cchState, float messageInterval, //in Hz float tOff, //in ms record of ChannelState sch1State } type record ProfileChannelTimeAspect { ProfileType profile, ChannelTimeAspect aspects } type record of ProfileChannelTimeAspect ProfileChannelTimeAspects; type record ProfileTimeChannelAspect { ProfileType profile, ChannelTimeAspect aspects } type record of ProfileTimeChannelAspect ProfileTimeChannelAspects; type record ProfileChannelAspect { ProfileType profile, record of record { ChannelState cchState, record of record { ChannelState sch1State, ChannelState sch2State } states } aspects } type record of ProfileChannelAspect ProfileChannelAspects; } group Constants { const integer c_maxCommandReference := 256; Loading Loading
ttcn/DCC/LibItsDcc_Functions.ttcn +54 −0 Original line number Diff line number Diff line Loading @@ -30,6 +30,8 @@ module LibItsDcc_Functions { connect(p_utComp:syncPort, self:syncPort); connect(p_itsInDcc:syncPort, self:syncPort); connect(p_itsRrxDcc:syncPort, self:syncPort); connect(p_itsInDcc:checkPort, mtc:checkPort); connect(p_itsRrxDcc:checkPort, mtc:checkPort); //Map map(p_utComp:utPort, system:utPort); Loading @@ -56,6 +58,8 @@ module LibItsDcc_Functions { disconnect(p_utComp:syncPort, self:syncPort); disconnect(p_itsInDcc:syncPort, self:syncPort); disconnect(p_itsRrxDcc:syncPort, self:syncPort); disconnect(p_itsInDcc:checkPort, mtc:checkPort); disconnect(p_itsRrxDcc:checkPort, mtc:checkPort); // Unmap unmap(p_utComp:utPort, system:utPort); Loading Loading @@ -580,4 +584,54 @@ module LibItsDcc_Functions { } // End of function f_iN_AllRequestedFramesSentOn2Channels } // End of group inFunctions group checkFunctions { function f_checkExpectedFrames() runs on ItsDccMts return FncRetCode { var FncRetCode v_ret := e_success; var integer v_framesIn := -1; var integer v_framesRxx := -1; timer t_check := PX_TSYNC_TIME_LIMIT; t_check.start; alt { [v_framesIn==-1] checkPort.receive(integer:?) from vc_itsInDcc -> value v_framesIn { t_check.stop; if (v_framesRxx != -1) { t_check.start; repeat; } } [v_framesRxx==-1] checkPort.receive(integer:?) from vc_itsRrxDcc -> value v_framesRxx { t_check.stop; if (v_framesIn != -1) { t_check.start; repeat; } } [] t_check.timeout { log("**** " & __SCOPE__ & ": Timeout while waiting for number of frames indication ****") ; return e_error; } } if (v_framesIn != v_framesRxx) { v_ret := e_error; } return v_ret; } // End of function f_checkExpectedFrames } // End of group checkFunctions group externalFunction { /** * @desc Returns the string representation of the float value * @param p_float The float value * @return The string representation of the float value */ external function fx_float2str(float p_float) return charstring; } } // End of module LibItsDcc_Functions No newline at end of file
ttcn/DCC/LibItsDcc_Pixits.ttcn +25 −4 Original line number Diff line number Diff line Loading @@ -7,6 +7,8 @@ */ module LibItsDcc_Pixits { import from LibItsDcc_TypesAndValues {type ProfileTimeAspects;} group acceptableTransmissionPower { /** * @desc Give an acceptable Transmission power for the CCH in the Relaxed state. Value in dBm. Loading Loading @@ -229,4 +231,23 @@ module LibItsDcc_Pixits { */ modulepar octetstring PIXIT_REFERENCE_BURST; group testcaseDataTables { /** * @desc Give the content of Table 7. * @see ETSI TS 102 917-2 Table 7 */ modulepar ProfileTimeAspects PIXIT_TABLE_7_TC_STS_REL_01_03 := { { 0, 20.0, 50.0 }, { 1, 10.0, 95.0 }, { 2, 10.0, 95.0 }, { 3, 4.0, 250.0 }, { 4, 2.0, 500.0 }, { 5, 1.0, 1000.0 }, { 6, 0.2, 5000.0 }, { 7, 0.1, 10000.0 }, { 8, 0.1, 10000.0 } } } } // End of module LibItsDcc_Pixits No newline at end of file
ttcn/DCC/LibItsDcc_TestSystem.ttcn +34 −3 Original line number Diff line number Diff line Loading @@ -45,6 +45,13 @@ module LibItsDcc_TestSystem { in RrxInd; } // End of port InPort /** * @desc Check Port used for intercomponent exchange of data to check */ type port CheckPort message { inout all; } } // end portDefinitions group componentDefinitions { Loading Loading @@ -86,6 +93,7 @@ module LibItsDcc_TestSystem { // IN ports port InPort inPort; port CheckPort checkPort; //timers Loading @@ -103,8 +111,9 @@ module LibItsDcc_TestSystem { */ type component ItsRrxDcc extends ItsBaseComponent { // IN ports // RRX ports port RrxPort rrxPort; port CheckPort checkPort; //timers Loading @@ -117,6 +126,28 @@ module LibItsDcc_TestSystem { } // End of component ItsInDcc /** * @desc Test component for ITS DCC MTC */ type component ItsDccMts extends ItsBaseMtc { // MTC ports port CheckPort checkPort; //timers //component variables var UtComp vc_utComp; var ItsInDcc vc_itsInDcc; var ItsRrxDcc vc_itsRrxDcc; //default var default vc_default := null; //global variables } // End of component ItsDccMts } // End of group componentDefinitions group upperTester { Loading
ttcn/DCC/LibItsDcc_TypesAndValues.ttcn +48 −0 Original line number Diff line number Diff line Loading @@ -86,6 +86,54 @@ module LibItsDcc_TypesAndValues { } // End of group subFields group moduleParTables { type integer ProfileType(0..infinity); type record ProfileTimeAspect { ProfileType profile, float messageInterval, //in Hz float tOff //in ms } type record of ProfileTimeAspect ProfileTimeAspects; type record ChannelTimeAspect { ChannelState cchState, float messageInterval, //in Hz float tOff, //in ms record of ChannelState sch1State } type record ProfileChannelTimeAspect { ProfileType profile, ChannelTimeAspect aspects } type record of ProfileChannelTimeAspect ProfileChannelTimeAspects; type record ProfileTimeChannelAspect { ProfileType profile, ChannelTimeAspect aspects } type record of ProfileTimeChannelAspect ProfileTimeChannelAspects; type record ProfileChannelAspect { ProfileType profile, record of record { ChannelState cchState, record of record { ChannelState sch1State, ChannelState sch2State } states } aspects } type record of ProfileChannelAspect ProfileChannelAspects; } group Constants { const integer c_maxCommandReference := 256; Loading