Skip to content

fix(pf400): restore monitor speed on init + expose speed control#105

Open
moeltae wants to merge 1 commit into
mainfrom
fix/pf400-speed
Open

fix(pf400): restore monitor speed on init + expose speed control#105
moeltae wants to merge 1 commit into
mainfrom
fix/pf400-speed

Conversation

@moeltae

@moeltae moeltae commented Jul 17, 2026

Copy link
Copy Markdown
Collaborator

Why the PF400 was moving slowly

The PF400 scales every motion by its global monitor speed mspeed (a 1–100 governor). The driver had set_sys_speed/get_sys_speed defined but never called anywhere — so the arm ran at whatever mspeed the last manual jog / teach-pendant session left behind (commonly 10–30%), silently slowing all automated moves.

Changes

  • driver.py — the fix: _ensure_system_speed() runs on every initialize() and sets mspeed to a configured value (default 100), clamped to 1–100. Non-fatal if it fails, so a bad governor can't block startup. Logs previous → new value.
  • pf400.proto / RobotConfig: new system_speed config field (default 100; unset/0 → 100).
  • server.py: wires system_speed into the driver; adds SetSpeed / GetSpeed gRPC commands (+ Estimate* for sim mode) so a teach-pendant speed slider can drive mspeed live.
  • server.py: adds a transit default motion profile (inrange=-1) enabling continuous-path blending on fast point-to-point legs — groundwork; approach/place keep inrange=0 profiles for precise settling.

Validation

  • Proto compiles and generates the new symbols.
  • Stubbed checks pass: mspeed clamping/default (0→100, 250→100, 30→30), SetSpeed clamping (150→100, 0→1), GetSpeed meta_data, transit profile (inrange=-1).
  • Not exercised against hardware — please verify on the arm, starting at low speed.

Notes / follow-ups

  • Generated *_pb2 are gitignored (built at install) — rebuild the package for the server to pick up Config.system_speed and the new commands. Takes effect on next tool Configure/initialize.
  • The transit profile is not yet wired into sequences (prod loads profiles from the Galago DB); applying blending to transit legs is a follow-up needing hardware tuning.
  • The C# device-controllers PF400 init has the same omission (Robot.cs has mspeed plumbing but doesn't set it) — same one-line fix applies.

This is Phase 1 of a larger PF400 / teach-pendant plan (jog overhaul, safety/recovery commands, richer status + teaching, pendant UI).

🤖 Generated with Claude Code

The PF400 scales every motion by its global monitor speed (mspeed, 1-100).
Nothing in the stack ever set it, so the arm inherited whatever governor was
left behind by manual jogging/teaching (commonly 10-30%), silently slowing
every automated move.

- driver: set mspeed to a configured value (default 100) on every
  initialize() via _ensure_system_speed(); non-fatal on failure.
- config: add system_speed field (pf400.proto Config + RobotConfig),
  default 100; server reads it and maps unset(0) -> 100.
- server: add SetSpeed/GetSpeed gRPC commands so a teach-pendant speed
  slider can drive mspeed live (plus Estimate* handlers for sim mode).
- server: add a "transit" default motion profile (inrange=-1) enabling
  continuous-path blending on fast point-to-point legs; approach/place
  keep inrange=0 profiles for precise settling.

Validated: proto compiles and generates the new symbols; mspeed
clamping/default, SetSpeed/GetSpeed dispatch, and profile config are
covered by stubbed checks.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@moeltae
moeltae marked this pull request as ready for review July 17, 2026 23:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants