Application programming interface.
More...
|
| CAEN_MCA_HANDLE | CAEN_MCA_OpenDevice (const char *path, int32_t *retcode, int32_t *index) |
| |
| void | CAEN_MCA_CloseDevice (CAEN_MCA_HANDLE handle) |
| |
| CAEN_MCA_HANDLE | CAEN_MCA_GetAncestorHandle (CAEN_MCA_HANDLE handle, CAEN_MCA_HandleType_t handleType) |
| |
| CAEN_MCA_HANDLE | CAEN_MCA_GetChildHandle (CAEN_MCA_HANDLE handle, CAEN_MCA_HandleType_t handleType, int32_t index) |
| |
| CAEN_MCA_HANDLE | CAEN_MCA_GetChildHandleByName (CAEN_MCA_HANDLE handle, CAEN_MCA_HandleType_t handleType, const char *name) |
| |
| int32_t | CAEN_MCA_GetData (CAEN_MCA_HANDLE handle, CAEN_MCA_DataType_t dataType, uint64_t dataMask,...) |
| |
| int32_t | CAEN_MCA_SetData (CAEN_MCA_HANDLE handle, CAEN_MCA_DataType_t dataType, uint64_t dataMask,...) |
| |
| int32_t | CAEN_MCA_SendCommand (CAEN_MCA_HANDLE handle, CAEN_MCA_CommandType_t cmdType, uint64_t cmdMaskIn, uint64_t cmdMaskOut,...) |
| |
| int32_t | CAEN_MCA_WaitEvent (CAEN_MCA_HANDLE handle, CAEN_MCA_HANDLE *eventHandle) |
| |
Application programming interface.
◆ CAEN_MCA_OpenDevice()
| CAEN_MCA_HANDLE CAEN_MCA_OpenDevice |
( |
const char * |
path, |
|
|
int32_t * |
retcode, |
|
|
int32_t * |
index |
|
) |
| |
Connect to a device. The device should be closed using CAEN_MCA_CloseDevice().
- Parameters
-
| [in] | path | URL to device in the form "\<scheme\>://\<domain\>[:\<port\>][/connection?\<parameters\>]":
scheme (required): can be "eth" (ethernet) "usb" (usb) and "opt" (optical)
domain (required): host to connect (can be IP address or hostname)
port (optional): port to use for connection. Default is 56342. Should be used only for Hexagon boards.
parameters (optional): list of parameters ampersand-separated. Supported parameters are "link=<number>", "conetnode=<number>", "vmeaddress=<number>" and "serial=<number>". The latter is supported only for Hexagon boards. Except for "eth" scheme, one and only one between "serial" and "link" must be specified.
|
| [out] | retcode | CAEN_MCA_RetCode_Success (0) in case of success. Error codes specified in CAEN_MCA_RetCode_t. Can be NULL. |
| [out] | index | the index of the opened device. Can be used as index to retrieve the returned handle later using CAEN_MCA_GetChildHandle(). Can be NULL. |
- Returns
- Handle of the device.
NULL in case of error.
- Examples:
- examples_board_control.c.
◆ CAEN_MCA_CloseDevice()
◆ CAEN_MCA_GetAncestorHandle()
Get an ancestor handle. Iterate over the ancestor of a given handle and return the first handle of the requested type.
- Parameters
-
| [in] | handle | the handle. |
| [in] | handleType | the ancestor handle type. |
- See also
- DATAMASK_HANDLE_TYPE
- Returns
- Handle of the ancestor.
NULL in case of error.
- Examples:
- examples_handles.c.
◆ CAEN_MCA_GetChildHandle()
◆ CAEN_MCA_GetChildHandleByName()
◆ CAEN_MCA_GetData()
◆ CAEN_MCA_SetData()
◆ CAEN_MCA_SendCommand()
◆ CAEN_MCA_WaitEvent()
Wait for events.
- Warning
- Not yet implemented.
- Parameters
-
| [in] | handle | the handle. |
| [out] | eventHandle | the type of command. |
- Returns
- CAEN_MCA_RetCode_Success (0) in case of success. Error codes specified in CAEN_MCA_RetCode_t.