Skip to content

Switch build system to bzlmod, bump all software versions for the FR3#4

Open
wernerpe wants to merge 17 commits into
RobotLocomotion:mainfrom
wernerpe:update_driver
Open

Switch build system to bzlmod, bump all software versions for the FR3#4
wernerpe wants to merge 17 commits into
RobotLocomotion:mainfrom
wernerpe:update_driver

Conversation

@wernerpe
Copy link
Copy Markdown

@wernerpe wernerpe commented Oct 16, 2025

I switched the build system and updated all of the software versions for the FR3. I am hoping this will help make using the frankas with drake more plug and play. I will be providing code on the drake side of things shortly 👍


This change is Reviewable

AdityaBhat-TRI and others added 11 commits November 25, 2024 14:58
- Migrate from WORKSPACE to MODULE.bazel approach using module extensions
- Create module extension at tools/workspace/external_repositories.bzl
  to load repository rules from individual files
- Keep all version information in separate repository.bzl files for
  easy maintenance

Upgrade dependencies:
- Upgrade libfranka v5 to faaefaa0ff17 (latest version with logging and
  new API)
- Upgrade libfranka-common v5 to cd38d0ec (compatible with new libfranka)
- Add pinocchio v2.6.21.bcr.4 from Bazel Central Registry (required by
  new libfranka for dynamics algorithms)

New structure:
- MODULE.bazel: Clean module declarations with bazel_dep for pinocchio
- tools/workspace/external_repositories.bzl: Module extension loading
  individual repository rules
- tools/workspace/*/repository.bzl: Version information for each
  dependency
- BCR pinocchio automatically pulls in transitive dependencies (Boost,
  urdfdom, etc.)

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This commit adds comprehensive version documentation for the FR3 robot update
and improves the developer experience with buildifier lint failures.

Version Documentation:
- Added Software Versions section to README listing Drake v1.45.0, libfranka
  v5 (~0.15.0) for FR3, libfranka v4 (0.9.0) for FE3, Pinocchio 2.6.21, and LCM
- Added detailed comments in MODULE.bazel explaining dependencies for FR3 support
- Added docstrings to libfranka repository files documenting exact versions
- Updated README notes with accurate libfranka version numbers

Buildifier Improvements:
- Created buildifier.py wrapper script that displays helpful error messages
- Updated lint.bzl to use Python wrapper instead of direct shell execution
- When buildifier fails, now shows clear instructions on how to fix formatting
- Makes it easier for developers to resolve lint failures quickly

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@wernerpe
Copy link
Copy Markdown
Author

@sammy-tri @jwnimmer-tri
If anyone would be interested in having a look it would be greatly appreciated. Thanks! (I know this is a big PR...)

@sammy-tri sammy-tri self-assigned this Oct 20, 2025
Copy link
Copy Markdown
Collaborator

@sammy-tri sammy-tri left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+a:@sammy-tri I probably won't get to it immediately but I'l take ownership

Reviewable status: 0 of 23 files reviewed, all discussions resolved

Copy link
Copy Markdown
Author

@wernerpe wernerpe left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

gotcha, thanks a ton!

Reviewable status: 0 of 23 files reviewed, all discussions resolved (waiting on @sammy-tri)

wernerpe and others added 5 commits October 27, 2025 11:29
- Add package.xml to define driver_models package for custom URDFs.
  This allows users to simply drop URDF files in the models/ folder
  and reference them via package://driver_models/... in directives
  without modifying C++ code.
- Add panda_hand_frozen.urdf with welded finger joints
- Add add_franka_control_with_frozen_hand.yaml directive
- Update franka_driver.cc to register driver_models package via AddPackageXml
- Update models/BUILD.bazel to include new model files
- Fix package path in add_franka_control.yaml (drake -> drake_models)

This enables using Drake's inverse dynamics with the hand mass/inertia
included in the model while keeping fingers fixed.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Add --disable_rate_limiting flag to allow bypassing libfranka's
conservative client-side velocity/acceleration limits. When enabled,
commands are sent directly to the robot without being clamped by
limitRate() calls in libfranka's control loop.

This is useful when:
- libfranka's zero packet-loss tolerance (kTolNumberPacketsLost=0.0)
  causes false positive limit violations
- Using external dynamics models (Drake MbP) that compute commands
  near but within actual robot limits
- Commands get rejected due to tight velocity limit tolerances

The robot firmware still enforces its own safety limits, so this
remains safe while providing more flexibility.

Also add .claude/* to .gitignore to exclude Claude Code metadata.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
Remove wildcards from .so file patterns to be more specific about
which shared library files are included. This prevents accidentally
including versioned symlinks and ensures only the actual .so files
are referenced.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
This new control mode accepts both position and velocity commands from
Drake, eliminating the phase lag from finite-differencing positions to
compute velocity feedforward.

Key improvements:
- New ControlMode::kPositionVelocity that accepts both q and v commands
- Velocity comes from Drake's analytical Bezier derivatives (no lag!)
- Only differentiates velocity once to get acceleration (cleaner)
- Uses diff_low_pass_freq for velocity filtering (30Hz)
- Same PD + dynamics feedforward control law as before

Expected benefit: Better tracking on fast trajectories by eliminating
the ~30Hz low-pass filter lag in velocity feedforward.

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
Removes accidentally added position_velocity control mode.
Adds command_receipt_utime_ tracking to fix command expiration logic.

The previous code checked command age using message timestamps which
failed with clock skew. Now tracks receipt time locally (following
drake-iiwa-driver pattern).

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
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.

3 participants