Commit d87b8bf2 authored by berge's avatar berge
Browse files

Implemented position related external functions

Changed timestamp computation so that they look a bit 'older' (~1s)
parent 6706e2b2
Loading
Loading
Loading
Loading
+7 −3
Original line number Diff line number Diff line
@@ -1225,7 +1225,10 @@ module LibItsGeoNetworking_Functions {
         * @return  Unix-Epoch-Time mod 2^32
         */
        function f_computeGnTimestamp() return UInt32 {
            return fx_computeGnTimestamp();	
        	
        	//  Timestamp is 1s older than current time to avoid sending beacons coming from the future (time sync between nodes)
        	var UInt32 v_timestamp := fx_computeGnTimestamp() - 1000;
            return v_timestamp;	
        } 
      
    } // end commonFunctions
@@ -1641,7 +1644,7 @@ module LibItsGeoNetworking_Functions {
            var LongPosVector v_result := p_iutLongPosVector;
            
            log("*** f_computePositionUsingDistance: INFO: calling fx_computePositionUsingDistance() ***");
            fx_computePositionUsingDistance(p_iutLongPosVector, p_distance, p_orientation, v_result.latitude, v_result.longitude);
            fx_computePositionUsingDistance(p_iutLongPosVector.latitude, p_iutLongPosVector.longitude, p_distance, p_orientation, v_result.latitude, v_result.longitude);
            
            return v_result;
        }
@@ -1673,7 +1676,8 @@ module LibItsGeoNetworking_Functions {
         * @return  LongPosVector
         */        
        external function fx_computePositionUsingDistance(
            in LongPosVector p_iutLongPosVector, 
            in UInt32 p_refLatitude, 
            in UInt32 p_refLongitude, 
            in integer p_distance, 
            in integer p_orientation,
            out UInt32 p_latitude,
+1 −1

File changed.

Contains only whitespace changes.