You are here

Trouble with custom hardware design

5 posts / 0 new
Last post
Evgeni
Offline
Last seen: 3 months 2 weeks ago
VESC Free
Joined: 2022-01-27 14:24
Posts: 3
Trouble with custom hardware design

Hello guys!

I try to use VESC firmware with my custom bldc controller hardware. I use the latest sources from github and the latest VESC Tool.

The problem now is that when i try to detect motor parameters in FOC mode, i.e. i press "measure R and L" in VESC Tool, all gate signals (GATE_H) are the same, with the same duty and phase, so obviously no current is flowing through the motor and VESC Tool says something like "can't detect motor parameters. R is 0". 

Next in the page "Expirements" i tried Duty Sweep, but again, all gate drive signals are the same, and duty (50%) doesn't change at all.

I can't figure out what's wrong by myself so i will appriciate all your help.

 

skyline1970
Offline
Last seen: 3 weeks 4 days ago
VESC Free
Joined: 2017-09-07 22:28
Posts: 204

Just replicate the test from the terminal window, measure r only first.

Give more details of your driver

Evgeni
Offline
Last seen: 3 months 2 weeks ago
VESC Free
Joined: 2022-01-27 14:24
Posts: 3

Thank you for your answer. I found the problem, it was an issue in my hw.h file, so that VESC couldn't measure currents at all i think. Now i have another problem. I still can't run the motor. It doesn't spin in BLDC mode only jerks. In FOC mode i can't even pass FOC detection. Because i always get abs_over_current fault. I tried to measure only R using terminal with the same result. The motor only jerks and doesn't spin. In graphs i can see that the current rises up exponentially and very sharply. Sometimes my hardware current protection turns off PWM (i use HW_BRK function).

My motor is a quite big 250 kv pmsm with 40 poles and 40uH inductance. I read the forum and tried different advice such as increasing frequency up to 60 kHz, increasing Stator Saturation Compensation, tried different duty cycle and current limits, and ramp timings, but nothing helped.

I'm sure that VESC now measures currents correctly, i checked it using waveform generator. Also i'm sure in my driver, because it works with the same motor but with different software.

I use VESC v5_03 sources from github, as i said in the first message and the latest VESC Tool. I have two phase current shunts if it's important.

 

skyline1970
Offline
Last seen: 3 weeks 4 days ago
VESC Free
Joined: 2017-09-07 22:28
Posts: 204

Could it be related with deadtime compansation?

I suggest you to try with a small motor to test your hw, first.

Evgeni
Offline
Last seen: 3 months 2 weeks ago
VESC Free
Joined: 2022-01-27 14:24
Posts: 3

Well, as i said my hw is 100% workable. Problem can be in between vesc and my hw, if i edit some configuration file the wrong way, but i checked it many times