PMSM motor drive analog control loop

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
Specifications of pmsm servo motor:300W 200VAC Encoder:2000 ppr

I am tasked with fabricating a servo drive for the above said motor,which is used to drive rotary table(1:50 gear reduction).Indexing accuracy needed for rotary table 0.001 deg

I can program to a extent in assembly and c for small microcontrollers,but DSP is not my forte,since the power of motor is only moderate,i decided to implement the position and speed control loop with microcontroller and current control in analog way.FOC is the targeted method to be implemented.

My question: is it correct /reliable way to implement Park Clarke and their inverse transformation with multiplying dac and opamp alone(due to bandwidth constraint in microcontroller)

Chain of control

Encoder--up/down counter--Static ram--MDAC and opamp(for coordinate transformation and PI current control)

I know what I asked is pretty vague without the further details like control bandwidth ,desired motion speed acceleration and other stuff.I am just bit skeptical about going with analog circuit for transformation and PI control,so wanted to get opinion about that,planning to use 12 bit DAC,application will be suffice with 8 bit accuracy
 

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
Just a matter of convenience .it is just a one time task(servo drive)for us.so trying to accomplish it with what we can manage and debug,besides from a cost point of view implementing the current control loop in semi-analog way provides more benefits,for same bandwidth of control a DSP solution costs 10-15 times more
 

Papabravo

Joined Feb 24, 2006
22,058
Just a matter of convenience .it is just a one time task(servo drive)for us.so trying to accomplish it with what we can manage and debug,besides from a cost point of view implementing the current control loop in semi-analog way provides more benefits,for same bandwidth of control a DSP solution costs 10-15 times more
I think your economic estimates are pretty far off the mark. Have you done the analysis lately? Have you considered the cost of maintaining such a one-off project. You should.
 

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
Maintaining is planned for atleast 5years.either parts are stocked or checked for supply in market

Yes I did a cost comparison but not in detail,but considering I have to learn new thing the time involved,that itself will weigh in a lot.
 

nsaspook

Joined Aug 27, 2009
16,250
Just a matter of convenience .it is just a one time task(servo drive)for us.so trying to accomplish it with what we can manage and debug,besides from a cost point of view implementing the current control loop in semi-analog way provides more benefits,for same bandwidth of control a DSP solution costs 10-15 times more
Not today. I still have some old analog direct drive systems that use resolvers. The modern replacement digital drives are much simpler, easier to set up, tune and troubleshoot. What's the analog parts count for a analog three phase to two phase transformation matrix and back?
https://www.analog.com/media/en/technical-documentation/application-notes/ee396.pdf
Using the ADSP-CM41x MATH Unit for Clarke and Park Transforms

https://en.wikipedia.org/wiki/Linear_transformation_in_rotating_electrical_machines
 
Last edited:

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
Parts count for transformation alone

32kx8 static ram --1 no
12 bit DAC spi based---8 no
Quad opamps - 4-7 no(exact no not calculated yet)
Precision trimpot -10 nos
4 bit up/ down counter---6 nos (for encoder pulse count and Ram position up counting)
And other misc digital logic
 
Last edited:

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
The weakest link here is trim pot,but for 6- 8bits of accuracy they are more than enough,can be replaced by digi pot if needed


This solution is still digital because position and speed control are still done digitally,only the current sampling and it's processing is done in quasi analog way
 
Last edited:

nsaspook

Joined Aug 27, 2009
16,250
Parts count for transformation alone

32kx8 static ram --1 no
12 bit DAC spi based---8 no
Quad opamps - 4-7 no(exact no not calculated yet)
Precision trimpot -10 nos
4 bit up/ down counter---6 nos (for encoder pulse count and Ram position up counting)
And other misc digital logic
Or one 32-bit controller designed for motor controller applications for under $10 that will handle everything (I/O, Display, networking, etc...) including FOC: https://www.microchip.com/en-us/sol...ollers-for-motor-control-applications/pic32mk
https://www.microchip.com/en-us/product/PIC32MK0512MCJ064

https://forum.allaboutcircuits.com/threads/pic32mk-mc-qei-example.150351/post-1538575
1725418064508.png
If you don't understand DSP, it's time to learn.
 
Last edited:

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
Is it a extrapolated six step commutation you performed,I don't see a current sensing. the main bottle neck will a current sampling with averaging and performing transformation,as rotary table need torque at zero speed,will extrapolation be stable for holding position with constant torque
 

nsaspook

Joined Aug 27, 2009
16,250
Is it a extrapolated six step commutation you performed,I don't see a current sensing. the main bottle neck will a current sampling with averaging and performing transformation,as rotary table need torque at zero speed,will extrapolation be stable for holding position with constant torque
1725460054225.png

I'm using sine wave (with third harmonic injection) commutation for the slow speed drives with encoder positioning so I can set the zero speed torque easily. I have current sensing from the H-bridge chip to the controllers ADC.
https://www.nxp.com/docs/en/data-sheet/MC33932.pdf
1725459534062.png
1725459666961.png
https://www.ti.com/product/DRV8313
Most chips have current sense resistor connections.
 

Thread Starter

dhuwarakesh

Joined Apr 20, 2024
22
I will implement both the method in this case

1) first i will try six step commutation for fast movement and for fine movement and holding torque will go with sinusoidal modulation with a lesser powerful microcontroller since I won't be needing display, networking(rotary table only need to move to pre planned indexing position input through buttons)

2) i also dont want to abandon the idea I mentioned at first,i will look into it simultaneously.

Will update the progress.
 

MisterBill2

Joined Jan 23, 2018
27,170
Consider that in some parts of the world, quality electronic parts are neither readily available nor reasonably priced. And also consider that the system response time had not been specified, that I saw. Back in 1974 we had some quite accurate totally analog position controls available. Certainly it was possible then, it should still be possible now. Cost is a variable problem, some have no limits , others do have limits.
 

nsaspook

Joined Aug 27, 2009
16,250
Consider that in some parts of the world, quality electronic parts are neither readily available nor reasonably priced. And also consider that the system response time had not been specified, that I saw. Back in 1974 we had some quite accurate totally analog position controls available. Certainly it was possible then, it should still be possible now. Cost is a variable problem, some have no limits , others do have limits.
Analog will cost more, require more parts and will be less reliable. It's 2024, not 1974.
 

MisterBill2

Joined Jan 23, 2018
27,170
Later, back in 1986, another project used a mechanically indexed rotary table that was entirely accurate enough for fully automatic operation. Of course, the indexed positions were not randomly select-able.
 

MisterBill2

Joined Jan 23, 2018
27,170
If randomly chosen positioning is a requirement then certainly the cost will be greater. Seriously. AND it does not matter one speck which technology is used, greater accuracy and repeatability cost more. And still I have seen no mention of any position sensors except for a 2000 PPR encoder.
AND, BY THE WAY, good accuracy at higher speeds costs more.
 
Last edited:

MisterBill2

Joined Jan 23, 2018
27,170
One more observation relates to the stated accuracy requirement: .Indexing accuracy needed for rotary table 0.001 deg it does not seem that you can get that with a 2000PPR encoder. on the turn table. And if you put the encoder on the motor, the 50:1 reduction box needs to have zero backlash. So there will need to be some sort of compromise. It is not clear to me where the "precision trimpots" come in to play, perhaps for setting the position? But neither the resolution nor the accuracy are within the capabilities of the encode/mechanical pieces. In addition I saw no reference to the required positioning speed. Often times with servo systems, speed is important.
 
Top