added function for reset

This commit is contained in:
Titus von Boxberg 2017-07-31 18:55:40 +02:00
parent 0947b31fbb
commit bdee01f492
2 changed files with 37 additions and 2 deletions

View File

@ -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
*

24
arch/arm/src/stm32f7/stm32_ltdc.h Executable file → Normal file
View File

@ -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