getting time from GPS reworked
This commit is contained in:
1 parent
817f7793c4
commit
a71a7e08a4
6 files changed
+128
-156
No files matched your search
+1
-8
@@ -5,17 +5,10 @@
|
||||
#include <RtcDateTime.h>
|
||||
#include "timekeeper.h"
|
||||
|
||||
#ifdef GPS_I2C // Needed for reading from I2C Bus
|
||||
#include <Wire.h>
|
||||
#endif
|
||||
|
||||
#ifndef GPS_BAUDRATE
|
||||
#define GPS_BAUDRATE 115200
|
||||
#define GPS_BAUDRATE 115200UL
|
||||
#endif
|
||||
|
||||
#define NMEA_FRAME_SIZE 82 // NEMA has a maxium of 82 bytes per record
|
||||
#define NMEA_COMPENSATION_FACTOR 480 // empiric for Ublox Neo 6M
|
||||
|
||||
extern TinyGPSPlus gps; // Make TinyGPS++ instance globally availabe
|
||||
extern TaskHandle_t GpsTask;
|
||||
|
||||
|
||||
@@ -21,13 +21,13 @@ extern Ticker timesyncer;
|
||||
extern timesource_t timeSource;
|
||||
extern TaskHandle_t ClockTask;
|
||||
extern DRAM_ATTR bool TimePulseTick; // 1sec pps flag set by GPS or RTC
|
||||
extern DRAM_ATTR unsigned long lastPPS;
|
||||
extern hw_timer_t *ppsIRQ;
|
||||
extern portMUX_TYPE mux;
|
||||
|
||||
void IRAM_ATTR CLOCKIRQ(void);
|
||||
void IRAM_ATTR GPSIRQ(void);
|
||||
void clock_init(void);
|
||||
void clock_loop(void *pvParameters);
|
||||
void timepulse_start(void);
|
||||
void setTimeSyncIRQ(void);
|
||||
uint8_t timepulse_init(void);
|
||||
bool timeIsValid(time_t const t);
|
||||
@@ -38,5 +38,4 @@ time_t compileTime(void);
|
||||
time_t mkgmtime(const struct tm *ptm);
|
||||
TickType_t tx_Ticks(uint32_t framesize, unsigned long baud, uint32_t config,
|
||||
int8_t rxPin, int8_t txPins);
|
||||
|
||||
#endif // _timekeeper_H
|
||||
Reference in new issue
Block a user