diff --git a/arch/arm/src/stm32f7/stm32_ltdc.c b/arch/arm/src/stm32f7/stm32_ltdc.c index 3264fe8094..fdd5a6a947 100644 --- a/arch/arm/src/stm32f7/stm32_ltdc.c +++ b/arch/arm/src/stm32f7/stm32_ltdc.c @@ -3428,6 +3428,21 @@ FAR struct ltdc_layer_s *stm32_ltdcgetlayer(int lid) } #endif /* CONFIG_STM32F7_LTDC_INTERFACE */ + +/**************************************************************************** + * Name: stm32_ltdcreset + * + * Description: + * Reset LTDC via APB2RSTR + * + * + ****************************************************************************/ +void stm32_ltdcreset(void) +{ + *((uint32_t *)(STM32_RCC_APB2RSTR)) |= RCC_APB2RSTR_LTDCRST; + *((uint32_t *)(STM32_RCC_APB2RSTR)) &= ~RCC_APB2RSTR_LTDCRST; +} + /**************************************************************************** * Name: stm32_ltdcinitialize * diff --git a/arch/arm/src/stm32f7/stm32_ltdc.h b/arch/arm/src/stm32f7/stm32_ltdc.h old mode 100755 new mode 100644 index c0e4698636..ea6821ec5b --- a/arch/arm/src/stm32f7/stm32_ltdc.h +++ b/arch/arm/src/stm32f7/stm32_ltdc.h @@ -106,9 +106,29 @@ struct stm32_ltdc_s * include/nuttx/video/fb.h. */ -int stm32_ltdcinitialize(void); +/**************************************************************************** + * Name: stm32_ltdcreset + * + * Description: + * Reset LTDC via APB2RSTR + * + * + ****************************************************************************/ +void stm32_ltdcreset(void); + +/**************************************************************************** + * Name: stm32_ltdcinitialize + * + * Description: + * Initialize the ltdc controller + * + * Return: + * OK + * + ****************************************************************************/ +int stm32_ltdcinitialize(void); FAR struct fb_vtable_s *stm32_ltdcgetvplane(int vplane); -void stm32_ltdcuninitialize(void); +void stm32_ltdcuninitialize(void); /************************************************************************************ * Name: stm32_ltdcgetlayer