2015-04-21 03:32 AM
Hi,
I would like to trigger ADC1 by TIM2 update. I checked and injected group workd fine by software triggering, i have checked in debug the sampled value. TIM2 cnt register also runs, so i probably enabled it correctly. But when trying to trigger ADC injected group by TIM update, ADC does not preform any sampling on injected group. Here is what i have added for the TIM2 for triggering:/* Timer TRGO selection */
master_timer_config.MasterOutputTrigger = TIM_TRGO_UPDATE;
master_timer_config.MasterSlaveMode = TIM_MASTERSLAVEMODE_DISABLE;
if (HAL_TIMEx_MasterConfigSynchronization(&TimHandle, &master_timer_config) != HAL_OK)
{
/* Timer TRGO selection Error */
Error_Handler();
}
Here is what i added to ADC1 for triggering:
sConfigInjected.ExternalTrigInjecConv = ADC_EXTERNALTRIGINJECCONV_T2_TRGO;
//
?
2015-04-21 05:04 AM
interruption
:HAL_ADCEx_InjectedStart_IT()