EasyManuals Logo
Home>Omron>Industrial Equipment>SYSMAC FH Series

Omron SYSMAC FH Series User Manual

Omron SYSMAC FH Series
882 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #809 background imageLoading...
Page #809 background image
WWW.NNC.IR
Macro Reference
807
8
Appendices
Vision System FH/FZ5 Series
User’s Manual (Z340)
WritePlcMemory
Writes values in the PLC memory area.
Format
WritePlcMemory <ioIdent>, <area>, <channelOffset>, <channelCount>, <writeData()>
Parameter
Return value
None.
Description
Writes the amount of data specified in the <channelCount> parameter from the address offset by the amount
of the value specified in the <channelOffset> parameter, of the PLC area type specified in the <area>
parameter by using the communication module specified in the <ioIdent> parameter.
Before using this macro function to write data to the PLC memory area, execute the SetPlcData function to
set the data to be written.
In the <writeData()> parameter, specify the 1D integer array variable that stores the data to be written,
without adding element numbers but adding () to the variables.
This macro function cannot be used to write data to a PLC that is connected by other than the PLC link
communication module.
In the <area> parameter, specify the identification of the register that is set with the PLC link setting in the
system settings.
In the <channelCount> parameter, specify the size in channel units. The size of one integer type data item is
two channels (4 bytes), and thus to write one integer value, a one-element array should be prepared with the
<writeData()> parameter, and 2 should be specified in the <channelCount> parameter.
If a size larger than the array size specified in the <writeData()> parameter is specified in the
<channelCount> parameter, a "Subscript out of range" error will occur.
If an incorrect data type is specified for a parameter, a "Type mismatch" error will occur.
If a non-existent number, numerical value, or combination of data types or values is specified for a parameter,
an "Illegal function call" error will occur.
If the format is written incorrectly, such as writing the macro function name incorrectly, omitting a comma, or
omitting a half-width space, a "Syntax error" error will occur.
Writes the data to the data output area. Note that if the data is written to the response area, the response data
will be overwritten after the command processing.
Usage Cautions
• Before using this macro function to write data, always use the SetPlcData function to set the data to be
written. If the data is directly set in the <writeData()> parameter without using the SetPlcData function, the
correct data may not be set.
Parameter
name
Data type Description
<ioIdent>
Character
string type
Identification name of the communication module to be used (Reference: XList of I/O
Modules (p.341))
<area> Integer type Area type number of data output area to be written to.
<channelOffset>
Integer type Offset from beginning of data output area to address where writing is to start.
<channelCount>
Integer type Data size to write
<writeData()> Integer array Data to write

Table of Contents

Other manuals for Omron SYSMAC FH Series

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Omron SYSMAC FH Series and is the answer not in the manual?

Omron SYSMAC FH Series Specifications

General IconGeneral
BrandOmron
ModelSYSMAC FH Series
CategoryIndustrial Equipment
LanguageEnglish

Related product manuals