Merge remote-tracking branch 'origin/next' into bsongis/9XR-PRO_port
Conflicts: companion/src/eeprominterface.cpp companion/src/eeprominterface.h companion/src/firmwares/opentx/opentxeeprom.cpp companion/src/firmwares/opentx/opentxinterface.cpp companion/src/firmwares/opentx/opentxinterface.h companion/src/mdichild.cpp radio/src/Makefile
This commit is contained in:
+65
-28
@@ -97,10 +97,9 @@ NAVIGATION = NO
|
||||
# Values = YES, NO
|
||||
AUTOSWITCH = NO
|
||||
|
||||
# Swap Stick Inputs for AIL,ELE,RUD,THR
|
||||
# Used in some scenarios where stick/pot entries
|
||||
# cannot be changed by soldering the pots.
|
||||
|
||||
# Stock sticks replaced by FrSky ones
|
||||
# Values = YES, NO
|
||||
FRSKY_STICKS = NO
|
||||
|
||||
# Sources automatic selection
|
||||
# Values = YES, NO
|
||||
@@ -126,6 +125,13 @@ CORRECT_NEGATIVE_VALUES = YES
|
||||
# Values = YES, NO
|
||||
ARITHMETIC_OVERFLOW_CHECK = NO
|
||||
|
||||
# increases resolution for throttle statistics and throttle counting, in very rare cases.
|
||||
# this will be only true if an output channel is used for throttle calculation, and this chanenel has changed limits, e.g. -90% to +80%
|
||||
# if you use standard limits for throttle or directly the throttle stick you do not need to bother about this option
|
||||
# not valid for ARM based transmitters like Taranis, They do not have this rounding issue at all
|
||||
# Values = YES, NO
|
||||
ACCURAT_THROTTLE_STATS = NO
|
||||
|
||||
# HAPTIC Mods
|
||||
# Values = YES, NO
|
||||
HAPTIC = NO
|
||||
@@ -264,15 +270,16 @@ LUA = NO
|
||||
|
||||
# Menu Lock modes
|
||||
# Values = NO, READONLY, NOMENUS
|
||||
MENUS_LOCK == NO
|
||||
MENUS_LOCK = NO
|
||||
|
||||
#------- END BUILD OPTIONS ---------------------------
|
||||
|
||||
# Define programs and commands.
|
||||
SHELL = sh
|
||||
IMG2LBM = -python ../util/img2lbm.py
|
||||
BIN2LBM = -python ../util/bin2lbm.py
|
||||
TRANSLATE = -python ../util/translate.py
|
||||
VERSION = 2.0
|
||||
VERSION = 1.99
|
||||
|
||||
SRC =
|
||||
CPPSRC =
|
||||
@@ -281,7 +288,7 @@ EXTRAINCDIRS =
|
||||
|
||||
# MCU name
|
||||
ifneq ($(PCB), $(filter $(PCB), STD 9X 9XR STD128 9X128 9XR128 9X2561 9XR2561 GRUVIN9X MEGA2560 SKY9X 9XRPRO TARANIS))
|
||||
$(error Sorry, the PCB $(PCB) is not supported yet in openTx)
|
||||
$(error Sorry, the PCB $(PCB) is not supported yet in OpenTX)
|
||||
endif
|
||||
|
||||
GVARS_VARIANT = +1
|
||||
@@ -616,10 +623,13 @@ ifeq ($(PCB), TARANIS)
|
||||
CPPDEFS = -DREV3
|
||||
else ifeq ($(PCBREV), REV4a)
|
||||
CPPDEFS = -DREV4a
|
||||
else ifeq ($(PCBREV), REVPLUS)
|
||||
CPPDEFS = -DREVPLUS
|
||||
HAPTIC = YES
|
||||
else
|
||||
CPPDEFS = -DREV4
|
||||
endif
|
||||
LDSCRIPT = targets/taranis/stm32_flash.ld
|
||||
LDSCRIPT = targets/taranis/stm32_flash_bl.ld
|
||||
TRGT = arm-none-eabi-
|
||||
MCU = cortex-m3
|
||||
OPT = 2
|
||||
@@ -627,19 +637,26 @@ ifeq ($(PCB), TARANIS)
|
||||
SDCARD = YES
|
||||
THR_TRACE = YES
|
||||
EXT = FRSKY
|
||||
AUTOSWITCH = YES
|
||||
AUTOSOURCE = YES
|
||||
DBLKEYS = YES
|
||||
PPM_LIMITS_SYMETRICAL = YES
|
||||
PPM_CENTER_ADJUSTABLE = YES
|
||||
DSM2 = PPM
|
||||
CPPDEFS += -DPCBTARANIS -DCPUARM -DEEPROM_VARIANT=0 -DAUDIO -DPXX
|
||||
INCDIRS += targets/taranis CoOS/kernel CoOS/portable
|
||||
EXTRAINCDIRS += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/inc targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/Device/ST/STM32F2xx/Include targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/include
|
||||
EXTRAINCDIRS += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_OTG_Driver/inc targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Core/inc
|
||||
EXTRAINCDIRS += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/inc targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/hid/inc
|
||||
BOARDSRC = targets/taranis/board_taranis.cpp
|
||||
EXTRABOARDSRC += targets/taranis/lcd_driver.cpp targets/taranis/aspi.cpp targets/taranis/i2c.c
|
||||
EXTRABOARDSRC += targets/taranis/lcd_driver.cpp targets/taranis/flash_driver.cpp targets/taranis/aspi.c targets/taranis/i2c.c targets/taranis/delays.c
|
||||
SRC += CoOS/kernel/core.c CoOS/kernel/hook.c CoOS/kernel/task.c CoOS/kernel/event.c CoOS/kernel/time.c CoOS/kernel/timer.c CoOS/kernel/flag.c CoOS/kernel/mutex.c CoOS/kernel/serviceReq.c CoOS/portable/GCC/port.c CoOS/portable/arch.c
|
||||
SRC += targets/taranis/pwr_driver.c targets/taranis/usb_driver.c
|
||||
EEPROMSRC = eeprom_common.cpp eeprom_rlc.cpp eeprom_conversions.cpp
|
||||
PULSESSRC = protocols/pulses_arm.cpp protocols/ppm_arm.cpp protocols/pxx_arm.cpp
|
||||
CPPSRC += audio_arm.cpp
|
||||
CPPSRC += targets/taranis/pwr_driver.cpp targets/taranis/pulses_driver.cpp targets/taranis/keys_driver.cpp targets/taranis/adc_driver.cpp targets/taranis/trainer_driver.cpp targets/taranis/audio_driver.cpp targets/taranis/delays.cpp targets/taranis/uart3_driver.cpp targets/taranis/sport_driver.cpp
|
||||
CPPSRC += bmp.cpp gui/view_channels.cpp gui/view_about.cpp gui/view_text.cpp
|
||||
CPPSRC += targets/taranis/pulses_driver.cpp targets/taranis/keys_driver.cpp targets/taranis/adc_driver.cpp targets/taranis/trainer_driver.cpp targets/taranis/audio_driver.cpp targets/taranis/uart3_driver.cpp targets/taranis/sport_driver.cpp
|
||||
CPPSRC += bmp.cpp gui/view_channels.cpp gui/view_about.cpp gui/view_text.cpp loadboot.cpp
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/Device/ST/STM32F2xx/Source/Templates/system_stm32f2xx.c
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/src/misc.c
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/src/stm32f2xx_gpio.c
|
||||
@@ -651,18 +668,14 @@ ifeq ($(PCB), TARANIS)
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/src/stm32f2xx_pwr.c
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/STM32F2xx_StdPeriph_Driver/src/stm32f2xx_usart.c
|
||||
SRC += targets/taranis/STM32F2xx_StdPeriph_Lib_V1.1.0/Libraries/CMSIS/Device/ST/STM32F2xx/Source/Templates/gcc_ride7/startup_stm32f2xx.s
|
||||
SRC += targets/taranis/usb_bsp.c targets/taranis/usbd_desc.c
|
||||
SRC += targets/taranis/usb_bsp.c targets/taranis/usbd_desc.c targets/taranis/usbd_hid_joystick.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_OTG_Driver/src/usb_core.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_OTG_Driver/src/usb_dcd.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_OTG_Driver/src/usb_dcd_int.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Core/src/usbd_core.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Core/src/usbd_ioreq.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Core/src/usbd_req.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/src/usbd_msc_data.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/src/usbd_msc_scsi.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/src/usbd_msc_bot.c
|
||||
SRC += targets/taranis/STM32_USB-Host-Device_Lib_V2.1.0/Libraries/STM32_USB_Device_Library/Class/msc/src/usbd_msc_core.c
|
||||
EXTRABOARDSRC += targets/taranis/usbd_usr.cpp targets/taranis/usbd_storage_msd.cpp
|
||||
EXTRABOARDSRC += targets/taranis/usbd_usr.cpp
|
||||
SRC += targets/sky9x/syscalls.c
|
||||
|
||||
ifneq ($(LUA), NO)
|
||||
@@ -703,6 +716,13 @@ ifeq ($(PCB), TARANIS)
|
||||
CPPSRC += protocols/hubsan.cpp
|
||||
CPPSRC += targets/taranis/a7105_driver.cpp
|
||||
endif
|
||||
|
||||
ifeq ($(HAPTIC), YES)
|
||||
CPPDEFS += -DHAPTIC
|
||||
CPPSRC += haptic.cpp
|
||||
CPPSRC += targets/taranis/haptic_driver.cpp
|
||||
endif
|
||||
|
||||
endif
|
||||
|
||||
CC = $(TRGT)gcc
|
||||
@@ -734,7 +754,7 @@ else
|
||||
TTS_SRC = $(shell sh -c "if test -f $(STD_TTS_SRC); then echo $(STD_TTS_SRC); else echo translations/tts_en.cpp; fi")
|
||||
endif
|
||||
|
||||
CPPSRC += opentx.cpp $(PULSESSRC) stamp.cpp gui/menus.cpp gui/menu_model.cpp gui/menu_general.cpp gui/view_main.cpp gui/view_statistics.cpp $(EEPROMSRC) lcd.cpp keys.cpp maths.cpp translations.cpp $(TTS_SRC)
|
||||
CPPSRC += opentx.cpp $(PULSESSRC) stamp.cpp gui/menus.cpp gui/menu_model.cpp gui/menu_general.cpp gui/view_main.cpp gui/view_statistics.cpp $(EEPROMSRC) lcd.cpp keys.cpp maths.cpp translations.cpp fonts.cpp $(TTS_SRC)
|
||||
|
||||
# Debugging format.
|
||||
# Native formats for AVR-GCC's -g are dwarf-2 [default] or stabs.
|
||||
@@ -791,8 +811,8 @@ ifeq ($(AUTOSOURCE), YES)
|
||||
CPPDEFS += -DAUTOSOURCE
|
||||
endif
|
||||
|
||||
ifeq ($(TARANIS_STICKS), YES)
|
||||
CPPDEFS += -DTARANIS_STICKS
|
||||
ifeq ($(FRSKY_STICKS), YES)
|
||||
CPPDEFS += -DFRSKY_STICKS
|
||||
endif
|
||||
|
||||
|
||||
@@ -864,6 +884,9 @@ ifeq ($(ARITHMETIC_OVERFLOW_CHECK), YES)
|
||||
CPPDEFS += -DPREVENT_ARITHMETIC_OVERFLOW
|
||||
endif
|
||||
|
||||
ifeq ($(ACCURAT_THROTTLE_STATS), YES)
|
||||
CPPDEFS += -DACCURAT_THROTTLE_TIMER
|
||||
endif
|
||||
|
||||
# EXTENSIONS (for Telemetry protocols)
|
||||
ifneq ($(EXT), $(filter $(EXT), STD FRSKY ARDUPILOT NMEA JETI MAVLINK TELEMETREZ))
|
||||
@@ -946,7 +969,7 @@ endif
|
||||
|
||||
ifeq ($(SDCARD), YES)
|
||||
CPPDEFS += -DSDCARD
|
||||
CPPSRC += logs.cpp
|
||||
CPPSRC += logs.cpp strhelpers.cpp
|
||||
endif
|
||||
|
||||
RUN_FROM_FLASH = 1
|
||||
@@ -985,8 +1008,10 @@ ifeq ($(HELI), YES)
|
||||
endif
|
||||
|
||||
ifeq ($(TEMPLATES), YES)
|
||||
CPPDEFS += -DTEMPLATES
|
||||
CPPSRC += templates.cpp
|
||||
ifneq ($(PCB), TARANIS)
|
||||
CPPDEFS += -DTEMPLATES
|
||||
CPPSRC += templates.cpp
|
||||
endif
|
||||
endif
|
||||
|
||||
ifeq ($(PXX), YES)
|
||||
@@ -1062,7 +1087,7 @@ MSG_CLEANING = Cleaning project:
|
||||
# Combine all necessary flags and optional flags.
|
||||
# Add target processor to flags.
|
||||
|
||||
ARMCPPFLAGS = -c -mcpu=$(MCU) -mthumb -fomit-frame-pointer -fverbose-asm -Wa,-ahlms=opentx.lst -DRUN_FROM_FLASH=1 -O$(OPT) $(CPPFLAGS) $(INCFLAGS) $(EXTRAINCFLAGS) $(GENDEPFLAGS)
|
||||
ARMCPPFLAGS = -c -mcpu=$(MCU) -mthumb -fomit-frame-pointer -fverbose-asm -Wa,-ahlms=opentx.lst -DRUN_FROM_FLASH=1 -O$(OPT) $(CPPFLAGS) -fdata-sections -ffunction-sections $(INCFLAGS) $(EXTRAINCFLAGS) $(GENDEPFLAGS)
|
||||
AVRCPPFLAGS = -mmcu=$(MCU) -I. -x c++ -O$(OPT) $(CPPFLAGS) $(INCFLAGS) $(EXTRAINCFLAGS) $(GENDEPFLAGS) -fwhole-program
|
||||
|
||||
ifeq ($(ARCH), AVR)
|
||||
@@ -1088,10 +1113,21 @@ all: begin gccversion sizebefore build sizeafter end
|
||||
# Change the build target to build a HEX file or a library.
|
||||
ifeq ($(ARCH), AVR)
|
||||
build: stamp_header tra lbm allsrc.cpp elf remallsrc hex
|
||||
else ifeq ($(PCB), TARANIS)
|
||||
build: stamp_header tra lbm bootloader.lbm allsrc.cpp elf remallsrc bin
|
||||
else
|
||||
build: stamp_header tra lbm allsrc.cpp elf remallsrc bin
|
||||
endif
|
||||
|
||||
# build bootloader
|
||||
bootloader.lbm: bootloader/bootloader_ramBoot.bin
|
||||
test -z "$$(find $^ -size +32k)"
|
||||
$(BIN2LBM) $^ $@
|
||||
|
||||
.PHONY bootloader/bootloader_ramBoot.bin:
|
||||
@echo "Building bootloader..."
|
||||
$(MAKE) -C bootloader PCB=$(PCB) PCBREV=$(PCBREV)
|
||||
|
||||
tra: translations/en.h translations/cz.h translations/de.h translations/es.h translations/fi.h translations/fr.h translations/it.h translations/pl.h translations/pt.h translations/se.h
|
||||
lbm: fonts bitmaps/sticks.lbm
|
||||
|
||||
@@ -1243,7 +1279,7 @@ sizeafter:
|
||||
@if test -f $(TARGET).elf; then echo; echo $(MSG_SIZE_AFTER); $(ELFSIZE); fi
|
||||
|
||||
# Display compiler version information.
|
||||
gccversion :
|
||||
gccversion:
|
||||
@$(CC) --version
|
||||
|
||||
FOXINC=-I/usr/local/include/fox-1.6 -I/usr/include/fox-1.6 \
|
||||
@@ -1283,8 +1319,7 @@ endif
|
||||
%.eep: %.elf
|
||||
@echo
|
||||
@echo $(MSG_EEPROM) $@
|
||||
-$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" \
|
||||
--change-section-lma .eeprom=0 -O $(FORMAT) $< $@
|
||||
-$(OBJCOPY) -j .eeprom --set-section-flags=.eeprom="alloc,load" --change-section-lma .eeprom=0 -O $(FORMAT) $< $@
|
||||
|
||||
# Create a symbol table from ELF output file.
|
||||
%.sym: %.elf
|
||||
@@ -1323,7 +1358,7 @@ OBJS = $(TMP:.s=.o)
|
||||
@echo
|
||||
@echo $(MSG_COMPILING) $@
|
||||
$(CC) $(ARMCPPFLAGS) $< -o allsrc.o
|
||||
$(CC) $(OBJS) allsrc.o -mcpu=cortex-m3 -mthumb -nostartfiles -lm -T$(LDSCRIPT) -Wl,-Map=$(TARGET).map,--cref,--no-warn-mismatch -o $@
|
||||
$(CC) $(OBJS) allsrc.o -mcpu=cortex-m3 -mthumb -nostartfiles -lm -T$(LDSCRIPT) -Wl,-Map=$(TARGET).map,--cref,--no-warn-mismatch,--gc-sections -o $@
|
||||
endif
|
||||
|
||||
# Target: clean project.
|
||||
@@ -1350,6 +1385,8 @@ clean_list :
|
||||
$(REMOVE) *.lst
|
||||
$(REMOVE) allsrc.cpp
|
||||
$(REMOVE) stamp-opentx.h
|
||||
$(REMOVE) `find . -name "*.lbm"`
|
||||
$(MAKE) -C bootloader clean
|
||||
|
||||
#### Install
|
||||
|
||||
|
||||
Reference in New Issue
Block a user