summaryrefslogtreecommitdiff
path: root/gps.py
diff options
context:
space:
mode:
authorEric S. Raymond <esr@thyrsus.com>2009-01-07 05:52:47 +0000
committerEric S. Raymond <esr@thyrsus.com>2009-01-07 05:52:47 +0000
commit263168dabfede17a78a1a18cd49f626899e06141 (patch)
tree050f3c91d46254b788a03d1f6531bdace0532a93 /gps.py
parent284198db2d5d005f263923f0d9bbaaf33463a0f9 (diff)
downloadgpsd-263168dabfede17a78a1a18cd49f626899e06141.tar.gz
Add Rad2Deg to gps.py.
Diffstat (limited to 'gps.py')
-rwxr-xr-xgps.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/gps.py b/gps.py
index 1c5c0f7c..872e669d 100755
--- a/gps.py
+++ b/gps.py
@@ -438,6 +438,10 @@ def Deg2Rad(x):
"Degrees to radians."
return x * (math.pi/180)
+def Rad2Deg(x):
+ "Radians to degress."
+ return x * (180/math.pi)
+
def CalcRad(lat):
"Radius of curvature in meters at specified latitude."
a = 6378.137