File contains all the functions used to measure the range of motion.
The range of motion is measured by first taking 5 'medium' sized steps which gives enough positions to predict future z positions. Next, one 'big' step is taken followed by 3 'small' steps to test that the stage is still moving as expected and has not reached the edge. Once the edge has been found and to account for the possibility that the edge was reached during a "big" step, the stage is moved in a sequence of steps in the opposite direction until motion is detected. This is position is taken as the true final position.
Throughout the test, parasitic motion (motion in the axis not being measured) is tracked and an error is raised if it exceeds a minimum amount. Currently this is 10% of the expected motion is the measured axis.
| Class | |
A class used to measure the range of motion of the stage in X and Y. |
| Class | |
Class for tracking range of motion data. |
| Class | |
Grouped dependencies for the Range of motion Thing. |
| Exception | |
Custom exception raised when parasitic motion is detected. |
| Constant | BIG |
Undocumented |
| Constant | DETECT |
Undocumented |
| Constant | MEDIUM |
Undocumented |
| Constant | PARASITIC |
Undocumented |
| Constant | SMALL |
Undocumented |
| Variable | |
Undocumented |
| Variable | |
Undocumented |
| Function | _axis |
Return the axis that a given movement dictionary moves in. |
| Function | _parasitic |
Compare desired movement to measured offset, report if parasitic motion was detected. |
dict[ str, float], return_other: Literal[ False]) -> str:dict[ str, float], return_other: Literal[ True]) -> tuple[ str, str]:dict[ str, float]) -> str:Return the axis that a given movement dictionary moves in.
For example: _axis_from_movement_dict({"x": 10, "y":0}) will return x.
| Parameters | |
movement:dict[ | The movement dictionary. |
returnbool | If True return a tuple with the first value being the movement axis and the second being the other axis. Default is False |
| Returns | |
str | tuple[ | The movement axis (and optionally the other axis) as strings. |
dict[ str, float], offset: dict[ str, float]) -> bool:
(source)
¶
Compare desired movement to measured offset, report if parasitic motion was detected.
| Parameters | |
movement:dict[ | The movement dictionary in image coordinates. |
offset:dict[ | The offset calculated from correlation. |
| Returns | |
bool | True if too much parasitic motion is detects. False if movement is as expected. |