Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   General Forum (http://www.chiefdelphi.com/forums/forumdisplay.php?f=16)
-   -   Hybrid Challenge-No Robot Left Behind (http://www.chiefdelphi.com/forums/showthread.php?t=61627)

Waynep 13-01-2008 23:42

Hybrid Challenge-No Robot Left Behind
 
The idea of this challenge came from this post, which deals with our responsibilities as veterans of FIRST to emanate positivity and foster the future of FIRST by encouraging and cultivating these younger teams. If you have time, I ask that you please read it.

HYBRID CHALLENGE
The GDC could not have done a better job at designing an autonomous/hybrid challenge to encourage all teams to at least move in the hybrid period. By simply putting a drive forward command into your code, you are then able to cross your start/finish line, allowing you to score points. There is absolutely no reason we should see robots take a "static defensive position" during the hybrid period, as we've seen too often in the past. A daunting portion of the game, many teams dismiss hybrid/autonomous period as being too difficult, whether due to lack of programming knowledge, or an absence of confidence in making a considerable difference or contribution in the match. Let's work together and change this mindset.

Veteran teams (or any team with a robot) that are attempting to do something in hybrid: it is my challenge to you to work before and at the regionals to ensure that NO ROBOT GETS LEFT BEHIND in hybrid; everyone DRIVES at the very least and attempts to cross one or two lines. Just giving the team the proper code does not fulfill the challenge. I fully expect you to help them understand the code (whether you enable them to dead reckon or use an IR remote to move), answer their questions, leave them with the confidence and knowledge to continue to improve their efforts and know you will be there to help them if questions arise, as well as to leave your door open to anyone seeking advice.

On a more selfish note, helping these teams will increase your odds of winning the match, so not only is it the RIGHT thing to do, but it will prove beneficial to your team as well. The level of play will only get better if we pair up these younger, less experienced teams with confident veterans and help them mature. We can slowly wait for this to happen, or we can come together and push this along.

MEASURE OF SUCCESS
There are 41 Regionals, thus 41 chances to get it right. Teams who scout, please report back in this thread what percentage of robots at your event attempted to move during hybrid period. I normally discourage overt bragging, but teams keep track of the teams that you helped go from "non-hybriders" to those who will actively participate in hybrid/auton mode. You will have earned your bragging rights and such accomplishments should be celebrated. I'd like to see 100% across the board, and do think that this is possible, but only if we work together to make it happen.

ACCEPTING THE CHALLENGE AND SPREADING THE WORD
If you accept my challenge, please insert the Hybrid Challenge Banner (courtesy of Joey Gannon) into your signature. I expect that by accepting the challenge you are committed to the cause, will help to spread the word, and will do your part in making this vision take life. Please share your thoughts and suggestions. I thank all of you in advance who will work to make sure that NO ROBOT is left behind during the hybrid period.

Guy Davidson 14-01-2008 00:27

Re: Hybrid Challenge-No Robot Left Behind
 
Wayne, I accept the challenge. I will make our Hybrid mode work (and work well, hopefully) before the regionals, so that (to the extent of my abilities) I can help other teams succesfuly take on the challenge of driving straight and turning left :)

If anyone would like some help programming, particularly if you're local (or if you'll be attending one of the regionals I will) please let me know, and I'll do what I can to make the code make more sense.

EDIT: I added the banner to my signature, now I guess I just have to wait for it to update.

Leav 14-01-2008 00:54

Re: Hybrid Challenge-No Robot Left Behind
 
I accept the challenge for the Israeli regional, and I'm sure Tottanka and feliks will join me.

Great Idea!

-Leav

Jimmy Nichols 14-01-2008 07:01

Re: Hybrid Challenge-No Robot Left Behind
 
Wayne, you know 1038 is and will always be willing to help out any team in need. It is what we do.

JBotAlan 14-01-2008 07:21

Re: Hybrid Challenge-No Robot Left Behind
 
I accept...newbies/veterans alike, feel free to PM/e-mail/IM/whatever me if you need help.

Tom Bottiglieri 14-01-2008 08:17

Re: Hybrid Challenge-No Robot Left Behind
 
Does this mean the end of "Spin Around/Dance" autonomous modes?

HedlessChkn 14-01-2008 10:39

Re: Hybrid Challenge-No Robot Left Behind
 
Quote:

Originally Posted by Tom Bottiglieri (Post 677464)
Does this mean the end of "Spin Around/Dance" autonomous modes?

haha our autonomous mode programmer did that accidentally then we improved upon it, within 2 rounds every bot that didnt already have an autonomous mode was spinning around just like it haha! i love it

petek 14-01-2008 21:34

Re: Hybrid Challenge-No Robot Left Behind
 
This year there are 63 teams registered for the week-one New Jersey regional, with a great lineup of veteran teams (totaling 343 years of experience!) and just four rookies. The caliber of teams that show up for this event is always great, as is the competition - except that there's usually only a handful that attempt autonomous on a regular basis.

I agree wholeheartedly with Wayne that Overdrive's Hybrid period makes scoring under robot control a very achievable goal for every team. With the number of veterans returning to NJ, most of whom are practicing strongly by lunchtime on Wednesday, there should be no excuse for any team to not at least make a lunge for the line!

So if you're one of those teams that has it together at lunch, instead of going home early, how about getting your scouts to pinpoint teams in need as Wayne suggests, and help them compete for the whole 2:15.

I'm sure that most events this year can boast equally strong fields and I hope all my fellow FTAs will join me in encouraging the NRLB initiative. When I walk through the pits in Trenton, Detroit and Philly I promise I'll be on the lookout for those in need and those who can help.

Travis Hoffman 14-01-2008 22:24

Re: Hybrid Challenge-No Robot Left Behind
 
How about we post and refine a simple, drop-in dead reckoning autonomous here in this thread so rookies and others can integrate and practice tuning such code ahead of time?

Why put teams under more pressure AT the events when you can help bridge the gap now, while there's still ample time?

d.courtney 14-01-2008 22:34

Re: Hybrid Challenge-No Robot Left Behind
 
I will accept this challenge. The biggest part of this I feel isn't so much helping them with understanding how to code, as much as ensuring they have the IR board working. A Hybrid code that has the functions of straight left right (just in case you turn left too much) and stop is extremely easy to explain after a team has a working IR board, and it only gets more complex from there. So make sure you bring the tools needed to help teams assemble a working IR board (I know most teams accepting this challenge wouldn't go anywhere without these tools)!

Guy Davidson 14-01-2008 22:37

Re: Hybrid Challenge-No Robot Left Behind
 
Quote:

Originally Posted by Travis Hoffman (Post 678058)
How about we post and refine a simple, drop-in dead reckoning autonomous here in this thread so rookies and others can integrate and practice tuning such code ahead of time?

Why put teams under more pressure AT the events when you can help bridge the gap now, while there's still ample time?

That sounds like a good idea Travis. However, some things to consider:

Teams use different framework codes - IFI's, Kevin Watson's, WPILib, EasyC. Each would need a different autonomous mode.

Teams use different pwm outputs for their drive motors, making it not truly a drop-in.

Teams use different gear ratios for the motors, so without encoders (or something similar, that regardless makes the whole routine a lot less drop-in-able) it would be hard to travel the same distances. While crossing the first line should be doable regardless, trying to add the turn would take more work.

d.courtney 14-01-2008 22:43

Re: Hybrid Challenge-No Robot Left Behind
 
Quote:

Originally Posted by sumadin (Post 678068)
Teams use different gear ratios for the motors, so without encoders (or something similar, that regardless makes the whole routine a lot less drop-in-able) it would be hard to travel the same distances. While crossing the first line should be doable regardless, trying to add the turn would take more work.

Unless I am missing something your saying that doesn't have to be the case, have the robocoach dictate when this turn takes place, why would it need an encoder or the same ratios?

Travis Hoffman 14-01-2008 23:29

Re: Hybrid Challenge-No Robot Left Behind
 
Quote:

Originally Posted by sumadin (Post 678068)
That sounds like a good idea Travis. However, some things to consider:

Teams use different framework codes - IFI's, Kevin Watson's, WPILib, EasyC. Each would need a different autonomous mode.

48, for one, uses MPLAB. I would not know how to perform this service for those teams who used anything else. But.....that's why we have all of yuns out there - to provide working, simple auto modes ahead of time in all formats. :)

Quote:

Teams use different pwm outputs for their drive motors, making it not truly a drop-in.


//Please replace pwm with actual values

#define leftmotor1 pwm01
#define leftmotor2 pwm02
#define rightmotor1 pwm03
#define rightmotor2 pwm04

leftmotor1 = 180;
leftmotor2 = 180;

...

Quote:


Teams use different gear ratios for the motors, so without encoders (or something similar, that regardless makes the whole routine a lot less drop-in-able) it would be hard to travel the same distances. While crossing the first line should be doable regardless, trying to add the turn would take more work.

Those who haven't programmed autonomous by the time of the regionals are most likely not going to care too much about anything other than simple timed auto routines. "Drop-in" the easy stuff with a pre-arranged routine, and you'll have more flexibility to add more functionality at the event.

Here's my initial contribution. This is the basic structure from one of our simpler auto modes from last year. If a team has successfully implemented encoders, they can replace the "timercounter" variable with the encoder variable. Please note I have never once taken a formal C programming course, so if I don't indicate something in the most "elegant" or "concise" manner, so be it. Often, the more complex and concise notations of the experienced aren't suitable for quickly teaching those who know jack squat about programming. Suggestions for improvements welcome.

Code:


unsigned int timercounter;
unsigned int timercounter2;
unsigned char pathtracker;
 
#define leftmotor1 pwm01
#define leftmotor2 pwm02
#define rightmotor1 pwm03
#define rightmotor2 pwm04

//Do a straight ahead timed move and stop - turn left at end of move
 
//Adjust values as necessary
 
#define NEUTRAL 127
 
#define STRAIGHTSPEEDLEFT  215 
#define STRAIGHTSPEEDRIGHT  200 //left side not as efficient
#define TURNSPEEDLEFT      54
#define TURNSPEEDRIGHT      200
#define STRAIGHTTIME        140  // ~ 35 counts per second
#define TURNTIME            185
#define DELAYTIME          0
 
//Step 1 - Straight Ahead to get in position
 
timercounter++;
 
if (pathtracker == 0)
{
timercounter2++;
 
if (timercounter2 < DELAYTIME)
{
//zzzzzzzzzzzzzz....delay start of movement
}
else
{
  if (timercounter < STRAIGHTTIME)
  {
      leftmotor1 = STRAIGHTSPEEDLEFT;
      leftmotor2 = STRAIGHTSPEEDLEFT;
      rightmotor1 = STRAIGHTSPEEDRIGHT;
      rightmotor2 = STRAIGHTSPEEDRIGHT;
  }
  else
  {
      pathtracker = 1;  //jump to the next step
  }
}
}
//Step 2 - TURN LEFT.
else if (pathtracker == 1)
{
if (timercounter < TURNTIME)
{
  leftmotor1 = TURNSPEEDLEFT;
  leftmotor2 = TURNSPEEDLEFT;
  rightmotor1 = TURNSPEEDRIGHT;
  rightmotor2 = TURNSPEEDRIGHT;
}
else
{
  pathtracker = 2;  //jump to the next step
}
 
}
else if (pathtracker == 2)
{
leftmotor  = NEUTRAL;  //Stop moving
rightmotor = NEUTRAL;
}
 
/*
You can add additional steps if desired to cross lane divider, turn again, drive past opponents'
finish line, etc.  And even if it might be boring and easy to program, don't forget about keeping the simple "line up in the left starting position and drive out a few feet" blocking defensive autonomous in your gee-whiz bag of tricks.  It may often prove to be a better strategy if you're facing a bevy of good autonomous bots - that is, if your bot is robust enough to survive the expected broadside contact from the opposing robots driving your way.
*/


Note that the left turn above is zero radius, when in fact, you might want to try and set up a gradual 180 degree turn that will take the bot smoothly past the lane divider. However, if you're running short on time or practice space to dial that kind of turn in, 90 degree zero-rad turns with a short move forward in between would be easier to set up.

I'll leave it up to others to add additional functionality if you wanted to include support for the IR remote to help indicate when to turn; i.e. you could program a longer timed straight move than necessary and use one of the remote functions to trigger the above program to step into the pathtracker = 1 left turn code. Another button (or another press of the same button - function written on 3 x 5 card would be "Jump to Next Autonomous Step") could then instruct the bot to jump from the turn step into the backstretch straightaway step. The IR commands would not replace the timed transitions - they would merely override the preset jumps prematurely. The timed jumps would still be there and occur should the robot not receive the IR commands from the Robocoach.

Not so hard - keep adding to it and see what we come up with.

blaxbb 14-01-2008 23:37

Re: Hybrid Challenge-No Robot Left Behind
 
I'll be in new york pit hopping

CzarValvador 14-01-2008 23:38

Re: Hybrid Challenge-No Robot Left Behind
 
Driving doesn't seem to be the difficult part.

Having the Robot figure out which ball is correct, and how to get there in order to push it off might be an issue.


All times are GMT -5. The time now is 23:06.

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