cancel
Showing results for 
Search instead for 
Did you mean: 

L6470 Change StepMode - stepLoss

andreas2399
Associate II
Posted on February 21, 2014 at 11:38

Our Setup:

L6470 with a small stepper (75mA Phase Current) and a linear stage.

We need to extend the movement Interface of the IC of +-2^21, to do long movements but have smoother movement in microstep mode.

Therefore our planned algorithm is like following:

Setup is Microstepmode128.

If the movement exceeds 2^21 ->

Switch to lower microstep mode (e.g. 1/64).

Do 99% of the required movement with microstepmode 1/64.

Switch to microstepmode 1/128 again

Move the remaining 1% with 1/128 again.

Note

: Movement is always in the granularity of FullSteps. So Resting Positions are always at a Full step position to not run into problems in that direction.)

This works most of the time, but we encoutered some problems, most likely resulting from the point while switching to a new step Mode.

For example:

We start at microstepmode128

Electrical position is 0.

We move 384 microsteps.

Electrical position is 384 (is correct, it's 3 fullsteps - we are in a valid fullStepPosition)

I change the stepmode to 1/2.

Now we can see a small movement on the linear stage with a MicrometerClock. -> This is not expected / and should not happen imho.

And the electrical Position changes to 128, which we also can't explain.

The Datasheet states that on changing step mode the ElectricalPosition is changed to the first microstep. But as we are always in a fullStep, there should not be a movement at all.

Best regards.andreas

#l6470
6 REPLIES 6
Enrico Poli
ST Employee
Posted on February 24, 2014 at 11:29

Hello Andreas,

Changing the step-mode causes the electrical position to be reset to 0, so if the previous value is different from 0 the motor changes its position.

Changing the step-mode during operation brings another drawback: the device bust be set in high impedance, so the motor is not kept in position by the holding current.

If you want to increase the range of the absolute position register you can consider to use the SYNC function. This way a position feedback is provided to the MCU and it can be used in combination with a counter to measure the number of full-steps performed by the device even if it is working at 128 microstep.

Best Regards

Enrico

andreas2399
Associate II
Posted on February 24, 2014 at 15:49

Hello Enrico,

Thanks for fast reply,

I do not believe the sync pin is feasible for our application. I forgot to mention that the user should not see the range extender functionality. So it is also not an option to drive 50% , stop , drive the rest. We want to drive 99% with another step mode, stop and drive the last part with fullMicrostepMode again. Whereas the last 1% of the movement is that small the user does not notice a movement at all.

In the example above, the stepper was at absolute position 384 (in MicrostepMode 1/128). As 384/128=3 - this is a FULL step position. Changing the step mode to 1/2, the register: ''electrical position'' changes its value to 128. And the stepper is also moving.

So at which electrical position is it safe to switch to another step mode ? Safe by means of the rotor will stay at the same position as before. And Full Step Positions do not work as expected.

The mechanic which is driven by the stepper is self-impending, so there is no movement from this side.

I have no problem if the electircal position is reset to 0, but the problem i phase is that i do not know which is the zero position (128? 256? 384?

 

- why is it 128 above?)./ Does it make a difference on which is the source/target step mode ?

I would be happy to know where i can switch step mode, without impact on rotation.

Best regards.andreas

andreas2399
Associate II
Posted on February 27, 2014 at 12:55

We did another bunch of tests, where i want to present the results here:

We started always in step mode 1/128, with a full reset (power off - on).

  1. Moving to Position 512

    1. electrPos = 0

    2. Switch step mode to 1/2

    1. electrPos = 128

  1. Moving to Position 128

    1. electrPos = 128

    1. Switch step mode to 1/2

    2. electrPos = 128

  1. Moving to Position 256

    1. electrPos = 256

    1. Switch step mode to 1/2

    1. electrPos = 128

  1. Moving to Position 384

    1. electrPos = 384

    1. Switch step mode to 1/2

    1. electrPos = 128

  1. Moving to Position 384

    1. electrPos = 384

    2. Switch step mode to 1/32

    3. electrPos = 128

  1. Moving to Position 128

    1. electrPos = 128

    2. Switch step mode to 1/32

    1. electrPos = 128

So every step change led to a change of the electrical position to 128.

Open Questions

Is the electrical position register information trustworthy about this information?

Is the electrical Position 128 the safe position to switch step mode, where no movement will be introduced?

Best regards.andreas

Enrico Poli
ST Employee
Posted on March 06, 2014 at 08:51

The EL_POS register contains a counter covering 4 full steps (a complete sinewave) and it should be reset to 0 each time you change the step mode value, so if you want to change the step mode keeping the electrical position unchanged you need to do it when EL_POS is zero.

In your last test something is wrong: changing the step mode the EL_POS should be 0, not 128.

Enrico

andreas2399
Associate II
Posted on March 11, 2014 at 16:16

There was an error in the test setup. The ElPos register ist now zero after each stepMode Change.

And our testruns look good now (no lost steps so far) if we only change the stepMode et electricalPos = 0.

best regards.andreas

Enrico Poli
ST Employee
Posted on March 13, 2014 at 14:33

Very good.

Kind Regards

Enrico