Loading ttcn/dPMR_Defaults.ttcn +9 −8 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ module dPMR_Defaults { import from dPMR_Types all; import from dPMR_Values all; //TODO JP description altstep a_dftUt() runs on Ut{ []syncPort.receive(m_syncServerStop){ Loading @@ -29,11 +29,12 @@ module dPMR_Defaults { log("a_dftUt: TEST COMPONENT NOW STOPPING ITSELF!"); stop; } []utPort.receive(e_error){ setverdict(inconc); log("*** a_dftUt: Unexpected error message received on upper tester ***"); repeat; } //TODO JP update //[]utPort.receive(e_error){ // setverdict(inconc); // log("*** a_dftUt: Unexpected error message received on upper tester ***"); // repeat; //} []utPort.receive{ setverdict(inconc); log("*** a_dftUt: Unexpected message received on upper tester ***"); Loading @@ -45,8 +46,8 @@ module dPMR_Defaults { altstep a_dftSimu() runs on Simu{ altstep a_dftMse() runs on Mse{ []syncPort.receive(m_syncServerStop){ log("a_dftSimu: Test component received STOP signal from MTC - going to IDLE state"); log("a_dftSimu: TEST COMPONENT NOW STOPPING ITSELF!"); Loading ttcn/dPMR_ExtFunctions.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -16,7 +16,7 @@ module dPMR_ExtFunctions { //Ats import from dPMR_Types all; //TODO JP add @param @remark clause /* * @desc: fx_calcDialString calculates and returns the dialstring Loading ttcn/dPMR_Functions.ttcn +74 −91 Original line number Diff line number Diff line Loading @@ -30,9 +30,9 @@ * @desc Init the Mse */ function f_initMse() runs on Simu { runs on Mse{ vc_mse.useAllCallCommonId := e_noAllCall; vc_mse.iutId := f_createMsAddress(true /* its IUT */); vc_mse.iutId := f_createMsAddress(true /* its IUT */);//TODO JPcleanup vc_mse.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_mse.iutIdUP := f_msAddress2Upper(vc_mse.iutId); vc_mse.iutIdLP := f_msAddress2Lower(vc_mse.iutId); Loading @@ -41,8 +41,10 @@ }//end f_initMse //TODO JP desc //TODO JP do nto forget the parameter itself p_useAllCallCommonId function f_initMse_isfAllCall(UseAllCallCommonId p_useAllCallCommonId) runs on Simu { runs on Mse{ vc_mse.useAllCallCommonId := p_useAllCallCommonId; vc_mse.iutId := f_createMsAddress(true /* its IUT */); Loading @@ -52,8 +54,37 @@ vc_mse.testerIdUP := f_msAddress2Upper(vc_mse.testerId); vc_mse.testerIdLP := f_msAddress2Lower(vc_mse.testerId); }//end f_initMse }//end f_initMse_isfAllCall /* * @desc Init the Upper Tester */ function f_initUt() runs on Ut{ vc_ut.useAllCallCommonId := e_noAllCall; vc_ut.iutId := f_createMsAddress(true /* its IUT */);//TODO JPcleanup vc_ut.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_ut.iutIdUP := f_msAddress2Upper(vc_ut.iutId); vc_ut.iutIdLP := f_msAddress2Lower(vc_ut.iutId); vc_ut.testerIdUP := f_msAddress2Upper(vc_ut.testerId); vc_ut.testerIdLP := f_msAddress2Lower(vc_ut.testerId); }//end f_initUt //TODO JP desc //TODO JP do nto forget the parameter itself p_useAllCallCommonId function f_initUt_isfAllCall(UseAllCallCommonId p_useAllCallCommonId) runs on Ut{ vc_ut.useAllCallCommonId := p_useAllCallCommonId; vc_ut.iutId := f_createMsAddress(true /* its IUT */); vc_ut.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_ut.iutIdUP := f_msAddress2Upper(vc_ut.iutId); vc_ut.iutIdLP := f_msAddress2Lower(vc_ut.iutId); vc_ut.testerIdUP := f_msAddress2Upper(vc_ut.testerId); vc_ut.testerIdLP := f_msAddress2Lower(vc_ut.testerId); }//end f_initUt_isfAllCall }//end initFunctions Loading @@ -66,11 +97,13 @@ * @param p_cc is the CoulourCode used */ function f_msConfigureRx(ColourCode p_cc) runs on Simu runs on Mse return FncRetCode { var FncRetCode v_ret := e_success; if (PIC_ISF_OR_CSF == e_isf) { v_ret := f_msConfig_Ut( m_msCfgParamsIsfPoliteRx( p_cc, int2bit(PXT_APPLICABLE_COMMON_ID,8)), v_ret); //TODO JP wrogn , CSF needs to be configured as well // get rid of f_msConfigureRx/Tx and just use f_utsHandshake_Ut v_ret := f_handshake_Ut( m_msCfgParamsIsfRx( p_cc, int2bit(PXT_APPLICABLE_COMMON_ID,8))); } return v_ret; }//end f_msConfigureRx Loading @@ -84,13 +117,13 @@ * @param p_callType is the CallType used */ function f_msConfigureTx(ColourCode p_cc, PoliteLvl p_politeLvl, CallType p_callType) runs on Simu runs on Mse return FncRetCode { var FncRetCode v_ret := e_success; if (PIC_ISF_OR_CSF == e_isf) { v_ret := f_iutMsTxInit_Ut(m_msCfgParamsIsfPoliteTx(p_cc, p_politeLvl, p_callType, int2bit(PXT_APPLICABLE_COMMON_ID,8)), v_ret); } v_ret := f_handshake_Ut(m_msCfgParamsIsfPoliteTx(p_cc, p_politeLvl, p_callType, int2bit(PXT_APPLICABLE_COMMON_ID,8))); } else { v_ret := f_iutMsTxInit_Ut(m_msCfgParamsCsfPoliteTx(p_cc, p_politeLvl, p_callType, fx_calcDialString(PXT_CSF_ADDRESS_TESTER)), v_ret); v_ret := f_handshake_Ut(m_msCfgParamsCsfPoliteTx(p_cc, p_politeLvl, p_callType, fx_calcDialString(PXT_CSF_ADDRESS_TESTER))); } return v_ret; }//end f_msConfigureTx Loading @@ -100,85 +133,37 @@ * @param p_msCfgParams MS config parameters * @param p_ret the return code */ function f_msConfig_Ut( template MsCfgParams p_msCfgParams , FncRetCode p_ret ) function f_handshake_Ut( template UtRequest p_utRequest) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msCfgParams); tc_maxTimeCfgActRly.start; alt{ []utPort.receive(m_success){ setverdict(pass); tc_maxTimeCfgActRly.stop; return e_success; } []utPort.receive(m_noSuccess){ setverdict(fail); tc_maxTimeCfgActRly.stop; log("*** f_msConfig_Ut: Error message received on upper tester ***"); } []tc_maxTimeCfgActRly.timeout{ setverdict(fail); log("*** f_msConfig_Ut: timeout of configuration or action ***"); } } return e_error; } // end f_msConfig_Ut } //end configFunctions /* * @desc f_iutMsTxInit_Ut is used to prepare the MS for transmission and * sets the following parameters * @param p_msCfgParams MS config parameters * @param p_ret the return code */ function f_iutMsTxInit_Ut(template MsCfgParams p_msCfgParams, FncRetCode p_ret) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msCfgParams); utPort.send(p_utRequest); tc_maxTimeCfgActRly.start; alt{ []utPort.receive(e_success){ setverdict(pass); []utPort.receive(mw_utsCfn_success){ tc_maxTimeCfgActRly.stop; setverdict(pass); return e_success; } []utPort.receive(e_error){ setverdict(fail); []utPort.receive(mw_utsCfn_noSuccess){ tc_maxTimeCfgActRly.stop; log("*** f_iutMsInit_Ut: Error message received on upper tester ***"); log("*** f_handshake_Ut: Error message received on upper tester ***"); setverdict(fail); return e_error; } []tc_maxTimeCfgActRly.timeout{ log("*** f_handshake_Ut: timeout of configuration or action ***"); setverdict(fail); log("*** f_iutMsInit_Ut: timeout of configuration or action ***"); return e_error; } } return e_error; } //end f_iutMsTxInit_Ut } // end f_handshake_Ut } //end configFunctions /* * @desc: f_iutMsAction_Ut is used to ask IUT ms to do following actions * Action Type:= PressPtt, DekeyPtt, * @param p_msActParams MS config parameters * @param p_ret the return code */ function f_iutMsAction_Ut(template MsActParams p_msActParams, FncRetCode p_ret) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msActParams); return e_success; } //end f_iutMsAction_Ut group converterFunctions { /* * @desc f_getCommonId returns the Common ID from an ISF address. Loading @@ -196,13 +181,11 @@ } } // end f_getCommonId group converterFunctions { /* * @desc f_getColourCode returns the Colour Code for ISF or CSF */ function f_getColourCode () runs on Simu runs on Mse return ColourCode { var ColourCode v_cc; Loading Loading @@ -254,7 +237,7 @@ * @remark This function should perhaps be rewritten (split) , and the enumerated type UseAllCallCommonId removed */ function f_createMsAddress( boolean p_testingEntityIsIUT) runs on Simu runs on Mse return MsAddress { var MsAddress v_retAdr; if (PIC_ISF_OR_CSF == e_isf) { Loading Loading @@ -285,7 +268,7 @@ * @remark This function should perhaps be rewritten (split) , and the enumerated type UseAllCallCommonId removed */ function f_getCsfAddress (boolean p_testingEntityIsIUT) runs on Simu runs on Mse return CSFAddress { var CSFAddress v_ret; if (p_testingEntityIsIUT) { Loading ttcn/dPMR_Pics.ttcn +0 −6 Original line number Diff line number Diff line Loading @@ -17,9 +17,6 @@ module dPMR_Pics { import from dPMR_TestConfiguration all; /* * @desc Is the IUT an ISF or CSF entity? * @remark see PICS, Table A.1/1. Loading @@ -27,7 +24,4 @@ module dPMR_Pics { modulepar {Entity PIC_ISF_OR_CSF := e_isf} } // end module dPMR_PICS No newline at end of file ttcn/dPMR_Pixits.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,7 @@ module dPMR_Pixits { */ modulepar {CsfChannelNr PXT_CSF_CHANNEL_NR := e_csfChannelNr_0 } ////TODO JP add clauses + make groups /* Loading Loading
ttcn/dPMR_Defaults.ttcn +9 −8 Original line number Diff line number Diff line Loading @@ -21,7 +21,7 @@ module dPMR_Defaults { import from dPMR_Types all; import from dPMR_Values all; //TODO JP description altstep a_dftUt() runs on Ut{ []syncPort.receive(m_syncServerStop){ Loading @@ -29,11 +29,12 @@ module dPMR_Defaults { log("a_dftUt: TEST COMPONENT NOW STOPPING ITSELF!"); stop; } []utPort.receive(e_error){ setverdict(inconc); log("*** a_dftUt: Unexpected error message received on upper tester ***"); repeat; } //TODO JP update //[]utPort.receive(e_error){ // setverdict(inconc); // log("*** a_dftUt: Unexpected error message received on upper tester ***"); // repeat; //} []utPort.receive{ setverdict(inconc); log("*** a_dftUt: Unexpected message received on upper tester ***"); Loading @@ -45,8 +46,8 @@ module dPMR_Defaults { altstep a_dftSimu() runs on Simu{ altstep a_dftMse() runs on Mse{ []syncPort.receive(m_syncServerStop){ log("a_dftSimu: Test component received STOP signal from MTC - going to IDLE state"); log("a_dftSimu: TEST COMPONENT NOW STOPPING ITSELF!"); Loading
ttcn/dPMR_ExtFunctions.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -16,7 +16,7 @@ module dPMR_ExtFunctions { //Ats import from dPMR_Types all; //TODO JP add @param @remark clause /* * @desc: fx_calcDialString calculates and returns the dialstring Loading
ttcn/dPMR_Functions.ttcn +74 −91 Original line number Diff line number Diff line Loading @@ -30,9 +30,9 @@ * @desc Init the Mse */ function f_initMse() runs on Simu { runs on Mse{ vc_mse.useAllCallCommonId := e_noAllCall; vc_mse.iutId := f_createMsAddress(true /* its IUT */); vc_mse.iutId := f_createMsAddress(true /* its IUT */);//TODO JPcleanup vc_mse.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_mse.iutIdUP := f_msAddress2Upper(vc_mse.iutId); vc_mse.iutIdLP := f_msAddress2Lower(vc_mse.iutId); Loading @@ -41,8 +41,10 @@ }//end f_initMse //TODO JP desc //TODO JP do nto forget the parameter itself p_useAllCallCommonId function f_initMse_isfAllCall(UseAllCallCommonId p_useAllCallCommonId) runs on Simu { runs on Mse{ vc_mse.useAllCallCommonId := p_useAllCallCommonId; vc_mse.iutId := f_createMsAddress(true /* its IUT */); Loading @@ -52,8 +54,37 @@ vc_mse.testerIdUP := f_msAddress2Upper(vc_mse.testerId); vc_mse.testerIdLP := f_msAddress2Lower(vc_mse.testerId); }//end f_initMse }//end f_initMse_isfAllCall /* * @desc Init the Upper Tester */ function f_initUt() runs on Ut{ vc_ut.useAllCallCommonId := e_noAllCall; vc_ut.iutId := f_createMsAddress(true /* its IUT */);//TODO JPcleanup vc_ut.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_ut.iutIdUP := f_msAddress2Upper(vc_ut.iutId); vc_ut.iutIdLP := f_msAddress2Lower(vc_ut.iutId); vc_ut.testerIdUP := f_msAddress2Upper(vc_ut.testerId); vc_ut.testerIdLP := f_msAddress2Lower(vc_ut.testerId); }//end f_initUt //TODO JP desc //TODO JP do nto forget the parameter itself p_useAllCallCommonId function f_initUt_isfAllCall(UseAllCallCommonId p_useAllCallCommonId) runs on Ut{ vc_ut.useAllCallCommonId := p_useAllCallCommonId; vc_ut.iutId := f_createMsAddress(true /* its IUT */); vc_ut.testerId := f_createMsAddress(false /* its not IUT (its Tester) */); vc_ut.iutIdUP := f_msAddress2Upper(vc_ut.iutId); vc_ut.iutIdLP := f_msAddress2Lower(vc_ut.iutId); vc_ut.testerIdUP := f_msAddress2Upper(vc_ut.testerId); vc_ut.testerIdLP := f_msAddress2Lower(vc_ut.testerId); }//end f_initUt_isfAllCall }//end initFunctions Loading @@ -66,11 +97,13 @@ * @param p_cc is the CoulourCode used */ function f_msConfigureRx(ColourCode p_cc) runs on Simu runs on Mse return FncRetCode { var FncRetCode v_ret := e_success; if (PIC_ISF_OR_CSF == e_isf) { v_ret := f_msConfig_Ut( m_msCfgParamsIsfPoliteRx( p_cc, int2bit(PXT_APPLICABLE_COMMON_ID,8)), v_ret); //TODO JP wrogn , CSF needs to be configured as well // get rid of f_msConfigureRx/Tx and just use f_utsHandshake_Ut v_ret := f_handshake_Ut( m_msCfgParamsIsfRx( p_cc, int2bit(PXT_APPLICABLE_COMMON_ID,8))); } return v_ret; }//end f_msConfigureRx Loading @@ -84,13 +117,13 @@ * @param p_callType is the CallType used */ function f_msConfigureTx(ColourCode p_cc, PoliteLvl p_politeLvl, CallType p_callType) runs on Simu runs on Mse return FncRetCode { var FncRetCode v_ret := e_success; if (PIC_ISF_OR_CSF == e_isf) { v_ret := f_iutMsTxInit_Ut(m_msCfgParamsIsfPoliteTx(p_cc, p_politeLvl, p_callType, int2bit(PXT_APPLICABLE_COMMON_ID,8)), v_ret); } v_ret := f_handshake_Ut(m_msCfgParamsIsfPoliteTx(p_cc, p_politeLvl, p_callType, int2bit(PXT_APPLICABLE_COMMON_ID,8))); } else { v_ret := f_iutMsTxInit_Ut(m_msCfgParamsCsfPoliteTx(p_cc, p_politeLvl, p_callType, fx_calcDialString(PXT_CSF_ADDRESS_TESTER)), v_ret); v_ret := f_handshake_Ut(m_msCfgParamsCsfPoliteTx(p_cc, p_politeLvl, p_callType, fx_calcDialString(PXT_CSF_ADDRESS_TESTER))); } return v_ret; }//end f_msConfigureTx Loading @@ -100,85 +133,37 @@ * @param p_msCfgParams MS config parameters * @param p_ret the return code */ function f_msConfig_Ut( template MsCfgParams p_msCfgParams , FncRetCode p_ret ) function f_handshake_Ut( template UtRequest p_utRequest) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msCfgParams); tc_maxTimeCfgActRly.start; alt{ []utPort.receive(m_success){ setverdict(pass); tc_maxTimeCfgActRly.stop; return e_success; } []utPort.receive(m_noSuccess){ setverdict(fail); tc_maxTimeCfgActRly.stop; log("*** f_msConfig_Ut: Error message received on upper tester ***"); } []tc_maxTimeCfgActRly.timeout{ setverdict(fail); log("*** f_msConfig_Ut: timeout of configuration or action ***"); } } return e_error; } // end f_msConfig_Ut } //end configFunctions /* * @desc f_iutMsTxInit_Ut is used to prepare the MS for transmission and * sets the following parameters * @param p_msCfgParams MS config parameters * @param p_ret the return code */ function f_iutMsTxInit_Ut(template MsCfgParams p_msCfgParams, FncRetCode p_ret) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msCfgParams); utPort.send(p_utRequest); tc_maxTimeCfgActRly.start; alt{ []utPort.receive(e_success){ setverdict(pass); []utPort.receive(mw_utsCfn_success){ tc_maxTimeCfgActRly.stop; setverdict(pass); return e_success; } []utPort.receive(e_error){ setverdict(fail); []utPort.receive(mw_utsCfn_noSuccess){ tc_maxTimeCfgActRly.stop; log("*** f_iutMsInit_Ut: Error message received on upper tester ***"); log("*** f_handshake_Ut: Error message received on upper tester ***"); setverdict(fail); return e_error; } []tc_maxTimeCfgActRly.timeout{ log("*** f_handshake_Ut: timeout of configuration or action ***"); setverdict(fail); log("*** f_iutMsInit_Ut: timeout of configuration or action ***"); return e_error; } } return e_error; } //end f_iutMsTxInit_Ut } // end f_handshake_Ut } //end configFunctions /* * @desc: f_iutMsAction_Ut is used to ask IUT ms to do following actions * Action Type:= PressPtt, DekeyPtt, * @param p_msActParams MS config parameters * @param p_ret the return code */ function f_iutMsAction_Ut(template MsActParams p_msActParams, FncRetCode p_ret) runs on Ut return FncRetCode{ if(p_ret != e_success){ return e_error; } utPort.send(p_msActParams); return e_success; } //end f_iutMsAction_Ut group converterFunctions { /* * @desc f_getCommonId returns the Common ID from an ISF address. Loading @@ -196,13 +181,11 @@ } } // end f_getCommonId group converterFunctions { /* * @desc f_getColourCode returns the Colour Code for ISF or CSF */ function f_getColourCode () runs on Simu runs on Mse return ColourCode { var ColourCode v_cc; Loading Loading @@ -254,7 +237,7 @@ * @remark This function should perhaps be rewritten (split) , and the enumerated type UseAllCallCommonId removed */ function f_createMsAddress( boolean p_testingEntityIsIUT) runs on Simu runs on Mse return MsAddress { var MsAddress v_retAdr; if (PIC_ISF_OR_CSF == e_isf) { Loading Loading @@ -285,7 +268,7 @@ * @remark This function should perhaps be rewritten (split) , and the enumerated type UseAllCallCommonId removed */ function f_getCsfAddress (boolean p_testingEntityIsIUT) runs on Simu runs on Mse return CSFAddress { var CSFAddress v_ret; if (p_testingEntityIsIUT) { Loading
ttcn/dPMR_Pics.ttcn +0 −6 Original line number Diff line number Diff line Loading @@ -17,9 +17,6 @@ module dPMR_Pics { import from dPMR_TestConfiguration all; /* * @desc Is the IUT an ISF or CSF entity? * @remark see PICS, Table A.1/1. Loading @@ -27,7 +24,4 @@ module dPMR_Pics { modulepar {Entity PIC_ISF_OR_CSF := e_isf} } // end module dPMR_PICS No newline at end of file
ttcn/dPMR_Pixits.ttcn +1 −1 Original line number Diff line number Diff line Loading @@ -26,7 +26,7 @@ module dPMR_Pixits { */ modulepar {CsfChannelNr PXT_CSF_CHANNEL_NR := e_csfChannelNr_0 } ////TODO JP add clauses + make groups /* Loading