Hello,
For AND block one can use variable number of inputs.
I would like to create a function block with adjustable number of inputs e.g. of INT (or BOOL) type.
How to handle it inside the block?
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In FBD you only can make a fixed number of inputs as you will have to declare them.
However you can make inputs and dont use them. you can set them in the declaration to a value, and when not used it will default to it.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
shooter hat geschrieben:
In FBD you only can make a fixed number of inputs as you will have to declare them.
However you can make inputs and dont use them. you can set them in the declaration to a value, and when not used it will default to it.
So how is the "AND" block made? Even if it is a function (and not a function block), it handles multiple inputs as defined by a user.
I am looking for a similar solution.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
and block is made just as you say it item1 AND item2 AND item3 etc.
when doing your own functions you can not add them while programming, so do it while defining the FB. you do not have to use all inputs. (you can define the state of them.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello,
For AND block one can use variable number of inputs.
I would like to create a function block with adjustable number of inputs e.g. of INT (or BOOL) type.
How to handle it inside the block?
In FBD you only can make a fixed number of inputs as you will have to declare them.
However you can make inputs and dont use them. you can set them in the declaration to a value, and when not used it will default to it.
So how is the "AND" block made? Even if it is a function (and not a function block), it handles multiple inputs as defined by a user.
I am looking for a similar solution.
and block is made just as you say it item1 AND item2 AND item3 etc.
when doing your own functions you can not add them while programming, so do it while defining the FB. you do not have to use all inputs. (you can define the state of them.