F7 optimizations (#5674)
commitbf984f39b14c685d20924e05874e4fc53b8df635
authorAndrey Mironov <diehertz@gmail.com>
Thu, 19 Apr 2018 20:37:32 +0000 (19 23:37 +0300)
committerMichael Keller <github@ike.ch>
Thu, 19 Apr 2018 20:37:32 +0000 (20 08:37 +1200)
tree8804400fdbab09a1c64642a139a671abb0c81848
parent39fec69fb0eaad17d68c468a5332221c3fb824cd
F7 optimizations (#5674)

* Revert "Revert "Rewritten F7 dshot to LL (draft)" (#5430)"

This reverts commit aa42a69d2feb4e44c44443394903d33d1b18de6b.

* Reworked F7 linker scripts to maximize performance of both F74x and F72x

* Some comments and changes from original F7 HAL DSHOT

* Prohibit inlining of some functions to place them in ITCM-RAM

* Fixed usartTargetConfigure implicit declaration

* Moved back to SRAM1 as main RAM

* Added SRAM2 attribute

* Fixed LL DSHOT FOR SPRF7DUAL and probably other adv TIM users

* Fixed SPRF7DUAL rev. A motor order

* Enabled CCM for data on F40x

* Fixed F7 startup assembly symbols

* Fixed KISSFCV2F7 linker script

* Added a quick way of building F7 targets only

* Got rid of the useless F7 target script

* Added NOINLINE and got rid of useless __APPLE__ define

* Added some important functions to ITCM

* Added NOINLINE macro for tests

* Copy to ITCM before passing execution into it

* Minimized cache footprint of motor output code

* Evicted low-impact functions from ITCM

* Switched MATEKF722 and SPRACINGF7DUAL to burst DSHOT

* Switched CLRACINGF7 to burst DSHOT

* Moved UART RX&TX buffers to DTCM-RAM to avoid cache incoherency

* Marked taskMainPidLoop for ITCM-RAM, disallowed inlining per-function

* Revert "Added a quick way of building F7 targets only"

This reverts commit 22945189980deaf493be54a5056a080e7edad629.
34 files changed:
lib/main/STM32F7/Drivers/STM32F7xx_HAL_Driver/Src/stm32f7xx_hal.c
make/mcu/STM32F7.mk
src/main/drivers/pwm_output.c
src/main/drivers/pwm_output.h
src/main/drivers/pwm_output_dshot_hal.c
src/main/drivers/serial_uart_hal.c
src/main/drivers/serial_uart_pinconfig.c
src/main/fc/fc_core.c
src/main/fc/fc_rc.c
src/main/flight/mixer.c
src/main/main.c
src/main/platform.h
src/main/sensors/gyro.c
src/main/startup/startup_stm32f40xx.s
src/main/startup/startup_stm32f722xx.s
src/main/startup/startup_stm32f745xx.s
src/main/startup/startup_stm32f746xx.s
src/main/target/CLRACINGF7/target.c
src/main/target/CLRACINGF7/target.h
src/main/target/KISSFCV2F7/stm32_flash_f722_no_split.ld
src/main/target/MATEKF722/target.c
src/main/target/MATEKF722/target.h
src/main/target/SPRACINGF7DUAL/config.c
src/main/target/SPRACINGF7DUAL/target.c
src/main/target/SPRACINGF7DUAL/target.h
src/main/target/common_fc_pre.h
src/main/target/link/stm32_flash_f722.ld
src/main/target/link/stm32_flash_f745.ld [deleted file]
src/main/target/link/stm32_flash_f746.ld [deleted file]
src/main/target/link/stm32_flash_f74x.ld [new file with mode: 0644]
src/main/target/link/stm32_flash_f7_split.ld
src/main/target/stm32f7xx_hal_conf.h
src/main/target/system_stm32f7xx.c
src/test/unit/platform.h