Fix movements axes
This MR contains the following
- Changes keybindings so that Right key increases the x value by default
- Adds a setting for inverting the axes for BaseStage, set as a mapping of axis and
Truefor inverting,Falseto not invert - A new action for inverting an axis
- Creates an internal attribute
_hardware_positionto track the position as defined by the underlying hardware. The propertypositionis in the "program" frame. Everything outside the stage Thing itself will only see things in the "program" frame. - Creates a private method for inverting position arrays. And turns
move_relativeandmove_absoluteinto wrappers around_hardware_move_relativeand_hardware_move_absolutethat first change the desired positions or directions into the hardware coordinates. Child stages should now override the_hardware_move_relativeand_hardware_move_absolutemethods, and update_hardware_positionnotposition. - Add in a check in
__init__for BaseStage thatmove_relativeandmove_absolutehave not been overridden. - Sets default movement axis inversions to True, False, True for the Sangaboard. Inverting x and z.
- Sets default movement axis inversions to True, False, False for the DummyStage. Inverting x.
Update to stage settings tab, allowing the user to flip z only
Stops user from flipping z key from navigate tab, and renames configuration
NOTE
- x is inverted in both Sangaboard and DummyStage so that the sample moving in to the right is positive x.
- y is not inverted in either so that the sample moving up is positive y
- z is inverted for the sangaboard, so that the objective moving up is positive z
## Still TODO
-
Multiple users (Julian, Ben) to test this on their microscopes -
[ ] Discussion of what the default behaviour should be, based on user expectations and ISO standards#514 -
[ ] Write a clear description into the documentation of what x,y, and z mean in terms of sample movement on the camera, and in terms of the stage.Now #514
Merge checklist:
-
All new/changed functions have up to date typehints and docstrings -
Any UI updates have a before and after screenshot in the MR description -
Unit testing of new functionality has similar or better coverage that similar existing code -
This code has been tested on a microscope -
With webapp has been recompiled (if changed) [ ] With updated settings JSON (if changed)-
SmartScan and live stitching work
-
Camera stage mapping also works
Final stitch also works
Closes #498 (closed)
Edited by Joe Knapper

