diff --git a/Makefile b/Makefile index 3940d4934..25371b5cb 100644 --- a/Makefile +++ b/Makefile @@ -48,17 +48,17 @@ COMMON_SRC = startup_stm32f10x_md_gcc.S \ buzzer.c \ config.c \ common/maths.c \ + common/printf.c \ + common/typeconversion.c \ failsafe.c \ main.c \ mw.c \ - printf.c \ sensors_acceleration.c \ sensors_barometer.c \ sensors_compass.c \ sensors_gyro.c \ sensors_initialisation.c \ sensors_sonar.c \ - typeconversion.c \ drivers/bus_i2c.c \ drivers/bus_i2c_soft.c \ drivers/gpio_common.c \ @@ -77,7 +77,6 @@ COMMON_SRC = startup_stm32f10x_md_gcc.S \ telemetry_common.c \ telemetry_frsky.c \ telemetry_hott.c \ - typeconversion.c \ serial_cli.c \ serial_msp.c \ statusindicator.c \ diff --git a/src/build_config.c b/src/build_config.c index 518db3ac2..4bb7e39d9 100644 --- a/src/build_config.c +++ b/src/build_config.c @@ -5,6 +5,9 @@ #include "platform.h" +#include "build_config.h" +#include "common/printf.h" + #include "drivers/gpio_common.h" #include "drivers/timer_common.h" #include "drivers/pwm_common.h" @@ -16,9 +19,7 @@ #include "drivers/serial_common.h" #include "runtime_config.h" -#include "printf.h" -#include "build_config.h" #if MAX_MOTORS != MAX_SUPPORTED_MOTORS #error Motor configuration mismatch diff --git a/src/printf.c b/src/common/printf.c similarity index 100% rename from src/printf.c rename to src/common/printf.c diff --git a/src/printf.h b/src/common/printf.h similarity index 100% rename from src/printf.h rename to src/common/printf.h diff --git a/src/typeconversion.c b/src/common/typeconversion.c similarity index 100% rename from src/typeconversion.c rename to src/common/typeconversion.c diff --git a/src/typeconversion.h b/src/common/typeconversion.h similarity index 100% rename from src/typeconversion.h rename to src/common/typeconversion.h diff --git a/src/mw.c b/src/mw.c index fcb0f5467..0237eedde 100755 --- a/src/mw.c +++ b/src/mw.c @@ -2,11 +2,11 @@ #include "mw.h" #include "common/maths.h" +#include "common/typeconversion.h" #include "flight_common.h" #include "serial_cli.h" #include "telemetry_common.h" -#include "typeconversion.h" #include "gps_common.h" #include "rx_common.h" #include "rx_sbus.h" diff --git a/src/serial_cli.c b/src/serial_cli.c index 34f967907..6c0007190 100644 --- a/src/serial_cli.c +++ b/src/serial_cli.c @@ -3,7 +3,7 @@ #include "board.h" #include "mw.h" -#include "printf.h" +#include "common/printf.h" #include "telemetry_common.h" #include "gps_common.h"