2004RedSox
Programmer
Does anyone have any experience with using ZComm and it's OnDataAvailable event to receive data from a peripheral on the serial port (such as a Keithley Voltmeter with a SCPI RS232 connection)?
I originally sent a read command to the Keithley then had a 2 second delay, then read the data in using the ZComm object such as data = ZComm1->text.
This works on Win95 PC and my coworker had it working on a Win98 PC but it fails (hangs) on my Win98 PC.
I hear that it's not good to use delays in Windows programming so I tried to use Application->ProcessMessage() in my while delay loop.
The Application->ProcessMessages() gets called during the while(1) so Windows doesn't get hung.
It still hangs.
I originally sent a read command to the Keithley then had a 2 second delay, then read the data in using the ZComm object such as data = ZComm1->text.
This works on Win95 PC and my coworker had it working on a Win98 PC but it fails (hangs) on my Win98 PC.
I hear that it's not good to use delays in Windows programming so I tried to use Application->ProcessMessage() in my while delay loop.
The Application->ProcessMessages() gets called during the while(1) so Windows doesn't get hung.
It still hangs.