diff --git a/src/straight_line.py b/src/straight_line.py index 29dc16e..55020ab 100755 --- a/src/straight_line.py +++ b/src/straight_line.py @@ -56,7 +56,7 @@ def get_forward_acceleration(y, velocity): #is less (or if we are close to the finish) forward_velocity=np.dot(velocity,unit_vector) forward_acceleration = 2*(9.5-forward_velocity) - forward_acceleration_2 = -1*(b2*forward_velocity+k2*(y-300))/m + forward_acceleration_2 = -1*(b2*forward_velocity+k2*(y-100))/m return min(forward_acceleration, forward_acceleration_2)*unit_vector def guidance_law(): @@ -77,7 +77,7 @@ def guidance_law(): #we add 2 to the vertical acceleration because otherwise it sometimes #just falls accelerations.vector.z=accel[2]+2 - return to_publish + return accelerations def accel_publisher():