package org.camsrobotics.frc2016.auto.actions;

import org.camsrobotics.frc2016.Vision;

/**
 * Waits for the vision target to 
 * 
 * @author Michael
 *
 */
public class WaitForVisionTargetAction extends TimeoutAction {
	private Vision m_table = Vision.getInstance();
	
	public WaitForVisionTargetAction(double timeout) {
		super(timeout);
	
	}
	
	@Override
	public boolean isFinished()	{
		return super.isFinished() || m_table != null;
	}
}
@@ -75,22 +75,85 @@
 frc2016.
-Vision
+Constants;%0D%0A%0D%0Aimport edu.wpi.first.wpilibj.networktables.NetworkTable
 ;%0D%0A%0D%0A/**
@@ -188,12 +188,8 @@
 rget
- to 
 %0D%0A *
@@ -297,45 +297,56 @@
 ate 
-Vision m_table = Vision.getInstance()
+NetworkTable m_table;%0D%0A%09private double m_contour
 ;%0D%0A%09
@@ -420,16 +420,120 @@
 out);%0D%0A%09
+%09m_table = NetworkTable.getTable(%22GRIP/myContourReport%22);%0D%0A%09%09m_contour = m_table.getNumber(%22centerx%22,0);
 %0D%0A%09%7D%0D%0A%09%0D
@@ -614,21 +614,48 @@
 %7C m_
-table != null
+contour == Constants.kCameraFrameWidth/2
 ;%0D%0A%09

update wait for vision target auto action