1 /****************************************************************************
3 ** Copyright (C) 2011 Tito Eritja Real <jtitoo@gmail.com>
5 ** This program is free software: you can redistribute it and/or modify
6 ** it under the terms of the GNU General Public License as published by
7 ** the Free Software Foundation, either version 3 of the License, or
8 ** (at your option) any later version.
10 ** This program is distributed in the hope that it will be useful,
11 ** but WITHOUT ANY WARRANTY; without even the implied warranty of
12 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 ** GNU General Public License for more details.
15 ** You should have received a copy of the GNU General Public License
16 ** along with this program. If not, see <http://www.gnu.org/licenses/>.
18 ****************************************************************************/
23 // tile size in pixels
26 #ifndef APPLICATION_NAME
27 #define APPLICATION_NAME GPS Sport Sniffer
30 #ifndef ERROR_VERBOSITY
31 #define ERROR_VERBOSITY 3
34 #ifndef WARN_VERBOSITY
35 #define WARN_VERBOSITY 2
38 #ifndef INFO_VERBOSITY
39 #define INFO_VERBOSITY 1
42 #ifndef DEBUG_VERBOSITY
43 #define DEBUG_VERBOSITY 0
46 #ifndef NOLOG_VERBOSITY
47 #define NOLOG_VERBOSITY -1
51 #define DATE_FORMAT "dd-MM-yyyy"
54 #ifndef XML_DATE_FORMAT
55 #define XML_DATE_FORMAT "yyyy-MM-ddThh:mm:ssZ"
58 #ifndef CONTINOUS_DATE_FORMAT
59 #define CONTINOUS_DATE_FORMAT "dd-MM-yyyy_hh-mm-ss"
62 #ifndef CLEAN_DATE_FORMAT
63 #define CLEAN_DATE_FORMAT "dd-MM-yyyy hh:mm:ss"
66 #ifndef APPLICATION_PATH
67 #define APPLICATION_PATH "/home/user/MyDocs/GPSSniffer/"
71 #define MAPS_DIR "maps"
75 #define TCX_FILE ".tcx"
79 #define GPX_FILE ".gpx"
82 #ifndef TCX_XSI_SCHEMALOCATION
83 #define TCX_XSI_SCHEMALOCATION "http://www.garmin.com/xmlschemas/TrainingCenterDatabase/v2 http://www.garmin.com/xmlschemas/TrainingCenterDatabasev2.xsd"
87 #define GPX_CREATOR "GPS Sport Sniffer v.1.1"
91 #define GPX_VERSION "1.1"
95 #define GPX_XMLNS "http://www.topografix.com/GPX/1/1"
100 #define TCX_XMLNS "http://www.garmin.com/xmlschemas/TrainingCenterDatabase/v2"
103 #ifndef TCX_XMLNS_XSI
104 #define TCX_XMLNS_XSI "http://www.w3.org/2001/XMLSchema-instance"
108 #define EARTH_RADIUS 6371
112 #define PI 3.1415926535897932386
115 #ifndef FIRST_LATITUDE
116 #define FIRST_LATITUDE 41.6105
119 #ifndef FIRST_LONGITUDE
120 #define FIRST_LONGITUDE 0.620667
125 #define DEFAULT_ZOOM 15
133 #define MIN_ICC_ZOOM 8
136 #ifndef MAX_ZOOM_DOWNL
137 #define MAX_ZOOM_DOWNL 16
140 #ifndef TIME_SECONDS_POSSITIONING_PAN
141 #define TIME_SECONDS_POSSITIONING_PAN 7
144 #ifndef TIME_MIN_TIMEAUTOSAVE
145 #define TIME_MIN_TIMEAUTOSAVE 5
148 #ifndef WIDTH_DEFAULT
149 #define WIDTH_DEFAULT 800
152 #ifndef HEIGHT_DEFAULT
153 #define HEIGHT_DEFAULT 480
157 #define HTTP_TIMEOUT 3600
160 #ifndef ACCURACY_V_MIN
161 #define ACCURACY_V_MIN 10000
164 #ifndef ACCURACY_H_MIN
165 #define ACCURACY_H_MIN 20000
168 enum MapType { MapTypeCloudMade=0,
171 MapTypeOpenCycleMaps=3,
172 MapTypeOpenStreetMaps=4
175 enum XMLFileType{XMLFile_GPX=0,
179 enum Mode { Mode_NewActivityMode, Mode_LoadTracksWindow
183 #endif // CONSTANTS_H