Talon SR speed control recieving power, not outputting power

On one of our test bench robots for Java, we have a simple robot drive with 4 Talon SR speed controllers. This robot was functioning fine with Labview, but when we switched to Java, the speed controllers stopped functioning. We have tried many different programs, ranging from using the sliders on the Smart Dashboard to a full scale joystick hookup. However, no matter which program we use, we get the same problem. The program builds successfully, but no amount of movement of the sliders or joysticks will control the speed controllers, which sit there mocking us with a solid orange light. We have tried everything, from older versions of Eclipse to re-imaging the roboRio to update the roboRio hardware. Does anyone have any ideas on why this is happening?

Some more information might be helpful for solving this problem. Could you possibly upload some of the code you were trying to run?

If the Talon LED is solid orange, then the Talon is getting a healthy PWM signal from the RIO with a neutral value. That means you are likely creating the Talon object correctly, but not giving it a nonzero value in the set() routine.

You can try deploying a simple java app that just sets the value to a fixed constant, for example: myTalon.set(0.10) for 10% and see what happens.

You can post your code like Jalerre suggested.

Or trying using the debugger to peek at the value being passed to the Talon.

My mistake. They are flashing orange.
We are using robo builder, which generates a large folder that I send to the robot using WPILIB java deploy
Here is a google drive link to the folder: https://drive.google.com/drive/folders/0B8bmV5PetYxMTllkWktWTkJ2MEk

Okay. We are using robo builder, which creates a whole folder full of files that I send to the robot with WPILIB java deploy. Here is the link to the folder on google drive.

https://drive.google.com/drive/folders/0B8bmV5PetYxMTllkWktWTkJ2MEk

Your SR’s aren’t getting a signal from the RoboRIO’s PWM.

  1. Is your robot in disabled mode? If yes, connect with the DS and put it into Teleop, they should now be solid orange or green or red

  2. Is your robot program actually running? Check the DS that your code is actually running, it could just be crashing and you don’t know it.

  3. Is it on the right port? A bit of a silly question, but still worth checking.

  4. Is the PWM cable faulty? Unlikely, but your robot could have been physically damaged.

1.) We have run this multiple times, and we are sure it is enabled.
2.) The smart dashboard is showing us the sliders to control the speed controllers in test mode, so the code should be running
3 and 4.) We had this robot working fine in labview, and we made no physical changes at all. We are completely sure the wires are plugged into the right port and we used a multimeter to check the voltage, and electricity is making it to the speed controller.

We can’t access your Google Drive folder, perhaps change the permissions so we can take a look at whats going wrong

As for code, there is a link further up in the forum.

Jaci is correct, your link does not work…see attached.

ss.png


ss.png

If you have an oscilloscope handy, you can check the PWM cables to really be sure you’re sending values. If you get a good reading then it just might be the motor controller. However, if you get nothing, then it’s probably your code, your RoboRio, the PWM cable (make sure it’s seated properly in the RoboRio)

Ok. I had the sharing settings set up incorrectly. I am pretty sure the folder works now.

Here is the robot.java file of a test project that we downloaded from FIRST for testing the robot in java. Same story, flashing orange lights.

package org.usfirst.frc.team3812.robot;

import edu.wpi.first.wpilibj.IterativeRobot;
import edu.wpi.first.wpilibj.Joystick;
import edu.wpi.first.wpilibj.RobotDrive;
import edu.wpi.first.wpilibj.livewindow.LiveWindow;

/**
 * The VM is configured to automatically run this class, and to call the
 * functions corresponding to each mode, as described in the IterativeRobot
 * documentation. If you change the name of this class or the package after
 * creating this project, you must also update the manifest file in the resource
 * directory.
 */
public class Robot extends IterativeRobot {
	RobotDrive myRobot;
	Joystick stick;
	int autoLoopCounter;
	
    /**
     * This function is run when the robot is first started up and should be
     * used for any initialization code.
     */
    public void robotInit() {
    	myRobot = new RobotDrive(0,1);
    	stick = new Joystick(0);
    }
    
    /**
     * This function is run once each time the robot enters autonomous mode
     */
    public void autonomousInit() {
    	autoLoopCounter = 0;
    }

    /**
     * This function is called periodically during autonomous
     */
    public void autonomousPeriodic() {
    	if(autoLoopCounter < 100) //Check if we've completed 100 loops (approximately 2 seconds)
		{
			myRobot.drive(-0.5, 0.0); 	// drive forwards half speed
			autoLoopCounter++;
			} else {
			myRobot.drive(0.0, 0.0); 	// stop robot
		}
    }
    
    /**
     * This function is called once each time the robot enters tele-operated mode
     */
    public void teleopInit(){
    }

    /**
     * This function is called periodically during operator control
     */
    public void teleopPeriodic() {
        myRobot.arcadeDrive(stick);
    }
    
    /**
     * This function is called periodically during test mode
     */
    public void testPeriodic() {
    	LiveWindow.run();
    }
    
}

We have debugged this code, and all of the different robot modes are being called correctly. However, the arcadeDrive and drive functions, despite being called, are not being called correctly. PLEASE help. We have been working on this for weeks.

That simple example looks good to me. Can you try this procedure?

  1. Deploy that simple example with “run as java deploy”. Make sure it deploys correctly by watching the output window in eclipse. DS should go to “No Robot Code” for a moment and then back to “Disable”.
  2. Teleop-Enable the DS.
  3. Check for DS errors in the DS messages view, make sure it’s empty.
  4. Look at Talon SRs connected to PWM channel 0 and PWM channel 1 since that’s what the example uses. Are they both blinking orange? Or just one is blinking orange?
  5. Disable robot and replace PWM cable with a fresh one. Re-teleop-enable. Still blinking orange?
    Make sure the black wire on the PWM cable is on the correct side marked ‘B’ on the Talon housing.
    Also make sure the PWM connector is seated all the way down in the Talon side.
    Double check the PWM connector on the RIO side. Make sure the black wire is the outside of the RIO.
  6. Disable robot and replace Talon with another Talon. Or if you are only using one Talon, move it from PWM0 to PWM1. Re-teleop-enable. Still blinking orange?

This should rule out Talon, PWM cable, and bad contacts.

OK. We finally tracked down the problem. We had the positive and negative wires mixed up. This is the last time I listen to what other people say about the robot. Thanks for everyone who helped us try to find this basic issue.