Thread: Example code
View Single Post
  #3   Spotlight this post!  
Unread 14-03-2006, 12:05
TubaMorg TubaMorg is offline
Programmermechanicalelect ricalcoach
AKA: Dan
FRC #1480 (Robatos Locos)
Team Role: Mentor
 
Join Date: Jan 2006
Rookie Year: 2005
Location: Houston
Posts: 450
TubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond reputeTubaMorg has a reputation beyond repute
Re: Example code

Quote:
You need to post more info about what you have tried so we know where to start with advice. We found that the default encoder code from Kevin's site was enough to get it working so we could see tooth count interrupts.
Remember to pay attention to the Forum section that this is posted in: "easyC for FRC"


Quote:
ooo I had some problems with that darn tooth-sensor.
Can anyone please give some examples to deal with it?
A real normal example.
I am really desprate
Have you tried the test code that comes with EasyC? Go to Open Project and navigate to where the test code is and open the GEARTOOTHTEST.ECP project. On my computer it is here:

C:\Program Files\Intelitek\easyC for FRC\Projects\Test Code\GEARTOOTHTEST.ECP

Also make sure you download and install the newest version of EasyC to make sure the test code is up to date (look here). There were some problems with the earlier test code because the print statement wasn't formatted correctly, so the tooth count was being output in the bajillions. I'm not sure if it has been fixed yet, because our gear tooth counters are in the crate. But this will help you with testing it out. Remember the tooth count is output to a long variable, so the output must be formatted for a long variable. Also look in the Help section of EasyC. Look for gear tooth counter and it will tell you how to use it.

Good luck!