Commit e948e5c5 authored by garciay's avatar garciay
Browse files

Adding ATS port

Cleaning FNTP code
parent 6b06d986
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -174,7 +174,7 @@ module LibItsFntp_Functions {
            // Unmap
            unmap(self:acPort, system:acPort);
            unmap(self:utPort, system:utPort);
            //unmap(self:cfPort, system:cfPort);
            unmap(self:cfPort, system:cfPort);
            unmap(self:fntpPort, system:fntpPort);
            
            // Disconnect
@@ -352,16 +352,16 @@ module LibItsFntp_Functions {
        
        /**
         * @desc Generate a NF-SAP request without waiting for a confirm message 
         * @param p_generateNfSapRequest The NF-SAP request message to send 
         * @param p_utFntpEvent The NF-SAP request message to send 
         * @verdict 
         */
        function f_fntpGenerateNfSApRequestWithoutConfirm( 
            in template (value) UtFntpEvent p_generateNfSapRequest 
            in template (value) UtFntpEvent p_utFntpEvent 
        ) runs on ItsCalm { 
            
            f_utEvent(
                UtEvent : { // TODO Simplify template call using m_utEventInd/mw_utEventInd templates 
                    utFntpEvent := p_generateNfSapRequest 
                    utFntpEvent := p_utFntpEvent 
                } 
            );
            
+2 −1
Original line number Diff line number Diff line
@@ -87,7 +87,8 @@ module LibItsFntp_Pixits {
         * @desc Identifies the VCI on ITS-S router (e.g. It coud be the G5 radio MAC address of the IUT)
         * @see ISO 21218 - Clause 6.2 Link Identifier 
         */
        modulepar EUI64 PX_WL_LOCAL_CIID :=     '0A0B0CFFFE0D0E0F'O; 
//        modulepar EUI64 PX_WL_LOCAL_CIID :=     '0A0B0CFFFE0D0E0F'O; Commsignia setting
        modulepar EUI64 PX_WL_LOCAL_CIID :=     'A22D8CFFFF198063'O; // Peek setting
        
        /**
         * @desc Identifies the VCI for broadcast on ITS-S router 
+41 −51
Original line number Diff line number Diff line
@@ -44,8 +44,8 @@ module LibItsFntp_Templates {
    import from CALMfntp language "ASN.1:1997" all; 
    import from LibItsCalm_Pixits { 
        modulepar 
            PX_LOC_ITS_ACCESS_SETTINGS, 
            PX_IUT_LOWER_LAYER_USED, PX_IUT_LOWER_LAYER_NOT_USED, 
            PX_LOC_ITS_FNTP_ACCESS_SETTINGS, 
            PX_IUT_LOWER_LAYER_USED, PX_IUT_LOWER_LAYER_UNUSED, 
            PX_IUT_TEST_MODE_ON 
    }; 
    import from LibItsFntp_TypesAndValues { 
@@ -56,14 +56,6 @@ module LibItsFntp_Templates {
            AcFntpPrimitive
    };
    import from LibItsFntp_Pixits all;
    import from LibItsIicp_Templates { 
        template 
            mdw_iicRequestTx_mnRequestRequest
    }; 
    import from LibItsMgt_Templates { 
        template 
            mdw_mnCommandConfirm 
    }; 
    import from LibItsMgt_Functions { 
        function 
            f_getNextCommandRef, 
@@ -72,6 +64,16 @@ module LibItsFntp_Templates {
    }; 
    import from LibItsCalm_Interface all; 
    
    group csapCstes { 
        
        /**
         * @desc CSAP value
         * @see ISO/CD 21218 - Table 5 — Addresses for the Link Service Access Point (IN-SAP)
         */
        const IN_SAPaddress c_fntpInSapAddress := 186; //oct2int('BA'O);
        
    } // group csapCstes 
    
    group errorStatusCstes { 
        
        const FNTPerrorStatus c_errStatus_success := 0; 
@@ -83,8 +85,8 @@ module LibItsFntp_Templates {
    group fntpPrimitives {
        
        /**
         * @desc    Send template for DEN Message (DenmPort Primitive)
         * @param   p_inSapPrimitivesUp IN-SAP message to be sent
         * @desc    Send template for IN-SAP Message (FntpPort Primitive)
         * @param   p_inSapPrimitivesUp IN-SAP message to be sent to the IUT
         */
        template (value) FntpReq m_fntpReq(
            template (value) INsapPrimitivesUp p_inSapPrimitivesUp
@@ -94,7 +96,7 @@ module LibItsFntp_Templates {
        
        /**
         * @desc    Receive template for IN-SAP message (FntpPort Primitive)
         * @param   p_inSapPrimitivesDown Expected IN-SAP message
         * @param   p_inSapPrimitivesDown Expected IN-SAP message generqted by the IUT
         */
        template FntpInd mw_fntpInd(
            template (present) INsapPrimitivesDown p_inSapPrimitivesDown
@@ -142,7 +144,7 @@ module LibItsFntp_Templates {
                template (value) LLserviceAddr m_llServiceAddr(
                    in template (value) Link_ID p_linkId
                ) := {
                    csap := mw_fntpInSapAddress_src_command,
                    csap := c_fntpInSapAddress,
                    linkID := p_linkId
                } //  // End of template m_llServiceAddr
                
@@ -177,29 +179,17 @@ module LibItsFntp_Templates {
                    servPrimitive := { IN_UNITDATA_request := p_inUnitdataRq } 
                } // End of template m_fntpImPrimitiveReq
                
                /**
                 * @desc Send template for IN-SAP address
                 * @see ISO/CD 21218 - Table 5 — Addresses for the Link Service Access Point (IN-SAP)
                 */
                template (value) IN_SAPaddress m_fntpInSapAddress_src_command := 186; //oct2int('BA'O);
                
                /**
                 * @desc Receive template for IN-SAP address
                 * @see ISO/CD 21218 - Table 5 — Addresses for the Link Service Access Point (IN-SAP)
                 */
                template (value) IN_SAPaddress mw_fntpInSapAddress_src_command := m_fntpInSapAddress_src_command; 
                
                /**
                 * @desc  Receive template for IN-UNITDATA.request SAP primitive
                 * @see   ISO/CD 21218 - Clause 8.2.2
                 */
                template IN_UNITDATA_request mw_inUnitDataReq_any := { 
                    source_addr := { 
                        csap := mw_fntpInSapAddress_src_command, 
                        csap := c_fntpInSapAddress, 
                        linkID := ? 
                    }, 
                    dest_addr := { 
                        csap := mw_fntpInSapAddress_src_command, 
                        csap := c_fntpInSapAddress, 
                        linkID := ? 
                    }, 
                    data := ?, 
@@ -221,11 +211,11 @@ module LibItsFntp_Templates {
                    in template (present) Link_ID p_destLinkId 
                ) modifies mw_inUnitDataReq_any := { 
                    source_addr := { 
                        csap := mw_fntpInSapAddress_src_command, 
                        csap := c_fntpInSapAddress, 
                        linkID := p_sourceLinkId 
                    }, 
                    dest_addr := { 
                        csap := mw_fntpInSapAddress_src_command, 
                        csap := c_fntpInSapAddress, 
                        linkID := p_destLinkId 
                    }
                } // End of template mdw_inUnitDataReq
@@ -267,7 +257,7 @@ module LibItsFntp_Templates {
                template LLserviceAddr mw_llServiceAddr(
                    in template (present) Link_ID p_linkId
                ) := {
                    csap := mw_fntpInSapAddress_src_command,
                    csap := c_fntpInSapAddress,
                    linkID := p_linkId
                } // End of template mw_llServiceAddr
                
@@ -832,6 +822,18 @@ module LibItsFntp_Templates {
         */
        group utPrimitives {
        
            template (present) UtEventInd mw_utEventInd( 
                in template (present) UtFntpEventInd p_utFntpEventInd 
            ) := { 
                utFntpEventInd := p_utFntpEventInd 
            } // End of template mw_utEventInd 
            
            template UtFntpEventInd mw_utFntpEventInd( 
                in template NFsapPrimitivesUp p_nfSapPrimitivesUp 
            ) := { 
                nfSapPrimitivesUp := p_nfSapPrimitivesUp 
            } // End of template mw_utFntpEventInd 
            
            /**
             * @desc Initializes the FNTP IUT
             */
@@ -841,8 +843,8 @@ module LibItsFntp_Templates {
                        mCmdRef := 255, 
                        mcmd := { 
                            TestConfigIICP := { 
                                location := PX_LOC_ITS_ACCESS_SETTINGS, 
                                lowerLayers := PX_IUT_LOWER_LAYER_NOT_USED, // PX_IUT_LOWER_LAYER_USED
                                location := PX_LOC_ITS_FNTP_ACCESS_SETTINGS, 
                                lowerLayers := PX_IUT_LOWER_LAYER_UNUSED, // PX_IUT_LOWER_LAYER_USED
                                testMode := PX_IUT_TEST_MODE_ON 
                            } 
                        } // End of field 'mcmd' 
@@ -898,18 +900,6 @@ module LibItsFntp_Templates {
                    } // End of field 'nfSapPrimitivesDown' 
                } // End of template m_generateNfFntpPortDeletionRequest
                
                template (present) UtEventInd mw_utEventInd( 
                    in template (present) UtFntpEventInd p_utFntpEventInd 
                ) := { 
                    utFntpEventInd := p_utFntpEventInd 
                } // End of template mw_utEventInd 
                
                template UtFntpEventInd mw_utFntpEventInd( 
                    in template NFsapPrimitivesUp p_nfSapPrimitivesUp 
                ) := { 
                    nfSapPrimitivesUp := p_nfSapPrimitivesUp 
                } // End of template mw_utFntpEventInd 
                
                /**
                 * @desc  Receive template used by the FNTP to acknowledge a previous NF-FNTP-PORT.request
                 * @param p_serviceRef  Contains the same value provided in parameter "serviceRef" in the related NF-FNTP-SOCKET.request
@@ -967,14 +957,14 @@ module LibItsFntp_Templates {
             * @desc Receive a succesful COMMAND.confirm primitive
             * @see ISO/CD 29281-2 Clause 8.2.1    NF-FNTP-PORT.request
             */
            template (present) NFsapPrimitivesUp mdw_fntpCommConfirm_failure //FIXME To be renamed 
            template (present) NFsapPrimitivesUp mdw_fntpCommConfirm_anyError  
            modifies mw_fntpCommConfirm_success := {
                servPrimitive := { 
                    NFfntpCommConfirm := {
                        errStatus := complement(c_errStatus_success) 
                    } // End of field 'NFfntpCommConfirm'
                } // End of field 'servPrimitive'
            } // End of template mw_fntpCommConfirm_failure
            } // End of template mdw_fntpCommConfirm_anyError
            
            /**
             * @desc    Receive an unsuccesful COMMAND.confirm primitive
+13 −12
Original line number Diff line number Diff line
@@ -15,6 +15,8 @@ module LibItsFntp_TypesAndValues {
    };
    
    // LibIts
    
    // LibItsCalm
    import from CALMllsap language "ASN.1:1997" {
        type
            INsapPrimitivesUp 
@@ -27,8 +29,7 @@ module LibItsFntp_TypesAndValues {
    };
    import from CALMiitsscu language "ASN.1:1997" {
        type 
            McmdRq, 
            IIC_Request, IIC_Response 
            McmdRq 
    };
    import from CALMmsap language "ASN.1:1997" {
        type 
+19 −6
Original line number Diff line number Diff line
@@ -65,7 +65,7 @@ module LibItsFsap_Functions {
            // Map
            map(self:acPort, system:acPort);
            map(self:utPort, system:utPort);
            map(self:mgtMfSapPort, system:mgtMfSapPort);
// TODO To be removed            map(self:mgtMfSapPort, system:mgtMfSapPort);
            
            // Connect
            f_connect4SelfOrClientSync(); 
@@ -100,7 +100,7 @@ module LibItsFsap_Functions {
            // Map
            map(self:acPort, system:acPort);
            map(self:utPort, system:utPort);
            map(self:mgtMfSapPort, system:mgtMfSapPort);
// TODO To be removed            map(self:mgtMfSapPort, system:mgtMfSapPort);
            map(self:iicpPort, system:iicpPort);
            
            // Connect
@@ -127,7 +127,7 @@ module LibItsFsap_Functions {
            // Unmap
            unmap(self:acPort, system:acPort);
            unmap(self:utPort, system:utPort);
            unmap(self:mgtMfSapPort, system:mgtMfSapPort);
// TODO To be removed            unmap(self:mgtMfSapPort, system:mgtMfSapPort);
            
            // Disconnect
            f_disconnect4SelfOrClientSync();
@@ -144,7 +144,7 @@ module LibItsFsap_Functions {
            // Unmap
            unmap(self:acPort, system:acPort);
            unmap(self:utPort, system:utPort);
            unmap(self:mgtMfSapPort, system:mgtMfSapPort);
// TODO To be removed            unmap(self:mgtMfSapPort, system:mgtMfSapPort);
            unmap(self:iicpPort, system:iicpPort);
            
            // Disconnect
@@ -162,7 +162,7 @@ module LibItsFsap_Functions {
            // Initialize variables
            
            // Set defaults
            activate(a_mgtMfSapPortDefault()); // Default for MGT module / MF-SAP port
// TODO To be removed            activate(a_mgtMfSapPortDefault()); // Default for MGT module / MF-SAP port
            activate(a_fsapDefault()); 
            if (p_componentName == "cf02Up") {
                activate(a_iicpDefault());
@@ -177,10 +177,23 @@ module LibItsFsap_Functions {
         * @desc Brings the IUT into an initial state.
         */
        function f_initialState() runs on ItsMgt {
            f_utInitializeIut(m_fsapInitialize);
            f_utInitializeIut(m_utFsapInitialize);
            f_sleepIgnoreDef(PX_WAIT_FOR_IUT_READY); // Wait until the IUT is in a stable situation (beaconing...)
        } // End of function f_initialState
        
		
		function f_fsapGenerateGcRegServerWithoutConfirm( 
			in template (value) UtFsapEvent p_utFsapEvent
		)  runs on ItsMgt { 
            
            f_utEvent(
                UtEvent : { // TODO Simplify template call using m_utEventInd/mw_utEventInd templates 
                    utFsapEvent := p_utFsapEvent 
                } 
            );
            
		} // End of function f_fsapGenerateGcRegServerWithoutConfirm 
		
    } // End of group preambles
    
    group postambles {
Loading