Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Multiple Auto Modes? (http://www.chiefdelphi.com/forums/showthread.php?t=141268)

Unexas 09-01-2016 22:23

Multiple Auto Modes?
 
Is it possible in anyway in labview to either take a switch or button on the robot itself to switch between different autos? I want to use this solely so our team will be able to adjust depending on where the obstacles are. If you know of anyway to make this happen please voice your help.

sparkydp 09-01-2016 22:40

Re: Multiple Auto Modes?
 
You can set it on your DS before the match starts
http://wpilib.screenstepslive.com/s/...smartdashboard

Unexas 09-01-2016 22:58

Re: Multiple Auto Modes?
 
Quote:

Originally Posted by sparkydp (Post 1519705)
You can set it on your DS before the match starts
http://wpilib.screenstepslive.com/s/...smartdashboard

I am using labview so this makes no sense to me.

Unexas 09-01-2016 23:11

Re: Multiple Auto Modes?
 
Quote:

Originally Posted by sparkydp (Post 1519705)
You can set it on your DS before the match starts
http://wpilib.screenstepslive.com/s/...smartdashboard

Are you able to use this if i program in labview or is it only for java?

thatnameistaken 09-01-2016 23:21

Re: Multiple Auto Modes?
 
Quote:

Originally Posted by Unexas (Post 1519740)
Are you able to use this if i program in labview or is it only for java?

The SmartDashboard is java. However, LabVIEW has it's own customize-able dashboard. It can be created by selecting FRC Dashboard Project under new in the initial screen when you launch LabVIEW. You can send data between the robot and dashboard by using the VIs in the Dashboard section of the WPI library.

Mark McLeod 09-01-2016 23:25

Re: Multiple Auto Modes?
 
There are couple of LabVIEW examples for a robot mounted switch here, but it just depends on what kind of electrical switch you choose.

You can also use the default LabVIEW Dashboard to choose an autonomous mode. Examples are on the Basic tab of the Dashboard and have corresponding code in the default project.

Kyle Heaton 10-01-2016 00:06

Re: Multiple Auto Modes?
 
In years past, whenever I wanted to do an auto-selector for our robots, I would use a 2-way switch(Up is an increment, down is an decrement) on the DS which is read in the LV code with a DS-Read Integer with a integer case selector. That case then corresponds to a specific auto.

I also have that int selector display the auto that you will run on the DS for the driver's convenience.

Wish I could post code snippets, but my LV is currently updating on this computer for the season.

Robo Hamsters 10-01-2016 00:10

Re: Multiple Auto Modes?
 
Last year we used a RioDuino with touch screen to do just that. The screen also displayed diagnostics info.

Unexas 11-01-2016 11:56

Re: Multiple Auto Modes?
 
Quote:

Originally Posted by Robo Hamsters (Post 1519809)
Last year we used a RioDuino with touch screen to do just that. The screen also displayed diagnostics info.

Can you explain to me how this integrates with the RoboRIO? i have no experience with having anything other than the roborio for processing things.

414cnewq 11-01-2016 12:20

Re: Multiple Auto Modes?
 
I have done multiple auto modes before on a robot in C++, but I will try and generalize it for you so that you can port it over to labview. If you are wanting a physical switch (I. E. not dashboard), during your auto loop, you have an IF statement checking whether the switch is on or not. Within the IF statement, you put your autonomous code or function. You can have multiple IF statements for multiple auto modes, and you can check all switches in the IF statement (i.e. if Switch 1 is off and switch 2 is on and switch 3 is on (3 switches is just an arbitrary number) it can be a different auto than if all switches are on).

EDesbiens 11-01-2016 12:20

Re: Multiple Auto Modes?
 
Last year I had 10 different auto modes using Labview... You can modify the dashboard to display infos about each and to send/receive data... I'm trying to get a screenshot of it...

EDIT : Got the picture :

Team34Guy 11-01-2016 12:30

Re: Multiple Auto Modes?
 
Our programming subteam discussed this issue at length Saturday. some dip switches would allow you to select one of any number of autonomous modes you wanted to run. Your first step in autonomous would be to poll the switches and then proceed to the selected mode. I know that's over simplified, but that was the gist of our discussion.

EDesbiens 11-01-2016 12:37

Re: Multiple Auto Modes?
 
Quote:

Originally Posted by Team34Guy (Post 1521102)
Our programming subteam discussed this issue at length Saturday. some dip switches would allow you to select one of any number of autonomous modes you wanted to run. Your first step in autonomous would be to poll the switches and then proceed to the selected mode. I know that's over simplified, but that was the gist of our discussion.

Why wouldn't your guys do it on the computer with a selector in the driver station? Way simpler and you can change the number of modes at any time...

fsgond 11-01-2016 13:06

Re: Multiple Auto Modes?
 
I have used the driver station way of doing things, with fairly good success. If you do not have strong coders you could always hook switches to the DIO ports and "Code in" your autonomous mode. You can enter binary and have your field team carry a cheat sheet.

EDesbiens 11-01-2016 13:19

Re: Multiple Auto Modes?
 
If someone needs help with having multiple autonomous modes on a Labview driver station, PM me :) We could discuss/skype about it...


All times are GMT -5. The time now is 10:34.

Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi