Скачиваний:
8
Добавлен:
10.07.2023
Размер:
867.4 Кб
Скачать

plc function ref - 34.42

AWT, AWA - Ascii WriTe, Ascii Write Append

 

 

 

 

 

 

 

 

 

A

 

AWT

 

 

 

 

 

 

 

 

ASCII WRITE

 

 

 

 

 

 

 

 

 

 

 

 

Channel

0

 

 

 

 

 

 

 

 

 

 

Source

ST11:9

 

 

 

 

 

Control

R6:3

 

 

 

 

 

 

 

 

 

 

String Length

14

 

 

 

 

 

Characters Sent

 

 

 

 

 

 

 

 

Description:

The AWT instruction will send a character string. In this example, when

 

’A’ goes from false to true, up to 14 characters will be sent from

 

’ST11:9’ to channel 0. This does not append any end of line charac-

 

ters.

 

 

The AWA function has a similar operation, except that the channel con-

 

figuration characters are added - by default these are ’CR’ and ’LF’.

Status Bits:

EN

enable - this will be set while the instruction is active

 

DN

done - this will be set after the string has been sent

 

ER

error bit - set when an error has occurred

 

UL

unload -

 

EM

empty - set if no string was found

 

EU

queue -

Registers:

POS

the number of characters sent instructions

Available on: Micrologix, PLC-5

34.2 DATA TYPES

The following table describes the arguments and return values for functions. Some notes are;

’immediate’ values are numerical, not memory addresses.

’returns’ indicates that the function returns that data value.

numbers between ’[’ and ’]’ indicate a range of values.

values such as ’yes’ and ’no’ are typed in literally.

plc function ref - 34.43

Table 1: Instruction Data Types

Function

Argument

Data Types

Edge Triggered

 

 

 

 

 

 

 

 

ABL

channel

immediate int [0-4]

yes

 

control

R

 

 

characters

returns N

 

 

 

 

 

ACB

channel

immediate int [0-4]

yes

 

control

R

 

 

characters

returns N

 

 

 

 

 

ACI

source

ST

no

 

destination

N

 

 

 

 

 

ACN

source A

ST

no

 

source B

ST

 

 

 

 

 

ACS

source

N,F,immediate

no

 

destination

N,F

 

 

 

 

 

ADD

source A

N,F,immediate

no

 

source B

N,F,immediate

 

 

destination

N,F

 

 

 

 

 

AEX

source

ST

no

 

index

immediate int [0-82]

 

 

number

immediate int [0-82]

 

 

destination

ST

 

 

 

 

 

AFI

 

 

no

 

 

 

 

AHL

channel

immediate int [0-4]

yes

 

AND mask

immediate hex [0000-ffff]

 

 

OR mask

immediate hex [0000-ffff]

 

 

control

R

 

 

 

 

 

AIC

source

N, immediate int

no

 

destination

ST

 

 

 

 

 

ARD

channel

immediate int [0-4]

yes

 

destination

ST

 

 

control

R

 

 

string length

immediate int [0-83]

 

 

characters read

returns N

 

 

 

 

 

plc function ref - 34.44

Table 1: Instruction Data Types

Function

Argument

Data Types

Edge Triggered

 

 

 

 

 

 

 

 

ARL

channel

immediate int [0-4]

yes

 

destination

ST

 

 

control

R

 

 

string length

immediate int [0-83]

 

 

characters read

returns N

 

 

 

 

 

ASC

source

ST

no

 

index

N, immediate

 

 

search

ST

 

 

result

R

 

 

 

 

 

ASN

source

N,F,immediate

no

 

destination

N,F

 

 

 

 

 

ASR

source A

ST

no

 

source B

ST

 

 

 

 

 

ATN

source

N,F,immediate

no

 

destination

N,F

 

 

 

 

 

AVE

file

#F,#N

yes

 

destination

F,N

 

 

control

R

 

 

length

N,immediate int

 

 

position

returns N

 

 

 

 

 

AWA

channel

immediate int [0-4]

yes

 

source

ST

 

 

control

R

 

 

string length

immediate int [0-82]

 

 

characters sent

returns N

 

 

 

 

 

AWT

channel

N, immediate int

yes

 

source

ST

 

 

control

R

 

 

length

immediate int [0-82]

 

 

characters sent

returns N

 

 

 

 

 

BSL

file

#B,#N

yes

 

control

R

 

 

bit address

any bit

 

 

length

immediate int [0-16000]

 

 

 

 

 

Соседние файлы в папке PLC