Chief Delphi

Chief Delphi (http://www.chiefdelphi.com/forums/index.php)
-   Programming (http://www.chiefdelphi.com/forums/forumdisplay.php?f=51)
-   -   Help Integrating Interrupts and Camera (http://www.chiefdelphi.com/forums/showthread.php?t=52594)

Keo-san 23-01-2007 19:28

Help Integrating Interrupts and Camera
 
This year our team is planning on using the camera as well as the KoP gear-tooth sensor. We have gotten both to work successfully but they are in different MPLab Workspaces. I tried adding some of the interrupt files over and I got some errors on the definitions of the PIC processor. This is over my head so any ideas and help are welcome!

sjung9442 23-01-2007 19:41

Re: Help Integrating Interrupts and Camera
 
Did you use Kevin Watson's code in the begining? or built you own code for gear tooth sensor?

If you modified Kevin Watson's code, you could try to find all the variables you actually used and compare it with kevin watson's new code.
Well, I think you know about this so I'm not going to talk about it more.

try to compare the defined variables in the default code. (kevin watson's)
that might give you some idea what had been changed.

Keo-san 23-01-2007 19:44

Re: Help Integrating Interrupts and Camera
 
I used both of Watson's FRC codes. For the interrupts and for the camera, I was doing that as far as I could determine but I found problems once It got into compiling processor definitions

sjung9442 23-01-2007 20:01

Re: Help Integrating Interrupts and Camera
 
Then, only think I could think of is to re-write the code.
If you understand your old code fully, it is not so hard to do that.
copy the main functions from the old code and try to combine old and new together

chris31 23-01-2007 20:28

Re: Help Integrating Interrupts and Camera
 
Run it through a tool like WinDiff to make sure you copied it all over.

charrisTTI 24-01-2007 08:10

Re: Help Integrating Interrupts and Camera
 
Camera uses interrupts for serial communications.
Encoder (gear tooth sensor) outputs should be connected to i/o pins which generate interrupts.


In the Kevin Watson code:
The interrupt routine (see user_routines_fast.c - InterruptHandlerLow) in the camera example only has code to handle the serial port interrupts.

The interrupt routine in the encoder (gear tooth sensor) example has code to handle the serial port interrupts as well as the i/o pin (connected to the encoder outputs) interrupts.

So, when you combine your workspaces use the interrupt service routine from the encoder example.

Keo-san 25-01-2007 22:20

Re: Help Integrating Interrupts and Camera
 
Thanks for all the help guys! I brought my CompSci teacher (who is our mentor) to help on this.Took us a couple of hours and lets just say we got VERY deep.As into the compiler. But if anyone needs the code let me know vmarmol@gmail.com


All times are GMT -5. The time now is 04:11.

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