You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit 781fa4a
Browse filesBrowse the repository at this point in the historyBrowse files
Copy file name to clipboardExpand all lines: CHANGELOG.md
+14Lines changed: 14 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -10,6 +10,20 @@ the next version with `-DEV`).
10
10
11
11
## [Unreleased]
12
12
13
+
### Fixed
14
+
-`PIStage`: `shutdown` could close another object's connection. `id` defaulted to `0`, a valid GCS id, and was never reset; it now defaults to `-1` and `shutdown` resets it.
15
+
-`PIStage.initialize` reported the stage connected before it was: `connectionstatus` was set before the connect, and a failed close after a failed reference left it `true`, so a retry answered "already initialized". It is now set only after the whole sequence succeeds, and every step after the connect is inside the cleanup.
16
+
-`PIStage.initialize` ignored a FALSE from reading the travel range (`PI_qTMN`/`PI_qTMX`) or setting the velocity, and came up connected with an unset range. Each is now checked; a failure closes the connection and throws. A failed range query no longer writes an uninitialized buffer into `range_x`/`range_y`.
17
+
-`PIStage.initialize`'s wait for motion to stop after the reference move had no deadline and ignored `PI_IsMoving`'s return, so a failed query could spin forever. It now polls every 0.1 s, throws on a failed query, and gives up after `REFERENCE_TIMEOUT_S`.
18
+
- A `PIStage.initialize` retried after a failed close reported the controller held by another process. The stage now closes its own earlier connection first, and does not reconnect if that close fails too.
19
+
- The stage, Triggerscope and objective-positioner panels log a failed `initialize` instead of throwing out of the callback, through one helper, and a stage panel reads no position after an `initialize` that did not connect.
20
+
21
+
### Changed
22
+
-`PIStage.initialize` waits for `PI_IsControllerReady` after the reference move, before polling `PI_qFRF`, as PI's samples do. Not yet run on hardware; needs a rig check on the C-867.
23
+
24
+
### Added
25
+
- Fake-GCS2 tests for `PIStage` (`test/pi_stage_fake_sdk.jl`, `test/pi_stage.jl`): `initialize`'s ordering and cleanup and `shutdown`'s id handling, the range, velocity and motion-stop checks, the reclaim after a failed close, and the GUI guard, with no hardware.
26
+
13
27
## [0.2.5] - 2026-09-29
14
28
15
29
A non-breaking release. It brings the TCube laser's closed-loop (power) mode and
Function to initialize PI Stage, right now this requires calibration using PiMikroMove to work correctly, no documentation on how to calibrate using the PI_GCS2 library
2
+
Initialize the PI stage. Connects to the first PI C-867 the GCS2 library enumerates, turns both
3
+
servos on, starts the reference move, waits for the controller and for both axes to report
4
+
referenced, reads the travel range, waits for motion to stop, and sets `stage.velocity`.
5
+
6
+
`connectionstatus` becomes true only when all of that succeeded. A failure after the connect
7
+
closes the connection and throws. Enumeration and connect failures log `@error` and return with
8
+
`connectionstatus == false`.
9
+
10
+
`[limitation]` Not yet run on hardware; the wait for `PI_IsControllerReady` needs a rig check on
11
+
the C-867. The stage needs calibration using PiMikroMove to work correctly; there is no
12
+
documentation on how to calibrate using the PI_GCS2 library.
Copy file name to clipboardExpand all lines: src/hardware_implementations/pi_stage/interface_methods.jl
+3-2Lines changed: 3 additions & 2 deletions
Original file line number
Diff line number
Diff line change
@@ -1,7 +1,7 @@
1
1
"""
2
-
Function to initialize PI Stage, right now this requires calibration using PiMikroMove to work correctly, no documentation on how to calibrate using the PI_GCS2 library
2
+
Initialize the PI stage; see `initialize_original` for the sequence and its failure behaviour.
0 commit comments