Skip to content
Snippets Groups Projects
Commit 904c46ce authored by rachelmoan's avatar rachelmoan
Browse files

Adding current control to robot class to keep track of control

parent ac30f993
No related branches found
No related tags found
No related merge requests found
import numpy as np
class Robot:
def __init__(self, label, color, radius, start, goal, dynamics_model, target_v, T, DT, rrtpath,waypoints):
self.label = label
......@@ -6,14 +8,15 @@ class Robot:
self.start = start
self.goal = goal
self.current_position = start
self.control = np.zeros(2)
self.rrtpath = rrtpath
self.next_step = None
self.next_control = None
if rrtpath is not None:
from guided_mrmp.controllers.path_tracker import PathTracker
self.tracker = PathTracker(start, dynamics_model,target_v, T, DT, waypoints)
# if rrtpath is not None:
# from guided_mrmp.controllers.path_tracker import PathTracker
# self.tracker = PathTracker(start, dynamics_model,target_v, T, DT, waypoints)
self.x_history = [start[0]]
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment