how to identify which one is removed?

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

cross mob
fumac_3907466
Level 1
Level 1

If I add two usb in the PC.

CCyUSBDevice*   m_pCyUSBDevice1;

CCyUSBDevice*   m_pCyUSBDevice2;

m_pCyUSBDevice1->Open(0);

m_pCyUSBDevice2->Open(1);

However, if remove one usb.

m_pCyUSBDevice1->Isopen = true;

m_pCyUSBDevice2->Isopen = true;

1. How to identify which one is remove? Why those are all opened?

2. If the removed one is inserted, how to open it?  I don't know which one?

3. Could you help to descripe the solution by codes more detail?

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

Hello,

Please refer to Example#1 under the CCyUSBDevice class definition of the CyAPI.PDF (Present as part of the FX3 SDK) document for details on handling the PnP events.

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,

Please refer to Example#1 under the CCyUSBDevice class definition of the CyAPI.PDF (Present as part of the FX3 SDK) document for details on handling the PnP events.

Best regards,

Srinath S

0 Likes