Using two remotes
Page 1 of 1

Author:  nelsonabo [ Fri Jan 16, 2009 6:12 pm ]
Post subject:  Using two remotes

My name is Maria, captain of the Stissing Mountain FTC team. We are having a problem programming our robot using two remotes. We have three pairs of remotes, two pairs are 12V motors, one pair are nxt motors. When we program one remote using two pairs of motors, 12V or 12V and nxt our program works fine. When we try to program using all three pairs of motors using a second remote, so we can use all our motors, our program does not work, completely. It just sits, so it doesn't get through any part of our program. It downloads and has no error messages, and we've checked it many times, so we are quite baffled. We're not sure if it is the program or the wiring of our motors. Included is a copy of our program.

#pragma config(Hubs, S1, HTMotor, Htmotor, none, none)
#pragma config(Motor, motorA, , tmotorNormal, PIDControl)
#pragma config(Motor, motorC, , tmotorNormal, PIDControl)
#pragma config(Motor, mtr_S1_C1_1, motorD, tmotorNormal, openLoop)
#pragma config(Motor, mtr_S1_C1_2, motorE, tmotorNormal, openLoop)
#pragma config(Motor, mtr_S1_C2_1, motorF, tmotorNormal, openLoop)
#pragma config(Motor, mtr_S1_C2_2, motorG, tmotorNormal, openLoop)

#include “JoystickDriver.c”

task main ()

while (true)
motor[motorD] = joystick.joy1_y1*0.5;
motor[motorE] = -joystick.joy1_y1*0.5;

motor[motorF] = joystick.joy2_y1;
motor[motorG] = joystick.joy2_y2;

motor[motorA] = joystick.joy1_y2;
motor[motorC] = joystick.joy1_y2;


Author:  tfriez [ Fri Jan 16, 2009 6:23 pm ]
Post subject:  Re: Using two remotes

Well this code crashed my ROBOTC... so anyone else out there, don't copy and paste it into a new program!

I'll investigate the issue and post fixed code or an explanation ASAP.

Author:  tfriez [ Fri Jan 16, 2009 6:27 pm ]
Post subject:  Re: Using two remotes

I believe the issue is as follows:

That should be a semi-colon, not a colon.

I went ahead and moved your code into the new FTC templates for Teleop. See it attached to this post. It compiles and works for me.

Modified_TeleOp.c [3.69 KiB]
Downloaded 328 times

Author:  nelsonabo [ Sun Jan 18, 2009 1:15 am ]
Post subject:  Re: Using two remotes


First of all, thank you for replying.

Maria made a mistake when she typed up her post. Our program DID have a ; not a colon:

We have been trying out our programs directly without the tele-op set-up. In other words, we have been taking the sample programs, modifying them, and compiling them directly.

Is it possible that the sample programs do not allow us to run more than two 12V motors and that is why we can't get more than 2 motors to run (we did go to the motors and sensors set-up and we set up a motor E and F as 12V motors)?

I am afraid that the problemmay be a wiring problem. We tried to attach a diagram of our wiring, but we could not get the forum to accept our attachment. I understand this forum is only for programming issues. If no programming suggestions work, we will post to the FTC forum

Anyway, we will try your version on Tuesday.

Author:  hobbseltoff [ Sun Jan 18, 2009 3:25 am ]
Post subject:  Re: Using two remotes

When you say 3 pairs of motors, how are they wired?

Author:  nelsonabo [ Sun Jan 18, 2009 10:54 am ]
Post subject:  Re: Using two remotes

I have an NXT cable going from sensor port 1 to the motor controller box. Do I need another NXT cable going from that motor controller box to the second motor controller box? (We are not using any servos so opted to use 2 motor controller boxes.
One motor controller box has the red and black wires from the batteries (and on/off switch). Another set of black and red wires go to the 2nd motor controlller box.

The 1st motor controller box has red and black wires going to a pair of 12V motors (drives the robot)
The 2nd motor controller bax has red and black wires going to a second pair of 12V motors (lifts and lowers the arm)
The NXT motors are connected to the NXT outputs A and C (swivels a dump truck type bucket at the end of the arm)

We we have 3 pairs of motors, 2 pairs are 12V motors and one pair are NXT motors.

Page 1 of 1 All times are UTC - 5 hours [ DST ]
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group