Go to Post For the love of God,please post the hint. We're starting to lose control. - johnr [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 18-03-2008, 07:07
Tottanka's Avatar
Tottanka Tottanka is offline
It isnt about bots,its about humans
AKA: Liron Gurvitz
FRC #3211 (The Y Team)
Team Role: Mentor
 
Join Date: Dec 2006
Rookie Year: 2006
Location: Hadera, Israel
Posts: 1,418
Tottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond repute
how to run auto?

Hey, i wanna test my auto code, but i don't have that fency box.
is there any way of doing it?
Thanks =]
__________________
My FRC record: 10 Years,FTA (2008-9), 3 Teams(1947,2669,3211).3 RCA, 1 Championship EI(2016), 1 Divisional finalist (2016), 1 Regional winner.
Israeli 2016 Volunteer of the year.
  #2   Spotlight this post!  
Unread 18-03-2008, 08:25
Racer26 Racer26 is offline
Registered User
no team
Team Role: Alumni
 
Join Date: Apr 2003
Rookie Year: 2003
Location: Beaverton, ON
Posts: 2,229
Racer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond repute
Re: how to run auto?

1) Get the fancy box, or make one yourself using the "Competition Port Pinout Guide" on IFIRobotics.com
2) Shove a paperclip or similar in the right pins on the competition port, based on the guide on IFIRobotics.com (NOT RECOMMENDED)
3) Set team number to ZERO on the RC.
  #3   Spotlight this post!  
Unread 18-03-2008, 10:50
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: how to run auto?

The best solution is to wire up a couple of switches to a 15-pin connector and plug it into the competition port. See the Competition Port Pinout Guide on the IFI Robotics web site.

You can also write your program to call the autonomous routine when a button is pressed on the Operator Console, but that's not very convenient. You would need to change the while (autonomous_mode) statement to also check that button, and you have to be very careful about assuming anything about the state of the OI input values.

Last edited by Alan Anderson : 18-03-2008 at 12:27. Reason: Either I can't count or I can't type. I pick B.
  #4   Spotlight this post!  
Unread 18-03-2008, 11:52
Racer26 Racer26 is offline
Registered User
no team
Team Role: Alumni
 
Join Date: Apr 2003
Rookie Year: 2003
Location: Beaverton, ON
Posts: 2,229
Racer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond reputeRacer26 has a reputation beyond repute
Re: how to run auto?

Quote:
Originally Posted by Alan Anderson View Post
The best solution is to wire up a couple of switches to a 25-pin connector...
I think you meant a 15-pin connector there Alan.
  #5   Spotlight this post!  
Unread 18-03-2008, 16:35
Tottanka's Avatar
Tottanka Tottanka is offline
It isnt about bots,its about humans
AKA: Liron Gurvitz
FRC #3211 (The Y Team)
Team Role: Mentor
 
Join Date: Dec 2006
Rookie Year: 2006
Location: Hadera, Israel
Posts: 1,418
Tottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond reputeTottanka has a reputation beyond repute
Re: how to run auto?

Thanks a lot guys, i just shortened pins 8 and 5, and it worked.
I am currently working on an auto box though, as it is a much better solution..
__________________
My FRC record: 10 Years,FTA (2008-9), 3 Teams(1947,2669,3211).3 RCA, 1 Championship EI(2016), 1 Divisional finalist (2016), 1 Regional winner.
Israeli 2016 Volunteer of the year.
  #6   Spotlight this post!  
Unread 22-03-2008, 01:18
aerophd2001 aerophd2001 is offline
Software Mentor - Team 2366
AKA: Andy
FRC #2366 (Tesla Robotics)
Team Role: Mentor
 
Join Date: Mar 2008
Rookie Year: 2008
Location: Blue Springs, MO
Posts: 7
aerophd2001 will become famous soon enough
Re: how to run auto?

Here's how I tested my autonomous code:

1. Create a subroutine 'Auto' that contains my entire autonomous code.

2. Put the routine 'Auto' at the start of my User Controlled section as well as inside the Autonomous section.

3. Power up the bot and watch it run the 'Auto' routine (while in the User Controlled section).

4. Tweak and re-deploy (repeat until you like your 'Auto' routine).

5. Comment out (or flat out remove) 'Auto' from your User Controlled section.

Voila!
__________________
(Test + Refine Code + Deploy) ^ n
  #7   Spotlight this post!  
Unread 22-03-2008, 01:20
Eugene Fang's Avatar
Eugene Fang Eugene Fang is offline
The Blue Alliance
no team
Team Role: Alumni
 
Join Date: Jan 2007
Rookie Year: 2000
Location: Bay Area, CA -> Pittsburgh, PA
Posts: 772
Eugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond reputeEugene Fang has a reputation beyond repute
Re: how to run auto?

Quote:
Originally Posted by Tottanka View Post
Thanks a lot guys, i just shortened pins 8 and 5, and it worked.
I am currently working on an auto box though, as it is a much better solution..

just be careful; if you short the wrong pins, then you might have to say goodbye to your OI
__________________
Eugene Fang
2010 Silicon Valley Regional Dean's List Finalist

Various FLL Teams - Student (2000-2006), Mentor (2007-2010)
FRC Team 604 - Student (2007-2010), Mentor/Remote Advisor (2011-2015)
FRC Team 1323 - Mentor/Remote Advisor (2011-2014)

The Blue Alliance | TBA GameDay | TBA Android App
  #8   Spotlight this post!  
Unread 22-03-2008, 02:09
Cow Bell Solo's Avatar
Cow Bell Solo Cow Bell Solo is offline
No Stolte No
AKA: Chris
FRC #2194 (Fondy Fire)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 2007
Location: Minnesota
Posts: 381
Cow Bell Solo is a jewel in the roughCow Bell Solo is a jewel in the roughCow Bell Solo is a jewel in the roughCow Bell Solo is a jewel in the rough
Send a message via AIM to Cow Bell Solo Send a message via MSN to Cow Bell Solo Send a message via Yahoo to Cow Bell Solo
Re: how to run auto?

yeah make sure you have the right pins laid out, we just got a box from Radio Shack, got a push button(also from Radio) so auto was activated when pushed and then stopped once released(nice expecially when robot goes crazy). Plus we also got a switch for the disable function(which has also come in handy when little kids might drive the robot). and then got a cable from someplace online that the mentor ordered that came witha pin layout.
Make sure that you match up the correct wires
__________________
Who let the Blue Smoke Out
Team 2194 Mentor - 2012-Present - http://fondyfire.com
Team 2207 Alumni - http://whitebearlakerobotics.com
Iowa FIRST LEGO League Planning Team Member - 2010-Present - http://www.isek.iastate.edu/fll
FIRST LEGO League volunteer - 2008-Present

2008: MN Regional Quarterfinalists, Website Excellence
2009: MN North Star Quarterfinalists, recognized for safety, Website Excellence
  #9   Spotlight this post!  
Unread 23-03-2008, 12:48
mluckham's Avatar
mluckham mluckham is offline
Registered User
FRC #0758 (Sky Robotics)
Team Role: Mentor
 
Join Date: Mar 2006
Rookie Year: 2006
Location: Ontario, Canada
Posts: 116
mluckham will become famous soon enoughmluckham will become famous soon enough
Re: how to run auto?

The IFI Operator Interface manual says that setting the Team Number to zero will cause the robot code to run in Autonomous Mode.
  #10   Spotlight this post!  
Unread 23-03-2008, 13:28
garyk garyk is offline
Programming Mentor: 668, 972, 2643
FRC #0668 (Apes of Wrath)
Team Role: Mentor
 
Join Date: Dec 2006
Rookie Year: 2005
Location: Santa Clara (Silicon Valley) Calif.
Posts: 93
garyk is a jewel in the roughgaryk is a jewel in the roughgaryk is a jewel in the roughgaryk is a jewel in the rough
Re: how to run auto?

Quote:
Originally Posted by mluckham View Post
The IFI Operator Interface manual says that setting the Team Number to zero will cause the robot code to run in Autonomous Mode.
This used to work, BUT 2006 and later, the PWMs won't be driven: From the OI Reference Guide on the IFI website:
Quote:
A team number of zero is reserved for Autonomous Mode on the Robot Controller. Starting with the 2006 Robot Controller, a team number of zero will put the Robot Controller in Autonomous Mode, but the PWM outputs will be disabled. For more information on Autonomous Mode, see the Programming Reference Guide.
Why? There's no way to turn off the robot.

The shorting-pins-out is a lousy idea, it's easy to smoke the OI (I've seen this done.) If you are determined to do it, make sure you have a spare OI. The next best thing is a 15 pin male connector with the two pins soldered together, at least you can yank it off. The KOP joysticks have all 15 pins in their connector - I haven't taken one apart but if the right wires are in the cable you could rewire one of its buttons to be 'Autonomous'. In this case make sure all the other wires in the connector are disconnected.
__________________

Silicon Valley Regional 2005, 2006 972
Silicon Valley Regional 2007 668 Xerox Creativity Award
Championship Event 2007 668
Portland Regional 2008 668
Silicon Valley Regional 2008 668, 972
Beta Test Team 2008 668 (with 100 & 254)
Silicon Valley Regional 2009 668 Regional Chairman's Award; 2643
Sacramento Regional 2009 668 Winning Alliance (thanks, 1717 & 2473!), 2010 Winning Alliance 3256
CalGames 2006, 2007, 2008, 2009, 2010, 2011 Field Tech
NorCal FTC Regional 2008, 2009 Inspector
Championship Event 2009
San Diego, Silicon Valley Regionals; Champ. Event 2010 668, 2643, 3256
Silicon Valley, Madera Regional 2012 2643
WRRF Programming Instructor 2006-2016
Regional Woodie Flowers Award 2014 2643 Utah Regional


Last edited by garyk : 23-03-2008 at 13:35.
  #11   Spotlight this post!  
Unread 23-03-2008, 14:07
tseres's Avatar
tseres tseres is offline
obsessed with FIRST...
FRC #1565 (Think Tank Tech)
Team Role: Leadership
 
Join Date: Apr 2007
Rookie Year: 2007
Location: Cambridge, ON
Posts: 305
tseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of lighttseres is a glorious beacon of light
Re: how to run auto?

we just put it in our teleop code, and place a jumper that activates it. also, a regular joystick button has to be pressed and held to keep executing the code. so far the only problems is that i always edit the code in autonomous.c and forget to add the function to teleop.c for testing. that always leads to confusion when we can't do any tests :S
__________________


  #12   Spotlight this post!  
Unread 23-03-2008, 15:32
Bongle's Avatar
Bongle Bongle is offline
Registered User
FRC #2702 (REBotics)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2002
Location: Waterloo
Posts: 1,069
Bongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond reputeBongle has a reputation beyond repute
Send a message via MSN to Bongle
Re: how to run auto?

I always just modify the main loop so that it reads

Code:
if(autonomous || p4_sw_trig)
{
  ... calls into autonomous...
}
Plug in the port 4 joystick, hold trigger, and then your robot starts doing its autonomous routine. Let go, and it returns to teleop mode.

Then I mark off the port 4 joystick port on the OI so that no-one tries to use it in the competition. This way, you can immediately stop execution of autonomous by releasing the button if it starts doing something dangerous to humans or itself, you don't have to remember to copy code around, you don't risk frying your OI, and you don't need a special piece of hardware.
  #13   Spotlight this post!  
Unread 31-03-2008, 21:09
lingomaniac88 lingomaniac88 is offline
Registered User
FRC #1554
Team Role: Alumni
 
Join Date: Jan 2008
Rookie Year: 2007
Location: Long Island, NY / Cambridge, MA
Posts: 230
lingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud oflingomaniac88 has much to be proud of
Re: how to run auto?

This year, our team lost the switch we used to trigger autonomous, so I just created a duplicate project in MPLab that forced autonomous. So I changed one line in the default code under ifi_aliases.h to:

Code:
#define autonomous_mode 1
Boy, I wish I knew about the "set team number to 0" trick for this year. Much faster than uploading a different set of code. 1554 is 11000010010 in base 2, so we only have to change 4 switches.

If it works, then copy-paste the autonomous code into the default project.
__________________
"It is common sense to take a method and try it. If it fails, admit it frankly and try another. But above all, try something."
-- Franklin Delano Roosevelt.
  #14   Spotlight this post!  
Unread 01-04-2008, 00:42
Chaos in a Can Chaos in a Can is offline
Joel Spadin
FRC #1736 (Robot Casserole)
Team Role: Programmer
 
Join Date: Mar 2007
Rookie Year: 2007
Location: Peoria, IL
Posts: 58
Chaos in a Can is an unknown quantity at this point
Send a message via MSN to Chaos in a Can
Re: how to run auto?

We had a held button activate autonomous and learned one important thing.
If your code looks like
Code:
autonomous_mode = p3_sw_aux1;
, you may want to consider removing that line before your first match.
__________________
2006 Xerox Creativity Award
2007 General Motors Industrial Design Award
2008 Judges' Award
2009 Chrysler Team Spirit Award

  #15   Spotlight this post!  
Unread 01-04-2008, 01:28
Matt H. Matt H. is offline
Long Distance Mentor
FRC #1726 (N.E.R.D.S.)
Team Role: Alumni
 
Join Date: May 2006
Rookie Year: 2007
Location: Sierra Vista, AZ
Posts: 238
Matt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond reputeMatt H. has a reputation beyond repute
Re: how to run auto?

Please dont use a paper clip to short out the pins. We still have a fried OI from when our first club president decided we didn't need a dongle. Shorting the wrong pins could leaving you with out a method to test your autonomous code period.

AndyMark sells a very nice dongle for a reasonable price. It can be found here http://www.andymark.biz/am-0016.html
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
How to Auto Calibrate J30H30 Programming 13 12-03-2008 10:54
Can't get auto mode to run with OI switches kiettyyyy Programming 11 15-04-2006 00:05
Auto run sirbleedsalot Chit-Chat 3 06-02-2005 00:17
How is your team run? D.J. Fluck General Forum 38 29-12-2002 08:23
How do you Run your WebTeams? mpking General Forum 6 14-10-2001 15:26


All times are GMT -5. The time now is 04:33.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


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