[bsp][stm32][469]修复编译错误。

Signed-off-by: Willian Chan <chentingwei@rt-thread.com>
This commit is contained in:
Willian Chan 2019-04-12 15:22:34 +08:00
parent 16e8f34e46
commit d8bbf27d3c
10 changed files with 24 additions and 122 deletions

File diff suppressed because one or more lines are too long

View File

@ -1,16 +1,4 @@
#MicroXplorer Configuration settings - do not modify
Dma.Request0=SPI3_RX
Dma.RequestsNb=1
Dma.SPI3_RX.0.Direction=DMA_PERIPH_TO_MEMORY
Dma.SPI3_RX.0.FIFOMode=DMA_FIFOMODE_DISABLE
Dma.SPI3_RX.0.Instance=DMA1_Stream0
Dma.SPI3_RX.0.MemDataAlignment=DMA_MDATAALIGN_BYTE
Dma.SPI3_RX.0.MemInc=DMA_MINC_ENABLE
Dma.SPI3_RX.0.Mode=DMA_NORMAL
Dma.SPI3_RX.0.PeriphDataAlignment=DMA_PDATAALIGN_BYTE
Dma.SPI3_RX.0.PeriphInc=DMA_PINC_DISABLE
Dma.SPI3_RX.0.Priority=DMA_PRIORITY_LOW
Dma.SPI3_RX.0.RequestParameters=Instance,Direction,PeriphInc,MemInc,PeriphDataAlignment,MemDataAlignment,Mode,Priority,FIFOMode
FMC.CASLatency1=FMC_SDRAM_CAS_LATENCY_3
FMC.ExitSelfRefreshDelay1=7
FMC.IPParameters=CASLatency1,ReadBurst1,ReadBurst2,SDClockPeriod1,SDClockPeriod2,LoadToActiveDelay1,ExitSelfRefreshDelay1,SelfRefreshTime1,RowCycleDelay1,RowCycleDelay2,WriteRecoveryTime1,RPDelay1,RPDelay2,RCDDelay1
@ -39,19 +27,18 @@ I2S3.VirtualMode=I2S_MODE_MASTER
KeepUserPlacement=false
Mcu.Family=STM32F4
Mcu.IP0=CRC
Mcu.IP1=DMA
Mcu.IP10=TIM4
Mcu.IP11=USART3
Mcu.IP12=USB_OTG_FS
Mcu.IP2=FMC
Mcu.IP3=GFXSIMULATOR
Mcu.IP4=I2S3
Mcu.IP5=NVIC
Mcu.IP6=PDM2PCM
Mcu.IP7=QUADSPI
Mcu.IP8=RCC
Mcu.IP9=SYS
Mcu.IPNb=13
Mcu.IP1=FMC
Mcu.IP10=USART3
Mcu.IP11=USB_OTG_FS
Mcu.IP2=GFXSIMULATOR
Mcu.IP3=I2S3
Mcu.IP4=NVIC
Mcu.IP5=PDM2PCM
Mcu.IP6=QUADSPI
Mcu.IP7=RCC
Mcu.IP8=SYS
Mcu.IP9=TIM4
Mcu.IPNb=12
Mcu.Name=STM32F469NIHx
Mcu.Package=TFBGA216
Mcu.Pin0=PE1
@ -142,7 +129,6 @@ Mcu.UserName=STM32F469NIHx
MxCube.Version=5.1.0
MxDb.Version=DB.5.0.10
NVIC.BusFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false
NVIC.DMA1_Stream0_IRQn=true\:0\:0\:false\:false\:true\:false\:true
NVIC.DebugMonitor_IRQn=true\:0\:0\:false\:false\:true\:false\:false
NVIC.HardFault_IRQn=true\:0\:0\:false\:false\:true\:false\:false
NVIC.MemoryManagement_IRQn=true\:0\:0\:false\:false\:true\:false\:false
@ -306,7 +292,7 @@ ProjectManager.StackSize=0x400
ProjectManager.TargetToolchain=MDK-ARM V5
ProjectManager.ToolChainLocation=
ProjectManager.UnderRoot=false
ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-MX_DMA_Init-DMA-false-HAL-true,3-MX_USART3_UART_Init-USART3-false-HAL-true,4-MX_FMC_Init-FMC-false-HAL-true,5-MX_QUADSPI_Init-QUADSPI-false-HAL-true,6-MX_GFXSIMULATOR_Init-GFXSIMULATOR-false-HAL-true,7-MX_CRC_Init-CRC-false-HAL-true,8-MX_I2S3_Init-I2S3-false-HAL-true,9-MX_TIM4_Init-TIM4-false-HAL-true,10-MX_PDM2PCM_Init-PDM2PCM-false-HAL-true,11-MX_USB_OTG_FS_PCD_Init-USB_OTG_FS-false-HAL-true,12-SystemClock_Config-RCC-false-HAL-false
ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-MX_USART3_UART_Init-USART3-false-HAL-true,3-MX_FMC_Init-FMC-false-HAL-true,4-MX_QUADSPI_Init-QUADSPI-false-HAL-true,5-MX_GFXSIMULATOR_Init-GFXSIMULATOR-false-HAL-true,6-MX_CRC_Init-CRC-false-HAL-true,7-MX_I2S3_Init-I2S3-false-HAL-true,8-MX_TIM4_Init-TIM4-false-HAL-true,9-MX_PDM2PCM_Init-PDM2PCM-false-HAL-true,10-MX_USB_OTG_FS_PCD_Init-USB_OTG_FS-false-HAL-true,11-SystemClock_Config-RCC-false-HAL-false
QUADSPI.ChipSelectHighTime=QSPI_CS_HIGH_TIME_5_CYCLE
QUADSPI.ClockPrescaler=1
QUADSPI.FifoThreshold=4

View File

@ -36,8 +36,6 @@
/* Global variables ---------------------------------------------------------*/
extern PDM_Filter_Handler_t PDM1_filter_handler;
extern PDM_Filter_Config_t PDM1_filter_config;
extern PDM_Filter_Handler_t PDM2_filter_handler;
extern PDM_Filter_Config_t PDM2_filter_config;
/* USER CODE BEGIN 1 */
/* USER CODE END 1 */

View File

@ -56,7 +56,6 @@ void SVC_Handler(void);
void DebugMon_Handler(void);
void PendSV_Handler(void);
void SysTick_Handler(void);
void DMA1_Stream0_IRQHandler(void);
void SPI3_IRQHandler(void);
void OTG_FS_IRQHandler(void);
/* USER CODE BEGIN EFP */

View File

@ -46,7 +46,6 @@
CRC_HandleTypeDef hcrc;
I2S_HandleTypeDef hi2s3;
DMA_HandleTypeDef hdma_spi3_rx;
QSPI_HandleTypeDef hqspi;
@ -65,7 +64,6 @@ SDRAM_HandleTypeDef hsdram1;
/* Private function prototypes -----------------------------------------------*/
void SystemClock_Config(void);
static void MX_GPIO_Init(void);
static void MX_DMA_Init(void);
static void MX_USART3_UART_Init(void);
static void MX_FMC_Init(void);
static void MX_QUADSPI_Init(void);
@ -111,7 +109,6 @@ int main(void)
/* Initialize all configured peripherals */
MX_GPIO_Init();
MX_DMA_Init();
MX_USART3_UART_Init();
MX_FMC_Init();
MX_QUADSPI_Init();
@ -445,20 +442,6 @@ static void MX_USB_OTG_FS_PCD_Init(void)
}
/**
* Enable DMA controller clock
*/
static void MX_DMA_Init(void)
{
/* DMA controller clock enable */
__HAL_RCC_DMA1_CLK_ENABLE();
/* DMA interrupt init */
/* DMA1_Stream0_IRQn interrupt configuration */
HAL_NVIC_SetPriority(DMA1_Stream0_IRQn, 0, 0);
HAL_NVIC_EnableIRQ(DMA1_Stream0_IRQn);
}
/* FMC initialization function */
static void MX_FMC_Init(void)
{

View File

@ -28,8 +28,6 @@
/* Global variables ---------------------------------------------------------*/
PDM_Filter_Handler_t PDM1_filter_handler;
PDM_Filter_Config_t PDM1_filter_config;
PDM_Filter_Handler_t PDM2_filter_handler;
PDM_Filter_Config_t PDM2_filter_config;
/* USER CODE BEGIN 1 */
/* USER CODE END 1 */
@ -54,30 +52,6 @@ void MX_PDM2PCM_Init(void)
PDM1_filter_config.mic_gain = 0;
PDM_Filter_setConfig(&PDM1_filter_handler, &PDM1_filter_config);
PDM2_filter_handler.bit_order = PDM_FILTER_BIT_ORDER_LSB;
PDM2_filter_handler.endianness = PDM_FILTER_ENDIANNESS_BE;
PDM2_filter_handler.high_pass_tap = 2104533974;
PDM2_filter_handler.in_ptr_channels = 2;
PDM2_filter_handler.out_ptr_channels = 2;
PDM_Filter_Init(&PDM2_filter_handler);
PDM2_filter_config.decimation_factor = PDM_FILTER_DEC_FACTOR_64;
PDM2_filter_config.output_samples_number = 16;
PDM2_filter_config.mic_gain = 0;
PDM_Filter_setConfig(&PDM2_filter_handler, &PDM2_filter_config);
PDM2_filter_handler.bit_order = PDM_FILTER_BIT_ORDER_LSB;
PDM2_filter_handler.endianness = PDM_FILTER_ENDIANNESS_BE;
PDM2_filter_handler.high_pass_tap = 2104533974;
PDM2_filter_handler.in_ptr_channels = 2;
PDM2_filter_handler.out_ptr_channels = 2;
PDM_Filter_Init(&PDM2_filter_handler);
PDM2_filter_config.decimation_factor = PDM_FILTER_DEC_FACTOR_64;
PDM2_filter_config.output_samples_number = 16;
PDM2_filter_config.mic_gain = 0;
PDM_Filter_setConfig(&PDM2_filter_handler, &PDM2_filter_config);
/* USER CODE BEGIN 3 */
/* USER CODE END 3 */

View File

@ -24,7 +24,6 @@
/* USER CODE BEGIN Includes */
/* USER CODE END Includes */
extern DMA_HandleTypeDef hdma_spi3_rx;
/* Private typedef -----------------------------------------------------------*/
/* USER CODE BEGIN TD */
@ -170,25 +169,6 @@ void HAL_I2S_MspInit(I2S_HandleTypeDef* hi2s)
GPIO_InitStruct.Alternate = GPIO_AF5_I2S3ext;
HAL_GPIO_Init(GPIOD, &GPIO_InitStruct);
/* I2S3 DMA Init */
/* SPI3_RX Init */
hdma_spi3_rx.Instance = DMA1_Stream0;
hdma_spi3_rx.Init.Channel = DMA_CHANNEL_0;
hdma_spi3_rx.Init.Direction = DMA_PERIPH_TO_MEMORY;
hdma_spi3_rx.Init.PeriphInc = DMA_PINC_DISABLE;
hdma_spi3_rx.Init.MemInc = DMA_MINC_ENABLE;
hdma_spi3_rx.Init.PeriphDataAlignment = DMA_PDATAALIGN_BYTE;
hdma_spi3_rx.Init.MemDataAlignment = DMA_MDATAALIGN_BYTE;
hdma_spi3_rx.Init.Mode = DMA_NORMAL;
hdma_spi3_rx.Init.Priority = DMA_PRIORITY_LOW;
hdma_spi3_rx.Init.FIFOMode = DMA_FIFOMODE_DISABLE;
if (HAL_DMA_Init(&hdma_spi3_rx) != HAL_OK)
{
Error_Handler();
}
__HAL_LINKDMA(hi2s,hdmarx,hdma_spi3_rx);
/* I2S3 interrupt Init */
HAL_NVIC_SetPriority(SPI3_IRQn, 0, 0);
HAL_NVIC_EnableIRQ(SPI3_IRQn);
@ -226,9 +206,6 @@ void HAL_I2S_MspDeInit(I2S_HandleTypeDef* hi2s)
HAL_GPIO_DeInit(GPIOD, GPIO_PIN_6);
/* I2S3 DMA DeInit */
HAL_DMA_DeInit(hi2s->hdmarx);
/* I2S3 interrupt DeInit */
HAL_NVIC_DisableIRQ(SPI3_IRQn);
/* USER CODE BEGIN SPI3_MspDeInit 1 */

View File

@ -56,7 +56,6 @@
/* USER CODE END 0 */
/* External variables --------------------------------------------------------*/
extern DMA_HandleTypeDef hdma_spi3_rx;
extern I2S_HandleTypeDef hi2s3;
extern PCD_HandleTypeDef hpcd_USB_OTG_FS;
/* USER CODE BEGIN EV */
@ -199,20 +198,6 @@ void SysTick_Handler(void)
/* please refer to the startup file (startup_stm32f4xx.s). */
/******************************************************************************/
/**
* @brief This function handles DMA1 stream0 global interrupt.
*/
void DMA1_Stream0_IRQHandler(void)
{
/* USER CODE BEGIN DMA1_Stream0_IRQn 0 */
/* USER CODE END DMA1_Stream0_IRQn 0 */
HAL_DMA_IRQHandler(&hdma_spi3_rx);
/* USER CODE BEGIN DMA1_Stream0_IRQn 1 */
/* USER CODE END DMA1_Stream0_IRQn 1 */
}
/**
* @brief This function handles SPI3 global interrupt.
*/

View File

@ -73,7 +73,7 @@
<LExpSel>0</LExpSel>
</OPTXL>
<OPTFL>
<tvExp>0</tvExp>
<tvExp>1</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<IsCurrentTarget>1</IsCurrentTarget>
</OPTFL>
@ -295,8 +295,8 @@
<tvExp>0</tvExp>
<tvExpOptDlg>0</tvExpOptDlg>
<bDave2>0</bDave2>
<PathWithFileName>..\..\..\src\mem.c</PathWithFileName>
<FilenameWithoutPath>mem.c</FilenameWithoutPath>
<PathWithFileName>..\..\..\src\memheap.c</PathWithFileName>
<FilenameWithoutPath>memheap.c</FilenameWithoutPath>
<RteFlg>0</RteFlg>
<bShared>0</bShared>
</File>

View File

@ -338,7 +338,7 @@
<MiscControls></MiscControls>
<Define>USE_HAL_DRIVER, STM32F469xx</Define>
<Undefine></Undefine>
<IncludePath>.;..\..\..\include;applications;.;board;board\CubeMX_Config\Inc;..\libraries\HAL_Drivers;..\libraries\HAL_Drivers\config;..\..\..\libcpu\arm\common;..\..\..\libcpu\arm\cortex-m4;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\finsh;..\libraries\STM32F4xx_HAL\STM32F4xx_HAL_Driver\Inc;..\libraries\STM32F4xx_HAL\CMSIS\Device\ST\STM32F4xx\Include;..\libraries\STM32F4xx_HAL\CMSIS\Include</IncludePath>
<IncludePath>.;..\..\..\include;applications;board;board\CubeMX_Config\Inc;board\ports;..\libraries\HAL_Drivers;..\libraries\HAL_Drivers\config;..\..\..\libcpu\arm\common;..\..\..\libcpu\arm\cortex-m4;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\drivers\include;..\..\..\components\finsh;..\libraries\STM32F4xx_HAL\STM32F4xx_HAL_Driver\Inc;..\libraries\STM32F4xx_HAL\CMSIS\Device\ST\STM32F4xx\Include;..\libraries\STM32F4xx_HAL\CMSIS\Include</IncludePath>
</VariousControls>
</Cads>
<Aads>
@ -423,9 +423,9 @@
<FilePath>..\..\..\src\kservice.c</FilePath>
</File>
<File>
<FileName>mem.c</FileName>
<FileName>memheap.c</FileName>
<FileType>1</FileType>
<FilePath>..\..\..\src\mem.c</FilePath>
<FilePath>..\..\..\src\memheap.c</FilePath>
</File>
<File>
<FileName>mempool.c</FileName>