Go to Post The students that I have known in FIRST over my 8 years of involvement have been far more inspired by the competition and some of the jaw dropping creations of "elite" teams than by anything that we made ourselves. - MattB703 [more]
Home
Go Back   Chief Delphi > FIRST > General Forum
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 21-01-2017, 18:48
Tom Line's Avatar
Tom Line Tom Line is offline
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,554
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Velocity Control - Battery Compensation Term

When doing velocity control with the talon srx's, the velocity you get from your feed-forward term is going to be affected by battery voltage. Has anyone experimented or used a battery offset term to correct for this? Is it worth it?
Reply With Quote
  #2   Spotlight this post!  
Unread 21-01-2017, 21:20
Paul Copioli's Avatar Unsung FIRST Hero Woodie Flowers Award
Paul Copioli Paul Copioli is offline
President, VEX Robotics, Inc.
FRC #3310 (Black Hawk Robotics)
Team Role: Engineer
 
Join Date: Jun 2001
Rookie Year: 2000
Location: Rockwall, TX
Posts: 1,392
Paul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond reputePaul Copioli has a reputation beyond repute
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Tom Line View Post
When doing velocity control with the talon srx's, the velocity you get from your feed-forward term is going to be affected by battery voltage. Has anyone experimented or used a battery offset term to correct for this? Is it worth it?
Tom,

The I gain is for things like that. We use I and P for velocity control and as long as you design your gearbox / motor combo with enough headroom then the I and P can compensate. We design our speed controlled devices to operate at 60% duty for the ideal situation. For example, if you want your shooter to go 2500 RPM, it better hit that speed at 60% - 70% duty. This way, the I and P gain can do their job. When testing without speed control, if you set your motor command at .6 or .7, then you should be able to score your game object from the desired shooting spot with a full battery and one ball at a time. At least, this is what we do.

Paul
__________________
In full disclosure I am the President of VEX Robotics, a division of Innovation First International.
Reply With Quote
  #3   Spotlight this post!  
Unread 21-01-2017, 21:32
Joey1939's Avatar
Joey1939 Joey1939 is offline
Registered User
AKA: Joey Holliday
FRC #1939 (Kuhnigits)
Team Role: Programmer
 
Join Date: Jan 2014
Rookie Year: 2014
Location: Kansas City, Missouri
Posts: 144
Joey1939 has a spectacular aura aboutJoey1939 has a spectacular aura aboutJoey1939 has a spectacular aura about
Re: Velocity Control - Battery Compensation Term

I'm currently working on something similar. It seems like when the Talon is in Velocity Control Mode the feed forward term is used to calculate an output voltage. This would make think that it wouldn't be affected by battery voltage unless it dropped bellow the requested output.
I'm not certain, but I'm sure CTRE will give an answer soon.
__________________



Last edited by Joey1939 : 21-01-2017 at 22:02.
Reply With Quote
  #4   Spotlight this post!  
Unread 21-01-2017, 22:09
Brandon_L Brandon_L is offline
Back @ it again with the white vans
AKA: Brandon Liatys
FRC #2180 (Zero Gravity)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2007
Location: Newark, NJ
Posts: 1,207
Brandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond repute
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Paul Copioli View Post
Tom,

For example, if you want your shooter to go 2500 RPM, it better hit that speed at 60% - 70% duty. This way, the I and P gain can do their job. When testing without speed control, if you set your motor command at .6 or .7, then you should be able to score your game object from the desired shooting spot with a full battery and one ball at a time. At least, this is what we do.

Paul
Is there a way to calculate this? Such as if I'm using a motor say with a 10kRPM free speed but I want my shooter to go 2.5kRPM, what method or charts would I need to calculate the ratio that will get me to 2.5kRPM at 60-70% duty cycle? I assume it would be less aggressive gearing than if I did the usual calculation, which in this case would be 4:1
__________________
FRC 2495 - Hamilton West Robotics [2007-2014] - whats a..."hive mind"?
FRC 3929 - Atomic Dragons [2012-2013]
FRC 2180 - Zero Gravity [2017-]

Just trying to collect all the possible team colors

Last edited by Brandon_L : 21-01-2017 at 22:12.
Reply With Quote
  #5   Spotlight this post!  
Unread 22-01-2017, 00:00
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
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: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Brandon_L View Post
Is there a way to calculate this? Such as if I'm using a motor say with a 10kRPM free speed but I want my shooter to go 2.5kRPM, what method or charts would I need to calculate the ratio that will get me to 2.5kRPM at 60-70% duty cycle? I assume it would be less aggressive gearing than if I did the usual calculation, which in this case would be 4:1
Here's a rough calculation:

10000 rpm motor free speed at 100% command
6500 rpm motor free speed at 65% command
2500 desired operating rpm of flywheel
2.6:1 speed reduction gear ratio = 6500/2500

YMMV depending on how much friction and windage you have in your gearing and flywheel



Last edited by Ether : 22-01-2017 at 00:02.
Reply With Quote
  #6   Spotlight this post!  
Unread 22-01-2017, 21:29
Brandon_L Brandon_L is offline
Back @ it again with the white vans
AKA: Brandon Liatys
FRC #2180 (Zero Gravity)
Team Role: Mentor
 
Join Date: Jan 2008
Rookie Year: 2007
Location: Newark, NJ
Posts: 1,207
Brandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond reputeBrandon_L has a reputation beyond repute
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Ether View Post
Here's a rough calculation:

10000 rpm motor free speed at 100% command
6500 rpm motor free speed at 65% command
2500 desired operating rpm of flywheel
2.6:1 speed reduction gear ratio = 6500/2500

YMMV depending on how much friction and windage you have in your gearing and flywheel


Didn't think it would be just that simple, thanks
__________________
FRC 2495 - Hamilton West Robotics [2007-2014] - whats a..."hive mind"?
FRC 3929 - Atomic Dragons [2012-2013]
FRC 2180 - Zero Gravity [2017-]

Just trying to collect all the possible team colors
Reply With Quote
  #7   Spotlight this post!  
Unread 23-01-2017, 11:28
Brian Selle's Avatar
Brian Selle Brian Selle is offline
Mentor
FRC #3310 (Black Hawk Robotics)
Team Role: Engineer
 
Join Date: Jan 2012
Rookie Year: 2012
Location: Texas
Posts: 170
Brian Selle has a spectacular aura aboutBrian Selle has a spectacular aura aboutBrian Selle has a spectacular aura about
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Ether View Post
Here's a rough calculation:

10000 rpm motor free speed at 100% command
6500 rpm motor free speed at 65% command
2500 desired operating rpm of flywheel
2.6:1 speed reduction gear ratio = 6500/2500

YMMV depending on how much friction and windage you have in your gearing and flywheel


This ^ with a 0.8-0.9 for gearbox efficiency will get you close. For this example, 65% command: 10,000 rpm * 0.65 * 0.8 = 5200 rpm free speed. 5200/2500 yields approx 2:1 gear ratio.
__________________
2016 Curie Quarter-Finalist (5803, 3310, 2168, 5940), Lubbock Regional Winner (3310, 4063, 4301), Arkansas Regional Winner (16, 3310, 6055)
2015 Newton Quarter-Finalist (3130, 2468, 3310, 537), Lubbock Regional Winner (2468, 3310, 4799)
2014 Galileo Quarter-Finalist (2052, 70, 3310, 3360), Colorado Regional Winner (1138, 3310, 2543)
2013 Archimedes Semi-Finalist (126, 3310, 1756), Texas Robot Roundup Winner (3310, 624, 2848), Dallas Regional Winner (148, 3310, 4610)
2012 Dallas West Regional Winner (935, 3310, 4206)
Reply With Quote
  #8   Spotlight this post!  
Unread 23-01-2017, 19:15
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
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: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Brian Selle View Post
This ^ with a 0.8-0.9 for gearbox efficiency will get you close. For this example, 65% command: 10,000 rpm * 0.65 * 0.8 = 5200 rpm free speed. 5200/2500 yields approx 2:1 gear ratio.
Consider the following thought experiment:

Take a CIM whose free speed is 5310 rpm at 12 volts and connect it to a good quality properly assembled and lubed 2:1 gearbox whose output shaft is connected to nothing (no load).

Using the same computation you did above, the CIM's speed would now be 5310*0.8 = 4248 rpm.

Now go to the motor curves for CIM and you'll see that CIM is drawing 29 amps.

Do you believe that? If not, where is the error?


Reply With Quote
  #9   Spotlight this post!  
Unread 24-01-2017, 12:53
Brian Selle's Avatar
Brian Selle Brian Selle is offline
Mentor
FRC #3310 (Black Hawk Robotics)
Team Role: Engineer
 
Join Date: Jan 2012
Rookie Year: 2012
Location: Texas
Posts: 170
Brian Selle has a spectacular aura aboutBrian Selle has a spectacular aura aboutBrian Selle has a spectacular aura about
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Ether View Post
Consider the following thought experiment:

Take a CIM whose free speed is 5310 rpm at 12 volts and connect it to a good quality properly assembled and lubed 2:1 gearbox whose output shaft is connected to nothing (no load).

Using the same computation you did above, the CIM's speed would now be 5310*0.8 = 4248 rpm.

Now go to the motor curves for CIM and you'll see that CIM is drawing 29 amps.

Do you believe that? If not, where is the error?


An unloaded, well lubed, 2:1 gearbox has a much higher efficiency factor and thus I would expect a higher CIM speed and lower current. If you lube the gearbox with toothpaste you might create enough friction to draw 29 amps at 4248 RPM.

The 0.8-0.9 factor approximates typical losses seen in FRC for gearboxes + belt/chain + bearing friction + wheel/roller windage.
__________________
2016 Curie Quarter-Finalist (5803, 3310, 2168, 5940), Lubbock Regional Winner (3310, 4063, 4301), Arkansas Regional Winner (16, 3310, 6055)
2015 Newton Quarter-Finalist (3130, 2468, 3310, 537), Lubbock Regional Winner (2468, 3310, 4799)
2014 Galileo Quarter-Finalist (2052, 70, 3310, 3360), Colorado Regional Winner (1138, 3310, 2543)
2013 Archimedes Semi-Finalist (126, 3310, 1756), Texas Robot Roundup Winner (3310, 624, 2848), Dallas Regional Winner (148, 3310, 4610)
2012 Dallas West Regional Winner (935, 3310, 4206)
Reply With Quote
  #10   Spotlight this post!  
Unread 24-01-2017, 13:42
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
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: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Brian Selle View Post
The 0.8-0.9 factor approximates typical losses seen in FRC for gearboxes + belt/chain + bearing friction + wheel/roller windage.
I've seen the .8 number in various places for drivetrains, which include rolling friction, carpet deformation, multi-stage gearboxes, and gears/chains or belts/pulleys.

It would be very interesting to see test data for a quality 2:1 single-stage gearbox (properly assembled and lubed) connected directly to a properly balanced spokeless shooter flywheel, when the flywheel is spinning unloaded (i.e. not firing balls) at its operating speed. Volunteers?


Reply With Quote
  #11   Spotlight this post!  
Unread 24-01-2017, 17:04
amesmich's Avatar
amesmich amesmich is offline
Registered User
FRC #4638 (Jagbots)
Team Role: Teacher
 
Join Date: Nov 2012
Rookie Year: 2012
Location: Maryland
Posts: 110
amesmich is an unknown quantity at this point
Re: Velocity Control - Battery Compensation Term

I would guesstimate the torque speed relationship is not linear from free speed. So the small amount of load the gearbox presents reduces the speed more initially without necessarily loading the motor to the point of 29A. I would then expect additional load to be more linear in current and speed.
Reply With Quote
  #12   Spotlight this post!  
Unread 24-01-2017, 17:36
tr6scott's Avatar
tr6scott tr6scott is offline
Um, I smell Motor!
AKA: Scott McBride
FRC #2137 (TORC)
Team Role: Mentor
 
Join Date: Dec 2007
Rookie Year: 2005
Location: Oxford, MI
Posts: 535
tr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond reputetr6scott has a reputation beyond repute
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Tom Line View Post
When doing velocity control with the talon srx's, the velocity you get from your feed-forward term is going to be affected by battery voltage. Has anyone experimented or used a battery offset term to correct for this? Is it worth it?
Our experience from last year, make sure you F term undershoots the desired speed, as opposed to overshoots the desired speed. When this is true, the srx is rock solid and smooth. I would not try to compensate the F term higher after the tune. I would tune with a full battery, make the F slightly under the target, and let the PID do the work. It was a beautiful thing last year on our shooters.

The other thing to watch for, is if you are going to let the shooter wheels run down, put them in %vbuss mode, or you will pid them to 0, which will make them stop fast and with a lot of heat for no good reason.
__________________
The sooner we get behind schedule, the more time we have to catch up.

Reply With Quote
  #13   Spotlight this post!  
Unread 24-01-2017, 18:00
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
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: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by tr6scott View Post
if you are going to let the shooter wheels run down, put them in %vbuss mode, or you will pid them to 0, which will make them stop fast and with a lot of heat for no good reason.
SRX lets you clamp the PIDF output, no? Don't allow negative voltage. And make sure it's in coast mode.


Reply With Quote
  #14   Spotlight this post!  
Unread 24-01-2017, 18:05
Ether's Avatar
Ether Ether is offline
systems engineer (retired)
no team
 
Join Date: Nov 2009
Rookie Year: 1969
Location: US
Posts: 8,125
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: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by amesmich View Post
I would guesstimate the torque speed relationship is not linear from free speed
Looks pretty linear down to about 0.03 Nm.




Last edited by Ether : 24-01-2017 at 18:15.
Reply With Quote
  #15   Spotlight this post!  
Unread 25-01-2017, 19:17
Tom Line's Avatar
Tom Line Tom Line is offline
Raptors can't turn doorknobs.
FRC #1718 (The Fighting Pi)
Team Role: Mentor
 
Join Date: Jan 2007
Rookie Year: 1999
Location: Armada, Michigan
Posts: 2,554
Tom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond reputeTom Line has a reputation beyond repute
Re: Velocity Control - Battery Compensation Term

Quote:
Originally Posted by Paul Copioli View Post
Tom,

The I gain is for things like that. We use I and P for velocity control and as long as you design your gearbox / motor combo with enough headroom then the I and P can compensate. We design our speed controlled devices to operate at 60% duty for the ideal situation. For example, if you want your shooter to go 2500 RPM, it better hit that speed at 60% - 70% duty. This way, the I and P gain can do their job. When testing without speed control, if you set your motor command at .6 or .7, then you should be able to score your game object from the desired shooting spot with a full battery and one ball at a time. At least, this is what we do.

Paul
Thanks Paul. I usually design for my shooting speed to be at about 50% max velocity, because that's usually right around the peak power for the motor and I want to optimize spin-up time after a shot.

Good to know I don't have to mess around with battery compensation.
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 06:49.

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