Empty #define statement

Moderator: Benj

Post Reply
mnf
Valued Contributor
Valued Contributor
Posts: 1188
Joined: Wed May 31, 2017 11:57 am
Has thanked: 70 times
Been thanked: 439 times
Contact:

Empty #define statement

Post by mnf »

A puzzle: I got stuck at this state - at line 76 there is an empty #define - which won't compile.

Not sure how I managed it or how to cure it....

Any suggestions
st7789.fcfx
(26.37 KiB) Downloaded 151 times
C:\Users\mn_fi\DOWNLO~1>"C:\PROGRA~2\Flowcode\Common\COMPIL~1\avr\BATCHF~1\..\bin\avr-gcc.exe" -mmcu=atmega328p -Os -ffunction-sections -fdata-sections -funsigned-char -o "C:\Users\mn_fi\DOWNLO~1\st7789.elf" "C:\Users\mn_fi\DOWNLO~1\st7789.c" -lm -Wl,-gc-sections
C:\Users\mn_fi\DOWNLO~1\st7789.c:55:10: error: no macro name given in #define directive
And the C code
MX_UINT8 FCLV_LOOP1;


/*========================================================================*\
Use :panel
:Variable declarations
:Macro function declarations
\*========================================================================*/
#define

#define FCV_FALSE (0)
#define FCV_TRUE (1)
MX_GLOBAL MX_UINT16 FCV_YSTART;
MX_GLOBAL MX_UINT16 FCV_XSTART;
Martin

stefan.erni
Valued Contributor
Valued Contributor
Posts: 654
Joined: Fri Aug 19, 2016 2:09 pm
Location: switzerland
Has thanked: 182 times
Been thanked: 179 times
Contact:

Re: Empty #define statement

Post by stefan.erni »

Hi Martin

I deleted all your macros and all your code and changed the chip to a PIC, but still this error!
There is a strange thing (for me) What is this panel with Pins in your Program even I deleted all?

regards

Stefan
Panel.PNG
Panel.PNG (46.13 KiB) Viewed 3399 times

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: Empty #define statement

Post by Steve »

This problem is related to the "DC Pin" property on the panel. If you edit this and untick "generate a define for the property" then the problem goes away.

Or if you want a define for this property to be added, click the drop-down next to that checkbox and enter the define name and value.

stefan.erni
Valued Contributor
Valued Contributor
Posts: 654
Joined: Fri Aug 19, 2016 2:09 pm
Location: switzerland
Has thanked: 182 times
Been thanked: 179 times
Contact:

Re: Empty #define statement

Post by stefan.erni »

Hi Steve

Thanks a lot. It solved the compiling problem.

In one of my program I had also this panel and I never understand why there are pins, and for what are this pins? a component?

In the 2D panel or 3D panel there are no components. I deleted all......

regards

Stefan
st7789_panel.fcfx
(9.44 KiB) Downloaded 164 times

mnf
Valued Contributor
Valued Contributor
Posts: 1188
Joined: Wed May 31, 2017 11:57 am
Has thanked: 70 times
Been thanked: 439 times
Contact:

Re: Empty #define statement

Post by mnf »

Many thanks, I don't think I'd have spotted that - and I'd have starting deleting things and that would surely have been last to go!

Martin

Post Reply