Allen-Bradley MicroLogix 1200 Reference Manual page 285

Hide thumbs Also See for MicroLogix 1200:
Table of Contents

Advertisement

Entering Parameters
Enter the following parameters when programming this instruction:
• Source - The contents of this location are converted to an integer
value.
• Destination - This is the location which receives the result of the
conversion. The data range is from -32,768 to 32,767 if the destination
is a word and from -2,147,483,648 to 2,147,483,647 if the destination is
a long word.
Addressing Modes and File Types can be used as shown below:
Table 20.16 ACI Instruction Valid Addressing Modes and File Types
For definitions of the terms used in this table see Using the Instruction Descriptions on page4-2.
Data Files
Parameter
Source
Destination
• •
• •
(1) The Control data file is the only valid file type for the Control Element.
Instruction Operation
The controller searches the source (file type ST) for the first character
between 0 and 9. All numeric characters are extracted until a non-numeric
character or the end of the string is reached. Action is taken only if
numeric characters are found. The string length is limited to 82 characters.
Commas and signs ( +, -) are allowed in the string. However, only the
minus sign is displayed in the data table.
This instruction sets the following math flags in the controller status file:
Math Flag
S:0/1
Overflow (V)
S:0/2
Zero (Z)
S:0/3
Sign (S)
S:5/0
Overflow Trap
S:5/15
ASCII String
Manipulation Error
(1)
Function Files
Description
Flag is set if the result is outside of the valid range.
Flag is set if the result is zero.
Flag is set if the result is negative.
Flag is set when the Overflow flag (S:0/1) is set.
Flag is set if the Source string exceeds 82 characters.
When S:5/15 is set, the Invalid String Length Error (1F39H) is
written to the Major Error Fault Code (S:6).
ASCII Instructions
20-17
Address
Address
Mode
Level
• •
Publication 1762-RM001C-EN-P

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Micrologix 1500

Table of Contents