Force Feedback MPC

April 14, 2026 ยท View on GitHub

Optimal control toolbox to achieve force feedback control in MPC. This library is basically an extension of the Crocoddyl optimal control library: it implements custom action models in C++ with unittests and python bindings. In particular, it contains the core classes used in MPC experiments of the following papers:

  • S. Kleff, et. al, "Introducing Force Feedback in Model-Predictive Control", IROS 2022. PDF
  • S. Kleff, et. al, "Force Feedback in Model-Predictive Control: A Soft Contact Approach" PDF (under review)

The code to reproduce our experiments (i.e. real-time implementation of the force-feedback MPC), along with our experimental data are available in this separate repository.

Dependencies

Python compatibility: 3.10-3.13

Core dependencies

PackageVersionPurpose
Pinocchio3.8.0Robot dynamics & kinematics
Crocoddyl>= 3.2.0Optimal control library
mim-solvers0.2.0Optimization solvers
CMake>= 3.10Build system

Demo dependencies

For force tracking & polishing demos (Kuka Iiwa):

For Go2 multi-contact demos (requires above + specific deps below):

Installation

Using the provided conda environment file:

# 1. Create environment from file
conda env create -f environments/force_feedback_mpc.yml
conda activate force_feedback_mpc

# 2. Build and install force_feedback_mpc from source
mkdir build && cd build
cmake .. -DCMAKE_INSTALL_PREFIX=$CONDA_PREFIX
make -j4
make install

# 3. Install required Python packages (from workspace root)
cd ..
pip install -e ./croco_mpc_utils --no-deps
pip install -e ./mim_robots --no-deps

# 4. [Optional] Install Go2Py for Go2 demos
pip install -e /path/to/Go2Py

Running the Demos

The demos are located in the demos/ directory. First, activate the environment:

conda activate force_feedback_mpc

Classical MPC (rigid contact force model)

python demos/force_tracking/classical/force_tracking_classical_mpc.py

Force-feedback MPC (soft contact force model)

python demos/force_tracking/soft/force_tracking_soft_mpc.py

Polishing Task (apply constant normal force while tracking end-effector circle)

python demos/polishing/classical/polishing_classical_mpc.py
python demos/polishing/soft/polishing_soft_mpc.py

Go2 Quadruped (whole-body multi-contact MPC)

Requires Go2Py to be installed.

python demos/go2arm/Go2MPC_demo_classical.py
python demos/go2arm/Go2MPC_demo_soft.py

Citing this work

@unpublished{kleff:hal-04572399,
  TITLE = {{Force Feedback in Model-Predictive Control: A Soft Contact Approach}},
  AUTHOR = {Kleff, S{\'e}bastien and Jordana, Armand and Khorrambakht, Rooholla and Mansard, Nicolas and Righetti, Ludovic},
  URL = {https://hal.science/hal-04572399},
  NOTE = {working paper or preprint},
  HAL_LOCAL_REFERENCE = {Rapport LAAS n{\textdegree} 24093},
  YEAR = {2025},
  MONTH = Jun,
  PDF = {https://hal.science/hal-04572399v2/file/force_feedback_article_second_submission.pdf},
  HAL_ID = {hal-04572399},
  HAL_VERSION = {v2},
}