Failed to Compile working FC, after recent PIC i2C updates.

Any bugs you encounter with Flowcode should be discussed here.
Post Reply
jay_dee
Posts: 229
http://meble-kuchenne.info.pl
Joined: Sun Dec 20, 2020 6:06 pm
Has thanked: 91 times
Been thanked: 58 times

Flowcode v10 Failed to Compile working FC, after recent PIC i2C updates.

Post by jay_dee »

Hi,
PIC 18F2585 project, compiled and worked fine a couple of weeks ago. It will now not compile and throws the error shown below.
I ran a recent update of all files, not sure if this is part of the issue.
There is no hardware channel 2 for i2C on the PIC18F2585 so maybe this is a bug of some sort?

I tried to follow the wiki on how to roll-back the PIC_CAL_I2C file to version 2. But 'download' button is always greyed out.
Every file is updated to latest version.

Any thoughts, J.
Employing 18F2585 errata work-arounds:
* Corrupted fast interrupt shadow registers
C:\ProgramData\MatrixTSL\FlowcodeV10\CAL\PIC\PIC_CAL_I2C.c:
227: #error "I2C Channel 2 does not have the SSP2IF defined on this chip - does your chip support this feature?"
^ (103) #error: "I2C Channel 2 does not have the SSP2IF defined on this chip - does your chip support this feature?"
227: #error "I2C Channel 2 does not have the SSP2IF defined on this chip - does your chip support this feature?"
^ (103) #error: "I2C Channel 2 does not have the SSP2IF defined on this chip - does your chip support this feature?"
(908) exit status = 1

chipfryer27
Valued Contributor
Posts: 1679
Joined: Thu Dec 03, 2020 10:57 am
Has thanked: 374 times
Been thanked: 581 times

Re: Failed to Compile working FC, after recent PIC i2C updates.

Post by chipfryer27 »

Hi

Sounds similar to another post earlier in the week regarding SSP. That chip didn't have a Ch2 either.

Just tried to backtrack PIC I2C CAL to v2 and see it is grey too.

Regards

medelec35
Matrix Staff
Posts: 2080
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 642 times
Been thanked: 697 times

Re: Failed to Compile working FC, after recent PIC i2C updates.

Post by medelec35 »

Did you select ch2 by accident (which I did not believe was possible) or does the error occur when ch1 is selected.
Just in case I have added a bt of belt an braces to the I2C cal to prevent the

Code: Select all

I2C Channel 2 does not have the SSP2IF defined on this chip - does your chip support this feature?
To test for this update:
Browse to this location using file explorer, it's hidden by default so just paste the link into your address bar.

Code: Select all

%ProgramData%\MatrixTSL\FlowcodeV10\CAL\PIC
Place the attached C file.
You will need to reload your project file for the fix to take place.
If you run any library updates, then the PIC_CAL_I2C.c you added will be overwritten, so it will stop working again (unless the PIC_CAL_I2C.c update has been pushed).

If you would like to post your .fcfx project, I can do some further testing.
Attachments
PIC_CAL_I2C.c
(31.14 KiB) Downloaded 61 times
Martin

jay_dee
Posts: 229
Joined: Sun Dec 20, 2020 6:06 pm
Has thanked: 91 times
Been thanked: 58 times

Re: Failed to Compile working FC, after recent PIC i2C updates.

Post by jay_dee »

Hi Martin,
The channel options were only for Software or Channel 1.
If i replace with the file you provided, the issue is resolved.
All of the effected FC now compile OK.
Thanks, J.

medelec35
Matrix Staff
Posts: 2080
Joined: Wed Dec 02, 2020 11:07 pm
Has thanked: 642 times
Been thanked: 697 times

Re: Failed to Compile working FC, after recent PIC i2C updates.

Post by medelec35 »

Thanks, J.
Yes I thought so, but best to confirm.
I appreciate the update.
Martin

Post Reply