Go to Post Our team calls me "John Regular Neun," because John V-Neun is so spectacular! - John Neun [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 25-01-2006, 20:15
schenkin schenkin is offline
Registered User
#0486
 
Join Date: Jan 2005
Location: Strath Haven High School
Posts: 17
schenkin is on a distinguished road
RPM Sensing Options

Hello all. I am trying to figure out a way to measure rpms, eventually this will lead to an approximate muzzle velocity of our ball shooter.

So far, I've come up with a couple of possible sollutions:

1. Use a seperate controller (probably our edubot), to count up encoder interupts, poll this data at a set interval from the main controller (probably over a few digital in/outs), and from this get rotations/time. The main problem with this is that I haven't gotten the encoder code to run properly on the edubot. If someone could help with this, i'll post the problems i'm having.

2. Use an analog device which outputs speed as variable voltage. So far i've been playing with just using a standard DC motor to generate a current, and feeding that back into the controller, but I have no idea what the sensed voltage range is in the A/D controllers, and I very much doubt that the output is going to be even close to linear. Is there an actuall sensor that will do this for me?

Any help would be appreciated! So far this forum has served me well!
  #2   Spotlight this post!  
Unread 25-01-2006, 20:29
Unsung FIRST Hero
Greg Marra Greg Marra is offline
[automate(a) for a in tasks_to_do]
FRC #5507 (Robotic Eagles)
Team Role: Mentor
 
Join Date: Oct 2004
Rookie Year: 2005
Location: San Francisco, CA
Posts: 2,030
Greg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond reputeGreg Marra has a reputation beyond repute
Re: RMP Sensing Options

That's a really interesting idea. I had never thought of using the EDUbot controller as an auxillery processor on the main RC. Innovative thinking!

Good luck!
  #3   Spotlight this post!  
Unread 25-01-2006, 20:36
Manoel's Avatar
Manoel Manoel is offline
Registered User
FRC #0383 (Brazilian Machine)
Team Role: Mentor
 
Join Date: Jun 2001
Rookie Year: 2000
Location: Porto Alegre, RS, Brazil
Posts: 608
Manoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond reputeManoel has a reputation beyond repute
Send a message via ICQ to Manoel Send a message via MSN to Manoel
Re: RMP Sensing Options

Quote:
Originally Posted by Greg Marra
That's a really interesting idea. I had never thought of using the EDUbot controller as an auxillery processor on the main RC. Innovative thinking!

Good luck!
It's a pretty good idea, indeed, but rule R49 states that electronic components must cost under 200 bucks, and the EDU has a retail price of $ 249. Coincidental, isn't it?

Quote:
Originally Posted by FIRST, <R49>
<R49> The total cost of all non-Kit items may not exceed $3,500.00 USD. No individual COTS electronic
component shall have a value of over $200.00 USD. No individual non-electronic item shall have a value of
over $400.00. The total cost of components purchased in bulk may exceed $400.00 USD as long as the cost of
an individual component does not exceed $400.00. The following items are EXCLUDED from the total cost...
calculation:
__________________
Manoel Flores da Cunha
Mentor
Brazilian Machine
Team # 383
  #4   Spotlight this post!  
Unread 25-01-2006, 21:04
BorisTheBlade's Avatar
BorisTheBlade BorisTheBlade is offline
lead programmer 2004
AKA: Dane
FRC #1351 (TKO)
Team Role: Mentor
 
Join Date: Oct 2005
Rookie Year: 2004
Location: San Jose, Ca
Posts: 23
BorisTheBlade has a spectacular aura aboutBorisTheBlade has a spectacular aura aboutBorisTheBlade has a spectacular aura about
Send a message via AIM to BorisTheBlade
Re: RMP Sensing Options

that and you have to keep in mind that it would have to be powered off the main battery not the normal battery that the edu bot controller uses.
__________________
Team 1351 TKO Robotics (click for our website)
2007 sacramento regional Johnson & Johnson Sportsmanship Award winners
2007 CAL Games Finalists
  #5   Spotlight this post!  
Unread 25-01-2006, 21:37
Jared Russell's Avatar
Jared Russell Jared Russell is offline
Taking a year (mostly) off
FRC #0254 (The Cheesy Poofs), FRC #0341 (Miss Daisy)
Team Role: Engineer
 
Join Date: Nov 2002
Rookie Year: 2001
Location: San Francisco, CA
Posts: 3,078
Jared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond reputeJared Russell has a reputation beyond repute
Re: RMP Sensing Options

Why not use an encoder/gear-tooth sensor/banner sensor feeding into the main RC?

Using interrupts is easy as long as your counts don't get too rapid. We're using just one piece of reflective tape and a banner sensor for our flywheel.
  #6   Spotlight this post!  
Unread 25-01-2006, 22:04
BrianBSL BrianBSL is offline
Registered User
FRC #0190
 
Join Date: Sep 2004
Rookie Year: 2000
Location: Worcester, MA
Posts: 251
BrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud of
Re: RMP Sensing Options

Not cheap, but within the "controls" budget limit. Does all the encoder work for you (just set the scaler up right, the right voltage range, and read the analog value) http://www.usdigital.com/products/etach2/

But unless you have some major reason for not dealing with the encoders on the RC, thats the most reasonable way.
__________________
My posts represent my personal views only, and do not represent the views of either my team, Team 190, nor its primary sponsor, Worcester Polytechnic Institute.

Last edited by BrianBSL : 25-01-2006 at 22:06.
  #7   Spotlight this post!  
Unread 26-01-2006, 00:17
b_mallerd b_mallerd is offline
Programmer
FRC #1346 (Trobotics)
Team Role: Programmer
 
Join Date: Dec 2005
Rookie Year: 2005
Location: Vancouver
Posts: 35
b_mallerd is on a distinguished road
Send a message via MSN to b_mallerd
Re: RPM Sensing Options

Wouldn't it be possible to just use the gear tooth counter along with the timer? So you know how many gear teeth pass for however many seconds...and then you have the speed that the wheel is turning in gears/min...all you have to do is count how many gears there are and use that as a reference to figure out RPM.
__________________
  #8   Spotlight this post!  
Unread 26-01-2006, 00:48
Matt Krass's Avatar
Matt Krass Matt Krass is offline
"Old" and Cranky. Get off my lawn!
AKA: Dark Ages
FRC #0263 (Sachem Aftershock)
Team Role: Mentor
 
Join Date: Oct 2002
Rookie Year: 2002
Location: Long Island, NY
Posts: 1,187
Matt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond reputeMatt Krass has a reputation beyond repute
Send a message via AIM to Matt Krass
Re: RPM Sensing Options

Quote:
Originally Posted by schenkin
Hello all. I am trying to figure out a way to measure rpms, eventually this will lead to an approximate muzzle velocity of our ball shooter.

So far, I've come up with a couple of possible sollutions:

1. Use a seperate controller (probably our edubot), to count up encoder interupts, poll this data at a set interval from the main controller (probably over a few digital in/outs), and from this get rotations/time. The main problem with this is that I haven't gotten the encoder code to run properly on the edubot. If someone could help with this, i'll post the problems i'm having.

2. Use an analog device which outputs speed as variable voltage. So far i've been playing with just using a standard DC motor to generate a current, and feeding that back into the controller, but I have no idea what the sensed voltage range is in the A/D controllers, and I very much doubt that the output is going to be even close to linear. Is there an actuall sensor that will do this for me?

Any help would be appreciated! So far this forum has served me well!

We tried both, ended up with #2 for simplicity, its not perfectly linear but its pretty close, it worked out well for us
__________________
Matt Krass
If I suggest something to try and fix a problem, and you don't understand what I mean, please PM me!

I'm a FIRST relic of sorts, I remember when we used PBASIC and we got CH Flightsticks in the KoP. In my day we didn't have motorized carts, we pushed our robots uphill, both ways! (Houston 2003!)
  #9   Spotlight this post!  
Unread 27-01-2006, 09:14
schenkin schenkin is offline
Registered User
#0486
 
Join Date: Jan 2005
Location: Strath Haven High School
Posts: 17
schenkin is on a distinguished road
Re: RPM Sensing Options

Sorry I didn't reply earlier, I thought I would get an email notification when new messages where posted. And I did, but only for the first one.

Anyhow, so long to the Edubot idea. I thought about using optical encoders like we are using to keep the robot going straight, but i'm not sure I understand how to get speed from that. Obviously you can get distance from the encoders, and then divide it by time, but how do I know how long it has been? I can't just keep track of loops can I? Wouldn't the interupts change the timing? Is there an internal clock I can tap into?

A gear tooth sensor would work too, but I had the same concerns.

That standalone tachometer is pretty awsome, and would save us alot of trouble, but I'd rather not spend that kind of money if I can avoid it.

--Sam

Last edited by schenkin : 27-01-2006 at 09:16.
  #10   Spotlight this post!  
Unread 27-01-2006, 09:29
BrianBSL BrianBSL is offline
Registered User
FRC #0190
 
Join Date: Sep 2004
Rookie Year: 2000
Location: Worcester, MA
Posts: 251
BrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud ofBrianBSL has much to be proud of
Re: RPM Sensing Options

Quote:
Originally Posted by schenkin
Sorry I didn't reply earlier, I thought I would get an email notification when new messages where posted. And I did, but only for the first one.

Anyhow, so long to the Edubot idea. I thought about using optical encoders like we are using to keep the robot going straight, but i'm not sure I understand how to get speed from that. Obviously you can get distance from the encoders, and then divide it by time, but how do I know how long it has been? I can't just keep track of loops can I? Wouldn't the interupts change the timing? Is there an internal clock I can tap into?

A gear tooth sensor would work too, but I had the same concerns.

That standalone tachometer is pretty awsome, and would save us alot of trouble, but I'd rather not spend that kind of money if I can avoid it.

--Sam
The PIC has timer interrupts that you can setup to make a pretty reliable counter.
__________________
My posts represent my personal views only, and do not represent the views of either my team, Team 190, nor its primary sponsor, Worcester Polytechnic Institute.
  #11   Spotlight this post!  
Unread 27-01-2006, 10:56
schenkin schenkin is offline
Registered User
#0486
 
Join Date: Jan 2005
Location: Strath Haven High School
Posts: 17
schenkin is on a distinguished road
Re: RPM Sensing Options

How exactly would I utilize that? Keep in mind that I thought myself to program the robot, which means I have little to know experience with what lies below the surface of the code. I do ok, but little of what I write is pretty or sophisticated.
  #12   Spotlight this post!  
Unread 27-01-2006, 16:11
Kevin Sevcik's Avatar
Kevin Sevcik Kevin Sevcik is offline
(Insert witty comment here)
FRC #0057 (The Leopards)
Team Role: Mentor
 
Join Date: Jun 2001
Rookie Year: 1998
Location: Houston, Texas
Posts: 3,673
Kevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond reputeKevin Sevcik has a reputation beyond repute
Send a message via AIM to Kevin Sevcik Send a message via Yahoo to Kevin Sevcik
Re: RPM Sensing Options

Use digital in 14. It corresponds to pin RC0 on the PIC, which coincidentally is the clock for Timer 1/3 when they are used as (a)synchonous counters. Look at the PIC reference on www.kevin.org/frc Specifically, look at the TIMER section and the PORTC section. Note that I haven't tried this yet, but this is how I'm planning on doing things. You can get pretty good resolution and update rates since the max frequency is 50kHz, and you just sample it and clear it every PID loop, so you don't have to deal with the variable update rates of some other methods. Best of all, no interrupts needed.
__________________
The difficult we do today; the impossible we do tomorrow. Miracles by appointment only.

Lone Star Regional Troubleshooter
  #13   Spotlight this post!  
Unread 28-01-2006, 21:13
Joohoo's Avatar
Joohoo Joohoo is offline
Registered User
FRC #0340 (G.R.R.)
Team Role: Mentor
 
Join Date: Jun 2005
Rookie Year: 2005
Location: Rochester
Posts: 241
Joohoo is just really niceJoohoo is just really niceJoohoo is just really niceJoohoo is just really niceJoohoo is just really nice
Send a message via AIM to Joohoo Send a message via Yahoo to Joohoo
Re: RPM Sensing Options

The interrupt file in http://kevin.org/frc/2005/ has many timers in it I used the file to do the same thing the only thing that you need to do is to get the speed from more than one gear tooth so it is more accurate. you need to make a circular array or something like that I'm still trying to understand it (circular array) myself(thank god for mentors)
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

Similar Threads
Thread Thread Starter Forum Replies Last Post
2006 Motor Specs Xufer Motors 39 10-12-2006 15:59
Light Sensing Robot John Gutmann Technical Discussion 6 24-08-2005 10:47
Kevin Watson's encoder code with RPM output MaxM Programming 2 05-02-2005 00:06
optimum sensing distance for sensors DaveG702 Electrical 3 31-01-2003 22:06
Drill Motor Max RPM with Gearbox? archiver 2001 1 23-06-2002 22:40


All times are GMT -5. The time now is 01:34.

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