Add debug mode for knee problem