yy1717
2022-12-08 f7a18ec4494b9c5c9ef3fd440bbf68ffc6425e18
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
//
// Created by YY on 2019/12/23.
//
 
#ifndef RTKDRIVERTEST_RTK_H
#define RTKDRIVERTEST_RTK_H
 
#include <string>
#include <sstream>
#include "../utils/num.h"
 
typedef struct {
    uint16_t gps_status;
    int YY;
    int MM;
    int DD;
    int hh;
    int mm;
    int ss;
    int mss;
    int satNum;
 
    double latitude;
    double longitude;
    double altitude;
    double speed;
    double trackTure;
 
    std::string toString(void) {
        std::stringstream sst;
 
        sst<<"GPS:"<<"qf="<<gps_status
        <<" "<<2000+YY<<intw(MM, 2)<<intw(DD, 2)<<intw(hh,2)<<intw(mm, 2)<<intw(ss, 2)<<"."<<intw(mss, 2)
        <<" satNum"<<satNum
                <<" latitude="<<round(latitude, 6)
                <<" longitude="<<round(longitude, 6)
                <<" altitude="<<round(altitude, 3)
                <<" speed="<<round(speed, 3)
                <<" trackTure="<<round(trackTure, 3);
 
        return sst.str();
    }
}gpsStatus_t;
 
typedef struct {
    int YY;
    int MM;
    int DD;
    int hh;
    int mm;
    int ss;
    int dss;
    int qf;
    double heading;
    double pitch;
    double roll;
    double x;
    double y;
 
    std::string toString(void) {
        std::stringstream sst;
 
        sst<<"RTK:"<<"qf="<<qf
           <<" "<<2000+YY<<intw(MM, 2)<<intw(DD, 2)<<intw(hh,2)<<intw(mm, 2)<<intw(ss, 2)<<"."<<intw(dss, 2)
           <<" heading="<<round(heading, 3)
           <<" pitch="<<round(pitch, 3)
           <<" roll="<<round(roll, 3)
           <<" x="<<round(x, 3)
           <<" y="<<round(y, 3);
 
        return sst.str();
    }
}rtk_info;
 
void RtkCommModeSel(int mode);
void ConfigRTKModule(bool ayDevice);
void ConfigRTKModuleLater(void);
void FactorySettings(void);
void RebootModule(void);
void SetAYFactoryParam(int freq);
void GetGpsStatus(gpsStatus_t &data);
void SetPjkPara(int centLon);
 
#endif //RTKDRIVERTEST_RTK_H