Hi,
Based on your remark "Yes, The LED toggle is happening on disconnecting debugger but Hall Sensor PWM Capture mode not working (motor not turning) but if we manually change the position by hand a little, it starts rotating.", the LED toggling means that the application code is running. After you change the position manually, the motor spinning means that your application code has issue.
The basic architecture of BLDC control with Hall sensor is that the hall sensor signals trigger interrupt, in the ISR of hall sensor, read the 3 hall signal state, then determine the PWM on/off with the motor specified direction. because the motor does spin after start-up, ISR is not fired, so motor does not spin.
After the speed/direction is set, the code should read the 3 hall state in main loop, then switch PWM without ISR.
Pls check your code
Hope it can help you
BR
XiangJun Rong