Go to Post They hit us, we hit them, it happens. Build your robots to take a hit and it doesn't matter. - Greg Needel [more]
Home
Go Back   Chief Delphi > Technical > Programming
CD-Events   CD-Media   CD-Spy   FRC-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 01-23-2007, 06:51 PM
Nathan's Avatar
Nathan Nathan is offline
Registered User
FRC #1501 (Team T.H.R.U.S.T.)
Team Role: Alumni
 
Join Date: Sep 2006
Rookie Year: 2007
Location: United States
Posts: 149
Nathan has a spectacular aura aboutNathan has a spectacular aura aboutNathan has a spectacular aura about
Gear Tooth Sensor

Hey guys, I have a rather wierd problem.

I'm trying to use a gear tooth sensor with easy c. When I use the default gear tooth sensor functions I don't get any readings from our sensor. But when I use the GetDigitalInput function, I get a reading from the sensor? Why would this be?

Thanks,
Nathan
  #2   Spotlight this post!  
Unread 01-23-2007, 07:08 PM
sjung9442 sjung9442 is offline
Student Mentor
FRC #0122 (NASA Knights)
Team Role: Programmer
 
Join Date: Jan 2006
Rookie Year: 2004
Location: Hampton, VA
Posts: 17
sjung9442 is an unknown quantity at this point
Re: Gear Tooth Sensor

I don't know much about easy C program, but I know that easy C does not give exact code we need. So, try look at Kevin Watsons encoder code and find how gear tooth sensor works. Than, try to combine or copy Kevin Watson's code to easy C.

If you are getting digital input, that is great. Because gear tooth sensor gives digital input. All you have to do is convert the data to analog and find the right parameter.
  #3   Spotlight this post!  
Unread 01-23-2007, 07:11 PM
michniewski michniewski is offline
Registered User
FRC #1353
 
Join Date: Jan 2007
Location: Canada
Posts: 6
michniewski is an unknown quantity at this point
Re: Gear Tooth Sensor

I'm not familiar with easyC (being a user of mplab), but maybe the gear tooth sensor functions rely on some particular digital input and you have it connected to a different one. Also, check for any configuration information, or perhaps calibration.. just a guess.

Good luck!
__________________
- Michael Michniewski
Team 1353, The Spartans



Greater Toronto Regional
- look for the Spartan mascot
  #4   Spotlight this post!  
Unread 01-23-2007, 07:37 PM
Nathan's Avatar
Nathan Nathan is offline
Registered User
FRC #1501 (Team T.H.R.U.S.T.)
Team Role: Alumni
 
Join Date: Sep 2006
Rookie Year: 2007
Location: United States
Posts: 149
Nathan has a spectacular aura aboutNathan has a spectacular aura aboutNathan has a spectacular aura about
Re: Gear Tooth Sensor

Yeah, the gear tooth sensor needs to be hooked up to Digital ports 1-6 to work, so says the easy c manual...

Also I have a variable keeping track of how many times the Digital port == 1, which is what I think the gear tooth sensor function does.

I just can't figure out why the default function won't work...

-Nathan
  #5   Spotlight this post!  
Unread 01-12-2008, 02:09 PM
Team 562 Team 562 is offline
Registered User
FRC #0562
 
Join Date: Jan 2006
Location: Massachusetts
Posts: 6
Team 562 is an unknown quantity at this point
Re: Gear Tooth Sensor

Nathan,

Sorry for the late reply. Maybe you have already figured it out since your post but I have set up the gear tooth sensor successfully with the easyC default code. The sensor returns an absolute value based on the number of times it senses a gear tooth passing by. So, all you need to do is create a variable of type "int", assign it the value from the GetGTSensor() function, and display the value of the variable with a screen print.

Good Luck.
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
Gear Tooth Sensor Zoom Programming 46 01-22-2008 07:05 AM
Gear Tooth Sensor nukem Programming 9 02-04-2006 07:21 PM
Gear Tooth Sensor Trouble cprogrammer Programming 1 01-24-2006 12:48 PM
Gear Tooth Sensor Talha Electrical 1 01-23-2006 08:29 PM
Gear Tooth Sensor AMIRAM Electrical 2 01-22-2006 03:09 AM


All times are GMT -5. The time now is 07:44 AM.

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


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