This file mostly worked for us. We had to add in an include for encoder.h and the Port_B and Port_B_Delta variables.
Now, encoders 3 through 6 work fine (indeed, I can run all four of them, each generating 1600 pulses/sec, and it keeps up) in tandem with the gyro and camera. But if try to use encoder 1, I get the red-light-o-death as soon as something triggers it. And if I try to enable encoder 2, it doesn't build:
C:\FIRST 2006\FRC 21 Jan 2006\encoder.c:131:Error [1205] unknown member 'INT3IP' in '__tag_223'
C:\FIRST 2006\FRC 21 Jan 2006\encoder.c:131:Error [1131] type mismatch in assignment
I noticed
this thread, but I've confirmed that my p18f8722.h (in c:\mcc18\h) file is the exact one from the installation CD, and there are no others on the system. Are there two versions of this .h floating around?
In any case, I've put the code online (with team-strategy specific stuff removed, but this version shows the problem) at
this link. I can probably run with just encoders 3-6, but wanted to run speed control on 1 and 2.
Any ideas?