Go to Post The great thing about liking someone in your robotics team is that they've already seen you at your worst, and you cant shock them with ANYTHING anymore :D - SCROSSLEY-GCEC [more]
Home
Go Back   Chief Delphi > Technical > Programming > C/C++
CD-Media   CD-Spy  
portal register members calendar search Today's Posts Mark Forums Read FAQ rules

 
Reply
 
Thread Tools Rate Thread Display Modes
  #1   Spotlight this post!  
Unread 27-10-2012, 13:40
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,089
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Robot "kicks out" when it goes right




From the video, this looks like a code issue.

Have you done anything at all to the code in the robot -- including re-loading it -- since the last time the robot worked properly?

Reply With Quote
  #2   Spotlight this post!  
Unread 27-10-2012, 13:51
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Robot "kicks out" when it goes right

While someone looks at the code for problems, have someone else double-check the wiring from your speed controllers to your motors. If something is cross-wired, you can get really weird results that only show up under specific conditions.
Reply With Quote
  #3   Spotlight this post!  
Unread 27-10-2012, 13:51
gyroscopeRaptor's Avatar
gyroscopeRaptor gyroscopeRaptor is offline
Registered ConfUser
AKA: Mark McGivern
FRC #3633 (Catalyst)
Team Role: College Student
 
Join Date: Dec 2010
Rookie Year: 2011
Location: Albert Lea, MN / Troy, NY
Posts: 360
gyroscopeRaptor has a spectacular aura aboutgyroscopeRaptor has a spectacular aura about
Re: Robot "kicks out" when it goes right

We lost our old code from last year and are trying to reprogram it for an unofficial competition coming up soon. We are using the new compact cRIO - last year we had used the cRIO I. The robot hasn't worked well since we changed cRIOs and lost the code.

Our programmer was thinking that it had to do with pointers in C++; he had been getting the "MotorSafetyController.cpp at line 123" error, but he fixed that and the problem is still present.

Quote:
While someone looks at the code for problems, have someone else double-check the wiring from your speed controllers to your motors. If something is cross-wired, you can get really weird results that only show up under specific conditions.
We'll check on that too, thanks. We are pretty certain nothing has changed since last seasons competition - where the bot worked fine - but there have been a lot of people around the robot so anything is possible.
Reply With Quote
  #4   Spotlight this post!  
Unread 27-10-2012, 13:59
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,089
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Robot "kicks out" when it goes right


Are you using one or two Joysticks? Arcade or tank style?

Are you using the WPI library functions for this, or home brew?


Reply With Quote
  #5   Spotlight this post!  
Unread 27-10-2012, 14:09
gyroscopeRaptor's Avatar
gyroscopeRaptor gyroscopeRaptor is offline
Registered ConfUser
AKA: Mark McGivern
FRC #3633 (Catalyst)
Team Role: College Student
 
Join Date: Dec 2010
Rookie Year: 2011
Location: Albert Lea, MN / Troy, NY
Posts: 360
gyroscopeRaptor has a spectacular aura aboutgyroscopeRaptor has a spectacular aura about
Re: Robot "kicks out" when it goes right

Quote:
Originally Posted by Ether View Post

Are you using one or two Joysticks? Arcade or tank style?

Are you using the WPI library functions for this, or home brew?


We attached our code in our OP and we are using WPILib. Two joysticks, one is arcade style.

@Alan: The wiring is solid.

@akoscielski: We reset the jaguars but it is still having the problems. Whenever we move the drive joystick the SLIGHTEST bit towards the right, even a tiny, indistinguishable bit, the robot kicks out.
Reply With Quote
  #6   Spotlight this post!  
Unread 27-10-2012, 14:28
gyroscopeRaptor's Avatar
gyroscopeRaptor gyroscopeRaptor is offline
Registered ConfUser
AKA: Mark McGivern
FRC #3633 (Catalyst)
Team Role: College Student
 
Join Date: Dec 2010
Rookie Year: 2011
Location: Albert Lea, MN / Troy, NY
Posts: 360
gyroscopeRaptor has a spectacular aura aboutgyroscopeRaptor has a spectacular aura about
Re: Robot "kicks out" when it goes right

Quote:
Originally Posted by gyroscopeRaptor View Post
We attached our code in our OP and we are using WPILib. Two joysticks, one is arcade style.

@Alan: The wiring is solid.

@akoscielski: We reset the jaguars but it is still having the problems. Whenever we move the drive joystick the SLIGHTEST bit towards the right, even a tiny, indistinguishable bit, the robot kicks out.
Oh.
My.
GOD.

The problem was that I forgot to put the sidecar power cable in.

[sarcasm]I want to slit my wrists now.[/sarcasm]

Sorry for wasting your guys' time.
Reply With Quote
  #7   Spotlight this post!  
Unread 27-10-2012, 14:36
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,089
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Robot "kicks out" when it goes right

Quote:
Originally Posted by gyroscopeRaptor View Post
The problem was that I forgot to put the sidecar power cable in.
I'd like to learn something here.

Could someone explain why this would cause the drivetrain would work fine in the forward, and reverse, and rotate left directions, but not in the rotate right direction?


Reply With Quote
  #8   Spotlight this post!  
Unread 28-10-2012, 01:56
Alan Anderson's Avatar
Alan Anderson Alan Anderson is offline
Software Architect
FRC #0045 (TechnoKats)
Team Role: Mentor
 
Join Date: Feb 2004
Rookie Year: 2004
Location: Kokomo, Indiana
Posts: 9,113
Alan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond reputeAlan Anderson has a reputation beyond repute
Re: Robot "kicks out" when it goes right

Quote:
Originally Posted by Ether View Post
Could someone explain why this would cause the drivetrain would work fine in the forward, and reverse, and rotate left directions, but not in the rotate right direction?
Assume four motors, two on each side. Further assume that the wiring is such that one side's motors run "forward" and the other side's motors run "reverse" for forward travel of the robot.

The DS can "sneak" some power from the PWM signals coming from the cRIO. When the robot is being commanded neutral, it's getting four 1.5ms pulses every so often, and that's enough to make it work. When it's being commanded either forward or reverse, two of the signals get shorter, but two get longer, and it balances out. When it's being commanded to turn left, all four signals get longer. But when it's being commanded to turn right, all four signals get shorter, the DS gets starved for power, and things stop working.
Reply With Quote
  #9   Spotlight this post!  
Unread 28-10-2012, 15:57
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,089
Ether has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond reputeEther has a reputation beyond repute
Re: Robot "kicks out" when it goes right


Thank you. The DS "sneaking power" from the cRIO's PWM signals was the puzzle piece I was missing.


Reply With Quote
Reply


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 14:15.

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