What's the difference between using the Visual Studio's SerialPort dbgPort = new SerialPort(); dbgPort .Open(); and the Cypress CyOpen(); ?

Tip / Sign in to post questions, reply, level up, and achieve exciting badges. Know more

cross mob
Anonymous
Not applicable

What's the difference between using the Visual Studio's SerialPort dbgPort = new SerialPort(); dbgPort .Open(); and the Cypress CyOpen(); ?

(USB Serial Library API - DllImport("cyusbserial.dll",)

0 Likes
1 Solution
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello,

The SerialPort.Open() method opens a COM port device whereas the CyOpen() API is only used to open a Cypress USB-Serial device to perform vendor specific operations. The CyOpen() API cannot be used to communicate with the COM port device. This API is used when one of the interfaces of the device is defined as a vendor interface.

The use of CyOpen() API can be understood from the example applications that come with the USB-Serial SDK.

Best regards,

Srinath S

View solution in original post

0 Likes
1 Reply
SrinathS_16
Moderator
Moderator
Moderator
1000 replies posted 750 replies posted 500 replies posted

Hello,

The SerialPort.Open() method opens a COM port device whereas the CyOpen() API is only used to open a Cypress USB-Serial device to perform vendor specific operations. The CyOpen() API cannot be used to communicate with the COM port device. This API is used when one of the interfaces of the device is defined as a vendor interface.

The use of CyOpen() API can be understood from the example applications that come with the USB-Serial SDK.

Best regards,

Srinath S

0 Likes