mpu设置修改
This commit is contained in:
1 parent
72bbf093b2
commit
efc78addd9
8 files changed
+25
-24
No files matched your search
+6
-3
@@ -810,6 +810,7 @@ void MPU_Config(void)
|
||||
MPU_InitStruct.Number = MPU_REGION_NUMBER1;
|
||||
MPU_InitStruct.BaseAddress = 0x30000000;
|
||||
MPU_InitStruct.Size = MPU_REGION_SIZE_128KB;
|
||||
MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
|
||||
|
||||
HAL_MPU_ConfigRegion(&MPU_InitStruct);
|
||||
|
||||
@@ -822,17 +823,19 @@ void MPU_Config(void)
|
||||
|
||||
/** Initializes and configures the Region and the memory to be protected
|
||||
*/
|
||||
MPU_InitStruct.Number = MPU_REGION_NUMBER3;
|
||||
MPU_InitStruct.BaseAddress = 0x0;
|
||||
MPU_InitStruct.Number = MPU_REGION_NUMBER4;
|
||||
MPU_InitStruct.BaseAddress = 0x30040000;
|
||||
MPU_InitStruct.Size = MPU_REGION_SIZE_32KB;
|
||||
MPU_InitStruct.AccessPermission = MPU_REGION_NO_ACCESS;
|
||||
|
||||
HAL_MPU_ConfigRegion(&MPU_InitStruct);
|
||||
|
||||
/** Initializes and configures the Region and the memory to be protected
|
||||
*/
|
||||
MPU_InitStruct.Number = MPU_REGION_NUMBER4;
|
||||
MPU_InitStruct.Number = MPU_REGION_NUMBER5;
|
||||
MPU_InitStruct.BaseAddress = 0xC0000000;
|
||||
MPU_InitStruct.Size = MPU_REGION_SIZE_32MB;
|
||||
MPU_InitStruct.AccessPermission = MPU_REGION_FULL_ACCESS;
|
||||
|
||||
HAL_MPU_ConfigRegion(&MPU_InitStruct);
|
||||
/* Enables the MPU */
|
||||
|
||||
@@ -127,6 +127,7 @@ void HAL_DMA2D_MspDeInit(DMA2D_HandleTypeDef* hdma2d)
|
||||
* @param hltdc: LTDC handle pointer
|
||||
* @retval None
|
||||
*/
|
||||
|
||||
/**
|
||||
* @brief LTDC MSP De-Initialization
|
||||
* This function freeze the hardware resources used in this example
|
||||
@@ -707,7 +708,7 @@ void HAL_HCD_MspInit(HCD_HandleTypeDef* hhcd)
|
||||
GPIO_InitStruct.Pin = GPIO_PIN_11|GPIO_PIN_12;
|
||||
GPIO_InitStruct.Mode = GPIO_MODE_AF_PP;
|
||||
GPIO_InitStruct.Pull = GPIO_NOPULL;
|
||||
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_HIGH;
|
||||
GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW;
|
||||
GPIO_InitStruct.Alternate = GPIO_AF10_OTG1_FS;
|
||||
HAL_GPIO_Init(GPIOA, &GPIO_InitStruct);
|
||||
|
||||
|
||||
Reference in new issue
Block a user