Welcome to our new forum
All users of the legacy CODESYS Forums, please create a new account at account.codesys.com. But make sure to use the same E-Mail address as in the old Forum. Then your posts will be matched.
Close
I have made an analog function block that will do the analog stuff. If it is possible i want to set and reset the function block with a digitial signal from a button. can anyone give me some advice on how to do this? I can't really find anything that will make me able to combine the digital and analog signals.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hi.
I sugest to do it in FBD using SEL function block. It works like IF function. It has got 3 inputs and 1 output. First input is a trigger (your bool varable). When bool=FALSE, then output takes 2 input, when bool=TRUE, then output takes 3 input. So solution is like this. 1in=bool variable, 2in=var_in_out, 3in=your_analog_signal, out=var_in_out. It will work like a buffer.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
I have made an analog function block that will do the analog stuff. If it is possible i want to set and reset the function block with a digitial signal from a button. can anyone give me some advice on how to do this? I can't really find anything that will make me able to combine the digital and analog signals.
Hi.
I sugest to do it in FBD using SEL function block. It works like IF function. It has got 3 inputs and 1 output. First input is a trigger (your bool varable). When bool=FALSE, then output takes 2 input, when bool=TRUE, then output takes 3 input. So solution is like this. 1in=bool variable, 2in=var_in_out, 3in=your_analog_signal, out=var_in_out. It will work like a buffer.