Extract sub-string from left (left), C.7.3 extract sub-string from left (left) – Nematron Pointe Controller User Manual
Page 412
Appendix C: Ladder Diagram Block Reference
Pointe Controller User Guide
410
* Any Input, Output, or Memory tag except 32-bit Real (F) or Bit (X). For more information, see
“
Defining Input, Output, Memory tags
” on page 114
.
C.7.3 Extract sub-string from left (LEFT)
When used in a Ladder Diagram, the LEFT block extracts a sub-string of specified
length from the left end of a string (variable or literal) and sends the result to an
output.
Select the
tool (from the
String Blocks
toolbar) and click on a ladder rung to
insert the following block:
Once the block is inserted, you can double-click on it to
configure
it.
Functional Description
This block always passes the Enable input state (EN) through to the Enable Out
output state (ENO) without change; when EN becomes on, ENO is turned on, and
when EN becomes off, ENO is turned off.
When EN becomes on, the block function is executed: a sub-string of up to
specified Length (LEN) is extracted from the Input String (IN) and placed in the
Output String (OUT). The sub-string is extracted from the left end of IN.
For example:
IN: ‘Hello world. This is PointeControl.’
LEN: 8
OUT: ‘Hello wo’
The block function is executed every time the ladder is
scanned
, so long as EN
remains on. If EN becomes off, then OUT remains at its last calculated value until
EN becomes on and the block function is executed again.