Quantcast
Channel: LabWindows/CVI topics
Viewing all articles
Browse latest Browse all 5357

Acquire data continuously using InstallComCallback

$
0
0

Hi

I am trying to aquire data (8 Bytes) every 20ms over RS232 using InstallComCallback.

This is how I am trying to do it :

 

// Open and Configure Com port 1
OpenComConfig (1, "", 9600, 0, 8, 1, 512, 512);

 

SetCTSMode (1, LWRS_HWHANDSHAKE_OFF);

FlushInQ (1);
FlushOutQ (1);

 

InstallComCallback (1, LWRS_RXFLAG, 0, (int)EventChar[0] , Event_Char_Detect_Func, 0); // Actuall event mask and function are some what different 

while(1)

{

          processsystemevent();        //bare with typo :/

}

 

when I am running it. It is working fine for 4850 (apprx) data set. after that its stopping automatically

I want to run this callback for really long time (infinte loop) with stopping/ getting inturrept by any means.

Is it inturrept related problem ??

How to solve it ??

Thanks in advance 

 

Ankur Verma


Viewing all articles
Browse latest Browse all 5357


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>