Go to Post If the teams that are building exact replicas are inspired, who are we to say "You're being inspired all wrong?!" - Ian Curtis [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Closed Thread
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 04-11-2015, 16:07
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
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?
  #2   Spotlight this post!  
Unread 04-11-2015, 16:32
Jalerre's Avatar
Jalerre Jalerre is offline
Registered User
FRC #4965 (FIRE)
Team Role: Alumni
 
Join Date: Apr 2014
Rookie Year: 2013
Location: Anderson, SC
Posts: 147
Jalerre is on a distinguished road
Re: Talon SR speed control recieving power, not outputting power

Quote:
Originally Posted by Mikey Richards View Post
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?
__________________
Vex
2013: 415 - Fabrication, Programming, Electrical
2014: 415D - Captain, Programming Lead
FTC
2014: 7354 - Programming Lead
FRC
2013: 415 - Safety Animation, Fabrication
2014-2015: 4965 - Programming & Electrical
2016: 4965 - Captain, Programming Lead, Electrical
  #3   Spotlight this post!  
Unread 05-11-2015, 10:54
ozrien's Avatar
ozrien ozrien is offline
Omar Zrien
AKA: Omar
no team
Team Role: Mentor
 
Join Date: Sep 2006
Rookie Year: 2003
Location: Sterling Heights, MI
Posts: 549
ozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

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.
  #4   Spotlight this post!  
Unread 05-11-2015, 21:10
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

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/folde...llkWktWTkJ2MEk

Last edited by Mikey Richards : 05-11-2015 at 21:37.
  #5   Spotlight this post!  
Unread 05-11-2015, 21:21
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

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/folde...llkWktWTkJ2MEk
  #6   Spotlight this post!  
Unread 05-11-2015, 21:36
Jaci's Avatar
Jaci Jaci is offline
Registered User
AKA: Jaci R Brunning
FRC #5333 (Can't C# | OpenRIO)
Team Role: Mentor
 
Join Date: Jan 2015
Rookie Year: 2015
Location: Perth, Western Australia
Posts: 266
Jaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

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.
__________________
Jacinta R

Curtin FRC (5333+5663) : Mentor
5333 : Former [Captain | Programmer | Driver], Now Mentor
OpenRIO : Owner

Website | Twitter | Github
jaci.brunning@gmail.com
  #7   Spotlight this post!  
Unread 05-11-2015, 21:41
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

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.
  #8   Spotlight this post!  
Unread 05-11-2015, 21:45
Jaci's Avatar
Jaci Jaci is offline
Registered User
AKA: Jaci R Brunning
FRC #5333 (Can't C# | OpenRIO)
Team Role: Mentor
 
Join Date: Jan 2015
Rookie Year: 2015
Location: Perth, Western Australia
Posts: 266
Jaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond reputeJaci has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

Quote:
Originally Posted by Mikey Richards View Post
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
__________________
Jacinta R

Curtin FRC (5333+5663) : Mentor
5333 : Former [Captain | Programmer | Driver], Now Mentor
OpenRIO : Owner

Website | Twitter | Github
jaci.brunning@gmail.com
  #9   Spotlight this post!  
Unread 05-11-2015, 21:46
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

As for code, there is a link further up in the forum.
  #10   Spotlight this post!  
Unread 07-11-2015, 00:42
ozrien's Avatar
ozrien ozrien is offline
Omar Zrien
AKA: Omar
no team
Team Role: Mentor
 
Join Date: Sep 2006
Rookie Year: 2003
Location: Sterling Heights, MI
Posts: 549
ozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

Jaci is correct, your link does not work...see attached.
Attached Thumbnails
Click image for larger version

Name:	ss.png
Views:	28
Size:	7.9 KB
ID:	19409  
  #11   Spotlight this post!  
Unread 07-11-2015, 07:29
Michael Hill's Avatar
Michael Hill Michael Hill is offline
Registered User
FRC #3138 (Innovators Robotics)
Team Role: Mentor
 
Join Date: Jul 2004
Rookie Year: 2003
Location: Dayton, OH
Posts: 1,580
Michael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond reputeMichael Hill has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

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)
  #12   Spotlight this post!  
Unread 07-11-2015, 12:30
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

Ok. I had the sharing settings set up incorrectly. I am pretty sure the folder works now.
  #13   Spotlight this post!  
Unread 07-11-2015, 13:02
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

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.


Code:
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.

Last edited by Mikey Richards : 07-11-2015 at 13:46.
  #14   Spotlight this post!  
Unread 07-11-2015, 15:19
ozrien's Avatar
ozrien ozrien is offline
Omar Zrien
AKA: Omar
no team
Team Role: Mentor
 
Join Date: Sep 2006
Rookie Year: 2003
Location: Sterling Heights, MI
Posts: 549
ozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond reputeozrien has a reputation beyond repute
Re: Talon SR speed control recieving power, not outputting power

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.
  #15   Spotlight this post!  
Unread 14-11-2015, 12:17
Mikey Richards's Avatar
Mikey Richards Mikey Richards is offline
Registered User
FRC #3812 (Bits and Bots)
Team Role: Programmer
 
Join Date: Oct 2015
Rookie Year: 2015
Location: Kelso, WA
Posts: 16
Mikey Richards is an unknown quantity at this point
Re: Talon SR speed control recieving power, not outputting power

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.
Closed Thread


Thread Tools
Display Modes Rate This Thread
Rate This Thread:

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 03:14.

The Chief Delphi Forums are sponsored by Innovation First International, Inc.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2017, Jelsoft Enterprises Ltd.
Copyright © Chief Delphi