Feature/tactile sensing#69
Merged
Merged
Conversation
… moved constants into new constants file
…ass, removed hardware version methods
Introduce protocol.py as a pure-function codec for the sensor wire format (frame building, parsing, decoding). Tighten validation (header checks, meta size guards, strict KeyError on missing taxels), move wire-format constants to constants.py, and reduce protocol knowledge leaking into sensor_client.py.
Moves the web-based sensor visualization (Flask/SocketIO) out of orca_core per reviewer feedback on separation of concerns. The UI now lives in its own repo and depends on orca_core as an external package.
Add MockOrcaHandTouch class backed by mock motor and sensor clients for testing hand+sensor workflows without hardware. Extract _create_sensor_client factory method from OrcaHandTouch to mirror the existing _create_motor_client pattern. Update sensor client type annotations to use PEP 604 union syntax.
- Clarify get_tactile_forces/get_tactile_taxels docstrings to show string-keyed dict access pattern and list valid finger keys - Remove unused taxel_coordinates module: 3D coordinate data is only consumed by the visualization UI, which now lives in orca_ui. Taxel counts remain in constants.py where the mock client uses them.
Lets tests synchronize on auto-stream startup without polling, and configure per-finger taxel counts via the constructor instead of mutating private state.
Replace class-based tests with module-level functions, parametrize where it tightens coverage, and use wait_for_first_frame() instead of the polling helpers.
Mock now round-trips through the real codec so wire-format bugs surface in tests.
OrcaHandTouch.connect() now mirrors the motor cascade: configured port first, then USB-VID auto-detection, with a successful auto-detect persisted to config.yaml. Adds connect_sensors_only() for motor-less sensor testing and makes get_auto_stats() return a snapshot copy so callers can diff values across calls.
# Conflicts: # orca_core/constants.py # orca_core/hand_config.py # orca_core/hardware_hand.py
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.
merge tactile sensing into main