Lebowski controller build possible IPM output stage

Very nice, thanks Chris! The tip for such complete and cheap resistor kits is also very useful, better than ordering single resistors.
Cheers, Marcel
 
Well been a busy day, I have a lot to update everyone on but atm the 6fet controller is built and not working :p

When I turn on the bench supply for the rails (separate supplies for the rails and control) with or without the control power on it reads like it is running into a dead short. Prior to connecting it I set the voltage to 37V (10s) but when I turn it on I get 1.2V and almost 4amps which seems wrong...

I have been through the setup menus a few times trying to find if I have something wrong. Doing the current sensor calibration I get a sound from the motor but no movement.

Thoughts?

Cheers

Chris
 
Well after looking into it some more I think my Bench supply is dead (Lambda LQ-532). It should run 5A 40V all day no sweat, found the manual and even says to set the current limit dead short the supply and set the max current for the voltage you want to run upto 40V 5A. When I dead short the supply I get 1.2V and 3.9amps so something is bad.

Time to open it up!

Cheers

Chris
 
Excited to follow this thread.
 
Does it go into setup as it should ? Did ypu setup everything ? Did you try the PWM test function ? Are the current sensors on the PCB or did you make them external ? If so, are you sure their polarity is correct ? Are you sure you did not interchange the drain and source of the FETs?
 
Lebowski said:
Does it go into setup as it should ? Did ypu setup everything ? Did you try the PWM test function ? Are the current sensors on the PCB or did you make them external ? If so, are you sure their polarity is correct ? Are you sure you did not interchange the drain and source of the FETs?

Setup works fine no issue.

I tried the PWM test function and the motor twitched slightly (50%) but I could still rotate it by hand

Current sensors for this one are on board what do you mean polarity? They are connected to the matching pair of fets if that is what you mean.

I checked the FET wiring about a dozen times but here are some pictures as another pair of eyes always sees the mistakes :D

IMG_20141117_063741.jpg

IMG_20141117_063746.jpg

Way I am testing the board

IMG_20141117_063857.jpg

I am pretty sure I have an issue with my bench supply, I have never really loaded it down and I bought it used. It should do 5amps at 40V into a short (current limited) but atm it does not.

Also a teaser as for what is to come!

image2.jpg

IPM with optical isolation (long black thing) and isolated power supplies (4 short black things) input board.

Cheers

Chris
 
The motor is not supposed to 'twitch' when you use the pwm test function. A twitch points to a wrong connection or a blown FET. With pwm test activated the motor is more difficult to turn by hand but in the same way as if the motor terminals are all connected together, and there should not be a heavy spot when you turn it...

About the polarity of the current sensors, make sure the output stage is connected to the side marked 'FETs' and motor on the side marked 'motor'
 
Which IPM are you using? I'm interested in this.
 
Lebowski said:
The motor is not supposed to 'twitch' when you use the pwm test function. A twitch points to a wrong connection or a blown FET. With pwm test activated the motor is more difficult to turn by hand but in the same way as if the motor terminals are all connected together, and there should not be a heavy spot when you turn it...

About the polarity of the current sensors, make sure the output stage is connected to the side marked 'FETs' and motor on the side marked 'motor'

By twitch I mean it moved a few mm in one direction and then stopped. No resistance to turning by hand in comparison to an unpowered motor. I do believe my power supply is the issue since it is providing no voltage. Any quick check for a blown FET?

Ok yes the current sensors are connected correctly :)

Cheers

Chris
 
heathyoung said:
Which IPM are you using? I'm interested in this.

IPM is a Powerex PM50RLA060 Intelligent Power Module http://www.pwrx.com/pwrx/docs/pm50rla060.pdf so its a 600V 50Amp.

Interface board is the Powerex bp7b-7s http://www.pwrx.com/pwrx/docs/BP7B Application note.pdf.

Using that specific IPM because it was cheap on ebay (although the interface board it came with was pretty bad so I had to cut it with a dremel to be able to remove it) the interface board will transfer to higher power 7pack IPMS.

Cheers

Chris
 
Typically a blown FET becomes a short, so there should be a few kOhm between each of the phases and ground and vdd, and also check none of the drain tabs shorts to your aluminium carrier

During pwm test there is hardly any current draw, maybe 100mA, so... using the pwm test function and a scope you can check whether all phase voltages are as they should be (remove motor for this measurement)
 
I like the interface board - I'm using the package C IPM (PM300CLA060 - 600V300A) but would like to move to package D (PM450CLA060 - 600V450A) in future (would like to push phase current past 300A).

What was the cost for the interface board? I'll let you know that those IPM's need a lot of heatsinking when pushed hard - more than you think (was considering watercooling at one stage).
 
Lebowski said:
Typically a blown FET becomes a short, so there should be a few kOhm between each of the phases and ground and vdd, and also check none of the drain tabs shorts to your aluminium carrier

During pwm test there is hardly any current draw, maybe 100mA, so... using the pwm test function and a scope you can check whether all phase voltages are as they should be (remove motor for this measurement)

FET drain to source all read pretty much open. All drain tabs to mount read open.

Found the problem.... Ummm maybe you guys should take my soldering iron away from me.... I had vdd and ground connected backwards because I had soldered the electrolytic on with the wrong polarity only realized when I saw the diode source to drain on the FET in the datasheet and checked my polarity.

Well now on with the testing.

Cheers

Chris
 
Yup and then forgot to flip the hi lo drive wires to the fets to account for the polarity change before trying the current sensor calibration.

Gahh!

R104, R27 and R18 all toasted and the fet drivers got very hot before I realized what was happening.

Might be time for bed. Try again tomorrow.

Cheers

Chris
 
Hi Lebowski,

What I mean by polarity is that I had the negative leg of the electrolytic and the negative terminal of my bench supply connected to the copper buss for the drain of the Fets and the positive connected to the Source copper bus.

I fixed that and no more dead short on the supply and then I had the drives wires backwards also! So when I ran the current sensor calibration I was driving the hi side fets from the low side output on your board etc.

Another thing I realized this morning is I did not tie my two supplies commons together with the new bench supply (I have one supply for control and one for the motor).
 
I love this stuff. It really teaches you to double check and test things as you go. You will learn systems that help you figure this stuff out and how to prevent it faster as you go. :)
 
Yeah my biggest mistake was I built my 6 FET stage using Lebowski's design but ended up with it backwards so every time I compare mine with his I get confused :p

But you are right, I have not worked with FET's before or motors or batteries so I am learning a fair bit as I go!

Hope to get it going tonight as I have 3 replacement drivers and the resistors so I should be able to make the repairs easily. (assuming I did not kill anything else)

Cheers

Chris
 
Ok, well I think it is alive but either I have a setup parameter set wrong (most likely) or my supply is not man enough for the job.

I think I fixed all my wiring issues and got the following results:
When doing the Current Sensor Calibration -> Perform offset measurement the motor made a high pitched noise and did not move
When doing the Current Sensor Calibration -> Perform gain measurement the motor made a high pitched noise and moved around about 90 degrees
When doing the FOC motor impedance -> perform impedance measurement the motor made a quiet noise
When doing the throttle setup -> test throttle the number 1 moves from the left to the right and it shows F- the whole time.

This looked promising so I saved (store parameters in ROM for motor use -> save data to ROM for motor use) powered down, removed the setup jumper, powered back up, turned the throttle and nothing :p

Motor was making a tiny amount of noise barely audible, nothing like the tone I heard in the video in Lebowski's thread. If I spun the motor by hand the green drive_3 LED would light for a second.

Maybe someone can tell me what I have set wrong :)

Supply - 48Vdc 8 amps
Motor - http://www.hobbyking.com/hobbyking/store/uh_viewItem.asp?idProduct=41051

PWM parameters
a) PWM frequency: 21kHz
b) deadtime: 366ns
c) dutycycle testsignal: 51%
d) toggle high side polarity, now active HIGH
e) toggle low side polarity, now active HIGH
f) test PWM signals

g) autocomplete

h) loop sample frequency: 41.03 kHz

current settings
a) current sensor transimpedance: 40.00 mV/A
b) maximum motor phase current: 9.9 A
c) maximum battery current, motor use: 7.9 A
d) maximum battery current, regen: 0.0 A

e) autocomplete

f) HF current, base level (HF only): 0.4 A
g) HF current, proportional factor (HF only): 1.0000
h) maximum phase current in drive 2 (HF only): 4.7 A
i) phase current for forcing motor position: 2.4 A
j) maximum shutdown error current, fixed: 1.2 A
k) maximum shutdown error current, proportional: 1.2 A
l) applied braking current (phase) on direction change: 0.0 A
m) offset filtering (phase) current limit: 0.0 A

throttle setup
a) calibrate throttle 1
b) calibrate throttle 2
c) polynomial coefficients throttle 1 (x, x^2, x^3): -0.0002, -0.0002, -0.0002
d) polynomial coefficients throttle 2 (x, x^2, x^3): -0.0002, -0.0002, -0.0002
e) use analog throttle 1: YES
f) use analog throttle 2: NO
receive throttle over CAN: NO
g) TX throttle over CAN: NO

erpm limits
a) erpm limit, forward: 7.85 k-erpm
b) erpm limit, reverse: 0.29 k-erpm
c) accept direction change below: 0 erpm
d) transition erpm drive 2 -> 3: 751 erpm
e) transition erpm drive 3 -> 2: 150 erpm

battery
a) battery voltage: 48.0 V

current sensor calibration
a) restore calibration, autocomplete
b) perform offset measurement
sensor a: -40.0 mV
sensor b: -37.5 mV
sensor c: -40.0 mV
c) perform gain measurement
channel a: 108.69 %
channel b: 93.65 %
channel c: 98.78 %
d) online gain calibration update rate: 0.302 %

control loop coefficients
a) autocomplete

phase control loop, drive 3
b) 1st order: 240
c) 2nd order: 12.0000
d) 3rd order: 0.3000
phase control loop, drive 2
e) 1st order: 480
f) 2nd order: 24.0000
g) 3rd order: 0.0299
amplitude control loop
h) 1st order: 120
i) 2nd order: 6.0000
j) 3rd order: 0.1499
k) maximum amplitude: 100 %

filter bandwidths
a) autocomplete

b) throttle current filter -3dB freq: 100 Hz
c) error current 50% step response time: 1.000 msec
d) induction position filter 45 degree delay speed: 3.04 k-erpm
e) drive 2 speed filter 50% step response time: 106.5 msec

FOC motor impedance
a) autocomplete

b) FOC measurement current: 4.9 A
c) FOC measurement erpm: 56.35 k-erpm
d) perform impedance measurement

measured inductance: 27.5 uH

CAN setup
a) CAN 'address': 16383
b) CAN CFG1 as per Microchip 30F manual: 65535
c) CAN CFG2 as per Microchip 30F manual: 65535
RS232 output rate: 3730 Hz

miscellaneous
a) autocomplete

b) motor standstill voltage threshold: 0.48 V
c) low side pulsing in drive 0: enabled
d) low side pulsing rate: 20 Hz
e) low side pulsing width: 20 usec
f) high frequency tone at standstill: enabled
g) wiggle range: 19 deg
h) wiggle rate: 10 Hz
i) minimum # of cycles going from drive 2 to 3: 1000
j) number of cycles going from drive 3 to 2, HF only: 200

Any thoughts?

Cheers

Chris
 
Just noticed miscellaneous -> high frequency tone at standstill was disabled so I tried enabling that. Now it does make a high pitched noise at standstill but still does not move in response to the throttle Pot been turned.

Cheers

Chris
 
throttle setup
a) calibrate throttle 1
b) calibrate throttle 2
c) polynomial coefficients throttle 1 (x, x^2, x^3): -0.0002, -0.0002, -0.0002
d) polynomial coefficients throttle 2 (x, x^2, x^3): -0.0002, -0.0002, -0.0002


Since you're using throttle 1.... option C tell it that in order to calculate the wanted phase current it should multiply the throttle info with 0.
More typical for a linear throttle curve is 1, 0, 0 .

When not using the HF tone, its best not to do gain calibration for the current sensors, so my recommendation is to reset this (option a). I typically
also do not use offset calibration...

I've found that when you want to use HF, the autocomplete settings are not optimal. First try it sensorless with no tone (disable HF tone at standstill in the misc menu).

Looking at the menu's, quite some progress was made since you're chips were programmed, so if you want you can send them back
for a re-flash. Which version are they ?
 
They are version 2.1, I will check with my brother but I have 4 chips so I could send you 2 and keep 2 for him to play with.

Well that fixed it! It lives!! For some reason I thought the calibrate throttle set the polynomial coefficients whoops :)

Here is a video of it running https://www.youtube.com/watch?v=MyQ1Fuma_aU&list=UUQJpO_A4kAIlmKROzqppDtw

Few comments/questions:
- When I turn the throttle up too much the motor just stops and the drive_3 led goes out? Is this due to the current limits I set or the erpm settings?
- How do I figure out the erpm settings from the motor specs?
- It seems to go straight from stand still to drive_3 no other LED's light?

Next will be switching out the 6 FET with the IPM, I need to check the signal requirements of the interface board and then check with you to see if I need to buffer the signals from the IC.

Cheers

Chris
 
About cutting out of drive 3, maybe increase in the bandwidths menu the error current 50% response time to 5 milli sec.
Another thing to try would be to increase the proportional error current setting to 2.4A, its in the current menu option k.
It should not cut out, if setup correctly. Later versions (i'm at 2.30 now) will auto restart after a cutout, and this is so
fast you wont even notice...

All LEDs should light at one point or another (except the drive_1 LED when using sensorless, if I remember correctly), so have a
look to make sure they are in the right way around.

Tja, motor spec, i had to dig into the bowls of the internet too to find this for my small rc motor so maybe have a look on the manufacturer site ?

The 48V is relatively low for the power supply, if you have a pickit programmer you can reflash the 12f617 to make it more
suitable for 48v. There is a number in the 12f617 which can be changed to have it work OK down to (a tested) 32 V... if you're sending
the main chips anyway i can do this too. The cutout you're seeing may be due to the power supply failing... do the power supply LEDs go
out for a short time ?
 
I tried those changes and nope it still cut out, I wonder if I am hitting the erpm limits...

Not to big a deal as I will be re doing all the setup when I try it on my brothers bike with his batteries.

Next is to see if I can get the IPM to run in the same fashion. The write up for the interface board I am using has the following to say about powering the optocouplers on the inputs:

An on signal (IPM control input low) is generated by pulling the respective control input low (GND) using a CMOS buffer capable of sinking at least 16mA (74HC04 or similar). In the off state the buffer should actively pull the control input high to maintain good noise immunity. Open collector drive that allows the control input to float will degrade common mode noise immunity and is therefore not recommended.

As you currently have it designed if I set it to:

d) toggle high side polarity, now active LOW
e) toggle low side polarity, now active LOW

and connect the interface board to pins 1 for hi and 2 for low from the IRS2186 socket points on the circuit board will I be ok? Can the 30F4011 sink 20mA per input and does it pull the output high internally? These are 5V logic signals right? Or should I use a buffer?

Thoughts?

on the LED's I checked orientation and they look good only thing I can see is the green is 3.2 forward voltage and the others are 2.2 V forward need to check the resistors to see if I am getting enough to power them.

Cheers

Chris
 
Back
Top