Page 1 of 1

Simpel Kipfunction

Posted: Sat May 08, 2010 10:40 am
by jgu1
Hello!

I am making a program which I need a Kip function like the attachment. It must be easy. It is also, but I just thought of this simple function fills the program very much.
Are there any "here" has a suggestion for a more simple program for this function?

Preferably without C code, since it is not my strong point.


Thanks in advance.

Jørgen :P

Re: Simpel Kipfunction

Posted: Sat May 08, 2010 12:01 pm
by medelec35
This is my fist attempt. I have reduced your program size from 12K to 7K.
I will see if I can think of a better way.

Re: Simpel Kipfunction

Posted: Sat May 08, 2010 12:32 pm
by ksor
Take a look at the "Componemt macro" and insert this ikon in your flowchart, dobble-click on it and you will see a list of elements.

Mark each element and see what macros you can use for each element.

Hope this gives you a hint !

Re: Simpel Kipfunction

Posted: Sat May 08, 2010 12:55 pm
by Sean
I have compiled the first two programs in this thread to check the program sizes being reported.

The original program compiles to 190 bytes of program memory and the second program to 145 bytes.

The files that change from 12K to 7K between the two versions are the Flowcode source file (.fcf). These are used by Flowcode but are not downloaded to the target device.

Details of the program downloaded to the target device are reported during compilation. This information is also saved along with the other project files created by Flowcode as a .msg (.txt) file.

Re: Simpel Kipfunction

Posted: Sat May 08, 2010 1:05 pm
by medelec35
sean wrote:
The original program compiles to 190 bytes of program memory and the second program to 145 bytes.

The files that change from 12K to 7K between the two versions are the Flowcode source file (.fcf). These are used by Flowcode but are not downloaded to the target device.

Details of the program downloaded to the target device are reported during compilation. This information is also saved along with the other project files created by Flowcode as a .msg (.txt) file.
Good point! 2nd program still smaller though :P
Phew! lol

Although I did get the impression, it was more about the amount of icons that was in the program, rather than both size of flowcode file and amount of program memory used up. So my logic is 7K instead of 12K = less icons.

Re: Simpel Kipfunction

Posted: Sat May 08, 2010 4:33 pm
by Sean
We hope that the size of the files created and saved on the PC by Flowcode is not considered to be a problem.

The main aim is to create efficient code for downloading to the target device.

Several factors will affect the size of either the Flowcode project files, the target program, or both.

Examples:
Custom images and comments increase the size of the Flowcode programs without affecting the memory used in the target device. These are usually considered to be beneficial for program clarity and maintenance.

ICD functionality, variable type selection, C code, and inclusion of external files will affect the size of the target device program more than the Flowcode project files.

Re: Simpel Kipfunction

Posted: Mon May 10, 2010 5:18 am
by jgu1
Hi All!

Thanks for your help, I'm glad that I can get some expert help here. I can see that the function is more simple now and the program does not take up so much. 8)

For you Ksor, I can see you are from Denmark maybe you live in Korsor? I live in Odense, but works in Korsor. If you wish we could exchange email addresses and share experiences together? :roll:

Greetings

Jorgen

Re: Simpel Kipfunction

Posted: Fri May 14, 2010 9:52 pm
by ksor
jgu1 wrote:Hi All!

Thanks for your help, I'm glad that I can get some expert help here. I can see that the function is more simple now and the program does not take up so much. 8)

For you Ksor, I can see you are from Denmark maybe you live in Korsor? I live in Odense, but works in Korsor. If you wish we could exchange email addresses and share experiences together? :roll:

Greetings

Jorgen
Hi Jorgen (maybe Jørgen in danish ?)

I live in Aarhus V ... so quit a distance anyway, but sometimes it's much easier to explain a special problem in our first language - danish - so here is my address:

keld DOT soerensen SNABELA os DOT dk