mirror of
https://github.com/paparazzi/paparazzi.git
synced 2026-05-28 18:07:25 +08:00
Copilot fixes
This commit is contained in:
@@ -43,7 +43,6 @@ VPATH += $(PAPARAZZI_HOME)/var/share
|
|||||||
## COMMON ROTORCRAFT ALL TARGETS (AP + NPS)
|
## COMMON ROTORCRAFT ALL TARGETS (AP + NPS)
|
||||||
##
|
##
|
||||||
|
|
||||||
$(TARGET).CFLAGS += -DFIRMWARE=ROTORCRAFT
|
|
||||||
$(TARGET).CFLAGS += $(ROTORCRAFT_INC)
|
$(TARGET).CFLAGS += $(ROTORCRAFT_INC)
|
||||||
$(TARGET).CFLAGS += -DBOARD_CONFIG=$(BOARD_CFG)
|
$(TARGET).CFLAGS += -DBOARD_CONFIG=$(BOARD_CFG)
|
||||||
$(TARGET).CFLAGS += -DPERIPHERALS_AUTO_INIT
|
$(TARGET).CFLAGS += -DPERIPHERALS_AUTO_INIT
|
||||||
|
|||||||
@@ -25,7 +25,6 @@
|
|||||||
##
|
##
|
||||||
## COMMON FIXEDWING ALL TARGETS (SIM + AP + FBW ...)
|
## COMMON FIXEDWING ALL TARGETS (SIM + AP + FBW ...)
|
||||||
##
|
##
|
||||||
$(TARGET).CFLAGS += -DFIRMWARE=FIXEDWING
|
|
||||||
|
|
||||||
#
|
#
|
||||||
# Board config + Include paths
|
# Board config + Include paths
|
||||||
|
|||||||
@@ -36,26 +36,12 @@
|
|||||||
<datalink message="MOVE_WP" fun="copilot_parse_move_wp_dl(buf)"/>
|
<datalink message="MOVE_WP" fun="copilot_parse_move_wp_dl(buf)"/>
|
||||||
<makefile target="ap">
|
<makefile target="ap">
|
||||||
<file name="copilot_common.c"/>
|
<file name="copilot_common.c"/>
|
||||||
<raw>
|
</makefile>
|
||||||
# attach the correct file based on firmware
|
<makefile target="ap" firmware="fixedwing">
|
||||||
RESULT=0
|
<file name="copilot_fixedwing.c"/>
|
||||||
|
</makefile>
|
||||||
ifneq (,$(findstring ROTORCRAFT,$($(TARGET).CFLAGS)))
|
<makefile target="ap" firmware="rotorcraft">
|
||||||
# Rotorcraft
|
<file name="copilot_rotorcraft.c"/>
|
||||||
RESULT=1
|
|
||||||
$(TARGET).srcs += $(SRC_MODULES)/mission/copilot_rotorcraft.c
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifneq (,$(findstring FIXEDWING,$($(TARGET).CFLAGS)))
|
|
||||||
# Fixedwing
|
|
||||||
$(TARGET).srcs += $(SRC_MODULES)/mission/copilot_fixedwing.c
|
|
||||||
RESULT=1
|
|
||||||
endif
|
|
||||||
|
|
||||||
ifeq ($(RESULT), 0)
|
|
||||||
$(error Error: Copilot module can be compiled only in Fixeding or Rotorcraft firmware. Please check your firmware.)
|
|
||||||
endif
|
|
||||||
</raw>
|
|
||||||
</makefile>
|
</makefile>
|
||||||
</module>
|
</module>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user