
7-6
Section
Details of BASIC Commands
190
pc eput
Syntax:
[<result> = ]
PC EPUT
#<common memory address> , <number>, “<pc format> {, <pc format>}”;
<numerical expression> {, <numerical expression>}
Description:
Statement. Writes data to the common memory area of the ASCII Unit.
Remarks:
<common memory address> gives the starting address in common memory area of where the data
should be written. It is an integer with a valid range of : [0…89].
<number> is the number of words of data to write. It is an integer value with a range of : [1…90].
<pc format> gives the format of the variables that are retrieved. For full details of these formats
see the
PC READ
statement.
<numerical expression> is any valid BASIC is any valid numerical expression with an integer
result in the range : [-32768…32767]. If the value of the numerical expression is not within this
range then no action will result.
The
PC EPUT
command can optionally return a <result> that can be assigned to a variable. This
<result> indicates the success, or otherwise of the
PC EPUT
command. If the <result> is 0 then the
command was successfully carried out and the data is written successfully. If the <result> is -1
then the
PC EPUT
could not be carried out because the common memory area was being used by
another
PC EPUT
or IORD #00xx command.
If the format string and the variable types do not match then a “FORMAT ERROR” (code B067)
will occur. Also if the format string specifies more memory than is allocated for writing in the
common memory area then a “FORMAT ERROR” (code B067) will result.
The data written to the common memory area by
PC EPUT
may be read by the IORD #00xx
command in the PLC program. this command is used to read up to 90 words of data from the
common data area of the ASCII Unit to the PLC. There is no synchronization between the
PC
EPUT
command in the BASIC program and the IORD #00xx command in the PLC program.
For a detailed description of how to use the
PC EPUT
statement and the IORD #00xx PLC
command refer to 6.3. Details of the Data Exchange Methods.
Examples:
PC EPUT #0, 4, “1H4, 1H4, 2H4”; A, B, C$
HEX 4 digits
HEX 4 digits
See also:
PC EGET
,
PC PUT
Summary of Contents for C200H-ASC11
Page 1: ...C200H ASC11 ASC21 ASC31 ASCII Units Operation Manual Revised June 2000...
Page 2: ...iv...
Page 4: ...vi...