Вы здесь

DlnPlsCntSetEventCfg() Function

The DlnPlsCntSetEventCfg() function defines the event configuration for the specified Pulse Counter port.

Syntax
C/C++
DLN_RESULT DlnPlsCntSetEventCfg(
  HDLN handle, 
  uint8_t port, 
  uint8_t eventType, 
  uint32_t repeatInterval
);
Parameters
handle

A handle to the DLN-series adapter.

port

A number of the port.

eventType

Defines the event type parameter. There are 4 possible event types.

  • DLN_PLS_CNT_EVENT_NONE - 0

  • DLN_PLS_CNT_EVENT_OVERFLOW - 1

  • DLN_PLS_CNT_EVENT_MATCH - 2

  • DLN_PLS_CNT_EVENT_REPEAT - 4

repeatInterval

Defines the repeat interval parameter.

Return Value
DLN_RES_SUCCESS (0x00)

The function successfully configured events for the specified port.

DLN_RES_INVALID_PORT_NUMBER (0xA8)

The port number is not valid. Use the DlnPlsCntGetPortCount() function to find the maximum possible port number.

DLN_RES_INVALID_EVENT_TYPE (0xA9)

The specified event type is not valid.

DLN_RES_INVALID_EVENT_PERIOD (0xAC)

The specified event period is not valid.

Remarks

The DlnPlsCntSetEventCfg() function is defined in the dln_pls_cnt.h file.

Языки

Вход на сайт