Vanetza
 
Loading...
Searching...
No Matches
nmea.hpp
1#ifndef NMEA_HPP_EJIHQ65L
2#define NMEA_HPP_EJIHQ65L
3
4#include <vanetza/units/angle.hpp>
5#include <vanetza/units/velocity.hpp>
6#include <vanetza/units/length.hpp>
7#include <boost/date_time/posix_time/posix_time_types.hpp>
8#include <cstdint>
9#include <string>
10
11namespace vanetza
12{
13
14// forward declaration
15struct Wgs84Point;
16
17namespace nmea
18{
19typedef boost::posix_time::ptime time;
20
21enum class Quality
22{
23 Unavailable = 0,
24 GPS = 1,
25 DGPS = 2,
26 PPS = 3,
27 RTK = 4,
28 Float_RTK = 5,
29 Estimated = 6,
30 Manual = 7,
31 Simulation = 8
32};
33
34enum class RMCStatus : char
35{
36 Warning = 'V',
37 Valid = 'A'
38};
39
40enum class FAAMode : char
41{
42 Autonomous = 'A',
43 Differential = 'D',
44 Estimated = 'E',
45 Manual = 'M',
46 Simulated = 'S',
47 Invalid = 'N'
48};
49
50std::string gprmc(const time&, const Wgs84Point&, units::NauticalVelocity ground, units::TrueNorth heading);
51std::string gpgga(const time&, const Wgs84Point&, Quality, units::Length hdop);
52uint8_t checksum(std::string::const_iterator, std::string::const_iterator);
53
54} // namespace nmea
55} // namespace vanetza
56
57#endif /* NMEA_HPP_EJIHQ65L */
58