Page 1 of 1

sending C to ff-buggy

Posted: Fri Mar 04, 2011 1:08 pm
by Stijn De Meeter
hi,

I am running flowcode 3 on a windows 7 system. And now me and my students are trying to make a music mellodie to send to my FF-buggy. In order to get the right tones i am using the C block to get the perfect delay for every tone. But every time i try to send the program to the buggy it gives an error and it can't be send. Do i need to make spetial modifications before i can send C? Or what can i do?

i hope i can be helped soon...
regards Stijn

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:00 pm
by Benj
Hello,

Ok have you selected the formula flowcode as your target in Flowcode?

Are you programming via Flowcode or are you writing and compiling in pure C?

What error message are you receiving?

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:10 pm
by Stijn De Meeter
yes i v taken the ff buggy target, and i am programming in flowcode:
here u see my program to send an F tone and the error:



File name: C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c
Generated by: Flowcode v3.4.7.48
Date: Friday, March 04, 2011 14:09:22
Licence: 50 User
Registered to: thomasgabriels


NIET VOOR COMMERCIELE TOEPASSINGEN

http://www.matrixmultimedia.com



Launching the compiler...

C:\Program Files (x86)\Matrix Multimedia\Flowcode V3\BoostC\boostc.pic18.flowcode.exe -v -t PIC18F4455 "toon met C toon F.c"

BoostC Optimizing C Compiler Version 6.70 (for PIC18 architecture)
http://www.sourceboost.com
Copyright(C) 2004-2007 Pavel Baranov
Copyright(C) 2004-2007 David Hobday

Licensed to FlowCode User under Single user Full License for 1 node(s)
Limitations: PIC18 max code size:Unlimited, max RAM banks:Unlimited, Non commercial use only


toon met C toon F.c
Starting preprocessor: "C:\Program Files (x86)\Matrix Multimedia\Flowcode V3\BoostC\pp.exe" "C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c" -i "C:\Program Files (x86)\Matrix Multimedia\Flowcode V3\BoostC\include" -d _PIC18F4455 -la -c2 -o "toon met C toon F.pp" -v -d _BOOSTC -d _PIC18

C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(113): error: missing semicolon
C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(113): error: missing right paren
C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(84): error: failure

failure

.......................
Return code = 1
Flowcode kan de C-code niet vertalen vanwege de volgende fout:


Als de flowchart C-code bevat, controleer die dan zorgvuldig. Als de flowchart geen C-code bevat of als die gegarandeerd vrij is van fouten, neem dan contact op met de technische ondersteuning.

FINISHED

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:12 pm
by Stijn De Meeter
i used the C block in flowcode for this delay:



delay_msec(1);
delay_usec(200);
delay_usec(231);

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:15 pm
by Stijn De Meeter
the program in attachement

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:16 pm
by Benj
Hello,

Your compilation is failing on line 113 of the C code.

C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(113): error: missing semicolon
C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(113): error: missing right paren
C:\Users\B02.06\Documents\De Meeter S\toon flowcode\toon met C toon F.c(84): error: failure

The missing semicolon problem is sometimes caused by a missing component connection on one of the components or could be due to a missing semicolon in your C code.

By looking at the C file Flowcode generates you should be able to find the problems by looking at line 113.

If you cannot find out whats going wrong then please can you attach your Flowcode file and generated C file to the forums and I will have a look.

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:17 pm
by Stijn De Meeter
picture of program

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:18 pm
by Benj
Problem is being caused by this in your C code.

delay_msec(1);
delay_usec(200);
delay_<strange character here>usec(231);

Both C code blocks have the same problem. Maybe a unicode character or something else strange.

Re: sending C to ff-buggy

Posted: Fri Mar 04, 2011 2:20 pm
by Benj
Cproblem.JPG
Cproblem.JPG (43.8 KiB) Viewed 8882 times