fasavard

Hi, 

 

I am quite new with the software so bear with me for the newbie question. 

 

I am trying to create my first function to use in a ladder project. 

So to test the procedure, I am trying to create a NAND function. Here's the step so far I do:
  1. Add Function
  2. In that new function, I add a Contunation1 and a Continuation 2 node that Hook in a AND function, then goes through an inverter to a Connection node. 
  3. Then I add the NAND function into my FD program
So far, I only get one node, with only an output. How do we assign with input is thought wich node? 

I have attached my project file to this Post 
Reply 0 0
thiagoralves
You don't use connections to define inputs or outputs of a function. You need to create variables and under "Class" you select either Input or Output. Then, that variable will be the input or output of your function. Naturally, functions already have one output defined which is the return value. FunctionBlocks don't have any output defined, so you need to create variables and assign them properly. Attached is an example project with the NAND function working.
Reply 1 0
r.breda

Hi Thiago,

I wanted to open the project you saved here, but unfortunately I got this error code: "Chosen folder doesn't contain a program. It's not a valid project!"

Could I have the entire folder that contains the project? I would like to write a program in SFC language.

For each step, I would assign a Function Block in which a smaller program of its own is executed.

It would be important to synchronize the input and output variables with the Main(SFC) program.Would that be possible?

Thank you!

Richard

Reply 0 0
thiagoralves
This file is for an older version of the editor. You can convert this file to the new format by just creating a blank project and then replacing the plc.xml file inside your project folder with this one.

About your SFC question, yes, you can do that.
Reply 0 0
Reply