17.02.2013 Views

Kuhnke Electronics Instruction Manual

Kuhnke Electronics Instruction Manual

Kuhnke Electronics Instruction Manual

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Function Libraries<br />

To set up a thread:<br />

To install a program module as a thread you must run the<br />

following code to identify the module:<br />

Index := INDEXOF (module name);<br />

Afterwards, the following function just needs to be run<br />

once in order to set up the thread:<br />

CREATE_THREAD (index);<br />

FUNCTION CREATE_THREAD : BOOL<br />

VAR_INPUT<br />

NPOU_IDparam: WORD;<br />

TSLICE: WORD;<br />

RUNS: WORD;<br />

END_VAR<br />

VAR<br />

END_VAR<br />

The value returned by the function tells you something<br />

about the thread status.<br />

Value returned Explanation<br />

0 not installed, no thread available<br />

1 installed as thread #1<br />

72 E 700 GB

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!