⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gps.h

📁 这是一个罗盘的串口数据读取过程,并且在此之前加入了标定过程
💻 H
字号:
#pragma once
#include "sensor.h"
#include "Globe.h"

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


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

	virtual void OnReceiveChar(const char ch);
	virtual void OnReceiveCh(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 + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -