13.07.2015 Views

1766-RM001A-EN-P MicroLogix 1400 Programmable Controllers ...

1766-RM001A-EN-P MicroLogix 1400 Programmable Controllers ...

1766-RM001A-EN-P MicroLogix 1400 Programmable Controllers ...

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.

ASCII Instructions 387ExampleI:110If input slot 1, bit 10 is set, search the stringin ST52:80 starting at the 36th character, forthe string found in ST38:40. In this example,the position result is stored in N10:0.ASCString SearchSource ST38:40Index 35String Search ST52:80Result N10:0Error ConditionsThe following conditions cause the controller to set the ASCII Error bit(S:5/15).• Source string length is less than 1 or greater than 82.• Index value is less than 1 or greater than 82.• Index value is greater than Source string length.The destination is not changed in any of the above conditions. When theASCII String Manipulation Error bit (S:5/15) is set, the Invalid StringLength Error (1F39H) is written to the Major Error Fault Code word (S:6).ASR - ASCII StringCompareASRASCII String CompareSource A ST10:8Source B ST10:9Instruction Type: inputExecution Time for the ASR InstructionControllerWhen Instruction Is:TrueFalse<strong>MicroLogix</strong> <strong>1400</strong> 4.8596 µs 0.2016 µsUse the ASR instruction to compare two ASCII strings. The controllerlooks for a match in length and upper/lower case characters. If twostrings are identical, the rung is true; if there are any differences, the rungis false.Entering ParametersEnter the following parameters when programming this instruction:• Source A is the location of the first string used for comparison.• Source B is the location of the second string used for comparison.Publication <strong>1766</strong>-<strong>RM001A</strong>-<strong>EN</strong>-P - October 2008

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

Saved successfully!

Ooh no, something went wrong!