Fine focusing a microscope using StackShot

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: 23561
Joined: Tue Aug 01, 2006 8:34 am
Location: Richland, Washington State, USA
Contact:

Fine focusing a microscope using StackShot

Post by rjlittlefield »

This one is almost too embarrassingly simple to post out... :wink:

Image

Image

The stepper motor and controller are those listed in the Cognisys catalog HERE.

The other key component is a short length of vinyl tubing from the local hardware store. The tubing is chosen to be a loose press fit on the conical fine focus knob of the microscope. I turned a matching wood cone to fit on the shaft of the stepper motor. The tubing is not fastened to either cone, so it's free to tip sideways as needed to account for misalignment up to 1/8"or so. [Added for emphasis: Note that the taper of the cone gives the ability to tip. See HERE and the reply following it for discussion of why this is important.]

Resolution of the controller & stepper is 3200 "steps" per revolution, but those are actually 200 full steps with 16 microsteps each. With my CH base at 200 µm per turn, that's 1 µm focus change per full step of the motor.

Smaller increments can also be set using microstepping, but because of nonlinearities and stiction, those are less trustworthy. I don't know yet what is the practical limit of this setup.
[Update: This setup turns out to be good down to about 0.1 µm worst case. See HERE for discussion.]

For a sample image shot with this setup, see the pollen HERE.

--Rik

Edit: added emphasis about the tapered cone.
Last edited by rjlittlefield on Wed Sep 03, 2014 10:18 am, edited 2 times in total.

Craig Gerard
Posts: 2877
Joined: Sat May 01, 2010 1:51 am
Location: Australia

Post by Craig Gerard »

Rik,

How did you get the StackShot controller to move in increments of 0.001 mm?

Were you able to observe the fine focus dial moving consistently between image slices?

Craig
To use a classic quote from 'Antz' - "I almost know exactly what I'm doing!"

Mitch640
Posts: 2137
Joined: Sun Aug 15, 2010 1:43 pm

Post by Mitch640 »

That's pretty simple. My kind of simple. LOL I guess the controller is programmable?

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

Post by rjlittlefield »

Craig Gerard wrote:How did you get the StackShot controller to move in increments of 0.001 mm?
Like this:

Image Image

The nomenclature is a little confusing because there are three kinds of "step". But here's the explanation. By setting the global configuration to "Units: Steps" and then specifying "Dist/step: 16 stp", I'm telling the controller to move the stepper motor by one of its full steps, of which there are 200 per rotation. Because the Olympus CH focus block is 200 µm per rotation, and 200µm/200 = 1µm, I end up getting 1 µm movement from that specification of "16 stp". If the focus block were 100 µm per rotation, I'd get 0.5 µm movement.
Were you able to observe the fine focus dial moving consistently between image slices?
Yes, it seemed quite consistent at this setting. However, when I programmed it to move "1 stp" at a time, it would give a lot of short movements interspersed with an occasional long one that I estimate as about 1/2 µm instead of the nominally specified 1/16 µm. At this time I don't know the source of this irregularity, which also means that I don't know if it can be removed without going to fancier mechanics such a geared drive.
Mitch640 wrote:I guess the controller is programmable?
Yes, within limits. On the unit that I have, the front panel buttons can set "Dist/step:" only to 1 stp, 6 stp, 11 stp, 16 stp, and so on incrementing by 5. So with this unit, using the front panel buttons, I don't see how to specify 0.5 µm which would require "Dist/step: 8 stp". Under the covers, the controller is fully programmable so it's reasonable to pursue getting this limit removed in some future firmware upgrade.

--Rik

Craig Gerard
Posts: 2877
Joined: Sat May 01, 2010 1:51 am
Location: Australia

Post by Craig Gerard »

Thanks Rik,

You have demonstrated the ability to achieve 1µm with the CH block.

What is the resulting step size when 'Dist/step' is set to 31, 46 (considering that step is set to increment by 5) , etc? Would that provide 2µm, 4µm respectively (or thereabouts)?

I was wondering, if by using this method, we could cover the increments between 1µm and the standard (default minimum) 10µm of the controller?

Is there any adjustment in the 'Advanced Settings' that could be applicable?
In '==Custom Config==' I can see adjustments for 'Dist/Rev' (default 1.59mm), 'Backlash' (default 0.22mm).
3.13.1
Distance per Revolution
This configuration specifies the distance the rail travels in the linear direction per revolution of the motor. The default is shown below. Use the UP and DOWN buttons to adjust this value as needed.
== Custom Config ==
>
Dist/Rev: 1.59 mm
Backlash: 0.22 mm
Quote from StackShot Manual Version 1.1

Craig

*edit: added quote
Last edited by Craig Gerard on Wed Sep 29, 2010 1:11 am, edited 2 times in total.
To use a classic quote from 'Antz' - "I almost know exactly what I'm doing!"

realjax
Posts: 138
Joined: Wed May 19, 2010 12:22 pm
Location: Netherlands
Contact:

Post by realjax »

Maybe this is an option as well (cheaper), get a controller (hook up to your pc) and a motor from here. http://steppercontrol.com/motors.html
total cost: approx: $ 100

Edit: just noticed they are no longer in business.. bummer.
Jacco

ChrisLilley
Posts: 674
Joined: Sat May 01, 2010 6:12 am
Location: Nice, France (I'm British)

Post by ChrisLilley »

Craig Gerard wrote: How did you get the StackShot controller to move in increments of 0.001 mm?
The stackshot as a whole has a minimum increment of 10μm, but that is set by the thread of the rotating screw and the camera platform.

Used by itself, the limits of stackshot motor and controller are the minimum rotation it can reliably perform. What that translates to in linear motion depends on what it is coupled to (microscope focus knob, micrometer, etc).

ChrisLilley
Posts: 674
Joined: Sat May 01, 2010 6:12 am
Location: Nice, France (I'm British)

Post by ChrisLilley »

realjax wrote:Maybe this is an option as well (cheaper)
For those of us who already have a stackshot, the incremental cost of an additional motor is 50 USD (plus postage).

ChrisLilley
Posts: 674
Joined: Sat May 01, 2010 6:12 am
Location: Nice, France (I'm British)

Post by ChrisLilley »

Rik, I assume you already have this but for other folks who may be interested in the stackshot system, the user manual is available online (1.5Mb pdf) and has useful info like timing diagrams, connector wiring, adjusting torque, backlash compensation and so forth.

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

Post by rjlittlefield »

Craig Gerard wrote:What is the resulting step size when 'Dist/step' is set to 31, 46 (considering that step is set to increment by 5) , etc? Would that provide 2µm, 4µm respectively (or thereabouts)?
Yes, except for the typo that 46 would actually give about 3µm, not 4.
I was wondering, if by using this method, we could cover the increments between 1µm and the standard (default minimum) 10µm of the controller?
Yes. But there is a better way...
Is there any adjustment in the 'Advanced Settings' that could be applicable?
Yes, through the use of "creative misrepresentation".

For example, the following settings give 0.5 µm (8 microsteps) per focus step.

Image

Image

What I have done here is to lie to the controller about the scale of my physical setup. Instead of the actual 200 micrometers per revolution, I have claimed that there are 200 millimeters per revolution. Then I have set my focus step to be 0.5 "millimeters". The controller happily does the division, figures out that I want 1/400 of a rotation, and turns that into the requisite 8 microsteps to drive the motor.

At least, that's what I think is happening. The controller is a black box to me too, so I'm using a bit of guess-and-test here. But when I shot the controller screens shown here, the fine focus knob was definitely moving at an average of 0.5 µm per focus step.

Again, I was seeing a lot of moves at shorter than average, interspersed with occasional moves longer than average. I am reluctant to blame the irregularity on stiction in this case because a) I can't feel any stiction when I run the rig by hand with the power off, and b) the long moves seem to be at repeatable positions. But I also can't blame it on nonlinearity in the microstepping, because that should exactly repeat every two focus steps in this case, and it doesn't. Bottom line is that at the moment I don't have a clue what's causing the irregularity.

--Rik

Craig Gerard
Posts: 2877
Joined: Sat May 01, 2010 1:51 am
Location: Australia

Post by Craig Gerard »

Chris wrote:The stackshot as a whole has a minimum increment of 10μm, but that is set by the thread of the rotating screw and the camera platform.
Used by itself, the limits of stackshot motor and controller are the minimum rotation it can reliably perform. What that translates to in linear motion depends on what it is coupled to (microscope focus knob, micrometer, etc).
Chris,

Thanks for the clarification. I suppose that is a question for the crew at Cognisys...

*later note: message sent to Cognisys

Craig

edit: added note
Last edited by Craig Gerard on Wed Sep 29, 2010 7:29 pm, edited 1 time in total.
To use a classic quote from 'Antz' - "I almost know exactly what I'm doing!"

Craig Gerard
Posts: 2877
Joined: Sat May 01, 2010 1:51 am
Location: Australia

Post by Craig Gerard »

Rik,

Thanks for the "creative misrepresentation" exercise :)

One final bothersome question....why did you elect to set 'Backlash' to '0mm'?

I'm going to spend the $50.00 and buy a separate motor. I have been intending to buy the AS adapter plate for the StackShot, so may as well consolidate the order. :roll:

Craig
To use a classic quote from 'Antz' - "I almost know exactly what I'm doing!"

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

Post by rjlittlefield »

Craig Gerard wrote:One final bothersome question....why did you elect to set 'Backlash' to '0mm'?
Because the microscope's fine focus mechanism has zero backlash. The scope's gear train is kept loaded by gravity and/or springs so that any movement of the fine focus knob is immediately reflected in movement of the stage. This is very different from the screw drive of the StackShot rail, where on changing direction, the screw may have to turn a significant amount to take up slack in the nut before the carriage will start moving.

If I left backlash at the default setting, then I would worry about having my start/end positions get messed up because the controller's belief about backlash would be different from physical reality. I'm not sure whether it matters in this situation, but I have run into others where it definitely did.

--Rik

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

Post by rjlittlefield »

rjlittlefield wrote:Again, I was seeing a lot of moves at shorter than average, interspersed with occasional moves longer than average. ... Bottom line is that at the moment I don't have a clue what's causing the irregularity.
Just to keep you updated on this issue...

In further testing, it turned out that the pattern of irregular jumps does repeat every full step, contrary to what I wrote earlier. I hooked up some instruments and tracked the problem down to electrical drive being given to the motor to control microstepping. The guys at StackShot now have all my data and are working to figure out what it means and what to do about it. As it stands right now, the smallest step on my hardware that's both reliable and easy to use would be 1 µm (=1/200 turn at 200 µm per turn).

I'll let you know when I find out something more.

--Rik

ChrisLilley
Posts: 674
Joined: Sat May 01, 2010 6:12 am
Location: Nice, France (I'm British)

Post by ChrisLilley »

from Microstepping: Myths and Realities:
The real compromise is that as you increase the number of microsteps per full step the INCREMENTAL torque per microstep drops off drastically. Resolution increases but accuracy will actually suffer.

Few, if any, stepper motors have a pure sinusoidal torque vs. shaft position and all have higher order harmonics that in fact distort the curve and affect accuracy. And while microstepping drives have come a long way too, they still only approximate a true sine wave.

Significant too is that any load torque will result in a “magnetic backlash”, displacing the rotor from the intended position until sufficient torque is generated.
(my italics. the article continues with some formulae to calculate this).

It struck me that this effect might explain what you are seeing; smaller than expected steps followed by a jump as the torque passes some threashold and the magnetic backlash in the motor is overcome and settles into a new stable position.

(The other explanation would be error correction as small accumulated errors pass some threashold and are corrected. But I believe the stackshot is an open ended system without any positional feedback, so that seems unlikely.)

A tutorial which I found useful, from the University of Iowa in the US: Microstepping of Stepping Motors. Also (with more diagrams) Microstepping Tutorial which lists a number of sources of error.

IANAEME (I am not an electro-mechanical engineer)

Post Reply Previous topicNext topic