2021-03-09 06:57 AM
Currently i am working with one pulse mode in stm32f030c8t6. TIM15, slave mode = Trigger mode,Trigger source=TI2FP2, and channel = PWM channel CH1 ,Input and output frequency 50Hz. My problem is whenever i connect the trigger input pulse,(From external optocoupler circuit) the input pulse disappears (observing with the help of CRO).And no signal at the output also.If i generate a 50Hz square pulse from the same controller and giving it to the trigger input, then the input signal level will reduce to half voltage(but it is giving the output properly). The code is given below. This code is working fine with stm32f103c836(there is no dip in the input signal level also).What is the actual problem?. help me to solve this problem.
code
--------
HAL_Init();
SystemClock_Config();
MX_GPIO_Init();
MX_TIM15_Init();
HAL_TIM_OnePulse_Start(&htim15,TIM_CHANNEL_1);
TIM15->CCR1 =20000;//maximum value 47999//prescalar 9
while (1)
{
HAL_Delay(100);
}
2021-03-09 07:42 AM
> My problem is whenever i connect the trigger input pulse,
Which pin?
Read out and check/post content TIM registers and also of relevant GPIO registers for this pin.
Is this a "known good" hardware such as Nucleo/Disco, or your own board? Can't there be a hardware problem such as a short to neighbouring pin?
JW
2021-03-09 07:55 AM
Hardware is custom one only. There is no short circuit.I tried with more than two boards.
2021-03-09 07:56 AM
But with blue pill board it is working..
2021-03-09 08:00 AM
Read out and check/post content TIM registers and also of relevant GPIO registers for this pin.
JW
2024-07-04 12:17 PM
Hello
Did you find a solution
I have the same problem.Thank you.