Micronic rack reader v1b1#1009
Open
alexjamesgodfrey wants to merge 23 commits intoPyLabRobot:v1b1from
Open
Conversation
- Replace abstract trigger_rack_id_scan() with composite scan_rack_id(timeout, poll_interval) -> str - Capability layer delegates directly; backend chooses one-shot vs trigger+poll - Micronic backend now uses GET /rackid (one-shot) instead of POST /scantube (which is the single-tube scanner, not the rack-barcode reader) - Update chatterbox, tests, and docs to match
- ruff format on rack_reader.py, driver.py, micronic_tests.py - annotate response.read() result so mypy --check-untyped-defs is clean
rickwierenga
reviewed
May 6, 2026
Member
rickwierenga
left a comment
There was a problem hiding this comment.
direct machine support is awesome
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.
Micronic provides liquid storage solutions in the form of barcoded vials, racks for the vials, and rack readers that read all vial Data Matrix codes plus the rack barcode.
This PR adds a generic
rack_readingcapability and a Micronic v1b1 integration that controls the reader hardware directly through PyLabRobot, without depending on Micronic Code Reader software, IO Monitor, or its HTTP server controlled by the software.The direct path:
PATHscanimagescan_commandio.SerialRackScanResultWhat's in this PR
RackReadercapability (rack_reading) withscan_rack,scan_rack_id, layout management, and state pollingMicronicCodeReaderdevice exposing therack_readingcapabilityMicronicDriverfor direct local scanner + serial rack barcode controlio.Serialrack barcode read path for the side barcode readerdocs/user_guide/capabilities/rack-reading.md,docs/user_guide/micronic/index.mdWhy not IO Monitor?
Micronic’s IO Monitor HTTP server can trigger rack scans and return results, but relying on that server means PLR is not actually controlling the hardware. This PR keeps the v1b1 shape, but moves hardware ownership into PLR itself.
PLR does not ship a TWAIN helper executable, SANE, or scanner drivers. The operator is responsible for installing the OS-level scanner bridge and Python decode dependencies in their runtime environment. For example I hd to install a driver for the COM4 barcode scanner that came with my rack reader.
Supported operations
reader.rack_reading.scan_rack()reader.rack_reading.scan_rack_id()io.Serialreader.rack_reading.get_state()reader.rack_reading.get_layouts()8x12/96get_current_layout()/set_current_layout()8x12,96(8x12),96Example
Hardware validation
Live-tested with an 8x12 Micronic rack (rd235) on the scanner: