feature: GPS support on HeltecV3
GPS support via EnvironmentSensorManager. Connect GPS RX to pin 45, TX to pin 46. Note that while you can disable using the GPS there is no way to power down the GPS without using a mosfet and adjusting PIN_GPS_EN.
This commit is contained in:
@@ -21,6 +21,10 @@ build_flags =
|
|||||||
-D ENV_INCLUDE_BME280=1
|
-D ENV_INCLUDE_BME280=1
|
||||||
-D ENV_INCLUDE_INA3221=1
|
-D ENV_INCLUDE_INA3221=1
|
||||||
-D ENV_INCLUDE_INA219=1
|
-D ENV_INCLUDE_INA219=1
|
||||||
|
-D ENV_INCLUDE_GPS=1
|
||||||
|
-D PIN_GPS_RX=45
|
||||||
|
-D PIN_GPS_TX=46
|
||||||
|
-D PIN_GPS_EN=-1
|
||||||
build_src_filter = ${esp32_base.build_src_filter}
|
build_src_filter = ${esp32_base.build_src_filter}
|
||||||
+<../variants/heltec_v3>
|
+<../variants/heltec_v3>
|
||||||
+<helpers/sensors>
|
+<helpers/sensors>
|
||||||
@@ -31,6 +35,7 @@ lib_deps =
|
|||||||
adafruit/Adafruit INA219 @ ^1.2.3
|
adafruit/Adafruit INA219 @ ^1.2.3
|
||||||
adafruit/Adafruit AHTX0 @ ^2.0.5
|
adafruit/Adafruit AHTX0 @ ^2.0.5
|
||||||
adafruit/Adafruit BME280 Library @ ^2.3.0
|
adafruit/Adafruit BME280 Library @ ^2.3.0
|
||||||
|
stevemarple/MicroNMEA @ ^2.0.6
|
||||||
|
|
||||||
[env:Heltec_v3_repeater]
|
[env:Heltec_v3_repeater]
|
||||||
extends = Heltec_lora32_v3
|
extends = Heltec_lora32_v3
|
||||||
|
|||||||
@@ -14,7 +14,14 @@ WRAPPER_CLASS radio_driver(radio, board);
|
|||||||
|
|
||||||
ESP32RTCClock fallback_clock;
|
ESP32RTCClock fallback_clock;
|
||||||
AutoDiscoverRTCClock rtc_clock(fallback_clock);
|
AutoDiscoverRTCClock rtc_clock(fallback_clock);
|
||||||
EnvironmentSensorManager sensors;
|
|
||||||
|
#if ENV_INCLUDE_GPS
|
||||||
|
#include <helpers/sensors/MicroNMEALocationProvider.h>
|
||||||
|
MicroNMEALocationProvider nmea = MicroNMEALocationProvider(Serial1);
|
||||||
|
EnvironmentSensorManager sensors = EnvironmentSensorManager(nmea);
|
||||||
|
#else
|
||||||
|
EnvironmentSensorManager sensors;
|
||||||
|
#endif
|
||||||
|
|
||||||
#ifdef DISPLAY_CLASS
|
#ifdef DISPLAY_CLASS
|
||||||
DISPLAY_CLASS display;
|
DISPLAY_CLASS display;
|
||||||
|
|||||||
Reference in New Issue
Block a user