168
3 DETAILS OF FUNCTION
3.2 MELSEC Data Link Functions
mdSendEx
This function writes devices in a batch.
■
Format
long mdSendEx(long lPath, long lNetNo, long lStNo, long lDevType, long lDevNo, long* plSize, short* psData)
■
Argument
■
Description
• This function writes data for the size specified to the write data size (plSize) from a device specified to the device type
(lDevType) and the start device number (lDevNo) of a module specified to the network number (lNetNo) and the station
number (lStNo).
• It checks the arguments and verifies whether the a size determined by the arguments is within the device memory
range.
• When the write data size exceeds the device range, a writable size is returned to the write data size (plSize).
• Note that the extension comment information will be deleted when the data is written to the block to which an extension
comment is assigned (extension file register).
■
Return value
■
Relevant functions
• Page 154 mdOpen
• Page 146 mdClose
• Page 165 mdReceiveEx (Device batch read function)
Argument
Name
Description
IN/OUT
lPath
Path of channel
Specify the path of the opened channel.
IN
lNetNo
Network number
Specify the network number of target module.
IN
lStNo
Station number
Specify the station number of target module.
IN
lDevType
Device type
Specify the device type for device to be written in batch.
IN
lDevNo
Start device number
Specify the start device number to be written in batch.
(For bit devices, specify the device number in multiples of 8.)
IN
plSize
Write data size
Specify the write data size in byte units.
(Specify the value in multiples of 4 when a double-word device (LZ, LTN, LCN, LSTN) is
specified, or specify the value in multiples of 2 when a word device or bit device is
specified. If the value other than that is specified, the size error (-5) will occur.)
IN/OUT
psData
Write data storage destination
Specify the storage destination (address) of write data.
Reserve a continuous area for the write data storage destination.
IN
Return value
Description
0 (0000H)
Normal
Other than 0
Error
For details on the error, refer to the following chapter.
Содержание MELSEC iQ-R C
Страница 1: ...MELSEC iQ R C Controller Module Programming Manual ...
Страница 2: ......
Страница 201: ...I 199 MEMO ...
Страница 203: ...I 201 MEMO ...
Страница 207: ......