Telescope Control Library
LocationProvider.h@19:fd854309cb4c, 2018-09-24 (annotated)
- Committer:
- caoyu@caoyuan9642-desktop.MIT.EDU
- Date:
- Mon Sep 24 19:36:48 2018 -0400
- Revision:
- 19:fd854309cb4c
- Parent:
- 10:e356188d208e
Fix bug in nudging with small speeds mentioned in the last commit
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 1 | #ifndef LOCATION_PROVIDER_H |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 2 | #define LOCATION_PROVIDER_H |
caoyuan9642 | 0:6cb2eaf8b133 | 3 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 4 | class LocationProvider; |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 5 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 6 | #include "CelestialMath.h" |
caoyuan9642 | 0:6cb2eaf8b133 | 7 | /** |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 8 | * Provides location information. Can be overriden if a GPS is installed for example. |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 9 | */ |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 10 | class LocationProvider { |
caoyuan9642 | 0:6cb2eaf8b133 | 11 | public: |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 12 | LocationProvider() { |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 13 | } |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 14 | virtual ~LocationProvider() { |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 15 | } |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 16 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 17 | virtual double getLongtitude() const; |
caoyuan9642 | 0:6cb2eaf8b133 | 18 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 19 | virtual double getLatitude() const; |
caoyuan9642 | 0:6cb2eaf8b133 | 20 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 21 | LocationCoordinates getLocation() const { |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 22 | return LocationCoordinates(getLatitude(), getLongtitude()); |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 23 | } |
caoyuan9642 | 0:6cb2eaf8b133 | 24 | }; |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 25 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 26 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 10:e356188d208e | 27 | |
caoyu@caoyuan9642-desktop.MIT.EDU | 9:d0413a9b1386 | 28 | #endif |