Advantech PCI-1682U Manual de usuario Pagina 47

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 104
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 46
41 PCI-1680U/1682U User Manual
Chapter 4 Software Requirements
4.3.6 SetCommMask
Users can use this interface to set event for CAN port.
Users have to call WaitCommEvent function to wait event.
Users can call GetCommMask to get the current event set before.
If users do not set any of the supported event types, the real event type will be zero.
In this case, if WaitCommEvent is called, the call will be returned and the event type
returned will be zero.
Syntax
BOOL SetCommMask(
HANDLE hDevice,
DWORD dwEvtMask
);
Parameters
Return Value
Successful: return non-zero values. Unsuccessful: return zero value. Please call Get-
LastError function.
Example
BOOL bSuccess = SetCommMask(hDevice, EV_ERR | EV_RXCHAR);
See Also
WaitCommEvent
GetCommMask
Note! Events supported at present are only:
Type Direction
EV_ERR Error
EV_RXCHAR Receive one frame data
Name Direction Description
hDevice Input Handle of the device which was opened.
dwEvtMask Input Event type.
Vista de pagina 46
1 2 ... 42 43 44 45 46 47 48 49 50 51 52 ... 103 104

Comentarios a estos manuales

Sin comentarios