navigation updated with completed dijkstra's algo

Dependents:   R5 2016 Robotics Team 1

Revision:
1:a53d97b74fab
Parent:
0:fd72f6df078c
Child:
2:17bd430aeca1
--- a/navigation.cpp	Fri Oct 30 15:48:48 2015 +0000
+++ b/navigation.cpp	Sun Nov 22 19:32:45 2015 +0000
@@ -1,6 +1,6 @@
+#include "StepperMotor.h"
 #include "navigation.h"
 #include "stdint.h"
-#include <iostream>
 #include <fstream>
 #include <stack>
 #include <set>
@@ -153,6 +153,29 @@
     }
 }
 
+// FUNCTION:
+//      void executeRoute()
+// IN-PARAMETERS:
+//      Address of left and right steppers (StepperMotor &)
+// OUT-PARAMETERS:
+//      None
+// DESCRIPTION:
+//      Sends command to steppers to execute route.
+void Navigation::executeRoute(StepperMotor &leftMotor, StepperMotor &rightMotor)
+{
+    uint16_t target;
+    uint16_t targetAngle;
+    uint16_t targetDist;
+    
+    while (!route.empty() )
+    {
+        target = route.top();
+        route.pop();
+        
+        for (int i = 0; graph[vertex][i].neighbor == target; i++)
+    }
+}
+
 // utility function
 void Navigation::printPrevious(Serial &pc)
 {