Hello
Generally,it is no recommended to have waits occur inside of callback functions. Callbacks should return as fast as possible, and this avoids any events being missed. You should move any waiting code into a seperate thread. Its simple to do using CmtScheduleThreadPoolFunction(). You can check for the DATA_READY flag to get set, and then do a TCP_Read() before exiting from the thread.
I hope this helps
Bilal Durrani
NI
Bilal Durrani
NI