AnsweredAssumed Answered

STM32F2xx_HAL_Driver : error in the driver TIM with DMA usage

Question asked by Stivy on Mar 25, 2016
Latest reply on Mar 25, 2016 by FTITI.Walid

I use a CubeMx V1.0, version 4.14.0.
Firmware Package SMT32F2 family, V1.3.0 / 20-November-2015.

There is an error in the file stm32fxx_hal_tim.c, in HAL_TIM_IC_Start_DMA function.
The problem is the beginning of the code, with the handling of the return state.

  if((htim->State == HAL_TIM_STATE_BUSY))
     return HAL_BUSY;
  else if((htim->State == HAL_TIM_STATE_READY))
    if((pData == 0 ) && (Length > 0))
      return HAL_ERROR;
      htim->State = HAL_TIM_STATE_BUSY;

In my application, I use 4 channels of the same TIM with DMA requests.
If we start a DMA with one channel of TIMx, it is impossible to start another DMA  channel of
this same TIMx, because the HAL returns always BUSY.

Can the ST team update this driver ? Since it's a part of the drivers used by CubeMx, it's a very annoying problem.

Thanks :-)