sending C to ff-buggy

For C and ASSEMBLY users to post questions and code snippets for programming in C and ASSEMBLY. And for any other C or ASM course related questions.

Moderators: Benj, Mods

Post Reply
Stijn De Meeter
Posts: 6
Joined: Mon Dec 06, 2010 7:53 pm
Contact:

sending C to ff-buggy

Post 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

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: sending C to ff-buggy

Post 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?

Stijn De Meeter
Posts: 6
Joined: Mon Dec 06, 2010 7:53 pm
Contact:

Re: sending C to ff-buggy

Post 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

Stijn De Meeter
Posts: 6
Joined: Mon Dec 06, 2010 7:53 pm
Contact:

Re: sending C to ff-buggy

Post by Stijn De Meeter »

i used the C block in flowcode for this delay:



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

Stijn De Meeter
Posts: 6
Joined: Mon Dec 06, 2010 7:53 pm
Contact:

Re: sending C to ff-buggy

Post by Stijn De Meeter »

the program in attachement
Attachments
toon met C toon F.fcf
(3.5 KiB) Downloaded 374 times

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: sending C to ff-buggy

Post 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.

Stijn De Meeter
Posts: 6
Joined: Mon Dec 06, 2010 7:53 pm
Contact:

Re: sending C to ff-buggy

Post by Stijn De Meeter »

picture of program
Attachments
progr.png
(12.02 KiB) Downloaded 4882 times

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: sending C to ff-buggy

Post 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.

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: sending C to ff-buggy

Post by Benj »

Cproblem.JPG
Cproblem.JPG (43.8 KiB) Viewed 7677 times

Post Reply