Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

MOTIX™ MCU Forum Discussions

User18173
Level 1
Level 1
Hello,

I try to use BEMF in my Project to check if and how the Motor is running.

For this I configure the BEMF to call my Interrupt Service Routine.
For testing, I enable all Interrupts with the same Routine.

3800.attach

My Problem is now, that this Routine is never called!!

All Register seems to be correct initialized, but the bits PHx_ZC_STS never changes!

5269.attach

The Interrupts are enabled, too.

5270.attach

What did I wrong!?

Thank you for your help!

Best regards
0 Likes
11 Replies
Fiz
Moderator
Moderator
Moderator
First solution authored Welcome!
Hi Eto,

our device is using a two stage interrupt handling.
To enable a specific interrupt you also need to enable the specific interrupt node.
Chapter 12 of the TLE987x UM shows which interrupt is linked to witch node.
3805.attach
Did you enable interrupts for node 2?

Best,
Fiz
0 Likes
User18173
Level 1
Level 1
Hi Fiz,

thank you for your answer.

Yes, I have also enabled the Node 2 Interrupt.

Configuration:
3806.attach
Debugger:
3807.attach

The bits PHx_ZC_STS never changes during the Motor runs!

Maybe I have to set another bit I dont't know!?


Best regards
0 Likes
Fiz
Moderator
Moderator
Moderator
First solution authored Welcome!
Hi ETO,

is your motor running in open or in closed loop?
Did you try to follow your interrupt routine and check if it is internally routed correctly?
You also need to activate the demagnetisation filter if you want to phase in for the closed loop.

Best,
Fiz
0 Likes
User18173
Level 1
Level 1
Hi Fiz,

sorry for my late answer, but I was on a Business trip.

It runs in both loops, first open than closed.
Yes, I checked it a lot of times, but nothing happends!
For testing this, I use the Infinen example BLDC_SENSORLESS_FOC_EXAMPLE_TLE987X.

Thank you for your help.

Best regards
ETO
0 Likes
Fiz
Moderator
Moderator
Moderator
First solution authored Welcome!
Hi ETO,

could you sent me your Software in a privat message so I could take a look at it?

Best,
Fiz
0 Likes
User18173
Level 1
Level 1
Hi Fiz,

thanks a lot for helping me!

Here are the configuration files.



I hope you find my problem!

Best regards
Eto
0 Likes
Fiz
Moderator
Moderator
Moderator
First solution authored Welcome!
Hi ETO,

I will look into your software and see if I can find your problem.

Best,
Fiz
0 Likes
Fiz
Moderator
Moderator
Moderator
First solution authored Welcome!
Hi Eto,

the BEMF comparators were not enabled in your example.
Can you try the example I have attached to see if this works for you?

Best,
Fiz
0 Likes
User18173
Level 1
Level 1
Hi Fiz,

thank you very much for your efforts and sorry for my late answer!
I have no time to try youre example, but above I show my settings and so I don't understand the answer!

Best regards
Eto
0 Likes
User20268
Level 1
Level 1
Hey Fiz,

Is there a BEMF example code using FOC? The attached file is for block.

Best regards,
JP
0 Likes
iamprt
Level 3
Level 3
10 questions asked First like received 50 sign-ins
Fiz wrote:
Hi Eto,

the BEMF comparators were not enabled in your example.
Can you try the example I have attached to see if this works for you?

Best,
Fiz


I was also facing the same issue that the motor was not running in BEMF mode. However, I tried the example code you gave, but in this case, the motor starts on pressing the MON button but stops as soon as it reaches the given reference speed.
Would you please provide a code that makes the motor run continuously at desired speed?
In love with Power Electronics and its applications.
0 Likes