From 7678540a931927b9c93ad0a095996bd0a0e02b17 Mon Sep 17 00:00:00 2001 From: geeksville Date: Wed, 17 Jun 2020 17:25:55 -0700 Subject: [PATCH] For #187 was not reporting GPS status on new API --- src/mesh/PhoneAPI.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/mesh/PhoneAPI.cpp b/src/mesh/PhoneAPI.cpp index 59750d468..8d705327b 100644 --- a/src/mesh/PhoneAPI.cpp +++ b/src/mesh/PhoneAPI.cpp @@ -3,6 +3,7 @@ #include "NodeDB.h" #include "PowerFSM.h" #include "RadioInterface.h" +#include "GPS.h" #include PhoneAPI::PhoneAPI() @@ -78,6 +79,7 @@ void PhoneAPI::handleToRadio(const uint8_t *buf, size_t bufLength) } } + /** * Get the next packet we want to send to the phone, or NULL if no such packet is available. * @@ -108,6 +110,7 @@ size_t PhoneAPI::getFromRadio(uint8_t *buf) break; case STATE_SEND_MY_INFO: + myNodeInfo.has_gps = gps && gps->isConnected; // Update with latest GPS connect info fromRadioScratch.which_variant = FromRadio_my_info_tag; fromRadioScratch.variant.my_info = myNodeInfo; state = STATE_SEND_RADIO;