18F8490 and CAN

Forum for problems or queries regarding Flowcode Comms Components. Eg LIN, I2C, SPI, RS232, CAN, IrDA etc

Moderators: Benj, Mods

Post Reply
beambase
Posts: 94
Joined: Wed Jul 29, 2009 5:15 pm
Has thanked: 6 times
Been thanked: 8 times
Contact:

18F8490 and CAN

Post by beambase »

Hi,
I am trying to use the CAN component with a 18F8490 but when I try to compile I get:

Panel8490a.c
Starting preprocessor: "C:\Program\Matrix Multimedia\Flowcode V4\BoostC\pp.exe" Panel8490a.c -i "C:\Program\Matrix Multimedia\Flowcode V4\BoostC\include" -d _PIC18F8490 -la -c2 -o Panel8490a.pp -v -d _BOOSTC -d _PIC18

Panel8490a.c(458): Illegal redefinition of symbol: TX1IE
Panel8490a.c(459): Illegal redefinition of symbol: TX2IE
Panel8490a.c(468): Illegal redefinition of symbol: TX1IF
Panel8490a.c(469): Illegal redefinition of symbol: TX2IF

4 errors detected
Error: preprocessing error

failure

....................
Return code = 1

Flowcode was unable to compile the flowchart's C code due to the following errors:


If your flowchart contains C code, please review this carefully. If your flowchart contains no C-code or you have thoroughly reviewed the code, contact Technical Support.

FINISHED



Any ideas what I need to do to get it to work?

User avatar
Steve
Matrix Staff
Posts: 3418
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times
Contact:

Re: 18F8490 and CAN

Post by Steve »

This is because the definitions in the CAN component are interfering with the definitions int he internal CAN module for this device. Note that the CAN component in Flowcode only works with the external MCP2515 CAN chip and does not currently work with the internal CAN module of some chips.

To work around this problem, you should be able to safely comment out the problematic "#define" statements in the CAN component's C code file. A modified file is attached.
Attachments
CAN_Code.c
(37.51 KiB) Downloaded 397 times

Post Reply