Skip to content

Commit

Permalink
Remove defaulting from MotorInfo.make_velocity_profile
Browse files Browse the repository at this point in the history
  • Loading branch information
coretl committed Feb 3, 2017
1 parent 080d4e6 commit b62aeb4
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions malcolm/parts/pmac/pmactrajectorypart.py
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ def _calculate_hat_params(self, v1, v2, acceleration, distance):
tm = dm / vm
return t1, tm, t2, vm

def _make_hat(self, v1, v2, acceleration, distance, min_time=MIN_TIME):
def _make_hat(self, v1, v2, acceleration, distance, min_time):
"""Make a hat that looks like this:
______ vm
Expand Down Expand Up @@ -175,7 +175,7 @@ def get_times(vm):
yield tm, vm
yield t2, v2

def make_velocity_profile(self, v1, v2, distance, min_time=MIN_TIME):
def make_velocity_profile(self, v1, v2, distance, min_time):
"""Calculate PVT points that will perform the move within motor params
Args:
Expand Down Expand Up @@ -215,10 +215,10 @@ def make_velocity_profile(self, v1, v2, distance, min_time=MIN_TIME):
it = self._make_padded_ramp(v1, v2, pad_velocity, min_time)
elif remaining_distance < 0:
# Make a hat pointing down
it = self._make_hat(v1, v2, -self.acceleration, distance)
it = self._make_hat(v1, v2, -self.acceleration, distance, min_time)
else:
# Make a hat pointing up
it = self._make_hat(v1, v2, self.acceleration, distance)
it = self._make_hat(v1, v2, self.acceleration, distance, min_time)
# Create the time and velocity arrays
time_array = [0.0]
velocity_array = [v1]
Expand Down

0 comments on commit b62aeb4

Please sign in to comment.