HOW DO I GET MY LINE FOLLOWER TO STOP AT AN INTERSECTION?

HOW DO I GET MY LINE FOLLOWER TO STOP AT AN INTERSECTION?

Problem:

Small_VEX_Logo

I want my AGV to stop at an intersection in the black line using the linefollowers so it can pick up parts. How do I do it?

 

Solution:

Thanks Matt B for the ideas. There are a couple ways to make this happen.

1.You could do three if(sensorvalue)’s in a row downward.

or

2. Cut and paste the code below and add your values into RobotC:

//Pseudocode for stopping the AGV at a line

Can to be installed as a Void command- refer to your lab for tips

if(sensorvalue(RightSensor) < Threshold &&

Sensorvalue(CenterSensor) < Threshold &&

Sensorvalue(LeftSensor) < Threshold)

{

//Stop the AGV for a designated time

 

}

 100 total views,  1 views today

CHRIS HURD

JIM HANSON



Chris and Jim CIM
© Copyright 2020
Developed by phan1221

Visits: 3,966,860