kopia lustrzana https://github.com/helium/longfi-arduino
add cayennelpp gps packing
rodzic
edd9a26a35
commit
5e4c7a90a1
|
@ -301,6 +301,9 @@ void readGPS() {
|
||||||
ledState = !ledState;
|
ledState = !ledState;
|
||||||
digitalWrite(LED_BUILTIN, ledState);
|
digitalWrite(LED_BUILTIN, ledState);
|
||||||
|
|
||||||
|
// Clear Payload
|
||||||
|
lpp.reset();
|
||||||
|
|
||||||
// Output GPS information from previous second
|
// Output GPS information from previous second
|
||||||
Serial.print("Valid fix: ");
|
Serial.print("Valid fix: ");
|
||||||
Serial.println(nmea.isValid() ? "yes" : "no");
|
Serial.println(nmea.isValid() ? "yes" : "no");
|
||||||
|
@ -345,12 +348,15 @@ void readGPS() {
|
||||||
else
|
else
|
||||||
Serial.println("not available");
|
Serial.println("not available");
|
||||||
|
|
||||||
|
lpp.addGPS(1, latitude_mdeg, longitude_mdeg, alt);
|
||||||
|
|
||||||
Serial.print("Speed: ");
|
Serial.print("Speed: ");
|
||||||
Serial.println(nmea.getSpeed() / 1000., 3);
|
Serial.println(nmea.getSpeed() / 1000., 3);
|
||||||
Serial.print("Course: ");
|
Serial.print("Course: ");
|
||||||
Serial.println(nmea.getCourse() / 1000., 3);
|
Serial.println(nmea.getCourse() / 1000., 3);
|
||||||
Serial.println("-----------------------");
|
Serial.println("-----------------------");
|
||||||
nmea.clear();
|
nmea.clear();
|
||||||
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Ładowanie…
Reference in New Issue