2 """ Useful constants for Breadcrumb client-side programs.
4 Sentence offsets for parsing sentence strings
5 See http://www.gpsinformation.org/dale/nmea.htm for an explanation on all sorts
6 of NMEA sentences, not anywhere near limited to those used in this application.
8 SENTENCE_OFFSETS: The keys can be a bit terse, so here's the explanation:
9 - lat_fl, lon_fl: floating point values for lat, lon (pretty raw)
10 - lat_ns, lon_ew: hemisphere (north/south for lat, east/west for lon)
11 - time: self-explanatory
12 - velocity, velocity_kt: velocity in m/s, knots
13 - heading: true heading
14 - m_var: magnetic variation
15 - m_var_dir: direction of magnetic variation, set(['E', 'W'])
18 DEFAULT_THRESHOLDS
= ( # Push a new point when...
19 ('heading', 15), # ... we turn 15 degrees or more,
20 ('distance', 500), # ... or we travel 500 meters or more,
21 ('timestamp', 1200), # ... or twenty minutes pass (heartbeat).