Dynomotion

Group: DynoMotion Message: 11843 From: cnc_machines Date: 7/1/2015
Subject: SnapAMP Encoders
Tom,

Sorry if it seems I am flooding the board here. I have been working with my SnapAmp all day. Trying to get a servo to run for the first time.

Here is the report that I get when I run the AutoPhaseFind.c program. I am wanting to double check what to do with these values.

REPORT
------
0 Position = -10050 PhaseAngle = 3.753000
1 Position = -20050 PhaseAngle = 7.753000
2 Position = -10051 PhaseAngle = 3.552000
3 Position =    -51 PhaseAngle = -0.448000
Counts per rev = -10000
Counts per cycle =  -2500
Counts per cycle (rounded)=  -2500
invDistPerCycle (rounded)= -0.000400000000
Commutation offset =  -1006
Input Gain Specified =  1.000

I believe that I will use some of these parameters in this C program, but dont understand what goes where.

{
            p0=ch4->Position; // save position
            ch4->Position=0;  // set current position to Zero
           
            // set commutation offset to 1/4th of a cycle
            // encoder has 4000 counts/rev
            // motor has 3 cycles per rev
           
            ch4->CommutationOffset = 3*8000/2.0/12.0 * 1.02;
           
            printf("Position = %f\n",p0);
            break;


Do I also paste -0.0004 into the configure flash screen?


Thanks,


Scott

Group: DynoMotion Message: 11847 From: Tom Kerekes Date: 7/1/2015
Subject: Re: SnapAMP Encoders
Hi Scott,

The Report looks reasonable.  But I thought you were using Hall Sensors and didn't have an encoder?

Notice the index pulse is detected at nearly exactly 10000 count increments forward and backward and there are -2500 counts per phase angle cycle.

So yes the commutation parameters extracted are:

Using InputGain0 = 1
invDistPerCycle = -0.0004
Commutation offset -1006

You need to get clear with the concept that there are multiple ways to set Parameters in KFLOP and that whatever manner you are currently using needs to have the settings that you want to use.  If you are using the Screens to test, then the Screens should have the correct values.  If you are using a C Program to set the parameters in KFLOP, then the C Program should have the correct values.  You can use the Import/Export buttons to synchronize the screens with the C Program and vice versa. Please review this Flash Video:

HTH
Regards
TK


Group: DynoMotion Message: 11850 From: cnc_machines Date: 7/2/2015
Subject: Re: SnapAMP Encoders
Tom,

I am using two motors on this machine, one brushless with halls and one with an encoder.

My main point of confusion is this is the first time I have set up anything other than a stepper on the KFlop. It was unclear where the values go in the configuration screen. I think I got it now. Thanks!

Scott
Group: DynoMotion Message: 11852 From: cnc_machines Date: 7/2/2015
Subject: Re: SnapAMP Encoders
Tom,

Been working on this for a while a few questions.

  1. When testing in the step response screens - How do you set the voltage clamping and current for the snapamp?
  2. Where exactly do the report parameters go?
    1. invDistPerCycle - seems obvious I got this one
    2.  Commutation offset - Does this go in the Output Channels "Offset" right next to "Gain" and gets exported?
    3. "Offset" gets exported to a "C" program. Why is there a second place to add this parameter in the example program "HomeBrushlessSnap5.c"?

Thanks,


Scott



  @@attachment@@
Group: DynoMotion Message: 11854 From: Tom Kerekes Date: 7/2/2015
Subject: Re: SnapAMP Encoders
Hi Scott,

It seems you like to complicate matters :}

You might try working on one thing at a time.

Regards
TK

Group: DynoMotion Message: 11856 From: Tom Kerekes Date: 7/2/2015
Subject: Re: SnapAMP Encoders [1 Attachment]
Hi Scott,

The Voltage Clamping and Peak Current Limits for SnapAmp must be set with a C Program.  After they are set you can tune and change other parameters from either the Screens or C Programs.

CommutationOffset is something different than OutputOffset.  Set OutputOffset to 0 in your case.  CommutationOffset can also only be set with a C Program.  A 3 Phase motor normally needs some method of determining the absolute rotor angle in order to commutate properly so some sort of C Program is always required to accomplish this.  We normally refer to that process as "Phase Finding".  There are a number of possible techniques to accomplish this.  Our most common and preferred approach and the approach that is used in conjunction with the AutoPhaseFind.c example is where after power up the motor is rotated until the Index Pulse is detected.  At that point we can zero the encoder position and then use the commutation offset previously determined by the AutoPhaseFind Report to forever after properly commutate the motor (until a loss of power). 

I don't understand your last question.  Are you confusing CommutationOffset with OutputOffset?

HTH
Regards
TK