Add SPIM-head F-drive device, hard limits, and focus/align plans#45
Merged
Merged
Conversation
- config.yml: add `temperature:` block (serial backend on COM8) so the device layer registers a `temperature` device. - Web Devices header: live water-temperature readout + setpoint control - data.py: GET /api/devices/temperature/status, POST /api/devices/temperature/set - devices.js: temperature panel (poll + set); main.css pill; index.html markup - Vendor integration SDKs: MQTT (test_temperature_controller.py) and USB serial (test_temp_usb.py).
- piezo.py: harden DiSPIMFDrive with module-level hard travel limits
(F_DRIVE_MIN_UM=30, F_DRIVE_MAX_UM=25000), non-overridable from above;
configurable per-move Status timeout (120s) for slow full-travel traverses.
- device_factory.py: register the SPIM head as `fdrive` (ZStage:V:37).
- plans/acquisition.py: spim_head_focus_descent_plan (3-phase descent:
fast traverse -> coarse 1000um steps -> fine sweep-and-fit under LED),
register_views_xy_plan (dual-view XY registration), and the composite
spim_head_focus_and_align_plan. Also fix get_stage_position_plan to use
bps.rd's actual return value (it was indexed as a {name:{value}} dict).
- device_layer.py: register the new plans and mark them heavy.
- test_dispim_device_safety.py: F-drive bounds tests for the 30/25000 limits.
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
5 tasks
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Adds the SPIM-head F-drive as a first-class device with non-overridable travel limits, plus automated focus-descent and dual-view alignment plans.
piezo.py: hardenDiSPIMFDrivewith module-level hard travel limits (F_DRIVE_MIN_UM=30,F_DRIVE_MAX_UM=25000), non-overridable from above; configurable per-move Status timeout (120 s) for slow full-travel traversesdevice_factory.py: register the SPIM head asfdrive(ZStage:V:37)plans/acquisition.py:spim_head_focus_descent_plan(3-phase descent: fast traverse → coarse 1000 µm steps → fine sweep-and-fit under LED),register_views_xy_plan(dual-view XY registration), and the compositespim_head_focus_and_align_plan. Also fixesget_stage_position_planto usebps.rd's actual return value (it was indexed as a{name:{value}}dict)device_layer.py: register the new plans and mark them heavytest_dispim_device_safety.py: F-drive bounds tests for the 30/25000 limitsTest plan
pytest tests/test_dispim_device_safety.pypasses (bounds enforcement)spim_head_focus_descent_planand confirm the 3-phase descent converges on focusNotes
Stacked on #44 (the diff shows the temperature-controller commit until #44 merges; the branches share history). Second of the two-PR split out of #43 — once both merge, #43 reduces to UX v2 only.
🤖 Generated with Claude Code