/* Sets or Resets the TIM peripheral Capture Compare Preload Control bit.  */
void TIM_CCPreloadControl(TIM_TypeDef *TIMx, FunctionalState NewState)
/* Sets or Resets the TIM peripheral Capture Compare Preload Control bit.  */
void TIM_CCPreloadControl(TIM_TypeDef *TIMx, FunctionalState NewState)
{
    assert_param(IS_TIM_LIST6_PERIPH(TIMx));
    assert_param(IS_FUNCTIONAL_STATE(NewState));
    if (NewState != DISABLE)
    {
        TIMx->CR2 |= TIM_CR2_CCPC;
    }
    else
    {
        TIMx->CR2 &= (uint16_t)~((uint16_t)TIM_CR2_CCPC);
    }
}