|
|
|
![]() |
|
|||||||
|
||||||||
|
|
Thread Tools | Rate Thread | Display Modes |
|
#12
|
||||
|
||||
|
Re: A Simple Improvement to Driving
My teams first robot used tank drive but with two drive wheels and two spining casters which made it very unstable at times and like you guys have said, it doesn't like to go in straight lines. Although this could be do inpart to the fact that one of the motors was slightly weaker that the other, but still that idea should work for us. After read the thread and seeing the drawbacks to it i came up with this idea:
If you were to designate one of the buttons on your joystick as a toggle switch and used it to toggle that function on and off depending on whether you want to be accurate or quick when driving. first set up code so when you push the button it switches a variable between 2 values. (you'll have to do this on your own because i don't know how. sorry )Then just use if statements: if ( toggle == 1 ) /* toggle = var. controlled by button */ { pwm01=(p1_y+((p1_y+p2_y)/2)/2); pwm02=(p2_y+((p1_y+p2_y)/2)/2); } else if ( toggle == 0 ) { pwm01 = /* what ever your normal code is */ ; pwm02 = /* what ever your normal code is */ ; } in theory that should work if you wanted to do that. thats what we did for our compressor last year to override the pressure sensor to build enough pressure to do the pull up on the bar. |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| A Simple note about life | dddriveman | Chit-Chat | 14 | 13-05-2004 20:33 |
| Simple things you can do to make your bot/team perform better | KenWittlief | General Forum | 21 | 01-04-2004 15:11 |
| Simple Autonomous Mode Example | deltacoder1020 | Programming | 5 | 08-03-2004 20:22 |
| In reference to the driving of Team 25 | Goober65 | General Forum | 24 | 14-04-2003 23:09 |
| Who's robots are driving already? | Anton Abaya | General Forum | 67 | 16-02-2002 00:07 |