Skip to content

Commit

Permalink
Merge branch 'master' into mavlink-cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
hydra committed Oct 13, 2016
2 parents a07eb7f + e2d51a7 commit bb842ee
Show file tree
Hide file tree
Showing 267 changed files with 9,885 additions and 3,615 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ obj/
patches/
startup_stm32f10x_md_gcc.s
.vagrant/
.vscode/

# script-generated files
docs/Manual.pdf
Expand Down
10 changes: 7 additions & 3 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ env:
- TARGET=CHEBUZZF3
- TARGET=OLIMEXINO
- TARGET=IRCFUSIONF3
- TARGET=RCEXPLORERF3

# use new docker environment
sudo: false
Expand All @@ -39,21 +40,24 @@ addons:
- wkhtmltopdf
- libxml2-dev
- libxslt-dev
- ccache

# We use cpp for unit tests, and c for the main project.
language: cpp
compiler: clang

before_install:
- curl --retry 10 --retry-max-time 120 -L "https://launchpad.net/gcc-arm-embedded/4.9/4.9-2015-q2-update/+download/gcc-arm-none-eabi-4_9-2015q2-20150609-linux.tar.bz2" | tar xfj -
- curl --retry 10 --retry-max-time 120 -L "https://launchpad.net/gcc-arm-embedded/5.0/5-2016-q2-update/+download/gcc-arm-none-eabi-5_4-2016q2-20160622-linux.tar.bz2" | tar xfj -

install:
- export PATH=$PATH:$PWD/gcc-arm-none-eabi-4_9-2015q2/bin
- export PATH=$PATH:$PWD/gcc-arm-none-eabi-5_4-2016q2/bin

before_script: arm-none-eabi-gcc --version
script: ./.travis.sh

cache: apt
cache:
- apt
- ccache

notifications:
irc: "chat.freenode.net#cleanflight"
Expand Down
83 changes: 69 additions & 14 deletions Makefile
100755 → 100644
Original file line number Diff line number Diff line change
Expand Up @@ -38,13 +38,13 @@ FORKNAME = cleanflight

64K_TARGETS = CJMCU
128K_TARGETS = ALIENFLIGHTF1 CC3D NAZE OLIMEXINO RMDO SPRACINGF1OSD
256K_TARGETS = ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE EUSTM32F103RC IRCFUSIONF3 LUX_RACE MOTOLAB PORT103R SPARKY SPRACINGF3 SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF3OSD
256K_TARGETS = ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE EUSTM32F103RC IRCFUSIONF3 LUX_RACE MOTOLAB PORT103R RCEXPLORERF3 SPARKY SPRACINGF3 SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF3OSD

F3_TARGETS = ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE IRCFUSIONF3 LUX_RACE MOTOLAB RMDO SPARKY SPRACINGF3 SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF3OSD
F3_TARGETS = ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE IRCFUSIONF3 LUX_RACE MOTOLAB RCEXPLORERF3 RMDO SPARKY SPRACINGF3 SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF3OSD

VALID_TARGETS = $(64K_TARGETS) $(128K_TARGETS) $(256K_TARGETS)

VCP_TARGETS = CC3D ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE LUX_RACE MOTOLAB SPARKY SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF1OSD SPRACINGF3OSD
VCP_TARGETS = CC3D ALIENFLIGHTF3 CHEBUZZF3 COLIBRI_RACE LUX_RACE MOTOLAB RCEXPLORERF3 SPARKY SPRACINGF3EVO SPRACINGF3MINI STM32F3DISCOVERY SPRACINGF1OSD SPRACINGF3OSD
OSD_TARGETS = SPRACINGF1OSD SPRACINGF3OSD

# Configure default flash sizes for the targets
Expand Down Expand Up @@ -149,7 +149,7 @@ INCLUDE_DIRS := $(INCLUDE_DIRS) \
LD_SCRIPT = $(LINKER_DIR)/stm32_flash_f103_$(FLASH_SIZE)k.ld

ARCH_FLAGS = -mthumb -mcpu=cortex-m3
TARGET_FLAGS = -D$(TARGET) -pedantic
TARGET_FLAGS = -D$(TARGET)
DEVICE_FLAGS = -DSTM32F10X_HD -DSTM32F10X

DEVICE_STDPERIPH_SRC = $(STDPERIPH_SRC)
Expand Down Expand Up @@ -194,7 +194,7 @@ endif
LD_SCRIPT = $(LINKER_DIR)/stm32_flash_f103_$(FLASH_SIZE)k.ld

ARCH_FLAGS = -mthumb -mcpu=cortex-m3
TARGET_FLAGS = -D$(TARGET) -pedantic
TARGET_FLAGS = -D$(TARGET)
DEVICE_FLAGS = -DSTM32F10X_MD -DSTM32F10X

endif #TARGETS
Expand Down Expand Up @@ -246,6 +246,8 @@ SYSTEM_SRC = \
common/printf.c \
common/streambuf.c \
common/typeconversion.c \
common/crc.c \
common/pilot.c \
drivers/buf_writer.c \
drivers/dma.c \
drivers/serial.c \
Expand All @@ -255,14 +257,16 @@ SYSTEM_SRC = \
io/statusindicator.c \
msp/msp.c \
msp/msp_serial.c \
msp/msp_server.c \
$(TARGET_SRC) \
$(CMSIS_SRC) \
$(DEVICE_STDPERIPH_SRC)

FC_COMMON_SRC = \
config/feature.c \
config/profile.c \
fc/boot.c \
fc/fc_debug.c \
fc/cleanflight_fc.c \
fc/fc_tasks.c \
fc/rate_profile.c \
Expand All @@ -283,11 +287,15 @@ FC_COMMON_SRC = \
flight/mixer.c \
flight/servos.c \
drivers/bus_i2c_soft.c \
drivers/exti.c \
drivers/io.c \
drivers/rcc.c \
drivers/sound_beeper.c \
drivers/gyro_sync.c \
io/beeper.c \
io/gimbal.c \
io/motor_and_servo.c \
io/servos.c \
io/motors.c \
io/serial_4way.c \
io/serial_4way_avrootloader.c \
io/serial_4way_stk500v2.c \
Expand All @@ -302,25 +310,34 @@ FC_COMMON_SRC = \
rx/spektrum.c \
rx/xbus.c \
rx/ibus.c \
rx/srxl.c \
sensors/sensors.c \
sensors/acceleration.c \
sensors/battery.c \
sensors/voltage.c \
sensors/amperage.c \
sensors/boardalignment.c \
sensors/compass.c \
sensors/gyro.c \
sensors/initialisation.c

OSD_COMMON_SRC = \
config/feature.c \
osd/boot.c \
osd/cleanflight_osd.c \
osd/fc_state.c \
osd/config.c \
osd/osd.c \
osd/osd_screen.c \
osd/osd_element.c \
osd/osd_element_render.c \
osd/osd_serial.c \
osd/msp_server_osd.c \
osd/msp_client_osd.c \
osd/osd_tasks.c \
sensors/battery.c \
sensors/voltage.c \
sensors/amperage.c \
io/beeper.c

HIGHEND_SRC = \
Expand Down Expand Up @@ -351,7 +368,7 @@ VCP_SRC = \
vcp/usb_prop.c \
vcp/usb_pwr.c \
drivers/serial_usb_vcp.c \
drivers/usb_io.c
drivers/usb_io.c

STM32F10x_COMMON_SRC = \
drivers/adc.c \
Expand Down Expand Up @@ -584,7 +601,7 @@ COLIBRI_RACE_SRC = \
$(FC_COMMON_SRC) \
$(SYSTEM_SRC) \
$(VCP_SRC)

LUX_RACE_SRC = \
$(STM32F30x_COMMON_SRC) \
$(STM32F30x_FC_COMMON_SRC) \
Expand Down Expand Up @@ -631,13 +648,34 @@ ALIENFLIGHTF3_SRC = \
$(FC_COMMON_SRC) \
$(SYSTEM_SRC) \
$(VCP_SRC)

RCEXPLORERF3_SRC = \
$(STM32F30x_COMMON_SRC) \
$(STM32F30x_FC_COMMON_SRC) \
drivers/accgyro_mpu.c \
drivers/accgyro_spi_mpu6000.c \
drivers/barometer_ms5611.c \
drivers/compass_hmc5883l.c \
drivers/compass_ak8975.c \
drivers/display_ug2864hsweg01.c \
drivers/serial_usb_vcp.c \
drivers/flash_m25p16.c \
drivers/light_ws2811strip.c \
drivers/light_ws2811strip_stm32f30x.c \
drivers/sonar_hcsr04.c \
io/flashfs.c \
$(HIGHEND_SRC) \
$(FC_COMMON_SRC) \
$(SYSTEM_SRC) \
$(VCP_SRC)

RMDO_SRC = \
$(STM32F30x_COMMON_SRC) \
$(STM32F30x_FC_COMMON_SRC) \
drivers/accgyro_mpu.c \
drivers/accgyro_mpu6050.c \
drivers/barometer_bmp280.c \
drivers/compass_hmc5883l.c \
drivers/display_ug2864hsweg01.h \
drivers/flash_m25p16.c \
drivers/light_ws2811strip.c \
Expand Down Expand Up @@ -679,6 +717,7 @@ SPRACINGF3EVO_SRC = \
drivers/display_ug2864hsweg01.h \
drivers/light_ws2811strip.c \
drivers/light_ws2811strip_stm32f30x.c \
drivers/serial_softserial.c \
drivers/serial_usb_vcp.c \
drivers/sdcard.c \
drivers/sdcard_standard.c \
Expand Down Expand Up @@ -737,7 +776,7 @@ SPRACINGF3MINI_SRC = \
$(FC_COMMON_SRC) \
$(SYSTEM_SRC) \
$(VCP_SRC)

IRCFUSIONF3_SRC = \
$(STM32F30x_COMMON_SRC) \
$(STM32F30x_FC_COMMON_SRC) \
Expand All @@ -756,6 +795,9 @@ SPRACINGF1OSD_SRC = \
drivers/bus_spi.c \
drivers/video_max7456.c \
drivers/flash_m25p16.c \
drivers/io.c \
drivers/exti.c \
drivers/rcc.c \
io/flashfs.c \
osd/fonts/font_max7456_12x18.c \
osd/osd_max7456.c \
Expand All @@ -767,7 +809,13 @@ SPRACINGF3OSD_SRC = \
$(STM32F30x_COMMON_SRC) \
drivers/video_max7456.c \
drivers/flash_m25p16.c \
drivers/io.c \
drivers/exti.c \
drivers/rcc.c \
drivers/transponder_ir.c \
drivers/transponder_ir_stm32f30x.c \
io/flashfs.c \
io/transponder_ir.c \
osd/fonts/font_max7456_12x18.c \
osd/osd_max7456.c \
$(OSD_COMMON_SRC) \
Expand All @@ -781,10 +829,17 @@ VPATH := $(VPATH):$(STDPERIPH_DIR)/src
# Things that might need changing to use different tools
#

# Find out if ccache is installed on the system
CCACHE := ccache
RESULT = $(shell (which $(CCACHE) > /dev/null 2>&1; echo $$?) )
ifneq ($(RESULT),0)
CCACHE :=
endif

# Tool names
CC = arm-none-eabi-gcc
OBJCOPY = arm-none-eabi-objcopy
SIZE = arm-none-eabi-size
CC := $(CCACHE) arm-none-eabi-gcc
OBJCOPY := arm-none-eabi-objcopy
SIZE := arm-none-eabi-size

#
# Tool options.
Expand All @@ -811,7 +866,7 @@ CFLAGS = $(ARCH_FLAGS) \
$(addprefix -I,$(INCLUDE_DIRS)) \
$(DEBUG_FLAGS) \
-std=gnu99 \
-Wall -Wextra -Wunsafe-loop-optimizations -Wdouble-promotion -Wundef \
-Wall -Wpedantic -Wextra -Wunsafe-loop-optimizations -Wdouble-promotion -Wundef \
-ffunction-sections \
-fdata-sections \
$(DEVICE_FLAGS) \
Expand Down
2 changes: 1 addition & 1 deletion Notes.md
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ acc x increases (blue)
acc z decreases (red)
mag x decreases (blue)

lift left of boar (i.e. roll right)
lift left of board (i.e. roll right)
gyro x increases (blue)
acc y increases (green)
mag y decreases (green)
Expand Down
6 changes: 4 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Please subscribe and '+1' the videos if you find them useful.
## Configuration Tool

To configure Cleanflight you should use the [Cleanflight-configurator GUI tool](https://chrome.google.com/webstore/detail/cleanflight-configurator/enacoimjcgeinfnnnpajinjgmkahmfgb
) (Windows/OSX/Linux) that can be found here:
) (Windows/OSX/Linux).

The source for it is here:

Expand All @@ -92,9 +92,11 @@ Contributions are welcome and encouraged. You can contribute in many ways:
* New features.
* Telling us your ideas and suggestions.

The best place to start is the IRC channel on freenode (see above), drop in, say hi. Next place is the github issue tracker:
The best place to start is the IRC channel on freenode (see above), drop in, say hi.
Next place is the github issue tracker:

https://github.com/cleanflight/cleanflight/issues

https://github.com/cleanflight/cleanflight-configurator/issues

Before creating new issues please check to see if there is an existing one, search first otherwise you waste peoples time when they could be coding instead!
Expand Down
Loading

0 comments on commit bb842ee

Please sign in to comment.