macro-rail, micro-processor, nano-steps

A forum to ask questions, post setups, and generally discuss anything having to do with photomacrography and photomicroscopy.

Moderators: rjlittlefield, ChrisR, Chris S., Pau

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:If you knew the step-size you would be able to detect the magnification of an unknown optical-system.
Sure. In this case, the rail would be serving as something like a stage micrometer, except that the two tick marks separated by a known distance would be in separate frames.
Probably you know the expensive test 3000 of Zeiss.
I do not know this. Can you point me to a web page that describes it?

--Rik

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:For my second quick test I have chosen the step-size 10µm, 5 steps forwards and 5 steps backwards.
This graph is clearly on the path toward what we are expecting. From here, doing just the center third, with steps about 30 times smaller, should show the backlash region clearly.
As far as I can see the size of the steps depends on the direction?!
Yes, it looks that way.

Of course the appearance could be either unexpected movement or some problem with the measurement.

In this case I expect the measurements are correct. Assuming this is camera resolution at 20 megapixels, then xoffset shifts of roughly 0.01 will be a couple of hundred pixels. It is very unlikely that there is any significant error in the alignment process with such a large shift, but you could check that in ZS by putting a checkmark on "Show as adjusted" in the Input Files panel, then clicking back and forth between adjacent frames to confirm that after alignment the images match.

At this point, my guess is that the precise step size varies depending on how the gear teeth happen to be engaged at each position. For your first graph, I wrote that "the second half of the movement curve looks like what I would expect from a gear-driven system." Here is what I what I was referring to in that comment:

Image

This sort of repeating pattern is typical of what happens as successive teeth engage and disengage. I expect what we're seeing with this fast/slow alternation is a more exaggerated instance of the pattern shown in the first two "cumulative movement" graphs at http://www.photomacrography.net/forum/v ... 119#170119.

In your latest graph with 10 points, the two directions may be different because different faces of the gears will be engaged.

The pattern would be more obvious with more data points. But note also that when you re-run the experiment, the pattern may be different if the screw starts in a different position. You can see from the last two "Deviation From Linear Distance" graphs at http://www.photomacrography.net/forum/v ... 119#170119 that the pattern of step sizes can become very complicated depending on what scale and where in the pattern you happen to be looking.

--Rik

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Rik,
Enclosed you will find a link to the resolution test slide 3000:
https://www.micro-shop.zeiss.com/?l=en& ... 8-9901-000
BR, Adi

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello everybody,
This time the rail has been moved 10 steps forwards then 10 steps backwards with the step-size of 140nm.
Image
As far I can see the rail has forecasted that the direction should be changed and has started the moving in the opposite direction earlier then the motor :-)
Only to be sure I would add to every stack some steps to the range.
BR, Adi

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:Enclosed you will find a link to the resolution test slide 3000:
Thanks, that helps.

So now, I think the question that you're asking goes something like this:

"I have a rail that can reliably make movements of 1/6 micron. Can I use that capability in some way that makes it equivalent to a test slide with say 3000 line pairs per mm (1/3 micron per pair)?"

For practical purposes, I think the answer is "No."

What makes the test slide different is that it presents detail at 3000 line pairs per mm in a single frame. This presents the difficulty of interference between various parts of the pattern, which is the essence of diffraction and aberrations.

You could, of course, use the rail as part of a micro-machining device, to construct your own test slide, say by scratching a fine pattern of lines in some soft material.

But it becomes challenging in the extreme to make sufficiently fine lines.

By the time you were done with the task, I think it would have been far more efficient to just do something you're good at, to earn the $1248 that is needed to buy the slide from Zeiss. ($1248 is the price quoted today for my login registered as a personal customer in the U.S.)

--Rik

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:As far I can see the rail has forecasted that the direction should be changed and has started the moving in the opposite direction earlier then the motor :-)
Check to see whether the order of frames has been reversed during the alignment process.

When running this sort of test, it is best to remove the check mark on Options > Alignment > "Automatic order". Also on Rotation, Scale, and Brightness, since by physical construction those things cannot change. But automatic order is the important one.

--Rik

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Rik,
Yes, I know this price therefore I’m looking for the alternative to this slide :-)
BR, Adi

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Rik,
"Automatic order"
Yes, that was !
Now, the changing of the direction has happened two steps later (as in the middle) but this could be OK.
Many thanks!
BR, Adi

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:Now, the changing of the direction has happened two steps later (as in the middle)
It seems that these careful measurements always reveal interesting behavior.

This last graph shows some "hysteresis" in the movement. In a perfect world, moving 10 steps forward and 10 steps backward would bring the rail back to its original position, but in fact it's off by about 2 steps.

That part is not unusual, but I am surprised by the way in which it occurs. Instead of the "dead" region that I expected to see, your rail apparently continues to move in the same direction for a couple of steps after it has been commanded to reverse, before then actually reversing with no dead region. Definitely not a pattern that I would have expected.

There is one aspect that continues to bother me: I cannot make the offset numbers quite match up against your nominal step size. Perhaps I don't understand how your setup is configured.

I am thinking as follows. I assume you are looking at xoffset, and that your camera sensor is 36 mm wide. When xoffset changes between -0.0025 and +0.0005, there is a total shift of 0.003. This represents 0.003 * 36 = 0.108 mm of image shift on the sensor. Assuming 40X manification, 0.108/40 = 0.0027 mm shift of the subject. This happens over 10 movements, so 0.0027/10 = 0.00027 mm per movement, which is almost twice as big as the nominal 0.00014 mm that you've listed.

I'm wondering if something may have happened like actually getting your stepper controller configured for 8 microsteps instead of 16.

Have you done any other independent checks of nominal versus actual step size in your implementation?

--Rik

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Rik,
“Have you done any other independent checks of nominal versus actual step size in your implementation?”
No, I haven’t time for that up to now since my rail has been completed. But I have already begun to do that with your method :-)


“how your setup is configured”
I have already checked if the lens with 40x has been used.

1.) Micro-stepping on TB6560 :
is:
Image

should be:
Image


2.) Calculation

Code: Select all

    // NEMA 17 step angle 1.8 degree ==> 200 steps for the 360 degrees
    // TB6560 16 micro steps for the step
    // gear-box (99 + 1044/2057) : 1 ratio
    long NrOfStepsForOneFullRotationNema17 = 318424; // 200 * 16 * 99,5075352455031599   // for one turn on the output of the gear-box

    // Mitutoyo screw: scala 25 positions a 0,0254 mm
    // one full rotation ==> movement of the rail=0,635mm (25*0,0254)
    long distanceByOneRotationOfMitutoyoScrew = 635 ; // micro-meter )

    // Number of the steps for the movement of the rail by one unit    318424 / 635
    // long MOVE_ONE_MILLIMETER =  501455 ;   // 501455.1181
    // long MOVE_ONE_MICROMETER =  501 ;      // 501.4551181
    long MOVE_10_NANOMETER =  5 ;             // 5.014551181

3.) Implementation

Code: Select all

long Rail::moveStep(int direction, int numberOfSteps)
{
  digitalWrite(_pinDir, direction);    // Set the direction of the motor

  for &#40;long i = 0; i < numberOfSteps * MOVE_10_NANOMETER ; i++&#41;  // iterate for the steps given in 10nm units
  &#123;
    digitalWrite&#40;_pinStep, LOW&#41;;     // This LOW to HIGH change is what creates the
    digitalWrite&#40;_pinStep, HIGH&#41;;    // "Rising Edge" so the easydriver knows to when to step.
    delayMicroseconds&#40;200&#41;;          // This delay time is close to top speed for this particular motor. Any faster the motor stalls
  &#125;
&#125;
For the test I have used the step-size 14 (so, 14 * 10nm = 140nm) because the smallest step used by the procedure is 10nm.


BR, Adi

nucleobyte
Posts: 51
Joined: Sun Aug 22, 2010 8:00 pm
Location: Virginia, USA

Post by nucleobyte »

The xoffset graph several posts above struck me in it's similarity to graph 5.1 at this link: http://homepage.cs.uiowa.edu/~jones/step/micro.html . I wonder if what you are seeing could be the "detent effect" discussed there in relation to the non-ideal behavior of stepping motors when using sine-cosine current driven microstepping. The cyclic behavior appears to be in intervals of about 16 data points consistent with your microstep setting.

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Nucleobyte,
Thank you for the link!
Yes, it is very similar to my issue.
BR, Adi

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

nucleobyte wrote:The xoffset graph several posts above struck me in it's similarity to graph 5.1 at this link: http://homepage.cs.uiowa.edu/~jones/step/micro.html . I wonder if what you are seeing could be the "detent effect" discussed there in relation to the non-ideal behavior of stepping motors when using sine-cosine current driven microstepping. The cyclic behavior appears to be in intervals of about 16 data points consistent with your microstep setting.
The graphs are visually similar and the number 16 is the same, but the underlying cause has to be completely different.

In the graph of Adalbert that I labeled as fast/slow, the average step size measures to be about 0.2 microns per step (offset 0.01 on 36 mm sensor at 40X = 9 microns total movement, over a total of 45 steps). Taking into account Adalbert's 100:1 gear system and 200 steps-per-rotation motor (model 17HS19-1684S-PG100), this calculates out to be about 100 microsteps per point on the graph.

In other words, the period of cycling shown in the graph is about 100 times longer than the period of cycling due to the motor's detent effect.

Because of this scale difference, the detent effect of the motor itself cannot be an explanation for the cyclic nonlinearity that we see in the graph.

On the other hand, the cyclic nonlinearity in the graph would likely be a nice match to the size of teeth at one point in the gear train. That's why I said earlier that "the second half of the movement curve looks like what I would expect from a gear-driven system."

--Rik

rjlittlefield
Site Admin
Posts: 23562
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Post by rjlittlefield »

Adalbert wrote:
“Have you done any other independent checks of nominal versus actual step size in your implementation?”
No, I haven’t time for that up to now since my rail has been completed. But I have already begun to do that with your method :-)
To begin, I suggest a more direct test. Tell your system to advance by 635 microns and watch the dial of the micrometer. If all is well, it should advance by exactly one turn.

In general, the less you have to rely on device specifications and calculations, the more likely that the test will measure what you intend it to.

--Rik

Online
Adalbert
Posts: 2427
Joined: Mon Nov 30, 2015 1:09 pm

Post by Adalbert »

Hello Rik,
I have just tested the full rotation by the step-size of 635 microns.
In order to be able do that I had to change the variable numberOfSteps from int to float because my units are nano-meters :-)
So, the output of the gear-box has been rotated by this step exactly 360°.
While I was working at it I noticed that the shaft coupling is mounted in the not really best way :-(
Image
Probably I will have to improve that.
BR, Adi

Post Reply Previous topicNext topic