| http://www.w3.org/ns/prov#value | - ){ P = currpos - pos; I = I + P; D = P - Last_P; Last_P = P; error = int(P * Kp + I * Ki + D *Kd); constrain (error, -255,255); return error; if (error < 0){ DirLR = 1; //Right direction speed = max_speed + error; } else{ //Where is the test for when error is zero?
|