Hall estimation at high EERPM

General topics and discussions about the VESC and its development.
e-biker
Posts: 18
Joined: 14 Aug 2016, 13:20
Location: Lithuania

Hall estimation at high EERPM

Postby e-biker » 30 Jun 2017, 08:44

Hi everyone,

This is a long post, so I appreciate your time reading this post. Is it possible to rewrite software witch is based on sensorless observer to run only on hall? Because what I'm seeing is that the teta (time between any hall change) is realated with PWM. What I mean is that hall change is checked when PWM interrup ocurs, when in normal conditions it shoud be checek with hall interrupt.

As example let's say we are runing at high EERPM and hall change has ocured but we just passed pwm cycle, so we are waiting for another one to update teta value, when in ideal situation that value should been updated straightaway as hall chage ocured. This problem get's worse when EERPM increases, teta error increases and motor gets out of sync more and more. I have managed to reduce this problem with increasing PWM switching freaquency (which increases switching losses - not ideal) and interpolation limits in VESC code.

I have tried to rewrite the code using this document http://www.atlantis-press.com/php/download_paper.php?id=3604 with no success. I get a lot jittering in hall change interrupt's (interrupt priority problem?), issuess with timer configuration and maybe wrong theory.

Does anyone have managed to make it work only on hall properly? Or have some better documentation about hall estimation in FOC?

Any ideas that could help or direct to right direction is welcome. :)

pf26
Posts: 278
Joined: 28 Mar 2016, 14:37
Location: FR Valence

Re: Hall estimation at high EERPM

Postby pf26 » 03 Jul 2017, 10:30

Capturing precise hall sensor switching is one thing, but then if you want to apply this to your FETs outputs, you need to wait for then next PWM anyway.
There is something implemented related to correct hall switches at high speed in FOC mode, in mcpwm_foc.c refer to:
static float correct_hall(float angle, float speed, float dt)
Pierre

e-biker
Posts: 18
Joined: 14 Aug 2016, 13:20
Location: Lithuania

Re: Hall estimation at high EERPM

Postby e-biker » 03 Jul 2017, 11:49

Yep, I got your point. I had idea of teta error compensation using timer's, but now after your's hint i know that compensating hall error wont help.

Basically PWM for each phase should be updated in hall change interupt, but that means rewriting a lot of software. I think I have seen it in my earlier Atmel FOC project, teta is calculated in hall interupt and right away PWM is updated.

Correct_hall function corrects hall value related to rotation speed and dt (time between pwm cyclcles). All my changes for smoother hall operation are made there.

Damn those saturation problems. Observer runs so much smoother on low power! I can't say that it is unrideable using hall sensors, it runs prety smooth, but due to some kind of sync prblems I get lower performance, which translates to more heat for my motor and waste of some energy.

Thank's for a hint,
Martynas. :)


Return to “General”

Who is online

Users browsing this forum: No registered users and 3 guests