Jump to content
OMRON Forums

How to mess up the encoder scale in a Power PMAC 465 Clipper


HJTrost

Recommended Posts

I now have got my Power PMAC 465 Clipper to move my stages smoothly, with one odd feature:  I have rotary encoders on the motors of my leadscrew stages with 2000 lines per rev, corresponding to 6 mm/rev of the screw.  However, the counts reported by the Power PMAC are off by a factor 3.125 - 100,000 quadrature counts are reported at 24 mm instead of 75 mm.  Motor[x].PosSf and its relatives are all set to 1.0.  From using other controllers (PMAC2A/PC104, Turbo Clipper) on the same system I positively know that 75 mm is the correct answer. Are there any candidates among the many parameters that could be "used" to create such a discrepancy?

Cheers,             Jochen

Link to comment
Share on other sites

  • Replies 6
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

The “raw” feedback is scaled by “EncTable[x].ScaleFactor”. When used in a motor by way of “Motor[x].pEnc” it is then scaled by “Motor[x].PosSf”. The “axis” units can then be scaled by the axis definition statement, which uses motor position as the source, “#x->{axis scale factor}{axis name}“.

Link to comment
Share on other sites

Thanks for clarifying the relationships.  By setting EncTable[x].ScaleFactor=1/813.0 I am now getting my 75 mm for 100,000 encoder counts.  For now, I can live with handling the encoder scale this way.  Still, I don't understand why the raw quadrature encoder counts, which are unambiguously defined in hardware, are not being made available without any hidden scaling.  After all, that factor 1/813 has its own uncertainty, which comes on top of the one in the hardware (the accuracy of the linearity is somewhere in the 100-150 micron range in my present test system), and which I will have to measure eventually.

Link to comment
Share on other sites

I’m not sure what you mean. There is no “hidden” scaling. Raw feedback data is typically “fixed-point” (integer) data, as in a quadrature encoder. The servo algorithms require floating-point data. The ECT converts the data from fixed-point to floating-point data using the “EncTable[n].ScaleFactor” structure element. It is “1” by default, making the ECT output the resolution of the raw feedback device. If you wish to see the motor position in “user” units, you would typically use “Motor[x].PosSf” to effect this.

 

Usually, Motor[x].PosSf will be left at the default value of 1.0, so the motor units are in “counts” or “LSBs” of the feedback device, or it will be set so that the motor units become the engineering units of millimeters, inches, degrees, or revolutions. In the first case, the units of the matching axis are made to be engineering units by a non-unity scale factor (e.g. #1->1000X); in the second case, there can be a unity scale factor in the axis definition (e.g. #1->X).

Link to comment
Share on other sites

My problem is that after loading a bunch of settings (Clipper[0]...., Motor[x]...., Coord[1]...., EncTable[n]....) through a .pmh file of mine in the Global Includes directory into my Power PMAC Clipper, and then entering a command #1j=100000 in the Terminal window of the Power PMAC IDE gives me a move that is not commensurate with my hardware parameters, i.e., the 100000 counts do not make for a 75 mm move.  My hardware has a lead screw of 6 mm/rev, and the rotary motor has a rotary encoder on it with 2000 lines or 8000 quadrature counts per rev.  My coordinate system definition is

&1  #1->x  #2->y  #3->z

and I want to move in units of encoder counts or LSBs.  But only if I set EncTable[n].ScaleFactor=1/813 do I get about 75 mm for my 100000 "counts" move.

My encoder conversion tables look like this:

EncTable[1].Type=1
EncTable[1].pEnc=Clipper[0].Chan[0].TimerA.a
EncTable[1].index1=0
EncTable[1].index2=0
EncTable[1].ScaleFactor=1/813
// EncTable[1].ScaleFactor=1/256

following the description on pages 71ff in the Power PMAC Clipper manual of August 21, 2021.  I just noticed that on p.31, ServoCapt.a is offered for setting up quadrature encoders rather than TimerA.a - I'll try that one this afternoon.  It is not obvious to me which one of those is "right" for what reason.

Link to comment
Share on other sites

3 hours ago, HJTrost said:

I just noticed that on p.31, ServoCapt.a is offered for setting up quadrature encoders rather than TimerA.a - I'll try that one this afternoon.  It is not obvious to me which one of those is "right" for what reason.

That did it.  ServoCapt.a and ScaleFactor=1/256 are what I need.  Now the motors behave quite like I am used to seeing.

Edited by HJTrost
Typo.
Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.


×
×
  • Create New...