View Single Post
  #2   Spotlight this post!  
Unread 15-06-2005, 12:59
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: Programming a 2nd PIC

Quote:
Originally Posted by ImmortalAres
In order to easily handle the analysis of PWM signal input I'm using a second PIC (PIC18F452) to do the calculation and plan on using the RC as the Master device where the two PICs communicate through the TTL serial line on the RC and a serial port on the demo board (PICDEM 2 Plus demonstration board from Microchip). I have a question about the programming of the 2nd PIC. Since both 40 pin PIC's are of the PIC18Fxx2 family their pin configuration and registers associated with each are the same. Does this then make it possible to transport the code that I had working on the RC to this 2nd PIC directly? Or do I have to completely rewrite my own code?

(Essentially I don't know what's in that RC box and if there is more to it then just a PIC and tracks that attach the pins to the headers for signal input on the outside)

Any advice would be greatly appreciated
You can't just program it with a project from the RC, the RC has 2 pic chips in it (a master processor, and the user processor that you program) and therefore a lot of the IO (tho mostly output) you do on the user processor actually goes through the master processor. You would have to start your project from scratch, but you could certinally reuse functions that you wrote for the RC on the demo board.