compiling to hex

For general Flowcode discussion that does not belong in the other sections.
peterhalloway
Posts: 33
http://meble-kuchenne.info.pl
Joined: Sat Nov 20, 2021 11:28 am
Has thanked: 1 time

Flowcode v10 compiling to hex

Post by peterhalloway »

Hi All
I am desperate to get a hex file out of the attached code but it is coming out with an error. Can someone please try to compile this to hex so I can narrow down the problem.

Many thanks

Pete
Attachments
Development Board.fcfx
(46.63 KiB) Downloaded 85 times

stefan.erni
Valued Contributor
Posts: 1029
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 196 times
Been thanked: 218 times

Re: compiling to hex

Post by stefan.erni »

Hi Peter

I also get an error with your program..
2024-12-05_21-28-35.PNG
2024-12-05_21-28-35.PNG (32.62 KiB) Viewed 4236 times

mnfisher
Valued Contributor
Posts: 1554
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 138 times
Been thanked: 741 times

Re: compiling to hex

Post by mnfisher »

Looking at the CMF file - looks like an easy fix (or workaround) is to rename without a space in the name.

I saved it as db.fcfx and then it compiles AOK
Memory Summary:
Program space used 2FC0h ( 12224) of 8000h bytes ( 37.3%)
Data space used 169h ( 361) of 600h bytes ( 23.5%)
Configuration bits used 7h ( 7) of 7h words (100.0%)
EEPROM space used 0h ( 0) of 100h bytes ( 0.0%)
ID Location space used 0h ( 0) of 8h bytes ( 0.0%)
Data stack space used 0h ( 0) of 496h bytes ( 0.0%)
Martin

peterhalloway
Posts: 33
Joined: Sat Nov 20, 2021 11:28 am
Has thanked: 1 time

Re: compiling to hex

Post by peterhalloway »

Thank you Martin yes that cured it for me didnt realise we could not have spaces

mnfisher
Valued Contributor
Posts: 1554
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 138 times
Been thanked: 741 times

Re: compiling to hex

Post by mnfisher »

- it was a surprise to me too. Something to watch as I occasionally use spaces in file names...
The CMF file was new to me too - haven't managed to find much info on it.

Martin

stefan.erni
Valued Contributor
Posts: 1029
Joined: Wed Dec 02, 2020 10:53 am
Has thanked: 196 times
Been thanked: 218 times

Re: compiling to hex

Post by stefan.erni »

Hi Martin, Hi Peter

Yes, if I remove the space in the name it's compiling nice.
2024-12-06_08-30-16.PNG
2024-12-06_08-30-16.PNG (24.41 KiB) Viewed 4212 times

Steve-Matrix
Matrix Staff
Posts: 1514
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 212 times
Been thanked: 351 times

Re: compiling to hex

Post by Steve-Matrix »

Thanks to Stefan and Martin for helping resolve this.
peterhalloway wrote:
Thu Dec 05, 2024 9:25 pm
didnt realise we could not have spaces
Flowcode itself should be ok without spaces, but some toolchains might have issues. Especially if 8.3 filename generation is turned off within Windows and an equivalent "8.3" filename is not available. I will look into this issue to see if there is anything else we can do to work around this.

We also see with some toolchains that the paths for included files can become very long and so keeping filenames short and installing toolchains close to the root folder of the drive help to avoid these issues.

Steve-Matrix
Matrix Staff
Posts: 1514
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 212 times
Been thanked: 351 times

Re: compiling to hex

Post by Steve-Matrix »

I've looked further into this and not been able to resolve it. It seems to be an issue within the XC8 toolchain and so we can't fix it. I have found another post about this on our old forums from 2016, and so it's been encountered before:

https://www.flowcode.co.uk/mmforums/vie ... hp?t=17965

mnfisher
Valued Contributor
Posts: 1554
Joined: Wed Dec 09, 2020 9:37 pm
Has thanked: 138 times
Been thanked: 741 times

Re: compiling to hex

Post by mnfisher »

It's not really fixing it - but a warning dialog if the user tries to create a filename with a space in it might help.

It could also strip spaces - but again, might cause more issues than it solves (does it do this for esp32?)

Or replace spaces with underscores?

Martin

Steve-Matrix
Matrix Staff
Posts: 1514
Joined: Sat Dec 05, 2020 10:32 am
Has thanked: 212 times
Been thanked: 351 times

Re: compiling to hex

Post by Steve-Matrix »

That's an idea, Martin. But I've just done some experimenting and it seems to affect only the 18F452. So it's going to be rare.

Post Reply