gps.h

来自「GPS的串口读取数据过程,并且进行了坐标转换,转化为通用的坐标系」· C头文件 代码 · 共 39 行

H
39
字号
#pragma once
#include "sensor.h"
#include "Globe.h"

typedef struct _tGPGGADATA
{
	int nHours;
	int nMinutes;
	int nSeconds;
	double fLatitude;
	double fLongitude;
	int nGPSQual;
	int nNumofSate;
	float fHdop;
	double fAltitude;
	float fUndulation;
} GPGGADATA;


class GPS :
	public Sensor<GPGGADATA>
{
public:
	GPS(void);
public:
	virtual ~GPS(void);

	virtual void OnReceiveChar(const char ch);

protected:
	void AnalyseGPGGA(const string& str);

	static const string m_sPrefix;
	string m_sInputBuffer;
	bool m_bNewLine;
	bool m_bValid;
	int m_nFlag;
};

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?