aboutsummaryrefslogtreecommitdiffstats
path: root/boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c
diff options
context:
space:
mode:
Diffstat (limited to 'boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c')
-rw-r--r--boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c22
1 files changed, 12 insertions, 10 deletions
diff --git a/boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c b/boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c
index 73df79e8..4fb5cebb 100644
--- a/boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c
+++ b/boards/base/STM32F746-Discovery/stm32f746g_raw32_ugfx.c
@@ -1,16 +1,18 @@
#include "gfx.h"
#include "stm32f7xx_hal.h"
-#if !GFX_USE_OS_CHIBIOS
-systemticks_t gfxSystemTicks(void)
-{
- return HAL_GetTick();
-}
-
-systemticks_t gfxMillisecondsToTicks(delaytime_t ms)
-{
- return ms;
-}
+#if GFX_USE_OS_CHIBIOS
+ #define HAL_GPIO_Init(port, ptr) palSetGroupMode(port, (ptr)->Pin, 0, (ptr)->Mode|((ptr)->Speed<<3)|((ptr)->Pull<<5)|((ptr)->Alternate<<7))
+#else
+ systemticks_t gfxSystemTicks(void)
+ {
+ return HAL_GetTick();
+ }
+
+ systemticks_t gfxMillisecondsToTicks(delaytime_t ms)
+ {
+ return ms;
+ }
#endif
static void SystemClock_Config(void);