Publication 1756-RM004B-EN-P - October 2000
5-14 Serial Port API
MVIsp_SetDTR
Syntax:
int MVIsp_SetDTR(int comport, int state);
Parameters:
comport port for which DTR is to be changed
state desired state
Description:
This function allows the state of the DTR signal to be controlled.
comport must be previously opened with MVIsp_Open.
state is the desired state of the DTR signal. Valid values for state are
ON and OFF.
Note: If DTR/DSR handshaking is enabled, changing the state of the
DTR signal with MVIsp_SetDTR will cause unpredictable results.
Return Value:
MVI_SUCCESS the DTR signal was set successfully
MVI_ERR_NOACCESS comport has not been opened
MVI_ERR_BADPARAM invalid state
Example:
if (MVIsp_SetDTR(COM1, ON) != MVI_SUCCESS)
printf(“Set DTR failed\n”);
See Also:
MVIsp_GetDTR