Machine Vision Camera SDK (C) Developer Guide
printf("Press a key to exit.\n");
WaitForKeyPress();
return 0;
}
MV_CAML_SetGenCPTimeOut
Set the waiting time of serial port operation.
API Definition
int MV_CAML_SetGenCPTimeOut(
void
*handle,
unsigned int
nMillisec
);
Parameters
handle
[IN] Device handle, which is returned by MV_CC_CreateHandle or
MV_CC_CreateHandleWithoutLog .
nMillisec
[IN] Waiting time of serial port operation, unit: ms
Return Value
Return MV_OK(0) on success, and return Error Code on failure.
Example
The following sample code is for reference only.
#include "MvCameraControl.h"
#include <stdio.h>
#include <Windows.h>
#include <conio.h>
// Wait for entering
void WaitForKeyPress(void)
{
while(!_kbhit())
{
Sleep(10);
}
_getch();
}
int main()
{
int nRet = MV_OK;
void* handle = NULL;
84
    "