From b0db5ef2b9672cfc88038d10a25470e8051fe680 Mon Sep 17 00:00:00 2001 From: zylx <1346773219@qq.com> Date: Sat, 26 Oct 2019 18:35:24 +0800 Subject: [PATCH] =?UTF-8?q?=E3=80=90=E4=BF=AE=E6=94=B9=E3=80=91=E6=9B=B4?= =?UTF-8?q?=E6=96=B0cpu=E9=A2=91=E7=8E=87=E8=87=B3400M=EF=BC=8C=E9=98=B2?= =?UTF-8?q?=E6=AD=A2cpu=E9=94=81=E6=AD=BB?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../board/CubeMX_Config/.mxproject | 4 +- .../board/CubeMX_Config/CubeMX_Config.ioc | 92 +++++++++---------- .../board/CubeMX_Config/Src/main.c | 8 +- .../stm32h750-armfly-h7-tool/board/board.c | 6 +- 4 files changed, 55 insertions(+), 55 deletions(-) diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/.mxproject b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/.mxproject index 94acf21ec3..90a1e4b4c6 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/.mxproject +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/.mxproject @@ -1,7 +1,7 @@ [PreviousGenFiles] -HeaderPath=D:/rt-thread/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Inc +HeaderPath=E:/rt-thread/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Inc HeaderFiles=stm32h7xx_it.h;stm32h7xx_hal_conf.h;main.h; -SourcePath=D:/rt-thread/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src +SourcePath=E:/rt-thread/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src SourceFiles=stm32h7xx_it.c;stm32h7xx_hal_msp.c;main.c; [PreviousLibFiles] diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/CubeMX_Config.ioc b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/CubeMX_Config.ioc index 7cb9921281..a6b6d880ae 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/CubeMX_Config.ioc +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/CubeMX_Config.ioc @@ -213,80 +213,80 @@ ProjectManager.ToolChainLocation= ProjectManager.UnderRoot=false ProjectManager.functionlistsort=1-MX_GPIO_Init-GPIO-false-HAL-true,2-SystemClock_Config-RCC-false-HAL-false,3-MX_USART1_UART_Init-USART1-false-HAL-true,4-MX_CRC_Init-CRC-false-HAL-true,5-MX_RNG_Init-RNG-false-HAL-true,6-MX_ADC3_Init-ADC3-false-HAL-true,7-MX_DAC1_Init-DAC1-false-HAL-true,8-MX_ETH_Init-ETH-false-HAL-true,9-MX_QUADSPI_Init-QUADSPI-false-HAL-true,10-MX_SDMMC1_MMC_Init-SDMMC1-false-HAL-true,11-MX_SPI5_Init-SPI5-false-HAL-true,12-MX_UART4_Init-UART4-false-HAL-true RCC.ADCFreq_Value=480000000 -RCC.AHB12Freq_Value=240000000 -RCC.AHB4Freq_Value=240000000 -RCC.APB1Freq_Value=120000000 -RCC.APB2Freq_Value=120000000 -RCC.APB3Freq_Value=120000000 -RCC.APB4Freq_Value=120000000 -RCC.AXIClockFreq_Value=240000000 +RCC.AHB12Freq_Value=200000000 +RCC.AHB4Freq_Value=200000000 +RCC.APB1Freq_Value=100000000 +RCC.APB2Freq_Value=100000000 +RCC.APB3Freq_Value=100000000 +RCC.APB4Freq_Value=100000000 +RCC.AXIClockFreq_Value=200000000 RCC.CECFreq_Value=32000 RCC.CKPERFreq_Value=64000000 -RCC.CortexFreq_Value=480000000 -RCC.CpuClockFreq_Value=480000000 -RCC.D1CPREFreq_Value=480000000 +RCC.CortexFreq_Value=400000000 +RCC.CpuClockFreq_Value=400000000 +RCC.D1CPREFreq_Value=400000000 RCC.D1PPRE=RCC_APB3_DIV2 RCC.D2PPRE1=RCC_APB1_DIV2 RCC.D2PPRE2=RCC_APB2_DIV2 RCC.D3PPRE=RCC_APB4_DIV2 -RCC.DFSDMACLkFreq_Value=480000000 -RCC.DFSDMFreq_Value=120000000 +RCC.DFSDMACLkFreq_Value=400000000 +RCC.DFSDMFreq_Value=100000000 RCC.DIVM1=5 RCC.DIVM2=5 -RCC.DIVN1=192 +RCC.DIVN1=160 RCC.DIVN2=192 -RCC.DIVP1Freq_Value=480000000 +RCC.DIVP1Freq_Value=400000000 RCC.DIVP2Freq_Value=480000000 RCC.DIVP3Freq_Value=50390625 -RCC.DIVQ1Freq_Value=480000000 +RCC.DIVQ1Freq_Value=400000000 RCC.DIVQ2Freq_Value=480000000 RCC.DIVQ3Freq_Value=50390625 -RCC.DIVR1Freq_Value=480000000 +RCC.DIVR1Freq_Value=400000000 RCC.DIVR2Freq_Value=480000000 RCC.DIVR3Freq_Value=50390625 -RCC.FDCANFreq_Value=480000000 -RCC.FMCFreq_Value=240000000 +RCC.FDCANFreq_Value=400000000 +RCC.FMCFreq_Value=200000000 RCC.FamilyName=M -RCC.HCLK3ClockFreq_Value=240000000 -RCC.HCLKFreq_Value=240000000 +RCC.HCLK3ClockFreq_Value=200000000 +RCC.HCLKFreq_Value=200000000 RCC.HPRE=RCC_HCLK_DIV2 -RCC.HRTIMFreq_Value=240000000 -RCC.I2C123Freq_Value=120000000 -RCC.I2C4Freq_Value=120000000 +RCC.HRTIMFreq_Value=200000000 +RCC.I2C123Freq_Value=100000000 +RCC.I2C4Freq_Value=100000000 RCC.IPParameters=ADCFreq_Value,AHB12Freq_Value,AHB4Freq_Value,APB1Freq_Value,APB2Freq_Value,APB3Freq_Value,APB4Freq_Value,AXIClockFreq_Value,CECFreq_Value,CKPERFreq_Value,CortexFreq_Value,CpuClockFreq_Value,D1CPREFreq_Value,D1PPRE,D2PPRE1,D2PPRE2,D3PPRE,DFSDMACLkFreq_Value,DFSDMFreq_Value,DIVM1,DIVM2,DIVN1,DIVN2,DIVP1Freq_Value,DIVP2Freq_Value,DIVP3Freq_Value,DIVQ1Freq_Value,DIVQ2Freq_Value,DIVQ3Freq_Value,DIVR1Freq_Value,DIVR2Freq_Value,DIVR3Freq_Value,FDCANFreq_Value,FMCFreq_Value,FamilyName,HCLK3ClockFreq_Value,HCLKFreq_Value,HPRE,HRTIMFreq_Value,I2C123Freq_Value,I2C4Freq_Value,LPTIM1Freq_Value,LPTIM2Freq_Value,LPTIM345Freq_Value,LPUART1Freq_Value,LTDCFreq_Value,MCO1PinFreq_Value,MCO2PinFreq_Value,PLL2FRACN,PLL3FRACN,PLLFRACN,PLLSourceVirtual,QSPIFreq_Value,RNGFreq_Value,RTCFreq_Value,SAI1Freq_Value,SAI23Freq_Value,SAI4AFreq_Value,SAI4BFreq_Value,SDMMCFreq_Value,SPDIFRXFreq_Value,SPI123Freq_Value,SPI45Freq_Value,SPI6Freq_Value,SWPMI1Freq_Value,SYSCLKFreq_VALUE,SYSCLKSource,Tim1OutputFreq_Value,Tim2OutputFreq_Value,TraceFreq_Value,USART16Freq_Value,USART234578Freq_Value,USBFreq_Value,VCO1OutputFreq_Value,VCO2OutputFreq_Value,VCO3OutputFreq_Value,VCOInput1Freq_Value,VCOInput2Freq_Value,VCOInput3Freq_Value -RCC.LPTIM1Freq_Value=120000000 -RCC.LPTIM2Freq_Value=120000000 -RCC.LPTIM345Freq_Value=120000000 -RCC.LPUART1Freq_Value=120000000 +RCC.LPTIM1Freq_Value=100000000 +RCC.LPTIM2Freq_Value=100000000 +RCC.LPTIM345Freq_Value=100000000 +RCC.LPUART1Freq_Value=100000000 RCC.LTDCFreq_Value=50390625 RCC.MCO1PinFreq_Value=64000000 -RCC.MCO2PinFreq_Value=480000000 +RCC.MCO2PinFreq_Value=400000000 RCC.PLL2FRACN=0 RCC.PLL3FRACN=0 RCC.PLLFRACN=0 RCC.PLLSourceVirtual=RCC_PLLSOURCE_HSE -RCC.QSPIFreq_Value=240000000 +RCC.QSPIFreq_Value=200000000 RCC.RNGFreq_Value=48000000 RCC.RTCFreq_Value=32000 -RCC.SAI1Freq_Value=480000000 -RCC.SAI23Freq_Value=480000000 -RCC.SAI4AFreq_Value=480000000 -RCC.SAI4BFreq_Value=480000000 -RCC.SDMMCFreq_Value=480000000 -RCC.SPDIFRXFreq_Value=480000000 -RCC.SPI123Freq_Value=480000000 -RCC.SPI45Freq_Value=120000000 -RCC.SPI6Freq_Value=120000000 -RCC.SWPMI1Freq_Value=120000000 -RCC.SYSCLKFreq_VALUE=480000000 +RCC.SAI1Freq_Value=400000000 +RCC.SAI23Freq_Value=400000000 +RCC.SAI4AFreq_Value=400000000 +RCC.SAI4BFreq_Value=400000000 +RCC.SDMMCFreq_Value=400000000 +RCC.SPDIFRXFreq_Value=400000000 +RCC.SPI123Freq_Value=400000000 +RCC.SPI45Freq_Value=100000000 +RCC.SPI6Freq_Value=100000000 +RCC.SWPMI1Freq_Value=100000000 +RCC.SYSCLKFreq_VALUE=400000000 RCC.SYSCLKSource=RCC_SYSCLKSOURCE_PLLCLK -RCC.Tim1OutputFreq_Value=240000000 -RCC.Tim2OutputFreq_Value=240000000 +RCC.Tim1OutputFreq_Value=200000000 +RCC.Tim2OutputFreq_Value=200000000 RCC.TraceFreq_Value=64000000 -RCC.USART16Freq_Value=120000000 -RCC.USART234578Freq_Value=120000000 -RCC.USBFreq_Value=480000000 -RCC.VCO1OutputFreq_Value=960000000 +RCC.USART16Freq_Value=100000000 +RCC.USART234578Freq_Value=100000000 +RCC.USBFreq_Value=400000000 +RCC.VCO1OutputFreq_Value=800000000 RCC.VCO2OutputFreq_Value=960000000 RCC.VCO3OutputFreq_Value=100781250 RCC.VCOInput1Freq_Value=5000000 diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src/main.c b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src/main.c index 2ad33da07f..40c0f4c37f 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src/main.c +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/CubeMX_Config/Src/main.c @@ -181,7 +181,7 @@ void SystemClock_Config(void) HAL_PWREx_ConfigSupply(PWR_LDO_SUPPLY); /** Configure the main internal regulator output voltage */ - __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE0); + __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE1); while(!__HAL_PWR_GET_FLAG(PWR_FLAG_VOSRDY)) {} /** Macro to configure the PLL clock source @@ -195,7 +195,7 @@ void SystemClock_Config(void) RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON; RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSE; RCC_OscInitStruct.PLL.PLLM = 5; - RCC_OscInitStruct.PLL.PLLN = 192; + RCC_OscInitStruct.PLL.PLLN = 160; RCC_OscInitStruct.PLL.PLLP = 2; RCC_OscInitStruct.PLL.PLLQ = 2; RCC_OscInitStruct.PLL.PLLR = 2; @@ -219,7 +219,7 @@ void SystemClock_Config(void) RCC_ClkInitStruct.APB2CLKDivider = RCC_APB2_DIV2; RCC_ClkInitStruct.APB4CLKDivider = RCC_APB4_DIV2; - if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_4) != HAL_OK) + if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_2) != HAL_OK) { Error_Handler(); } @@ -266,7 +266,7 @@ static void MX_ADC3_Init(void) /** Common config */ hadc3.Instance = ADC3; - hadc3.Init.ClockPrescaler = ADC_CLOCK_ASYNC_DIV1; + hadc3.Init.ClockPrescaler = ADC_CLOCK_ASYNC_DIV16; hadc3.Init.Resolution = ADC_RESOLUTION_16B; hadc3.Init.ScanConvMode = ADC_SCAN_DISABLE; hadc3.Init.EOCSelection = ADC_EOC_SINGLE_CONV; diff --git a/bsp/stm32/stm32h750-armfly-h7-tool/board/board.c b/bsp/stm32/stm32h750-armfly-h7-tool/board/board.c index d81b932e58..7783d407a8 100644 --- a/bsp/stm32/stm32h750-armfly-h7-tool/board/board.c +++ b/bsp/stm32/stm32h750-armfly-h7-tool/board/board.c @@ -25,7 +25,7 @@ void SystemClock_Config(void) HAL_PWREx_ConfigSupply(PWR_LDO_SUPPLY); /** Configure the main internal regulator output voltage */ - __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE0); + __HAL_PWR_VOLTAGESCALING_CONFIG(PWR_REGULATOR_VOLTAGE_SCALE1); while(!__HAL_PWR_GET_FLAG(PWR_FLAG_VOSRDY)) {} /** Macro to configure the PLL clock source @@ -39,7 +39,7 @@ void SystemClock_Config(void) RCC_OscInitStruct.PLL.PLLState = RCC_PLL_ON; RCC_OscInitStruct.PLL.PLLSource = RCC_PLLSOURCE_HSE; RCC_OscInitStruct.PLL.PLLM = 5; - RCC_OscInitStruct.PLL.PLLN = 192; + RCC_OscInitStruct.PLL.PLLN = 160; RCC_OscInitStruct.PLL.PLLP = 2; RCC_OscInitStruct.PLL.PLLQ = 2; RCC_OscInitStruct.PLL.PLLR = 2; @@ -63,7 +63,7 @@ void SystemClock_Config(void) RCC_ClkInitStruct.APB2CLKDivider = RCC_APB2_DIV2; RCC_ClkInitStruct.APB4CLKDivider = RCC_APB4_DIV2; - if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_4) != HAL_OK) + if (HAL_RCC_ClockConfig(&RCC_ClkInitStruct, FLASH_LATENCY_2) != HAL_OK) { Error_Handler(); }