Page 1 of 1
C-Error due to filename
Posted: Mon Jul 02, 2012 9:28 pm
by Jan Lichtenbelt
Whatever can be is error message? (fout=error, resultaten=results)
I substract 2 integers: RC_Time_on=RC_Time_On - RC_Center. But this gives an error?????????

- Error_message.jpg (178.13 KiB) Viewed 6706 times
Who can help?
Kind regards
Jan Lichtenbelt
Re: Error substracting 2 integers
Posted: Mon Jul 02, 2012 9:47 pm
by JohnCrow
Hi Jan
Thats a strange one.
Ive just tried a simple flowchart using your variable names, and it works regardless of which value is the larger.
(fout=error, resultaten=results)
Are you using any C code, I think fout is a file command in C.
Re: Error substracting 2 integers
Posted: Mon Jul 02, 2012 11:14 pm
by kersing
Jan,
A simple test program with just an integer subtraction works fine so it is probably something specific to your total program. PM the file if you want me to take a look.
Groeten,
Jac
Re: Error substracting 2 integers
Posted: Mon Jul 02, 2012 11:20 pm
by kersing
JohnCrow wrote:(fout=error, resultaten=results)
Are you using any C code, I think fout is a file command in C.
John,
As Jan stated, fout is the dutch translation of error. He was referring to the message at the bottom of the screen dump "Foutresultaten", "Error results" when using the English language setting.
fout is a standard construct in C++, not in C afaik.
Best regards,
Jac
Re: Error substracting 2 integers
Posted: Tue Jul 03, 2012 7:52 am
by JohnCrow
Yes, I see what Jan was refering to now.
Ah well it was the end of the day

Re: Error substracting 2 integers
Posted: Tue Jul 03, 2012 8:54 am
by Jan Lichtenbelt
I have the feeling that it has to do with the ROM use (97%), but I'm not sure, see msg.txt file.
Jan Lichtenbelt
Re: Error substracting 2 integers
Posted: Tue Jul 03, 2012 9:18 am
by JonnyW
Good morning Jan.
At a guess is the line that the error is showing up on line 1840 of the generated .c file?
It may be that the parsing is getting mixed up as to what is an error and what is not. How the error report works is it looks at the compiler output for the filename and a line number (we can not even guarantee the word 'error' is present). If it finds the .c files name and a line number it can link to an icon, it reports this in the error window.
I'd be surprised if this is the case, as the parser should see 12F1840 as a single word and discard it, but I'm at a loss from the msg.txt to find anything else that could cause this.
Jonny
Re: Error substracting 2 integers
Posted: Tue Jul 03, 2012 9:40 am
by Jan Lichtenbelt
Dear Johnny,
You are right. The error is on line 1840/1841 of the C-program. Changing the flowcode filename into test.fcf did not give this error message anymore.
Thanks a lot for help!!
Kind regards
Jan Lichtenbelt
Re: Error substracting 2 integers
Posted: Tue Jul 03, 2012 10:20 am
by JonnyW
How very odd. Thanks for letting me know - I'll look into this as I've been looking at the code this morning and cant see why this would be!
Cheers,
Jonny
C error on text equal filename
Posted: Fri Jul 06, 2012 9:15 pm
by Jan Lichtenbelt
Again in a complete other situation, I get an error in C on the place where the text in C is equal to the filename. Now the error is in the first comment, which indeed contains the filename. The filename in this case is "RS232 RX flowcode_V2.2". The error given is in the comment which contains: "RS232 RX flowcode".
Remark: Foutresultaten means error results.
It stays indeed very odd, but consistent.
kind regards
Jan Lichtenbelt