![background image](http://html.mh-extra.com/html/omron/sysmac-3g8f7-clk12-ev1/sysmac-3g8f7-clk12-ev1_operation-manual_1633421076.webp)
56
Library Functions
Section 4-1
4-1
Library Functions
This section describes the library functions used for the Control Link Support
Boards for PCI bus. Refer to
SECTION 3 Creating Applications Using the C
Functions
4-1-1
ClkOpen()
Board Open
Function
Opens the application interface and gets a CLK handle.
Call Format
PCLKHANDLE ClkOpen(BYTE byAppUnitAdr, INT *piRetErr);
Return Value
A CLK handle is returned if the function ends normally.
CLK_ERROR is returned if the function ends in an error. Detailed error infor-
mation is stored in piRetErr.
Description
Set a value between 1 and 15 for AppUnitAdr. Set 0 when it is not necessary
to set a specific application unit address. An unused unit address will be auto-
matically allocated.
The function will end in an error if a Controller Link Support Board is not
mounted.(Detailed error information = ERR_NO_CLKUNIT: No CLK Unit)
The function will end in an error if a handle cannot be obtained because of
insufficient memory. (Detailed error information = ERR_NO_MEMORY: Mem-
ory acquisition error)
The function will end in an error if the unit address specified in the argument is
not between 0 and 15. (Detailed error information = ERR_UNIT_ADDRESS:
Unit address range error)
Function name
Name
Function
Page
ClkOpen
Board Open
Opens the application interface and gets a
CLK handle.
ClkClose
Board Close
Closes the application interface and
releases the CLK handle.
ClkSendFins
FINS Message Send
Sends a FINS message.
ClkRecvFins
FINS Message Receive
Receives a FINS message.
ClkWriteDatalink
Data Link Data Write
Writes data to a data link area.
ClkReadDatalink
Data Link Data Read
Reads data from a data link area.
ClkGetNetworkStatus
Network Status Read
Reads the network status.
ClkGetRingStatus
Optical Ring Status Read
Reads the optical ring status.
ClkSetMessageOnArrival
FINS Message Reception
Notification Registration to
Window
Makes settings to notify the specified win-
dow with a Windows message when a
FINS message is received.
ClkSetThreadMessageOnArrival
FINS Message Reception
Notification Registration to
Thread
Makes settings to notify the specified
thread with a Windows message when a
FINS message is received.
ClkClearMessageOnArrival
FINS Message Reception
Notification Clear
Clears windows message notification
when a FINS message is received.
ClkGetLastError
Detailed Error Information
Acquire
Gets an error code generated when a
CLK library function is used.
Type
Variable name
Description
BYTE
byAppUnitAdr
Unit address allocated to the application
INT*
piRetErr
Error information for ClkOpen()
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: ......