![background image](http://html.mh-extra.com/html/omron/sysmac-3g8f7-clk12-ev1/sysmac-3g8f7-clk12-ev1_operation-manual_1633421079.webp)
59
Library Functions
Section 4-1
4-1-5
ClkWriteDatalink()
Data Link Data Write
Function
Writes data to a data link area.
Call Format
INT ClkWriteDatalink(PCLKHANDLE hCLK, PEMCLKADDRESS pEmAd-
dress, LPWORD lpWriteData, DWORD dwSize);
Return Value
CLK_SUCCESS is returned if the function ends normally.
CLK_ERROR is returned if the function ends in an error. Detailed error infor-
mation can be obtained using ClkGetLastError().
Description
Refer to
Structure Descriptions
for information on the starting address struc-
ture for writing data.
The function will end in an error if a data size of 0 is specified for write data
size specified as the argument. (Detailed error information =
ERR_WRITE_BUFFER_SIZE: Write data size error)
The function will end in an error if access is requested to 3 or more different
memory areas for one CLK handle. (Detailed error information =
ERR_MEMORY_AREA: Multiple memory area specification error)
The function will end in an error if a memory name specified in the argument
does not exist. (Detailed error information = ERR_NO_MEM_TYPE: No such
memory)
4-1-6
ClkReadDatalink()
Data Link Data Read
Function
Reads data from a data link area.
Call Format
INT ClkReadDatalink(PCLKHANDLE hCLK, PEMCLKADDRESS pEmAd-
dress, LPWORD lpReadData, DWORD dwSize);
Return Value
CLK_SUCCESS is returned if the function ends normally.
CLK_ERROR is returned if the function ends in an error. Detailed error infor-
mation can be obtained using ClkGetLastError().
Description
Refer to
Structure Descriptions
for information on the starting address struc-
ture for reading data.
The function will end in an error if 0 is specified for the read data size speci-
fied as the argument. (Detailed error information =
ERR_READ_BUFFER_SIZE: Read data size error)
Type
Variable name
Description
PCLKHANDLE
hCLK
The CLK handle obtained with ClkO-
pen()
PEMCLKADDRESS
pEmAddress
Pointer to the starting address struc-
ture for writing data
LPWORD
lpWriteData
Pointer to the buffer to store the write
data
DWORD
dwSize
Write data size (unit: words)
Arguments
Type
Variable name
Description
PCLKHANDLE
hCLK
The CLK handle obtained with ClkO-
pen()
PEMCLKADDRESS
pEmAddress
Pointer to the starting address struc-
ture for reading data
LPWORD
lpWriteData
Pointer to the buffer to store the read
data
DWORD
dwSize
Read data size (unit: words)
Arguments
Summary of Contents for SYSMAC 3G8F7-CLK12-EV1
Page 2: ......
Page 4: ...iv ...
Page 20: ...xx Conformance to EC Directives 6 ...
Page 48: ...28 Applications Precautions Section 1 4 Example CX Programmer Response Timeout Setting ...
Page 68: ...48 Backup Power Supply Wiring Optical Ring Systems Only Section 2 4 ...
Page 74: ...54 Using the C Library Section 3 2 ...
Page 110: ...90 Changing the Data Link Tables with Active Data Links Section 5 5 ...
Page 187: ......