Repository navigation
v1 Mantis: bring up the arm and Z, and a stop that halts the device - #1623
Merged
Merged
Conversation
BioCam
force-pushed
the
mantis-v1-03-arm-bring-up
branch
from
November 12, 2026 19:00
f9eaacb to
e00ab9d
Compare
BioCam
force-pushed
the
mantis-v1-03-arm-bring-up
branch
from
November 12, 2026 21:05
e00ab9d to
8a697ec
Compare
BioCam
marked this pull request as ready for review
November 12, 2026 21:18
BioCam
force-pushed
the
mantis-v1-03-arm-bring-up
branch
2 times, most recently
from
November 13, 2026 08:03
b24411f to
524c5bf
Compare
On a v4 the arm is built when board 11 answers. Its calibration, each arm motor's offset, encoder reference and encoder correction, comes from the unit's configuration and correction files or a saved configuration, never from a recording: without it, bringing the arm up refuses before anything is sent. The kinematics are pure maths in arm_kinematics: device units, inverse and forward kinematics, the encoder correction. setup() brings the arm and Z up command for command as in the recorded v4 startup: energise, declare from the absolute encoders, following error, move to idle, home Z on its home-done event, declare and move to idle twice, home Z. It moves only from near idle; elsewhere it refuses and unpowers the arms. setup(skip_arm=True) reads only. stop() aborts the sequencer, stops every motor, parks an arm brought up once every motor stopped (Z up alone and read back by its encoder, then queued as in the recorded close, Z down to 20 mm), then releases the clamp; each step in its own try. A move that fails part way stops the motors it started and logs where their encoders read. On a v4 the LED bar shows the bring-up in setup's colour. The Z column and the arm's links join the resource model, placed from a pose read. The simulation brings a simulated arm up. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
BioCam
force-pushed
the
mantis-v1-03-arm-bring-up
branch
from
November 13, 2026 08:29
524c5bf to
159c54c
Compare
…ne comes Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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.
The Problem
The Mantis arm (two arms driving one head, plus Z) has to be brought up after every power-on: energised, told where it is, homed. Each unit's arm is calibrated at the factory, so values from one unit put another's head in the wrong place. And a stop has to actually halt the device: abort what is queued, stop every motor and park, before the link closes.
PR Content/Solution
mantis.arm(v4), built when the absolute encoder board answers. Its calibration (each arm motor's offset, encoder reference and encoder correction) comes from the unit's configuration folder or a saved file, never from a recording; without it, bringing the arm up refuses before anything is sent.setup()brings the arm and Z up as in the recorded v4 startup: energise, read where the arms are from the absolute encoders, set the following-error limits, move to idle, home Z. It only starts near idle; anywhere else it refuses and unpowers the arms.setup(skip_arm=True)reads only, nothing moves.stop()halts the device: aborts the sequencer, stops every motor, parks an arm that was brought up (Z down to 20 mm), then releases the clamp. Each step runs even if one before it fails.arm_kinematics.py): device units, inverse and forward kinematics and the encoder correction, as pure maths.request_head_position,request_joint_position,request_absolute_joint_position,request_link_angles.Usage
On the device
A Mantis v4 on Windows (D2XX), head clear, no chip:
stop()🤖 Generated with Claude Code