|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
FRC default code
On the FRC default program is it programmed for one or two controllers to begin with???
-Hedgehogger |
|
#2
|
||||
|
||||
|
Re: FRC default code
Quote:
Perhaps this little chunk of code from user_routines.c will answer your question: Code:
/*---------- 1 Joystick Drive ---------------------------------------------- *-------------------------------------------------------------------------- * This code mixes the Y and X axis on Port 1 to allow one joystick drive. * Joystick forward = Robot forward * Joystick backward = Robot backward * Joystick right = Robot rotates right * Joystick left = Robot rotates left * Connect the right drive motors to PWM13 and/or PWM14 on the RC. * Connect the left drive motors to PWM15 and/or PWM16 on the RC. */ pwm13 = pwm14 = Limit_Mix(2000 + p1_y + p1_x - 127); pwm15 = pwm16 = Limit_Mix(2000 + p1_y - p1_x + 127); |
|
#3
|
|||
|
|||
|
Re: FRC default code
It also is able to do so with 2 joysticks as well, if you would look at where the PWM declorations above it a bit, I forget the lne numbers. You would use PWM outputs 1 and 2
|
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problem with FRC Default code | AsimC | Programming | 2 | 11-01-2004 19:22 |
| How long does it take you to load the default code? | vegasmcse | Robotics Education and Curriculum | 10 | 03-11-2003 21:41 |
| 2003 PBasic default code from Innovation First | ttedrow | Programming | 0 | 06-01-2003 11:18 |
| default code | archiver | 2001 | 2 | 23-06-2002 22:53 |
| Rookie Programmer has question about the default code | DanL | Programming | 3 | 26-01-2002 19:59 |