mirror of
https://github.com/meshtastic/firmware.git
synced 2025-12-22 10:42:49 +00:00
begin cleanup on gps code
This commit is contained in:
26
src/GPS.h
Normal file
26
src/GPS.h
Normal file
@@ -0,0 +1,26 @@
|
||||
#pragma once
|
||||
|
||||
#include <TinyGPS++.h>
|
||||
#include "PeriodicTask.h"
|
||||
#include "Observer.h"
|
||||
|
||||
/**
|
||||
* A gps class that only reads from the GPS periodically (and FIXME - eventually keeps the gps powered down except when reading)
|
||||
*
|
||||
* When new data is available it will notify observers.
|
||||
*/
|
||||
class GPS : public PeriodicTask, public Observable, public TinyGPSPlus
|
||||
{
|
||||
public:
|
||||
GPS();
|
||||
|
||||
String getTime();
|
||||
|
||||
void setup();
|
||||
|
||||
virtual void loop();
|
||||
|
||||
virtual void doTask();
|
||||
};
|
||||
|
||||
extern GPS gps;
|
||||
Reference in New Issue
Block a user