mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-06-04 05:42:49 +08:00
[gps] update gps ublox module to comply with multi gps
This commit is contained in:
@@ -18,17 +18,31 @@
|
||||
<!--periodic fun="gps_periodic_check()" freq="1." autorun="TRUE"/-->
|
||||
<!--event fun="GpsEvent(on_gps_solution)"/-->
|
||||
<makefile target="ap">
|
||||
<configure name="UBX_GPS_PORT" default="$(GPS_PORT)" case="upper|lower"/>
|
||||
<configure name="UBX_GPS_BAUD" default="$(GPS_BAUD)"/>
|
||||
<file name="gps.c" dir="subsystems"/>
|
||||
<file name="gps_ubx.c" dir="subsystems/gps"/>
|
||||
<define name="USE_GPS"/>
|
||||
<configure name="GPS_PORT" case="upper|lower"/>
|
||||
<define name="USE_$(GPS_PORT_UPPER)"/>
|
||||
<define name="GPS_LINK" value="$(GPS_PORT_LOWER)"/>
|
||||
<define name="$(GPS_PORT_UPPER)_BAUD" value="$(GPS_BAUD)"/>
|
||||
<define name="USE_$(UBX_GPS_PORT_UPPER)"/>
|
||||
<define name="UBX_GPS_LINK" value="$(UBX_GPS_PORT_LOWER)"/>
|
||||
<define name="$(UBX_GPS_PORT_UPPER)_BAUD" value="$(UBX_GPS_BAUD)"/>
|
||||
<configure name="GPS_LED" default="none"/>
|
||||
<define name="GPS_LED" value="$(GPS_LED)" cond="ifneq ($(GPS_LED),none)"/>
|
||||
<raw>
|
||||
ifdef SECONDARY_GPS
|
||||
ifneq (,$(findstring $(SECONDARY_GPS), ublox))
|
||||
# this is the secondary GPS
|
||||
ap.CFLAGS += -DGPS_SECONDARY_TYPE_H=\"subsystems/gps/gps_ubx.h\"
|
||||
ap.CFLAGS += -DSECONDARY_GPS=gps_ubx
|
||||
else
|
||||
ap.CFLAGS += -DGPS_TYPE_H=\"subsystems/gps/gps_ubx.h\"
|
||||
ap.CFLAGS += -DPRIMARY_GPS=gps_ubx
|
||||
endif
|
||||
else
|
||||
# plain old single GPS usage
|
||||
ap.CFLAGS += -DGPS_TYPE_H=\"subsystems/gps/gps_ubx.h\"
|
||||
endif
|
||||
</raw>
|
||||
</makefile>
|
||||
<makefile target="nps">
|
||||
|
||||
Reference in New Issue
Block a user