summaryrefslogtreecommitdiff
path: root/src/main.cpp
diff options
context:
space:
mode:
authorokaestne <git@oliver-kaestner.de>2020-11-15 15:05:51 +0100
committerokaestne <git@oliver-kaestner.de>2020-11-16 01:35:45 +0100
commit1516573df46239ea76b7a8b142a6b719668cb26d (patch)
treeb11259f8ca0e10e3d1e2da5df827703ac0294317 /src/main.cpp
parentc3475b92fad2eff4b2a43e5343863d11fe4caca3 (diff)
Include cleanup: components
Diffstat (limited to 'src/main.cpp')
-rw-r--r--src/main.cpp54
1 files changed, 33 insertions, 21 deletions
diff --git a/src/main.cpp b/src/main.cpp
index 45aac6de..35057045 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -1,32 +1,44 @@
-#include <FreeRTOS.h>
-#include <task.h>
-#include <timers.h>
-#include <legacy/nrf_drv_clock.h>
+// nrf
#include <hal/nrf_rtc.h>
#include <hal/nrf_wdt.h>
-#include <os/os_cputime.h>
-#include <libraries/timer/app_timer.h>
+#include <legacy/nrf_drv_clock.h>
#include <libraries/gpiote/app_gpiote.h>
-#include "displayapp/DisplayApp.h"
+#include <libraries/timer/app_timer.h>
#include <softdevice/common/nrf_sdh.h>
-#include "components/datetime/DateTimeController.h"
-#include "components/battery/BatteryController.h"
-#include "components/ble/BleController.h"
-#include "components/ble/NotificationManager.h"
-#include <drivers/St7789.h>
-#include <drivers/SpiMaster.h>
-#include <drivers/Spi.h>
-#include "displayapp/LittleVgl.h"
-#include <systemtask/SystemTask.h>
-#include <nimble/nimble_port_freertos.h>
-#include <nimble/npl_freertos.h>
-#include <nimble/nimble_port.h>
-#include <host/ble_hs.h>
+
+// nimble
+#define min // workaround: nimble's min/max macros conflict with libstdc++
+#define max
#include <controller/ble_ll.h>
-#include <transport/ram/ble_hci_ram.h>
+#include <host/ble_hs.h>
#include <host/util/util.h>
+#include <nimble/nimble_port.h>
+#include <nimble/nimble_port_freertos.h>
+#include <nimble/npl_freertos.h>
+#include <os/os_cputime.h>
#include <services/gap/ble_svc_gap.h>
+#include <transport/ram/ble_hci_ram.h>
+#undef max
+#undef min
+
+// FreeRTOS
+#include <FreeRTOS.h>
+#include <task.h>
+#include <timers.h>
+#include "components/battery/BatteryController.h"
+#include "components/ble/BleController.h"
+#include "components/ble/NotificationManager.h"
+#include "components/datetime/DateTimeController.h"
+#include "displayapp/DisplayApp.h"
+#include "displayapp/LittleVgl.h"
+#include "drivers/Spi.h"
+#include "drivers/SpiMaster.h"
+#include "drivers/SpiNorFlash.h"
+#include "drivers/St7789.h"
+#include "drivers/TwiMaster.h"
+#include "drivers/Cst816s.h"
+#include "systemtask/SystemTask.h"
#if NRF_LOG_ENABLED
#include "logging/NrfLogger.h"