|
Re: Code error?
Sorry to ask the obvious question but,
pwm10? Are you sure you did not mean pwm01?
Try putting in a printf and then let the loader open the terminal window after programming. Leave the programming cable on. (Its a good idea to put blocks under any drive wheels while running with a computer connected to the robot)
Add this line
printf("p1_sw_aux1 = %d, p1_sw_aux2 =%d\r", p1_sw_aux1, p1_sw_aux2);
What buttons are you pressing? The trigger is p1_sw_trig, and the thumb switch is p1_sw_top, I don't think the aux inputs are connected to anything on the joystick.
As for setting the motor to 255, every time in the loop it should always go.
Brian
__________________
Brian K
Team 1225 Robotics Mentor
|