diff options
Diffstat (limited to 'boards/base/STM32F429i-Discovery')
4 files changed, 50 insertions, 39 deletions
diff --git a/boards/base/STM32F429i-Discovery/example_chibios_3.x/Makefile b/boards/base/STM32F429i-Discovery/example_chibios_3.x/Makefile index 217d1d24..16611673 100644 --- a/boards/base/STM32F429i-Discovery/example_chibios_3.x/Makefile +++ b/boards/base/STM32F429i-Discovery/example_chibios_3.x/Makefile @@ -13,20 +13,22 @@ # uGFX settings # See $(GFXLIB)/tools/gmake_scripts/library_ugfx.mk for the list of variables - GFXLIB = ../uGFX + GFXLIB = ../../resources/ugfx GFXBOARD = STM32F429i-Discovery GFXDEMO = modules/gdisp/basics # ChibiOS settings ifeq ($(OPT_OS),chibios) - # See $(GFXLIB)/tools/gmake_scripts/os_chibios.mk for the list of variables - CHIBIOS = ../ChibiOS3 - CHIBIOS_VERSION = 3 - CHIBIOS_BOARD = ST_STM32F429I_DISCOVERY - CHIBIOS_CPUCLASS = ARMCMx - CHIBIOS_PLATFORM = STM32/STM32F4xx - CHIBIOS_PORT = stm32f4xx - CHIBIOS_LDSCRIPT = STM32F407xG.ld + # See $(GFXLIB)/tools/gmake_scripts/os_chibios_x.mk for the list of variables + CHIBIOS = ../../resources/chibios_3.0.1 + CHIBIOS_VERSION = 3 + CHIBIOS_BOARD = ST_STM32F429I_DISCOVERY + CHIBIOS_CPUCLASS = ARMCMx + CHIBIOS_PLATFORM = STM32 + CHIBIOS_DEVICE_FAMILY = STM32F4xx + CHIBIOS_STARTUP = startup_stm32f4xx + CHIBIOS_PORT = v7m + CHIBIOS_LDSCRIPT = STM32F429xI.ld endif ############################################################################################## diff --git a/boards/base/STM32F429i-Discovery/example_chibios_3.x/chconf.h b/boards/base/STM32F429i-Discovery/example_chibios_3.x/chconf.h index 53700421..4a34b223 100644 --- a/boards/base/STM32F429i-Discovery/example_chibios_3.x/chconf.h +++ b/boards/base/STM32F429i-Discovery/example_chibios_3.x/chconf.h @@ -1,5 +1,5 @@ /* - ChibiOS - Copyright (C) 2006-2014 Giovanni Di Sirio + ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -99,7 +99,8 @@ * @details When this option is activated the function @p chSysInit() * does not spawn the idle thread. The application @p main() * function becomes the idle thread and must implement an - * infinite loop. */ + * infinite loop. + */ #define CH_CFG_NO_IDLE_THREAD FALSE /** @} */ @@ -440,7 +441,7 @@ * @details This hook is invoked just before switching between threads. */ #define CH_CFG_CONTEXT_SWITCH_HOOK(ntp, otp) { \ - /* System halt code here.*/ \ + /* Context switch code here.*/ \ } /** @@ -449,7 +450,7 @@ * should be invoked from here. * @note This macro can be used to activate a power saving mode. */ -#define CH_CFG_IDLE_ENTER_HOOK() { \ +#define CH_CFG_IDLE_ENTER_HOOK() { \ } /** @@ -458,7 +459,7 @@ * should be invoked from here. * @note This macro can be used to deactivate a power saving mode. */ -#define CH_CFG_IDLE_LEAVE_HOOK() { \ +#define CH_CFG_IDLE_LEAVE_HOOK() { \ } /** diff --git a/boards/base/STM32F429i-Discovery/example_chibios_3.x/halconf.h b/boards/base/STM32F429i-Discovery/example_chibios_3.x/halconf.h index 90ceebc0..6f80a255 100644 --- a/boards/base/STM32F429i-Discovery/example_chibios_3.x/halconf.h +++ b/boards/base/STM32F429i-Discovery/example_chibios_3.x/halconf.h @@ -1,5 +1,5 @@ /* - ChibiOS - Copyright (C) 2006-2014 Giovanni Di Sirio + ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -52,6 +52,13 @@ #endif /** + * @brief Enables the DAC subsystem. + */ +#if !defined(HAL_USE_DAC) || defined(__DOXYGEN__) +#define HAL_USE_DAC FALSE +#endif + +/** * @brief Enables the EXT subsystem. */ #if !defined(HAL_USE_EXT) || defined(__DOXYGEN__) @@ -125,14 +132,14 @@ * @brief Enables the SERIAL subsystem. */ #if !defined(HAL_USE_SERIAL) || defined(__DOXYGEN__) -#define HAL_USE_SERIAL FALSE +#define HAL_USE_SERIAL TRUE #endif /** * @brief Enables the SERIAL over USB subsystem. */ #if !defined(HAL_USE_SERIAL_USB) || defined(__DOXYGEN__) -#define HAL_USE_SERIAL_USB TRUE +#define HAL_USE_SERIAL_USB FALSE #endif /** diff --git a/boards/base/STM32F429i-Discovery/example_chibios_3.x/mcuconf.h b/boards/base/STM32F429i-Discovery/example_chibios_3.x/mcuconf.h index c64b2740..80417b89 100644 --- a/boards/base/STM32F429i-Discovery/example_chibios_3.x/mcuconf.h +++ b/boards/base/STM32F429i-Discovery/example_chibios_3.x/mcuconf.h @@ -1,5 +1,5 @@ /* - ChibiOS - Copyright (C) 2006-2014 Giovanni Di Sirio + ChibiOS - Copyright (C) 2006..2015 Giovanni Di Sirio Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. @@ -14,6 +14,9 @@ limitations under the License. */ +#ifndef _MCUCONF_H_ +#define _MCUCONF_H_ + /* * STM32F4xx drivers configuration. * The following settings override the default settings present in @@ -88,6 +91,19 @@ #define STM32_CAN_CAN2_IRQ_PRIORITY 11 /* + * DAC driver system settings. + */ +#define STM32_DAC_DUAL_MODE FALSE +#define STM32_DAC_USE_DAC1_CH1 FALSE +#define STM32_DAC_USE_DAC1_CH2 FALSE +#define STM32_DAC_DAC1_CH1_IRQ_PRIORITY 10 +#define STM32_DAC_DAC1_CH2_IRQ_PRIORITY 10 +#define STM32_DAC_DAC1_CH1_DMA_PRIORITY 2 +#define STM32_DAC_DAC1_CH2_DMA_PRIORITY 2 +#define STM32_DAC_DAC1_CH1_DMA_STREAM STM32_DMA_STREAM_ID(1, 5) +#define STM32_DAC_DAC1_CH2_DMA_STREAM STM32_DMA_STREAM_ID(1, 6) + +/* * EXT driver system settings. */ #define STM32_EXT_EXTI0_IRQ_PRIORITY 6 @@ -136,10 +152,9 @@ /* * I2C driver system settings. */ -#define HAL_USE_I2C TRUE #define STM32_I2C_USE_I2C1 FALSE #define STM32_I2C_USE_I2C2 FALSE -#define STM32_I2C_USE_I2C3 TRUE +#define STM32_I2C_USE_I2C3 FALSE #define STM32_I2C_BUSY_TIMEOUT 50 #define STM32_I2C_I2C1_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) #define STM32_I2C_I2C1_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 6) @@ -218,7 +233,7 @@ * SERIAL driver system settings. */ #define STM32_SERIAL_USE_USART1 FALSE -#define STM32_SERIAL_USE_USART2 FALSE +#define STM32_SERIAL_USE_USART2 TRUE #define STM32_SERIAL_USE_USART3 FALSE #define STM32_SERIAL_USE_UART4 FALSE #define STM32_SERIAL_USE_UART5 FALSE @@ -233,37 +248,21 @@ /* * SPI driver system settings. */ -#define HAL_USE_SPI TRUE #define STM32_SPI_USE_SPI1 FALSE #define STM32_SPI_USE_SPI2 FALSE #define STM32_SPI_USE_SPI3 FALSE -#define STM32_SPI_USE_SPI4 FALSE -#define STM32_SPI_USE_SPI5 TRUE -#define STM32_SPI_USE_SPI6 FALSE #define STM32_SPI_SPI1_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 0) #define STM32_SPI_SPI1_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 3) #define STM32_SPI_SPI2_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 3) #define STM32_SPI_SPI2_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 4) #define STM32_SPI_SPI3_RX_DMA_STREAM STM32_DMA_STREAM_ID(1, 0) #define STM32_SPI_SPI3_TX_DMA_STREAM STM32_DMA_STREAM_ID(1, 7) -#define STM32_SPI_SPI4_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 0) -#define STM32_SPI_SPI4_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 1) -#define STM32_SPI_SPI5_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 3) -#define STM32_SPI_SPI5_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 4) -#define STM32_SPI_SPI6_RX_DMA_STREAM STM32_DMA_STREAM_ID(2, 6) -#define STM32_SPI_SPI6_TX_DMA_STREAM STM32_DMA_STREAM_ID(2, 5) #define STM32_SPI_SPI1_DMA_PRIORITY 1 #define STM32_SPI_SPI2_DMA_PRIORITY 1 #define STM32_SPI_SPI3_DMA_PRIORITY 1 -#define STM32_SPI_SPI4_DMA_PRIORITY 1 -#define STM32_SPI_SPI5_DMA_PRIORITY 1 -#define STM32_SPI_SPI6_DMA_PRIORITY 1 #define STM32_SPI_SPI1_IRQ_PRIORITY 10 #define STM32_SPI_SPI2_IRQ_PRIORITY 10 #define STM32_SPI_SPI3_IRQ_PRIORITY 10 -#define STM32_SPI_SPI4_IRQ_PRIORITY 10 -#define STM32_SPI_SPI5_IRQ_PRIORITY 10 -#define STM32_SPI_SPI6_IRQ_PRIORITY 10 #define STM32_SPI_DMA_ERROR_HOOK(spip) osalSysHalt("DMA failure") /* @@ -310,8 +309,8 @@ /* * USB driver system settings. */ -#define STM32_USB_USE_OTG1 FALSE -#define STM32_USB_USE_OTG2 TRUE +#define STM32_USB_USE_OTG1 TRUE +#define STM32_USB_USE_OTG2 FALSE #define STM32_USB_OTG1_IRQ_PRIORITY 14 #define STM32_USB_OTG2_IRQ_PRIORITY 14 #define STM32_USB_OTG1_RX_FIFO_SIZE 512 @@ -319,3 +318,5 @@ #define STM32_USB_OTG_THREAD_PRIO LOWPRIO #define STM32_USB_OTG_THREAD_STACK_SIZE 128 #define STM32_USB_OTGFIFO_FILL_BASEPRI 0 + +#endif /* _MCUCONF_H_ */ |