Skip to main content

bar_ros2

BAR humanoid low-level control stack

A unified ros2_control stack for the Berkeley Architecture Research bimanual humanoids — same controllers, same MIT-mode interfaces, mock / MuJoCo / real CAN selectable from a single xacro arg.

Two robots, one codebase

Lite (bimanual, Robstride on SocketCAN) and Prime (eRob over EtherCAT + Sito on SocketCAN) share every controller, policy, and message. Robot differences live entirely in URDF and hardware-plugin selection.

Real-time-safe by construction

C++20 on ros2_control + realtime_tools. read() / update() / write() are allocation-free; PREEMPT_RT scheduling and CPU pinning are first-class.

MIT-mode hybrid commands

Five command interfaces per joint (position, velocity, effort, stiffness, damping) — the same convention silicon, MuJoCo, and mock hardware all honor, so policies port across tiers without re-mapping.

Five-mode FSM

ZERO_TORQUEDAMPINGSTANDBY LOCOMOTION | REMOTE. The gamepad picks the policy at the button — there's no launch-time arg. Safety status auto-falls to DAMPING; every transition is one switch_controller call.

MuJoCo sim2real

MuJoCo applies the same MIT-mode torque formula via qfrc_applied that our Robstride firmware computes — controllers and trained policies run unchanged against silicon and sim.

Out-of-process VLA tier

Heavy transformer / diffusion policies live in a Python rclpy node and publish MITAction over DDS. ObservationManager mirrors the C++ side structurally so policies promote between tiers without index drift.