SOLVED: Error code 1: unknown identifier 'FCM . . .

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 6.

Moderator: Benj

Post Reply
bvolken
Posts: 14
Joined: Mon Nov 30, 2015 1:57 am
Location: California, United States
Has thanked: 6 times
Been thanked: 9 times
Contact:

SOLVED: Error code 1: unknown identifier 'FCM . . .

Post by bvolken »

Okay, I've battled a lot of stuff getting this to work.
Target: PIC18F4580
Programmer: PICKIT3
OS: Windows 10 home 64 bit
FlowCode 6.1.2.0 (11.05.2015)

I got the PICKIT3 to work. I solved the Low Voltage Programming problem, I cracked the OSSCON setting requirement.
I tested some code to write 16 consecutive bytes to a 2x16 serial LCD display. Worked fine when I had it all in the "Main" macro.
So, I broke each 'subroutine' into individual macros in preparation to make a component.
Same stuff that I had working all in "main", but now throws a compiler error (error code 1)
Macro names have no spaces. None of these macros take or return any parameters. The only variable is a UINT 'counter'
This seems pretty basic to me, but I'm tired of scouring the internet for hints.
Thanks in advance.

Error:

Code: Select all

LCD_Serial.c(230:2): error: unknown identifier 'FCM_LCD_Init'
LCD_Serial.c(230:2): error: failed to generate expression
LCD_Serial.c success

failure
Completed BoostC compilation, return = 1

C:\Program Files (x86)\Flowcode 6\compilers\pic\boostc\boostc_18F.exe reported error code 1
temp.jpg
temp.jpg (51.52 KiB) Viewed 3669 times
Last edited by bvolken on Mon Nov 30, 2015 5:49 pm, edited 1 time in total.
Programmer: PICKIT3
OS: Windows 10 home 64 bit
FlowCode 6.1.2.0 (11.05.2015)

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: Error code 1: unknown identifier 'FCM . . .

Post by Benj »

Hello,

Please could you attach your Flowcode project file and I will investigate this problem for you. From what your saying it sounds like it should be fairly simple and should be working.

bvolken
Posts: 14
Joined: Mon Nov 30, 2015 1:57 am
Location: California, United States
Has thanked: 6 times
Been thanked: 9 times
Contact:

Re: SOLVED: Error code 1: unknown identifier 'FCM . . .

Post by bvolken »

Here is the (self created) problem and solution.
The key was when I said "preparation to make a component".
While experimenting, I set the macros as "Embedded Macros" in the Interface Manager.
After watching a few more YouTube videos, I tried switching the macros to "Downloadable Macro" and everything compiled, downloaded and worked as desired.
To quote Homer: "D'oh"
Not sure what the problem was, specifically, I just know what fixed it.
Attachments
temp.jpg
(85.04 KiB) Downloaded 562 times
Programmer: PICKIT3
OS: Windows 10 home 64 bit
FlowCode 6.1.2.0 (11.05.2015)

User avatar
Benj
Matrix Staff
Posts: 15312
Joined: Mon Oct 16, 2006 10:48 am
Location: Matrix TS Ltd
Has thanked: 4803 times
Been thanked: 4314 times
Contact:

Re: SOLVED: Error code 1: unknown identifier 'FCM . . .

Post by Benj »

Ok thanks for letting us know what the cause was.

Embedded is slightly different to downloadable in that you can make it call code without adding to the call stack, we use it quite a lot in the DSP components to avoid subroutine slowdown when reading or writing the buffers but it's fairly complicated.

I would say that in most cases when making components you either want downloadable, simulation or hidden.

Post Reply