Advise correct method for own component

For Flowcode users to discuss projects, flowcharts, and any other issues related to Flowcode 7.

Moderator: Benj

Post Reply
User avatar
QMESAR
Valued Contributor
Valued Contributor
Posts: 1287
Joined: Sun Oct 05, 2014 3:20 pm
Location: Russia
Has thanked: 384 times
Been thanked: 614 times

Advise correct method for own component

Post by QMESAR »

Hi All.

I need help advise on what would be the steps or correct method in FC ,
I have a project that I would like to run purely in FC as the project would require that I use a lot of my own functions foe example to configure and drive the Motor Control PWM module on a dsPIC33 to name one
now I know I can use a C call to do that but I was thinking is it not possible to embed this C function call into a component Icon that would give me for example PWM_MC Initailze and calcualte set point and so on then I would have icons on the Flow chart or is it better to make a complete component ?

I guess I am not sure what to do embed the C code into an Icon or make complete components and then in both cases I have actually no clue where to start :D any input advise or direction is highly appreciated this is quite important for me as since FC7 I am trying to fully move over to FC and not run both C style projects and FC However I need to make the FC charts lean and not having 100 C call icons in a Flowchart
The simulation part of FC is interesting but that is something I rarly use I code run and debug on the target hardware in my opinion (with my little knowledge on FC ) I would like not to add all the simulation features to my Component or icon that embed my C code

Thanks a million for your support

User avatar
LeighM
Matrix Staff
Posts: 2178
Joined: Tue Jan 17, 2012 10:07 am
Has thanked: 481 times
Been thanked: 699 times

Re: Advise correct method for own component

Post by LeighM »

Hi,
To create a component that has some custom API...
Just create a new project and your required macros, that contain Flowcode icons and C icon code.
Then use the Interface manager to change your macros into "Downloadable"
interface_mngr.jpg
interface_mngr.jpg (42.75 KiB) Viewed 5125 times
Then create your new component by File->Export component
Give the new component a name and a new GUI ID (just the first time you export it)
export.jpg
export.jpg (66.12 KiB) Viewed 5125 times
Refresh or rerun Flowcode, then use search to find and use your new component.

There is an example here...
http://www.matrixtsl.com/mmforums/viewt ... 386#p73065

Hope that gets you started.
Leigh

User avatar
QMESAR
Valued Contributor
Valued Contributor
Posts: 1287
Joined: Sun Oct 05, 2014 3:20 pm
Location: Russia
Has thanked: 384 times
Been thanked: 614 times

Re: Advise correct method for own component

Post by QMESAR »

Hi LeighM

Thank you this helps already a great deal just tried it and I could export one of my makro's

I will slowly start to use these techniques to improve myself and my FC knowledge

Many Thanks

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: Advise correct method for own component

Post by Benj »


User avatar
Steve
Matrix Staff
Posts: 3433
Joined: Tue Jan 03, 2006 3:59 pm
Has thanked: 114 times
Been thanked: 422 times

Re: Advise correct method for own component

Post by Steve »

So you are aware, we have been working on component creation and the next 7.2 release of Flowcode will have a number of features to make it much easier. We'll have more information available in the new year.

User avatar
QMESAR
Valued Contributor
Valued Contributor
Posts: 1287
Joined: Sun Oct 05, 2014 3:20 pm
Location: Russia
Has thanked: 384 times
Been thanked: 614 times

Re: Advise correct method for own component

Post by QMESAR »

That sounds really good looking forward to this :D

User avatar
QMESAR
Valued Contributor
Valued Contributor
Posts: 1287
Joined: Sun Oct 05, 2014 3:20 pm
Location: Russia
Has thanked: 384 times
Been thanked: 614 times

Re: Advise correct method for own component

Post by QMESAR »

Sorry double post

Post Reply