Commit e1e66809 authored by berge's avatar berge
Browse files

relaxed timestamps in reception templates

parent 2e2de430
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -422,7 +422,7 @@ module LibItsGeoNetworking_Functions {
            
            vc_neighbourDefault := activate(a_neighbourDefault());
            f_acTriggerEvent(m_startBeaconing(m_beaconHeader(f_getPosition(vc_componentName)).beaconHeader));
            
            f_sleep(1.0);
        } // end f_startBeingNeighbour

        /**
@@ -1097,7 +1097,7 @@ module LibItsGeoNetworking_Functions {
                            mw_geoNwPdu(
                                mw_lsReplyHeader(
                                    ?,
                                    f_longPosVector2ShortPosVector(valueof(p_reqSrcPosVector))
                                    mw_shortPosVectorPosition(f_longPosVector2ShortPosVector(valueof(p_reqSrcPosVector)))
                                )
                            )
                        )
+51 −27
Original line number Diff line number Diff line
@@ -566,19 +566,19 @@ module LibItsGeoNetworking_Templates {
            }

            /**
             * @desc    Receive template for long position vector with position check with delta
             * @desc    Receive template for long position vector with strict position check 
             * @param   p_longPosVector The base long position vector
             */
            template LongPosVector mw_longPosVectorPosition(
                in LongPosVector p_longPosVector
                in template (value) LongPosVector p_longPosVector
            ) := {
            	gnAddr := p_longPosVector.gnAddr,
                timestamp := ?,
                    latitude := (p_longPosVector.latitude-PX_POS_DELTA .. p_longPosVector.latitude+PX_POS_DELTA),
                    longitude := (p_longPosVector.longitude-PX_POS_DELTA .. p_longPosVector.longitude+PX_POS_DELTA),
                    speed := (p_longPosVector.speed-PX_POS_DELTA .. p_longPosVector.speed+PX_POS_DELTA),
                latitude := p_longPosVector.latitude,
                longitude := p_longPosVector.longitude,
                speed := p_longPosVector.speed,
                heading := p_longPosVector.heading,
                    altitude := (p_longPosVector.altitude-PX_POS_DELTA .. p_longPosVector.altitude+PX_POS_DELTA),
                altitude := p_longPosVector.altitude,
                timeAccuracy := ?,
                posAccuracy := ?,
                speedAccuracy := ?,
@@ -587,14 +587,38 @@ module LibItsGeoNetworking_Templates {
            }
                     
            /**
             * @desc    Receive template for short position vector with position check with delta
             * @desc    Receive template for long position vector with position check with delta
             * @param   p_longPosVector The base long position vector
             */
            template LongPosVector mw_longPosVectorPosition_withDelta(
                in LongPosVector p_longPosVector
            ) modifies mw_longPosVectorPosition := {
                    latitude := (p_longPosVector.latitude-PX_POS_DELTA .. p_longPosVector.latitude+PX_POS_DELTA),
                    longitude := (p_longPosVector.longitude-PX_POS_DELTA .. p_longPosVector.longitude+PX_POS_DELTA),
                    speed := (p_longPosVector.speed-PX_POS_DELTA .. p_longPosVector.speed+PX_POS_DELTA),
                    altitude := (p_longPosVector.altitude-PX_POS_DELTA .. p_longPosVector.altitude+PX_POS_DELTA)
            }
            
            /**
             * @desc    Receive template for short position vector with strict position check
             * @param   p_shortPosVector The base short position vector
             */
            template ShortPosVector mw_shortPosVectorPosition(
                in ShortPosVector p_shortPosVector
                in template (value) ShortPosVector p_shortPosVector
            ) := {
                    gnAddr := p_shortPosVector.gnAddr,
                    timestamp := ?,
                    latitude := p_shortPosVector.latitude,
                    longitude := p_shortPosVector.longitude
            }
            
            /**
             * @desc    Receive template for short position vector with position check with delta
             * @param   p_shortPosVector The base short position vector
             */
            template ShortPosVector mw_shortPosVectorPosition_withDelta(
                in ShortPosVector p_shortPosVector
            ) modifies mw_shortPosVectorPosition := {
                    latitude := (p_shortPosVector.latitude-PX_POS_DELTA..p_shortPosVector.latitude+PX_POS_DELTA),
                    longitude := (p_shortPosVector.longitude-PX_POS_DELTA..p_shortPosVector.longitude+PX_POS_DELTA)
            }