Hi
I have this feature request that should not be to complicated to implement
but will make Programming with flowcode much easier .
It has to do with Macro Parameters , now I try to explain .
A Macro that can do different Tasks, say if input parameter (Byte)
Is set to 0 will read the external device , if set to 1 it will write , if 2 will configure the device
and so on , now in a macro you can have more then one of these task selectors and it is very
likely that after a few days you forget what the values where doing exactly .
So one have to go through the macro again every time which is very time consuming .
Can we have an option for the parameters that if enabled , will
make it possible to assign a name to a specific value
Something like Html drop down menu . where you have the value and the name to be displayed .
Below is an Example from Labview .
Thanks in Advance
Alan
Macro Parameters
Moderator: Benj
- Alan_37
- Posts: 179
- Joined: Sun May 01, 2016 8:36 pm
- Has thanked: 51 times
- Been thanked: 54 times
- Contact:
Macro Parameters
- Attachments
-
- Drop down.png
- (1.96 KiB) Downloaded 3150 times
-
- Drop 2.png
- (8.4 KiB) Downloaded 3150 times
- Steve
- Matrix Staff
- Posts: 3422
- Joined: Tue Jan 03, 2006 3:59 pm
- Has thanked: 114 times
- Been thanked: 422 times
- Contact:
Re: Macro Parameters
Hi Alan,
One way to implement this now is to use global constants. The attached image and program should help.
One way to implement this now is to use global constants. The attached image and program should help.
- Attachments
-
- constants as parameters.fcfx
- (5.23 KiB) Downloaded 256 times
-
- constants as parameters.png
- (39.5 KiB) Downloaded 3136 times
- Alan_37
- Posts: 179
- Joined: Sun May 01, 2016 8:36 pm
- Has thanked: 51 times
- Been thanked: 54 times
- Contact:
Re: Macro Parameters
hi Steve
yes that is a great idea , although now i realize
that using a variable for every value will increase the
ram usage of the micro controller .
do you think there is a solution to that ?
thanks for your support
yes that is a great idea , although now i realize
that using a variable for every value will increase the
ram usage of the micro controller .
do you think there is a solution to that ?
thanks for your support
-
- Valued Contributor
- Posts: 2045
- Joined: Wed Aug 27, 2008 10:31 pm
- Location: Netherlands
- Has thanked: 553 times
- Been thanked: 1081 times
- Contact:
Re: Macro Parameters
Constants do not use additional controller resources (ram/flash)
“Integrity is doing the right thing, even when no one is watching.”
― C.S. Lewis
― C.S. Lewis
- Alan_37
- Posts: 179
- Joined: Sun May 01, 2016 8:36 pm
- Has thanked: 51 times
- Been thanked: 54 times
- Contact:
Re: Macro Parameters
Hi kersing
Did't know that, so that is a very good work around .
Will implement that for sure .
Thanks
Did't know that, so that is a very good work around .
Will implement that for sure .
Thanks