|
|
|
![]() |
|
|||||||
|
||||||||
![]() |
| Thread Tools | Rate Thread | Display Modes |
|
#1
|
||||
|
||||
|
problem with the default code
I ran into a problem with the default code from IFI. The drive pwm out puts are the same for each side when the joystick is moved only in the Y-axis where that should be the case for the X-axis.
|
|
#2
|
|||||
|
|||||
|
Re: problem with the default code
X axis is left and right. Y axis is front and back. When you move the joystick along the Y axis, you want the robot to move straight forward or backward. That requires controlling the motors on both sides identically.
The default code is doing what it is designed to do, and it is correct. |
|
#3
|
||||
|
||||
|
Re: problem with the default code
yes that I realize. Right now I have one side wired backward so it will go straight. I know that is not FIRST legal.
|
|
#4
|
|||||
|
|||||
|
Re: problem with the default code
What do you mean wired backward. If you mean the M+ to the black wire coming off the motor and the red to the M- this is completely legal we have done it in first many times before.
|
|
#5
|
||||
|
||||
|
Re: problem with the default code
Thanks thats a relief.
|
|
#6
|
||||||
|
||||||
|
Re: problem with the default code
Quote:
|
|
#7
|
|||
|
|||
|
Re: problem with the default code
You can switch the X-axis in the default code by subtracting p1_x value from 255.
Example: Code:
Limit_Mix(2000 + p1_y + (255 - p1_x) - 127); |
|
#8
|
|||
|
|||
|
Re: problem with the default code
Quote:
But I say leave the wires "backwards" and let the processor have a few extra cycles for other things. Heck, the victors aren't labeled this year, so just put your own lables on them, and have the N+ and M- switched on those to prevent confusion. |
![]() |
| Thread Tools | |
| Display Modes | Rate This Thread |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Problem running compiled code | jskene | Programming | 10 | 23-01-2005 21:13 |
| user code to default code | phoenixomega001 | Programming | 5 | 09-01-2005 00:09 |
| heres the code. y this not working | omega | Programming | 16 | 31-03-2004 15:18 |
| Strange IR sensor movement with default tracker code | wun | Programming | 5 | 19-03-2004 10:51 |
| default code and the actual robot | tml240 | Programming | 15 | 24-01-2004 11:31 |