FIRST Robotics Competition Discussions

cancel
Showing results for 
Search instead for 
Did you mean: 

getting starting aera of robot

How can we get the starting area (back, middle, front) from the dashboard to the robot? Do you create shared variable and pass it back and forth?

What's efficient?

How are others doing it?

Thanks

"Lockheed" Joe
Testing Blog"
0 Kudos
Message 1 of 10
(5,191 Views)

There's a Get Alliance VI that, according to the documentation, returns the starting position.  The same VI existed last year but returned the position of the driver station, not the robot - does anyone know if the same is true this year?

I believe the recommended way to pass data from the Dashboard to the cRIO is the simulated IO channels.  You can use a couple of the simulated Digital IO points to tell the robot its field position before the match starts.

0 Kudos
Message 2 of 10
(3,427 Views)

The vi is there and the documentation says that it returns a 1,2,3 that

will say which position on the field. That's what I was looking for.

"Lockheed" Joe
Testing Blog"
0 Kudos
Message 3 of 10
(3,427 Views)

Yes I now believe that it is the DRIVER STATION POSITION and not the field position

The simulated IO is a easy way to set the field position.

Or a jumper on a spair IO line on the side car of the robot that you set when you place the robot on the field.

But you have to remember to set.

Omar
0 Kudos
Message 4 of 10
(3,427 Views)

Which VI sends data from the drivers station to the robot? I've only seen the one's going from the robot to the drivers station.

"Lockheed" Joe
Testing Blog"
0 Kudos
Message 5 of 10
(3,427 Views)

Get Digital Input VI

Returns the value of each of the digital inputs on the driver station.

Get Analog Input VI

Returns the voltage of each of the analog inputs on the driver station.

Omar
0 Kudos
Message 6 of 10
(3,427 Views)

Ok, those go from the sidecar DIO and analog. What about from the from the dashboard that shows up on the screen. Can you set a LabVIEW button on the dashboard and get it to the robot?

"Lockheed" Joe
Testing Blog"
0 Kudos
Message 7 of 10
(3,427 Views)

LockheedJoe wrote:

Ok, those go from the sidecar DIO and analog. What about from the from the dashboard that shows up on the screen. Can you set a LabVIEW button on the dashboard and get it to the robot?

If "those" in your post refers to the simulated IO on the Driver Station, they are not connected to the IO on the cRIO.  They are designed to simulate the Cypress board supplied in this year's kit, which plugs into the USB hub connected to the Classmate.  If you are not using the Cypress board then the simulated IO is available and you can use it to send data to the cRIO.  You can read those values in your robot code using the functions mentioned above, which are found in the DriverStation palette under the WPI Robotics Library.

0 Kudos
Message 8 of 10
(3,427 Views)

My ultimate goal is to get numbers from the Dashboard to the robot. I can kludge the transfer of numbers using binary and multiple DIO lines. (It just seems that there's a better way)

I understand how to read the DIO and Analog on the robot, no problem there.

However, How do you simulate the Digital IO output from the dashboard?

"Lockheed" Joe
Testing Blog"
0 Kudos
Message 9 of 10
(3,427 Views)

As far as I've seen, the FRC framework does not provide for sending data from the dashboard to the robot.

I'm replying in more detail about how you could do this outside the framework in your post titled Network Variable.  From a software point of view there should be no problem (unless the networking on the Classmate is locked down), but you would need to check whether it is permitted by the rules.

0 Kudos
Message 10 of 10
(3,427 Views)