Ny-Series Instructions Reference Manual (W560 - Omron NY532-5400 Reference Manual

Ny-series
Hide thumbs Also See for NY532-5400:
Table of Contents

Advertisement

The following figure shows a programming example. The contents of array variable abc[0] is written to
a file named 'Temp/f_name.bin.' Variable abc is an INT array variable with three elements.
LD
A
'Temp/f_name.bin'
TRUE
WriteVar[0]=abc[0]
WriteVar[1]=abc[1]
WriteVar[2]=abc[2]
Related System-defined Variables
Name
_Card1Ready
SD Memory Card
Ready Flag
*2
SD Memory Card Write
_Card1Protect
Protected Flag
*2
SD Memory Card Error
_Card1Err
Flag
*2
SD Memory Card
_Card1Access
Access Flag
_Card1PowerFail
SD Memory Card
Power Interruption Flag
*1 For the NJ/NX-series, it is a precondition that the SD Memory Card is physically inserted and mounted normally. For an
NY-series Controller, it is a precondition that the shared folder is detected by the Controller.
*2 These variables are not used for the NY-series Controller. They are fixed to FALSE.
*3 For the NJ/NX-series, this indicates an access to the SD Memory Card. For an NY-series Controller, this indicates an
access to the shared folder (Virtual SD Memory Card).

NY-series Instructions Reference Manual (W560)

FileWriteVar_instance
FileWriteVar
Execute
Done
FileName
Busy
abc
WriteVar
Error
OverWrite
ErrorID
The FileWriteVar instruction writes the value of variable
WriteVar to the file specified by FileName in the SD
Memory Card. The value is written in binary format.
Written.
INT#1234
INT#2345
INT#3456
Meaning
Data type
BOOL
BOOL
BOOL
BOOL
BOOL
ST
FileWriteVar_instance(A, 'Temp/f_name.bin', abc,
def
ghi
jkl
mno
File FileName = 'Temp/f_name.bin'
INT#1234
INT#2345
INT#3456
This flag indicates if the SD Memory Card can be accessed
by instructions and communications commands.
TRUE: Can be used.
FALSE: Cannot be used.
This flag indicates if the SD Memory Card is write protected
when it is inserted and ready to use.
TRUE: Write protected.
FALSE: Not write protected.
This flag indicates if an unspecified SD Memory Card (e.g.,
an SDHC card) is mounted or if the format is incorrect (i.e.,
not FAT16 or corrupted).
TRUE: Error.
FALSE: No error.
This flag indicates if the SD Memory Card is currently being
accessed.
TRUE: Being accessed.
FALSE: Not being accessed.
This flag indicates if an error occurred in completing pro-
cessing when power was interrupted during access
flag is not cleared automatically.
TRUE: Error.
FALSE: No error.
2 Instruction Descriptions
TRUE, def, ghi, jkl, mno);
Description
*1
*3
2
. This
2-1245

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents