cancel
Showing results for 
Search instead for 
Did you mean: 

I am using advance timer 1 for pwm generation and hall sensor on timer 4.Internal trigger is not working in this case.

Tejashree
Associate III

I am trying to use combined channel :XOR/HALL sensor on timer 4:

0693W00000GYNmKQAX.pngand trigger mode on timer 1 to trigger pwm:

0693W00000GYNisQAH.png0693W00000GYNnIQAX.pngI don't understand why my trigger is not working.I see a constant pwm on the line

4 REPLIES 4
LCE
Principal

The first picture gives the impression that timer 4 is not enabled.

You cannot trust CubeMX 100%, it's mostly a starting point, so always find a way to check the register settings (UART).

Tejashree
Associate III

I am using STM32G431CB, which has dedicated pins for hall sensor.So when ever i select XOR/HALL sensor setting.The channel assignment is done automatically and so i cannot change any settings.

TDK
Guru

I believe LCE is saying that "Clock source: Disable" indicates the timer isn't running. Probably this should be set to internal.

If you feel a post has answered your question, please click "Accept as Solution".
cedric H
ST Employee

Hello @Tejashree​ ,

Could you describe your working flow ?

Are you using the MC-SDK or do you try to configure the peripherals yourself ?

For your information, the MC-SDK allows you to configure the hall sensor as speed sensor. Once the project is generated, an IOC file is available. You can open it with cubeMX and observe how did the MCSDK configure the timer.

Regards

Cedric