Revision be629f33 examples/yarp_icub/src/icub_jointinterface.cpp

View differences:

examples/yarp_icub/src/icub_jointinterface.cpp
249 249
        double error_d = (position_error - last_position_error[id]) / (framerate*1000.0);
250 250
        last_position_error[id] = position_error;
251 251
        //finally do a PD loop to get the target velocity
252
        double target_velocity = PID_P[id] * position_error + PID_D[id]*error_d - speed;
252
        double target_velocity = 0.1*(PID_P[id] * position_error + PID_D[id]*error_d) - speed;
253 253

  
254 254
        printf("%f %f %f %f %f %f PID%d\n",
255 255
               get_ts_position(e).get_interpolated_value(data_ts),

Also available in: Unified diff