Recently, my team has been having trouble with the integrated motor encoders. We have never had problems up until a few weeks ago, but now the IEM’s wont initialize. We have four encoders chained together, all of which are displaying a solid orange color. We have already tried re-wiring the chain to see if that was the problem, but nothing. We know the encoders work because they were working properly a few weeks ago. We are also running the latest version of RobotC.
Here’s the configuration of our encoders:
#pragma config(I2C_Usage, I2C1, i2cSensors)
#pragma config(Sensor, in1, PowerExpander, sensorAnalog)
#pragma config(Sensor, in2, RightLineFollower, sensorLineFollower)
#pragma config(Sensor, in3, MiddleLineFollower, sensorLineFollower)
#pragma config(Sensor, in4, LeftLineFollower, sensorLineFollower)
#pragma config(Sensor, in5, Gyroscope, sensorGyro)
#pragma config(Sensor, in6, XAccelerometer, sensorAccelerometer)
#pragma config(Sensor, in7, YAccelerometer, sensorAccelerometer)
#pragma config(Sensor, in8, ZAccelerometer, sensorAccelerometer)
#pragma config(Sensor, dgtl1, ArmRight, sensorQuadEncoder)
#pragma config(Sensor, dgtl3, ArmLeft, sensorQuadEncoder)
#pragma config(Sensor, dgtl5, SonarLeft, sensorSONAR_inch)
#pragma config(Sensor, dgtl7, SonarRight, sensorSONAR_inch)
#pragma config(Sensor, dgtl9, RightPushButton, sensorTouch)
#pragma config(Sensor, dgtl10, LeftPushButton, sensorTouch)
#pragma config(Sensor, I2C_1, DLBIEM, sensorQuadEncoderOnI2CPort, , AutoAssign)
#pragma config(Sensor, I2C_2, LLFIEM, sensorQuadEncoderOnI2CPort, , AutoAssign)
#pragma config(Sensor, I2C_3, LRFIEM, sensorQuadEncoderOnI2CPort, , AutoAssign)
#pragma config(Sensor, I2C_4, DRBIEM, sensorQuadEncoderOnI2CPort, , AutoAssign)
#pragma config(Motor, port1, IntakeLeft, tmotorVex393, openLoop)
#pragma config(Motor, port2, DriveRightBack, tmotorVex393, openLoop, encoder, encoderPort, I2C_4, 1000)
#pragma config(Motor, port3, DriveLeftBack, tmotorVex393, openLoop, reversed, encoder, encoderPort, I2C_1, 1000)
#pragma config(Motor, port4, DriveRightFront, tmotorVex393, openLoop)
#pragma config(Motor, port5, DriveLeftFront, tmotorVex393, openLoop, reversed)
#pragma config(Motor, port6, LiftRightFront, tmotorVex269, openLoop, encoder, encoderPort, I2C_3, 1000)
#pragma config(Motor, port7, LiftRightBack, tmotorVex269, openLoop)
#pragma config(Motor, port8, LiftLeftFront, tmotorVex269, openLoop, reversed, encoder, encoderPort, I2C_2, 1000)
#pragma config(Motor, port9, LiftLeftBack, tmotorVex269, openLoop, reversed)
#pragma config(Motor, port10, IntakeRight, tmotorVex393, openLoop, reversed)
//!!Code automatically generated by ‘ROBOTC’ configuration wizard !!//
Any suggestions on what we may be doing wrong or how to initialize the encoders?