IMEs Not Functioning (RobotC)

Cutting to the chase, we have four motors on our robot with IMEs attached. The IMEs are brand new out of the box and as far as I know are wired correctly, with only the first in the chain working. A few weeks ago we had two out of the four working but they soon reverted back to their solid yellow LED state. We need to figure this out ASAP becuase we will be competing at the State level this weekend. Thank you for considering my problem.

  • 1489E Head Programmer

Here are pictures of the Encoders in the order that they are daisey chained… - Into Cortex
- I2C_1
- I2C_2
- I2C_3
]( - I2C_4)

How are the IME’s being attached between one another (meaning, are you chaining multiple cables together to reach the motors that are further away from the base of the robot/Cortex)? If so, there is a possibility that there is signal loss occurring due to the length of the cables.

Before we test that, though, please run the code below on the robot and turn the motors slightly by hand. You should see the values increase/decrease accordingly on the Debug Stream debugger window and in the Motors debugger window.

#pragma config(I2C_Usage, I2C1, i2cSensors)
#pragma config(Sensor, dgtl11, ClawSensor,     sensorTouch)
#pragma config(Sensor, I2C_1,  LeftTowerEncoder, sensorQuadEncoderOnI2CPort,    , AutoAssign)
#pragma config(Sensor, I2C_2,  RightTowerEncoder, sensorQuadEncoderOnI2CPort,    , AutoAssign)
#pragma config(Sensor, I2C_3,  LeftDriveEncoder, sensorQuadEncoderOnI2CPort,    , AutoAssign)
#pragma config(Sensor, I2C_4,  RightDriveEncoder, sensorQuadEncoderOnI2CPort,    , AutoAssign)
#pragma config(Motor,  port1,           ClawMotor,     tmotorVex393_HBridge, openLoop, encoderPort, I2C_1)
#pragma config(Motor,  port2,           FrontRightDrive, tmotorVex393_MC29, openLoop, reversed, driveRight, encoderPort, I2C_2)
#pragma config(Motor,  port3,           BackLeftDrive, tmotorVex393_MC29, openLoop, driveRight, encoderPort, I2C_3)
#pragma config(Motor,  port4,           FrontLeftDrive, tmotorVex393_MC29, openLoop, driveLeft, encoderPort, I2C_4)
#pragma config(Motor,  port5,           BackRightDrive, tmotorVex393_MC29, openLoop, reversed, driveLeft)
#pragma config(Motor,  port6,           LeftArmTowerTop, tmotorVex393_MC29, openLoop, driveLeft)
#pragma config(Motor,  port7,           RightArmTowerTop, tmotorVex393_MC29, openLoop, driveLeft)
#pragma config(Motor,  port8,           LeftArmTowerBottom, tmotorVex393_MC29, openLoop, driveRight)
#pragma config(Motor,  port9,           RightArmTowerBottom, tmotorVex393_MC29, openLoop)
#pragma config(Motor,  port10,          Gimbol,        tmotorVex393_HBridge, openLoop, reversed, driveRight)

//*!!Code automatically generated by 'ROBOTC' configuration wizard               !!*//

#pragma DebuggerWindows("debugStream")

task main()
	nMotorEncoder[ClawMotor] = 0;
	nMotorEncoder[FrontLeftDrive] = 0;
	nMotorEncoder[FrontRightDrive] = 0;
	nMotorEncoder[BackLeftDrive] = 0;
	nMotorEncoder[BackRightDrive] = 0;

		writeDebugStreamLine("Encoder1: %d", nMotorEncoder[ClawMotor]);

		writeDebugStreamLine("Encoder2: %d", nMotorEncoder[FrontRightDrive]);

		writeDebugStreamLine("Encoder3: %d", nMotorEncoder[BackLeftDrive]);

		writeDebugStreamLine("Encoder4: %d", nMotorEncoder[FrontLeftDrive]);

		writeDebugStreamLine("Encoder5: %d", nMotorEncoder[BackRightDrive]);

Please let us know if this code works correctly with your current setup and we will be more than happy to assist you further.